Nieuwsbrief koppelen aan eigen gemaakt inschrijfformulier

Overzicht Reageren

Sponsored by: Vacatures door Monsterboard

-- R --

-- R --

21/12/2012 12:41:32
Quote Anchor link
Ik zit hier al een tijdje mee te stoeien om deze korte tutorial uit te voeren.
http://support.wysija.com/knowledgebase/plugin-form-integrate/

Graag zou ik willen om bovenstaande link te combineren met mijn eigen inschrijfformulier:

Code (php)
PHP script in nieuw venster Selecteer het PHP script
1
2
3
4
5
6
7
8
9
10
11
<div class="blok4">
                <h3>Nieuwsbrief</h3>
                <form action="formulier.php" id="nieuwsbrief">
                <input name="white_box" type="text" class="vak" size="20" onclick="this.value='';" onblur="this.value=!this.value?'Naam..':this.value;" value="Naam.." />
                <input name="white_box" type="text" class="vak" size="20" onclick="this.value='';" onblur="this.value=!this.value?'E-mailadres..':this.value;" value="E-mailadres.." />
                <input name="submit" type="button" class="inschrijven" value="Inschrijven" />
                <input type="hidden" name="ie" value="ISO-8859-1" />
                <input type="hidden" name="cof" value="FORID:10" />
                <input type="hidden" name="cx" value="partner-pub-5563407691970865:t3e0y89u7in" />
                </form>
</div>
Gewijzigd op 21/12/2012 12:42:46 door -- R --
 
PHP hulp

PHP hulp

18/04/2024 15:05:05
 
Max -

Max -

21/12/2012 12:47:47
Quote Anchor link
En wat is dus precies je probleem?
 
-- R --

-- R --

21/12/2012 12:51:55
Quote Anchor link
Max - op 21/12/2012 12:47:47:
En wat is dus precies je probleem?


Om onderstaande code te koppelen, maar zou niet weten hoe..
Code (php)
PHP script in nieuw venster Selecteer het PHP script
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
function processMyForm(){
 
    //you could make some validation even though validation
    //is also processed in our function
    $myEmailVariable=$_POST['myEmailVariable'] ;
    $myListId1=$_POST['myListId1'] ;
    $myListId2=$_POST['myListId2'] ;
 
    //in this array firstname and lastname are optional
    $userData=array(
        'email'=>$myEmailVariable,
        'firstname'=>$firstname,
        'lastname'=>$lastname);
    $data=array(
      'user'=>$userData,
      'user_list'=>array('list_ids'=>array($myListId1,$myListId2))
    );
 
    $userHelper=&WYSIJA::get('user','helper');
    $userHelper->addSubscriber($data);
    //this function will add the subscriber to wysija
 
    //if double optin is on it will send a confirmation email
    //to the subscriber
 
    //if double optin is off and you have an active automatic
    //newsletter then it will send the automatic newsletter to the subscriber
}
add_action('init','processMyForm') ;
 
- SanThe -

- SanThe -

21/12/2012 17:23:08
Quote Anchor link
<input name="white_box" type="text"
<input name="white_box" type="text"

Twee keer dezelfde name?
Gaat vast niet werken.
 
-- R --

-- R --

21/12/2012 20:01:26
Quote Anchor link
- SanThe - op 21/12/2012 17:23:08:
<input name="white_box" type="text"
<input name="white_box" type="text"

Twee keer dezelfde name?
Gaat vast niet werken.


Los daar van, had ik inderdaad over het hoofd gezien, moet ik hem toch zien te koppelen
 



Overzicht Reageren

 
 

Om de gebruiksvriendelijkheid van onze website en diensten te optimaliseren maken wij gebruik van cookies. Deze cookies gebruiken wij voor functionaliteiten, analytische gegevens en marketing doeleinden. U vindt meer informatie in onze privacy statement.