[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
[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
[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
[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
[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
[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
[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
[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
[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 - AJAX Poller creating tables but then error?
Page 1 of 2

AJAX Poller creating tables but then error?

PostPosted: Wed Dec 05, 2007 11:19 am
by maxi

PostPosted: Wed Dec 05, 2007 4:47 pm
by Batalf

PostPosted: Wed Dec 05, 2007 5:14 pm
by maxi

PostPosted: Wed Dec 05, 2007 5:16 pm
by Batalf

PostPosted: Wed Dec 05, 2007 5:19 pm
by maxi

PostPosted: Wed Dec 05, 2007 5:21 pm
by Batalf

PostPosted: Wed Dec 05, 2007 5:27 pm
by maxi

PostPosted: Wed Dec 05, 2007 5:28 pm
by Batalf
You can also make it dynamic

if you open the url like this:

ajax-poller.php?pollerId=1

and then change

$pollerId=1

to

$pollerId = $_GET['pollerId']

PostPosted: Wed Dec 05, 2007 5:29 pm
by maxi
Excellent! :)

Thanks ever so much Alf! 8)

PostPosted: Wed Dec 05, 2007 5:36 pm
by Batalf
You should also remember to include some sort of authentication in the poller admin page.

It could be as simple as

<?php

if(!isset($_GET['password']) || $_GET['password']!='myPassword') {
die("Access denied");
}

?>

at the top of the page.

You should of course change "myPassword" to something of your own.

Then you open the admin page by adding ?password=myPassword to the url.

PostPosted: Wed Dec 05, 2007 5:41 pm
by maxi
Done! :)

PostPosted: Thu Dec 06, 2007 10:18 am
by maxi
I've added the password bit and can enter adding ?password=<myPassword> but if I click on "New" or any previous polls it gives me Access denied?

PostPosted: Thu Dec 06, 2007 10:23 am
by Batalf

PostPosted: Thu Dec 06, 2007 10:30 am
by maxi

PostPosted: Thu Dec 06, 2007 10:31 am
by Batalf
No, that shouldn't cause any problems either. There shouldn't be any direct links to adm-poller.php. I think I've used $_SERVER['PHP_SELF']