AJAX Forums

PHP include problem

This is a discussion on PHP include problem within the AJAX Help forums, part of the Beginners AJAX category; Hello, i've been working with ajax for a few weeks now and i have a simple question. I want to keep this somewhat simple but tell me if i ...


Go Back   AJAX Forums > Beginners AJAX > AJAX Help

Register FAQ Members List Calendar Search Today's Posts Mark Forums Read
Old 07-10-2008, 01:35 PM   #1 (permalink)
Junior Member
 
Join Date: Jul 2008
Posts: 2
Rep Power: 0 jflowers is on a distinguished road
PHP include problem

Hello, i've been working with ajax for a few weeks now and i have a simple question. I want to keep this somewhat simple but tell me if i need to give more.

I have an ajax method that is being called, lets say....
function listClient(str)
{
xmlHttp=GetXmlHttpObject()
if (xmlHttp==null)
{
alert ("Browser does not support HTTP Request")
return
}
var url="/lib/clients.php"
url=url+"?q="+str
url=url+"&sid="+Math.random()
xmlHttp.onreadystatechange=generateHTML
xmlHttp.open("GET",url,true)
xmlHttp.send(null)
}
When it opens up /lib/clients.php and runs everything works fine and dandy.

Athough as my script has progressed in complexity, i turns out i need to add an include file in that clients.php

whenever i add the include file ---- require_once('file.php'); The script stops working. Let me be more clear the clients.php script still works, but the ajax doesn't.

(The Entire process is this... going from html and using Jquery to tell if someone clicked something.. jquery called the ajaxs method and that opens up the connection to the php script. PHP runs and then generates xml in which ajax/jquery reads and then sends back to html. Again the entire process works if i don't add that include (the include file is only one line right now) so i think its something wrong with ajax getting confused)

Please help
jflowers is offline   Reply With Quote
Old 07-14-2008, 10:33 AM   #2 (permalink)
Junior Member
 
Join Date: Jul 2008
Posts: 2
Rep Power: 0 jflowers is on a distinguished road
any help at all would be wonderfull
jflowers is offline   Reply With Quote
Reply

Bookmarks

Tags
incude help, php/ajax


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes


Similar Threads

Thread Thread Starter Forum Replies Last Post
AJAX Jobs : same site as www.grabtube.de include own deisgn by newidea admin AJAX Freelance Jobs 0 07-13-2008 08:42 PM
Google Sites Launches, Using AJAX to Include Gadgets, to Mixed Reviews microbee AJAX Help 0 03-04-2008 01:10 PM
Html Problem...? James H XHTML and CSS 3 05-30-2007 02:28 PM
Can someone tell me if there is a problem... timoothy36 JavaScript 0 03-19-2007 03:35 PM
web 3.0 forum problem bicu Announcements 1 11-21-2006 02:27 AM


All times are GMT -4. The time now is 06:47 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 RC5
Copyright ©2006 - 2008, AJAXwith.com