Results 1 to 2 of 2

Thread: searching for a javascript

  1. #1
    Join Date
    Nov 2007
    Posts
    21
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default searching for a javascript

    Hi guys. I am looking for a javascript that will check to see if a page exists or not. If it does, I would like it to return some text. If not I would like it to return some other text. Is this possible? Any help appreciated!

  2. #2
    Join Date
    Mar 2006
    Location
    Illinois, USA
    Posts
    12,164
    Thanks
    265
    Thanked 690 Times in 678 Posts

    Default

    You could use Ajax for a local page, though that seems a bit complex. Ajax will also not work for an external page. (Another domain)

    You can use PHP, or another server side language, to do this. You could also then use Ajax to check the response of a PHP script, meaning you could have it output "works" or "fails", then the JS could react.
    Daniel - Freelance Web Design | <?php?> | <html>| español | Deutsch | italiano | português | català | un peu de français | some knowledge of several other languages: I can sometimes help translate here on DD | Linguistics Forum

Bookmarks

Posting Permissions

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