[phpBB Debug] PHP Notice: in file /includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
www.dhtmlgoodies.com • View topic - Multiple Forms with Ajax Poller
Advertisement

Multiple Forms with Ajax Poller

Moderators: Calcifer, slothy

Multiple Forms with Ajax Poller

Postby kent3800 » Tue Jun 24, 2008 10:15 am

Is there a way to identify the Ajax poller by <div> element rather than by form element? It seems that if you have multiple forms on a page this tag needs to be altered:

FROM:

<a href="#" onclick="castMyVote(<? echo $pollerId; ?>,document.forms[0])"><img src="/survey/images/vote_button.gif" border="0"></a>

TO:

<a href="#" onclick="castMyVote(<? echo $pollerId; ?>,document.forms[2])"><img src="/survey/images/vote_button.gif" border="0"></a>

I am trying to include the poller with a php include but I sometimes have a different number of forms on a page i.e. search, contact, newsletter etc.

If it is possible to identify the poller via some other method please let us know.

Thanks! Great Poll!
kent3800
 
Posts: 3
Joined: Tue Jun 24, 2008 9:57 am

Here is the multiple form solution

Postby kent3800 » Tue Jun 24, 2008 5:54 pm

kent3800
 
Posts: 3
Joined: Tue Jun 24, 2008 9:57 am


Return to General questions regarding AJAX scripts

Who is online

Users browsing this forum: No registered users and 4 guests

cron