View Full Version : Resolved trying to get ajax to work with perl.

06-13-2009, 02:19 PM

Resolved: I don't now know why I couldn't get it to work. all ticketyboo now.

I have a form with three textboxes. It calls another file (query.php), which queries the db and populates the textbox if there is a match after 4 chars have been entered. works fine in php but for the fact that it isn't inside my perl login page (containing an iframe with the script) and therefore is not within the server-side session.

When I go the the form in a perl file, within the iframe, it won't work and I ask, if it might be because of a conflict between the two languages. There is a jquery script in the head of my file output so maybe the perl processor is requiring 'escapes' to make it work.

1. is there a snippet of code, which can force the jquery file to have escapes as appropriate?
2. the query file (in php format) requires the data from the textbox as part of the query string. I can't seem to check if this is being passed properly, when within the perl file.

Really I don;t understand how perl may affect the php.

$db = mysql_connect('localhost','user','pwd') or die(mysql_error());
$box = mysql_real_escape_string($_GET['box']) or die (mysql_error()); // Get the query string box=
$input = mysql_real_escape_string($_GET['input']); // get the query string input

should this be changed in some way?

I know I haven't given all the file details but I can. I just thought it would be a huge post if I had included it, which might have been too much.


06-14-2009, 09:00 AM
God bless America Bazz.... you should be a perl guru by now! Ticketyboo huh? I learned me a new word! ;)