www.webdeveloper.com
Results 1 to 4 of 4

Thread: failed Jquery Test

  1. #1
    Join Date
    Aug 2011
    Location
    Saginaw Mi
    Posts
    22

    Question failed Jquery Test

    Hi, how are you?

    I had used thiis :

    <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js" ></script>

    Placed it in <head></head>.

    Then I tried to test to see if it works. So used:
    <p onclick="alert('Works');">This is a test</p>
    I don't understand why the test had failed.

    I did it the exact way the guy in the tutorial did it.

    I am using XAMMP, does that have something maybe to do with it?
    Last edited by mooapo; 08-24-2011 at 09:31 PM.

  2. #2
    Join Date
    Apr 2006
    Location
    Perth
    Posts
    154
    Code:
    <html>
    <p onclick="alert('Works');">This is a test</p> 
    </html>
    This does work, should work for every browser regardless of ajax.

    I have a feeling that the bowser has aborted processing any JavaScript due to there
    being a major error on the page.

    Where have you saved jquery.min.js file? Is your test page in the top level folder which
    also contains the sub folders //ajax.googleapis.com/ajax/libs/jquery/1.6.2/
    Colin Fiat Simple Solutions To Complex Problems

  3. #3
    Join Date
    Aug 2011
    Location
    Saginaw Mi
    Posts
    22

    Update

    Update! Got it to load right. Thank you guys for your help.

  4. #4
    Join Date
    Apr 2010
    Location
    Salem,Ma
    Posts
    623
    just to be clear you do nto have to load jquery to make that work, its sijmple javascript

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

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



Recent Articles