SitePoint Sponsor

User Tag List

Results 1 to 4 of 4
  1. #1
    SitePoint Member
    Join Date
    Dec 2012
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    classic asp and iframe

    Hi all

    I need to use an iframe on a classic asp shopping website which has been around for many years.

    Currently when the customer clicks an item on the product lists, it opens a new window to add the item to the shopping list. Clicking a second item updates this window.
    I use this approach because I don't want to refresh the product page display which stays open in the background (there is a lot of processing to build this page, and I don't want to keep repeating it when orders tend to have many items).

    (For years this worked well. When an item was clicked this page did all the processing required and the product page stayed in focus. Last year it stopped doing this and now the order page needs to be clicked to regain focus!).

    I now want this new window, which is opened each time an item from the order page is clicked, to update an iframe on the products list page. This window can terminate with this action if possible. I cannot find a way to do this without updating the page holding the iframe.

    I hope that I have explained it properly!!!

    thanks

  2. #2
    SitePoint Enthusiast
    Join Date
    Jan 2012
    Posts
    45
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    using javascript, you can do this from the new window:

    Code:
    function refreshFrame()
    {
    window.opener.frames[0].location.reload();
    window.close();
    return true;
    }

  3. #3
    SitePoint Member
    Join Date
    Dec 2012
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    hi, thanks for the reply.
    I am probably being stupid!! but I cannot see how to code this requirement.
    The customer clicks an item from the product list being displayed.
    The first item clicked opens a second window showing the shopping basket summary. It also creates the order and populates it with the item.
    The second and subsequent times an item is clicked from the product list, the focus switches to this second window showing the updated basket. All the processing to update the order is done in this second window.
    I want this second window to update an iframe in the first page with items ordered count and value of order to date. That would mean that customers viewing the many different price lists would have the latest value of the
    order displayed on all product pages.
    I have not found a way to do this. It might be impossible using classic asp!!
    thanks

  4. #4
    SitePoint Guru
    Join Date
    Jun 2007
    Posts
    675
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    This is the type of task which is best performed with javascript on the client side, not with ASP. Try moving your question to the javascript forum. folks there can likely give you a solution.


Tags for this Thread

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
  •