Forums

This topic is locked

Browser Redirection

Posted 08 Oct 2001 08:35:13
1
has voted
08 Oct 2001 08:35:13 Mark Johnston posted:
Hi, i am a longtime GoLive user but have recently started work with a company using DW and UD. I for the life of me cannot find anywhere that has an action similar to one Walter Blady has made for GoLive. I cannot understand why this would be when there is so much other stuff out there to do wierd and wonderful stuff. All i wanna do is Redirect on Browser Type and version numbers. Only thing I fond in the DW Wxtension Archive is a redirect action by Brendan Dawes but when clicking the link I get a 404 and his new site has no information about it either...can somebody help me out here. I can be contacted at Thanx in advance guys. Sorry bout the posting to multiple forums but it does concern all 3.

Replies

Replied 08 Oct 2001 10:22:30
08 Oct 2001 10:22:30 Bjorn Fripon replied:
first get to Window|behaviours
show the behaviours window
click the + sign
choose browser

there your are <img src=../images/dmxzone/forum/icon_smile_wink.gif border=0 align=middle>

-jezter (back)

Replied 09 Oct 2001 05:20:33
09 Oct 2001 05:20:33 Mark Johnston replied:
No I am not there sorry. <img src=../images/dwzone/forum/icon_smile_sad.gif border=0 align=middle> &lt;br&gt;
That only allows me to distinguish between all IE browsers over a ertain version or NN browsers over a certain version. The action I use in GoLive will allow me to choose between 3 different versions of IE, NN and AOL on both the Mac, PC and WebTV platforms as well as a URL for all other browsers.&lt;br&gt;

To me the DW action is far to basic. What about browsers like iCab and Opera.&lt;br&gt;

The reason why platform is iportant to me is because framesets in NN 4.X display differently between Mac and PC, and the reason I wanna distinguish between IE and NN is that NN frame rendering on any platform is nothing short of woeful with it deciding how big it wants to make my 140pixel from for example...might make it 142, might be 144, just depends on how big the window is it is opened in and even what platform it is on.&lt;br&gt;

The action I use in GL I got from www.wblady.com/actions.html&lt;br&gt;

Now I am no script guru myself and certainly could not make the extension, but it just seems strange that with the other 400+ plugins kicking around that one like this has not been made/addressed. I really like the way DW operates and am porting most of my sites over to it as I can but this has got me really bothered. Too bad that browser makes could not all stick to perfect standards huh although IE 5.x+ and NN 6.x+ seem to render nearer each other.&lt;br&gt;

Once again if anybody has got some suggestions please email me.

Replied 09 Oct 2001 08:12:33
09 Oct 2001 08:12:33 B. B. replied:
Hello! Not sure if this is what you are looking for.

You can get the browser plus many other environment values from the Request.ServerVariables object. Once you have the browser type you can then redirect to a specific page.

What you would need to do is upon a successful login, assuming you are using the Login User behavior, set the successful login page value in the behavior to a temporary page such as temp_redirect.asp and on this page you will check the browser type and redirect accordingly to another page. The temp_redirect page would not display at all since all your redirection code is in the head tag and you have nothing in the body tag.

You can write information in the body tag for testing purposes just to check values or whatever but in production you would comment this.

Some sample redirect code follows.

If Session("MM_UserAuthorization" = "admin" Then
Response.Redirect("admin_home.asp"
end if

if Session("MM_UserAuthorization" = "member" and Request.ServerVariables(name) = "somevalue" Then
Response.Redirect("member_home.asp"
end if

where name is the ServerVariable name you want.

Go here for more information.
www.4guysfromrolla.com/webtech/092298-3.shtml

Once you ask for one ServerVariable you get them all which is due to the way the object works. The link above has all the details you need.

Hope this is what you were looking for. Thanks!



Replied 15 Oct 2001 13:11:09
15 Oct 2001 13:11:09 Mark Johnston replied:
What about us lowly DW users?? <img src=../images/dwzone/forum/icon_smile_sad.gif border=0 align=middle>
Its a bastard that Macromedia seemed to stop making the redirection action usefull when they decided we only need to differentiate 2 browsers and wheter they are above or below a certain version and thats all the options we got. What about redirecting on platform...another shortcoming of it. It just seems a very half a$$ed not finished but possibly useful action. Oh and the site I am working on has no ASP asit on a linux box as well as having no password systems at that point. I just want to be able to distinguish browser and platform and go through the correct pages to set the interface up sweetly. <img src=../images/dwzone/forum/icon_smile_sad.gif border=0 align=middle>

Reply to this topic