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 3 of 3
  1. #1
    By@
    By@ is offline
    New Coder
    Join Date
    Sep 2005
    Posts
    17
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Refreshing Certain Areas of an HTML Document

    Is it possible to refresh certain areas of a document when a button is pressed.

    Like input fields between some div or p tags?
    Last edited by By@; 09-24-2005 at 08:34 AM.

  • #2
    Master Coder felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, Australia
    Posts
    6,618
    Thanks
    0
    Thanked 645 Times in 635 Posts
    It is possible using AJAX (Asynchronous Javascript and XML) which requires both some Javascript attached to the button to make the refresh request and some server side scripting to deliver the new content. It would only work on those browsers that support the appropriate Javascript commands that allow the servr side call.

    Alternatively you could use an iframe to contain the refreshable content as a separate page.
    Stephen
    Learn Modern JavaScript - http://javascriptexample.net/
    Helping others to solve their computer problem at http://www.felgall.com/

    Don't forget to start your JavaScript code with "use strict"; which makes it easier to find errors in your code.

  • #3
    By@
    By@ is offline
    New Coder
    Join Date
    Sep 2005
    Posts
    17
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hey, thanks for the reply, felgall.

    I've had bit of a look at Ajax, but dont really see how it works.
    (I dont know too much about JavaScript unfortunately.)

    Can you possibly explain it to me or post some code?
    Cheers!!


  •  

    Posting Permissions

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