Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 3.5 > BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3
This is the forum to discuss the Wrox book Beginning ASP.NET 3.5: In C# and VB by Imar Spaanjaars; ISBN: 9780470187593
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 3.5 : in C# and VB BOOK ISBN: 978-0-470-18759-3 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Display Modes
  #1 (permalink)  
Old March 6th, 2012, 04:08 AM
Authorized User
Points: 178, Level: 3
Points: 178, Level: 3 Points: 178, Level: 3 Points: 178, Level: 3
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2011
Posts: 35
Thanks: 12
Thanked 0 Times in 0 Posts
Default Chapter 6: theme cookie expires at the end of the session

Hello Imar,

I refer to pages 214-228 of your book (Themes).

I set my Internet Explorer options to accept all the cookies,
I set the Expires property of my theme cookie to a very long time,
I debugged my app and saw the cookie is created, as expected.

Despite all of the above, when I restart my app, after a few seconds, there is no more cookie and the theme is retrieved from web.config.

Why ?
Reply With Quote
  #2 (permalink)  
Old March 6th, 2012, 04:11 AM
Imar's Avatar
Wrox Author
Points: 67,317, Level: 100
Points: 67,317, Level: 100 Points: 67,317, Level: 100 Points: 67,317, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 16,230
Thanks: 66
Thanked 1,416 Times in 1,396 Posts
Default

Hard to say without seeing your code.

Does it work when you open the full source of the site that comes with the book? (Try opening the code for Chapter 18). If that doesn't work, there may be something blocking cookies on your machine (security software, network policies, etc). Have you tried a different browser?

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
Reply With Quote
  #3 (permalink)  
Old March 6th, 2012, 04:38 AM
Authorized User
Points: 178, Level: 3
Points: 178, Level: 3 Points: 178, Level: 3 Points: 178, Level: 3
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Aug 2011
Posts: 35
Thanks: 12
Thanked 0 Times in 0 Posts
Default

Quote:
Originally Posted by Imar View Post
Have you tried a different browser?

Imar
Than you for your hint.
The code works with Chrome and Firefox. I mean, the theme cookie is saved at the end of the session and when I restart the app, the theme is retrieved from the cookie, not from web. config.
The problem is with Internet Explorer (version 9), despite I set the option to accept all the cookies.

Bye
Reply With Quote
  #4 (permalink)  
Old March 6th, 2012, 05:02 AM
Imar's Avatar
Wrox Author
Points: 67,317, Level: 100
Points: 67,317, Level: 100 Points: 67,317, Level: 100 Points: 67,317, Level: 100
Activity: 100%
Activity: 100% Activity: 100% Activity: 100%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 16,230
Thanks: 66
Thanked 1,416 Times in 1,396 Posts
Default

Hmmm, not sure what's going on then. Could be anything ;-) Are you running IE as an Adminstrator? (E.g. starting it from Visual Studio in "Run As Administartor" mode?

Not sure what else to check....

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
session state expires?? chroniclemaster1 ASP.NET 2.0 Professional 4 February 5th, 2010 10:43 AM
Session/Cookie Expires, Login page appears rajn ASP.NET 1.0 and 1.1 Professional 3 June 27th, 2007 06:19 AM
Session expires immediately codebuyer Classic ASP Components 6 March 18th, 2005 11:54 AM
session and cookie problem (empty session file) msincan BOOK: Beginning PHP, Apache, MySQL Web Development ISBN: 978-0-7645-5744-6 0 February 27th, 2005 04:31 PM



All times are GMT -4. The time now is 09:03 PM.


Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.