Rank: Administration
Joined: 4/2/2004(UTC) Posts: 2,395 Location: Hummelstown, PA Thanks: 6 times Was thanked: 163 time(s) in 158 post(s)
|
Recently it occurred to me that the "Closed" page has a critical flaw: if a user refreshes the page to see if the store is open, it will always show the closed page. The only way a user will realize that the store has opened again is by stripping the "Closed.aspx" from the URL or following some other link or bookmark to the site. Not good! Here's a little snippet of code that you can add to the beginning of your Page_Load method: Code:' <DEVELISYS> If Not WebAppSettings.StoreClosed Then Response.Redirect(WebAppSettings.SiteStandardRoot) End If ' </DEVELISYS>
|
Aaron Sherrick BV Commerce Toll-free 888-665-8637 - Int'l +1 717-220-0012 |
|
|
|
Rank: Member
Joined: 11/25/2003(UTC) Posts: 370
|
|
|
|
|
|
Rank: Member
Joined: 11/5/2003(UTC) Posts: 1,786
|
Thanks for the suggestion!
|
|
|
|
Rank: Administration
Joined: 4/2/2004(UTC) Posts: 2,395 Location: Hummelstown, PA Thanks: 6 times Was thanked: 163 time(s) in 158 post(s)
|
And if you really want to make it sexy, add the following JavaScript code to the Closed.aspx page or via the Closed page content in the admin. This will cause the page to automatically reload every 15 seconds. Once you open the store again the VB code from my first post will redirect the user to the homepage. Code: <!-- <DEVELISYS> --> <script type="text/javascript"> var refreshTimeInSeconds = 15; setTimeout("location.reload(true)", refreshTimeInSeconds * 1000); </script> <!-- </DEVELISYS> -->
|
Aaron Sherrick BV Commerce Toll-free 888-665-8637 - Int'l +1 717-220-0012 |
|
|
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.