URLBuilder and Cookies (problem)
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > Microsoft Commerce Server > Commerce Server General > URLBuilder and Cookies (problem)




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    URLBuilder and Cookies (problem)  
Tomas Vera


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
02-22-05 10:50 PM

Hello All,
A couple of days ago, I posted about having some issues with
CommerceContext.Current.AuthenticationInfo.SupportsSessionCookies
property always returning false.

I found a workaround for the time being, but I've tracked the problem
down to the URLBuilder (...) call in the
UrlBuilder.Current.Redirect(...) call in the EnsureAccess(..) function
in the SiteUtlity.CS file that comes with the FP1 Solution Sites.

Here's what's happening:
I've unpacked the site to per instructions to
<WWWROOT>\MyProject\

When I start at any page in the project, Commerce is setting the
TestPersistentCookie in a file named:
user@localhost.txt.

This happens whether I enter a URL of
http://localhost/MyProject/default.aspx or
http://servername/MyProject/dfault.aspx .

Then when ensureAccess is called URLBuilder returns a URL in the form
of
http://servername/MyProject/default.aspx. But then Commerce is
checking for a cookie in user@MyProject.txt and does not find it,
because the TestPersistentCookie was places in user@localhost.txt .
This leads to SupportsSessionCookies always returning false.

So...Some questions:

1.  How do I get Commerce to set the persistent cookie in
user@MyProject.txt or how do I get commerce to check for the cookie in
user@localhost.txt .

2. Why does UrlBuilder always change my urls from
http://localhost/MyProject/... to http://servername/MyProject/...

3. Is it critical tha I use URL Builder for the redirects? (I'm
currently using some of my own code int he EnsureAccess function).

Any insights are welcome.

-tomas






[ Post a follow-up to this message ]



    Re: URLBuilder and Cookies (problem)  
chekai


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
07-21-05 10:52 PM

> Tomas Verawrote:

> 2. Why does UrlBuilder always change my urls from
> http://localhost/MyProject/... to http://servername/MyProject/...
>
> 3. Is it critical tha I use URL Builder for the redirects? (I'm
> currently using some of my own code int he EnsureAccess function).
>
> Any insights are welcome.
>
> -tomas

I'm also facing similar issue here. Thought I share it here and hope
someone else have resolution for it.

I have a MSCMS website using MSIB 21. The virual directory is at
http://servername/msib21/

I am making use of UrlBuilder.Current.BuildUrl( "/Login/Login.aspx",
true );  to contruct the url for my login page. However, the
UrlBuilder returns the following:

http://servername/AnotherApplicatio...ogin/Login.aspx

Also wondering why UrlBuilder is returning the wrong URL....






[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 09:25 AM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register