Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New Coder
    Join Date
    Oct 2007
    Posts
    26
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Ajax Load PHP file not working?

    Hi Guys,

    I've been stuck on this for a few days now, and tried a few different work arounds but I just can't get this to work. My PHP script is correct and simply echo's out a small string. The Div is want everything displayed in is correct, and I BELIEVE (probably where this issue is) that my Ajax is correct.

    Code:
    <script>
    $(document).ready(function() {
        $("#displayresults").load("dansearch.php");
    });
    </script>
    <div id="displayresults"></div>
    Can anyone help? Many thanks in advance!

  • #2
    The fat guy next door VIPStephan's Avatar
    Join Date
    Jan 2006
    Location
    Halle (Saale), Germany
    Posts
    8,919
    Thanks
    6
    Thanked 1,040 Times in 1,013 Posts
    Is the file path correct? If you used the browser’s error console you wouldn’t have to ask here because it would probably tell you exactly what’s wrong.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •