|
http://www.sitepoint.com/articles/770/33
srikanth
|
|
|
|
|
What a JOTD???
"Two wrongs don't make a right, but three lefts do!" - Alex Barylski
|
|
|
|
|
Hockey wrote:
JOTD
Joke Of The Day.
"Ask not for whom the bell tolls; It tolls for thee..."
|
|
|
|
|
Ahh....
now it makes sense...
"Two wrongs don't make a right, but three lefts do!" - Alex Barylski
|
|
|
|
|
http://www.jsptut.com/Loginforms.jsp
http://www.jguru.com/faq/JSP
check out these sites u may get some useful info
|
|
|
|
|
http://www.sitepoint.com/article/770/33
http://www.sitepoint.com/article/305
http://forums.devshed.com/archive/9/2002/01/4/29371
check these sites it there is source code in the first link,
and other two r tutorials
Srikanth
|
|
|
|
|
so far, I've stumbled across godaddy.com for a domain name @ 9/yr and
edatarack.com for decent hosting @ 3/mo...
This is for a simple little website - nothin fancy...
Am i on the right track?
Thanks
...Steve
|
|
|
|
|
Check out tophost.com
You can find a hosting company which fits your exact needs i'm sure
Cheers
"Two wrongs don't make a right, but three lefts do!" - Alex Barylski
|
|
|
|
|
Yes GoDaddy.com for domains is good.
And for searching for Web hosts I like:
http://www.hostsearch.com/s_power_n.asp
Best regards,
J. Paul Schmidt
http://www.Bullschmidt.com - Freelance ASP Web Developer
http://www.Bullschmidt.com/DevTip.asp - ASP Developer Tips
|
|
|
|
|
Steve Hazel wrote:
I've stumbled across godaddy.com for a domain name @ 9/yr
I use DotYou.com[^] for domain names. I have around 30 of them and DotYou provides full DNS support. Have had no major problem in the two years I have been using them.
Rocky Moore <><
|
|
|
|
|
A website I've been working on for a while requires a user logon; the user info is checked and a session variable keeps track of whether the user is allowed to proceed. It worked perfectly yesterday, but last night I installed the .NET Framework. Today it doesn't work - What changed? Here's the code:
In global.asa -
Sub Session_OnStart
usrOK = False
currTbl = ""
currRec = ""
update = "No"
End Sub
In login.asp -
If (strUser="member") AND (strPass="webuild") Then
Session("usrOK") = True
End If
If Session("usrOK") = False Then
strHTML="You are not authorized to view this page" &_
""
Out(strHTML)
Wait(2)
Response.Flush
Server.Transfer("maintain.asp")
Else
'blah, blah, blah
Just for good measure, I checked the site settings in IIS to see if they'd been changed. There were no changes that would affect this routine, and session settings are still where I left them. Maintain.asp is the entry point where I obtain user id info, and Wait() is a delay function in a SSI file. Any ideas?
"Ask not for whom the bell tolls; It tolls for thee..."
|
|
|
|
|
That is very strange. We have plenty of ASP websites running on our box that use Sessions and the global.asa. When we installed .NET Framework on that box they all carried on running just fine.
This bit of code, Server.Transfer("maintain.asp") , though worries me. Why are you using Server.Transfer? It might be part of the problem, not sure though.
Also, and forgive me for asking, but you are making sure that you are not mixing ASP and ASPX pages in your app? e.g. You are not redirecting from an ASP login page to an ASPX detail page for instance.
Paul Watson Bluegrass Cape Town, South Africa
Chris Losinger wrote:
i hate needles so much i can't even imagine allowing one near The Little Programmer
|
|
|
|
|
Paul Watson wrote:
Why are you using Server.Transfer? It might be part of the problem, not sure though.
It was the only way I know to reload the first page (where user credentials are entered) using ASP. If it's a problem today, it should have been a problem yesterday, as well, along with the several weeks I've been using it reliably. I haven't made any aspx pages yet, so mixing pages is not a problem, either.
I've had trouble with session variables before, with some of them in global.asa being correctly intialized, but others being left undefined for no apparent reason. But this one has worked perfectly since the day I wrote it. I've read many warnings to avoid session variables as unreliable entities in books and on the web, so I haven't been concerned about the occasional eerie failure as long as there was another way to get the job done.
I just love mysteries... I can always count on Windows and IIS to keep me entertained.
"Ask not for whom the bell tolls; It tolls for thee..."
|
|
|
|
|
Roger Wright wrote:
It was the only way I know to reload the first page (where user credentials are entered) using ASP
The normal way is to use Response.Redirect "filename.asp"
Roger Wright wrote:
If it's a problem today, it should have been a problem yesterday
AFAIK Server.Transfer does a whole lot more than Response.Redirect, which might be what is causing the problem. You are right though that installing the .NET Framework should not have caused a problem. Server.Transfer though generally is used on server farms where you need Session data to move from one server in the farm to the other. Response.Redirect will not do this. If I start on Server1, some Session info is captured and I am then moved to Server2 without a Server.Transfer then I loose that Session info.
I don't know actually Roger, searching Google now for people who have had a similar problem to you. As you say " I can always count on Windows and IIS to keep me entertained"
Paul Watson Bluegrass Cape Town, South Africa
Chris Losinger wrote:
i hate needles so much i can't even imagine allowing one near The Little Programmer
|
|
|
|
|
You're not going to believe this (well, maybe you will), but after spending the morning trying to figure out what is going on today that wasn't yesterday I walked away from it for a couple of hours, then returned to it. Now it's working perfectly, though I've changed nothing. I think I'll look at that Redirect option as you suggested. Thanks!
"Ask not for whom the bell tolls; It tolls for thee..."
|
|
|
|
|
Paul Watson wrote:
The normal way is to use Response.Redirect "filename.asp"
I will have to disgree with you. Response.Redirect works in conjunction with the browser. IIS sends a response with HTTP status code 302 and the new url to the browser when you call Response.Redirect. The browser than renavigates to the page. Server.Transfer is more efficient in the sense that it doesnot cause any extra network trips look at this page which explains it more clearly.
http://msdn.microsoft.com/library/en-us/iisref/htm/ref_vbom_seromtr.asp?frame=true[^]
One of the things I learned involved copying & pasting the code. You'll notice that some of the code is virtually the same for each player, I had forgotten to change the files for player 2 for upgrade. I finally noticed it and provided the fix.
Rodney Yates in Points of Interest in this article
|
|
|
|
|
Yes but for one you cannot use a querystring with Server.Transfer, a big minus mark IMO.
Server.Transfer is a more recent addition. Hence why I said Response.Redirect is the normal way.
They are used for different things.
Paul Watson Bluegrass Cape Town, South Africa
Chris Losinger wrote:
i hate needles so much i can't even imagine allowing one near The Little Programmer
|
|
|
|
|
Having spent the rest of the day and most of the night trying to get Response.Redirect to work, I now have a completely non-functional site. It redirects nicely, but the page I want to display to inform the user that access is not allowed never displays. I've tried it with buffering on and off, and using Clear and Flush in various combinations - no go. The text I use for a reference recommends that the newer functions, Server.Transfer and Server.Execute, be used instead of Response.Redirect in almost all situations. One idiosyncracy I haven't been able to figure out yet is that, when it is working properly and displaying the message before transferring back to the first page, the text is merely added to the current page being displayed. There must be some way to clear the existing page out of the browser and display the message as a new page! The fun factor is rapidly diminishing here...
"Ask not for whom the bell tolls; It tolls for thee..."
|
|
|
|
|
must be some way to clear the existing page out of the browser and display the message as a new page..
in this setuation Transfer won't work..
you need to redirect.
one problem with redirect is that it causes some problems if the uses is viewing the page behind a proxy..
try to use some Client script to handle your problem..
|
|
|
|
|
hspc wrote:
use some Client script to handle your problem
I hadn't thought of that... one of my goals in this project is to write the whole thing to execute on the server, but I've already had to break that in order to set the default focus on a specific INPUT field. Redirect makes it impossible to display any text at all, so it's useless. But adding some client side stuff might be the ticket... Thanks for the suggestion!
"Ask not for whom the bell tolls; It tolls for thee..."
|
|
|
|
|
Paul Watson wrote:
The normal way is to use Response.Redirect "filename.asp "
Uck, that looks so naked without brackets and a semicolon - I had to do a double take before I even realised what you were saying!
I've been doing JScript far too long...
David Wulff
"Without hopes and dreams we're directionless" - Anna
|
|
|
|
|
David Wulff wrote:
Uck, that looks so naked without brackets and a semicolon - I had to do a double take before I even realised what you were saying!
I know. Had to go back to a VBScript/ASP project the other day and I felt so uncomfortable coding. Kept putting in ; and wanting to use } instead of end if etc.
Paul Watson Bluegrass Cape Town, South Africa
Chris Losinger wrote:
i hate needles so much i can't even imagine allowing one near The Little Programmer
|
|
|
|
|
What exactly isn't working? I assume you get a VBS error message of some kind.
Jason Henderson My articles
"The best argument against democracy is a five-minute conversation with the average voter." - Winston Churchill
|
|
|
|
|
Jason Henderson wrote:
I assume you get a VBS error message
Yeah, right! No, there are no error messages - which only says that the code is perfectly valid VBS, but my understanding of what I've written is defective.
Actually, Jason, I've got everything working almost satisfactorily. It's a simple login routine - nothing fancy - that asks for id, checks its validity, and displays a 'Go Away' message if the login fails. It works, though not the way I'd like, because my intent is to display the message, wait a few seconds, then display the login screen again. What I get, though, is the message at the top of the screen, and the login appended after it, and both appear after the delay period, rather than in the order they're written (msg - delay - transfer). Very odd.
"Ask not for whom the bell tolls; It tolls for thee..."
|
|
|
|
|
Roger Wright wrote:
and both appear after the delay period, rather than in the order they're written (msg - delay - transfer). Very odd.
Could be the buffering. If it is buffered it will wait until the page is compelete before sending it. If you want a delay you could use a meta tag in the "go away" page that causes it to refresh after x amount of seconds. Would have the added bonus to allow the user to hit refresh for instant login screen.
Rocky Moore <><
|
|
|
|