+ Reply to Thread
Results 1 to 4 of 4
  1. #1
    Junior Member
    Join Date
    Apr 2009
    Posts
    3

    Red face Ajax refresh div

     
    Hi, I need to refresh a div. Just refresh/reload, with the same content. I'd tried the Ajax.Updater from the prototype framework; however it needs an Url. I only want to update the div with refresh button. Whenever users click refresh button, the page will only refresh DIV. Any ideas? Please help me out. Thanks.

  2. #2
    Super F@D Folder
    Join Date
    Jun 2004
    Posts
    5,091
    I assume you're using some kinda server side scripting to build the div? Basically what you need to do is build a webpage that is just the div, then call it on update. Get what i mean?

  3. #3
    Junior Member
    Join Date
    Apr 2009
    Posts
    3
    Thanks for your advice. Currently, I am using php. My situation is I have a page with multiple DIV sections. I would like users to click refesh buttons in order to refresh each div if they have done any changes. I am using Ajax.Updater; however, I don't know what URL that I should put in the second param. Actually, I don't want to refresh whole page only div. Kind of lost. Please advise. Thanks.

    My code is as follows:

    <script type="text/javascript">
    function refreshcontent(v,fb0c4de,fdcdcdc){
    alert(f_b0c4de);
    new Ajax.Updater('contact', 'URL', { method: 'get' });

    Olive

  4. #4
    Super F@D Folder
    Join Date
    Jun 2004
    Posts
    5,091
    in other words you would have a php script that creates the framework for the page (from < html > to < /html >), but would leave each div empty. Then you would create SEPARATE scripts for the content in each div. Now you have separate urls to load the data into each div. Make sense?

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. How to make a DIV rest at the bottom of another DIV in CSS?
    By celebritymusic in forum Webmastering and Programming
    Replies: 1
    Last Post: March 1st, 2007, 10:15 AM
  2. AJAX: Determine the link "onclick" within a DIV
    By gberz3 in forum Webmastering and Programming
    Replies: 2
    Last Post: September 6th, 2006, 02:53 PM
  3. help with setting desktop refresh rate to game refresh rate
    By sweeper2 in forum Graphics Cards and Displays
    Replies: 7
    Last Post: December 27th, 2005, 08:54 PM

Tags for this Thread

Posting Permissions

  • You may post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Recommended Sites: ResellerRatings Store Reviews