Web Design Forum: How does this button work? - Web Design Forum

Jump to content

WDF
WDF Premium Memberships Reseller Hosting
Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

How does this button work?

#1 User is online   adamsmith 

  • Advanced Member
  • PipPipPip
  • Group: Members
  • Posts: 336
  • Joined: 04-June 11
  • Reputation: 9
  • Gender:Male
  • Experience:Intermediate
  • Area of Expertise:Web Designer

Posted 28 January 2012 - 06:26 PM

I'm trying to create a button that works in a similar way to the 'Stumble' button on www.stumbleupon.com

The button is in relation to what website an <iframe> shows.

When the button is pressed, the stumbleupon website is refreshed and a new website is shown in the iframe. When refreshing the page without pressing the button the page that is shown in the iframe stays the same as it did before.

I thought this button used a php form to get the data from the database (the websites to be shown in the iframe are stored in the database) but it isn't, i tried making this and it worked until i reloaded the page and a box came up saying, "are you sure you want to reload the page, the form will be submitted again", or something like that, where it doesn't on StumbleUpon.

I looked into it using Google Chrome and they are using the <a> tags to make a link and the "href" is pointing to 'javascript: void(0).

So how would a button be made like this that queries the database, but only when the button is pressed not when the page is reloaded, and when the page is reloaded it keeps the same page in the iframe as was there before it was reloaded.

If you use the site you'll know what I mean lol...
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users