Clarify Postback

Results 1 to 2 of 2

Thread: Clarify Postback

  1. #1
    Join Date
    Dec 1969

    Default Clarify Postback

    Ok just checked MS for information on what exactly is a “postback”, didn’t find anything. So please tell me if I’m right when I say the following…<BR>“If a user hits the back button then it is a postback.”<BR>“When a user first hits a button that runs at the server it is also a post back.” <BR>“And when a page is loaded for the first time it is not a postback.”<BR><BR>So basically I need to check for postback to prevent double dataentry or a double hit to the database.<BR><BR>As you can see I am confused, if you could help clarify this it would be much appreciated. <BR>

  2. #2
    Join Date
    Dec 1969

    Default Uhhhhhh.......No.

    IsPostBack is the VB method or submitting the page onto itself....basically...reloading it.<BR><BR>IF Page IsPostBack THEN<BR><BR>is used when you&#039;re reloading a your 3rd statement is true....BUT.... You can also specify which page loads when you submit information to a page...using a Sub...<BR><BR>You do this by specifying an onclick event handler such as "onclick="doPost"<BR><BR>And of course somewhere above the html, you&#039;d specify a sub called doPost. <BR><BR>You can also have a form method post action blah blah blah....just like the old asp...but I think you need things not to be run from the server if you&#039;re doing things that way....kind of a waste really....because if you can submit a forms page to itself while declaring a;re saving yourself pages...and a mess of a time editing sites & applications. Why would you want a login submit to a database verification page...and then to a logged in page? Wouldn&#039;t it be much easier to postback with a sub that does all that work, and then redir to the appropriate page?

Posting Permissions

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