Sponsored Content
Top Forums Web Development How to detect browser and re-direct Post 302246020 by cbkihong on Sunday 12th of October 2008 09:55:47 AM
Old 10-12-2008
You can examine the HTTP "User-Agent" header that may carry information about the user's browser used. How to do depends on your server-side development platform (e.g. CGI/PHP/Java etc.) However, because that field can be easily forged, it is not necessarily accurate but that is mostly what you can do.

For redirects, there are mainly 2 ways: HTTP redirect and HTML-based (browser) redirect. With HTTP redirect the server-side generates a redirect (a "moved" HTTP response) that the browser responds to. The second way is to generate a meta tag in the HTML returned to browser, that the browser will do the redirect, but only after the original response is rendered completely. Again, how to do depends on your development platform.

The main difference is that HTML-based redirect will break the "back" button. If the user presses the back button after the redirect, the browser will run the redirect again and the end result is the user is not redirected.

You do not necessarily need to do this with programming. I think you can also implement some of these redirect schemes with certain Apache configuration directives. Dealing with this the Apache way is not my favourite, but that is up to you.
 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Problem using connect direct

Hi, I have a script in which i'm using ndm connect direct to fetch data from the client server..syntax i'm using is ./con_using_connectdirect /load/nctrl nctrl $xhost where con_using_connectdirect is the script which establishes connection load/nctrl is the path from where data... (4 Replies)
Discussion started by: Sheema
4 Replies

2. Solaris

Direct login without password

Hi, I am trying to setup direct login from server test1 (Solaris 10) to server test2 (Solaris 9) using id taops (ldap id). Process Followed on Test 2. created .rhosts file in home directory of user taops geneted public key on test1 and appended to authorized keys on test2. Now trying... (8 Replies)
Discussion started by: tuxian
8 Replies

3. UNIX for Dummies Questions & Answers

re-direct to log file

#!/bin/ksh -x cd /tmp/tj ftp -n servername.com << DONE user username password as put test.log quit close DONE echo "testing..." sh -x scriptname, and it shows all, but username, as, put, quit, close, DONE. how can i see those ? (1 Reply)
Discussion started by: tjmannonline
1 Replies

4. Shell Programming and Scripting

Connect:Direct

Hello all, I have a requirement to transfer files to mainframe usinf NDM connect:direct. So can anybody provide me a sample shell script on how to call a connect;direct script by providing filename as a parameter please? Thanks, Ajay (0 Replies)
Discussion started by: ajaykumar4534
0 Replies

5. Shell Programming and Scripting

Manipulating sed Direct Input to Direct Output

Hi guys, been scratching round the forums and my mountain of resources. Maybe I havn't read deep enough My question is not how sed edits a stream and outputs it to a file, rather something like this below: I have a .txt with some text in it :rolleyes: abc:123:xyz 123:abc:987... (7 Replies)
Discussion started by: the0nion
7 Replies

6. UNIX for Dummies Questions & Answers

Can I re-direct nohup to a different filename?

Hi, I want to be able to run a script nohup & but I want the output file named like <script>.out instead of nohup.out. Is there anyway to achieve this? At the moment, workaround is I cd to a different directory and then do nohup <script> &. So far, I've tried below but it does not seem to... (2 Replies)
Discussion started by: newbie_01
2 Replies

7. Shell Programming and Scripting

Direct read / load

Guys, I wrote a script to do the following - Read a file that is placed into a directory and depending upon the contents, load into one or multiple tables into Oracle. After the file is loaded into the table, depending upon the exit status of the process I will either delete the file or... (3 Replies)
Discussion started by: ManoharMa
3 Replies

8. Shell Programming and Scripting

File not exist in direct

friends can do this from unix AIX I need to ask for a file that does not exist then if file.txt * **** echo "execute procedure" else *** echo "File does not exist" if You can sucedere that the file does not exist (2 Replies)
Discussion started by: tricampeon81
2 Replies

9. UNIX for Beginners Questions & Answers

Direct Printing In AIX

Hello. I recently upgraded to a new Power 8 server and running AIX 7.1. I migrated from an IBM P520 and AIX 5.5. My application on the P520 works best if I direct print, it doesn't work well with spooling. My IBM rep set up the new Power 8 server with spooling which is causing an issue.... (4 Replies)
Discussion started by: ldavis1080
4 Replies
hman(1)                                                       General Commands Manual                                                      hman(1)

NAME
hman - browse the on-line manual pages SYNOPSIS
hman [ -P browser ] [ -H host ] [ section ] name hman [ -P browser ] [ -H host ] [ section ] [ index ] DESCRIPTION
The hman script is an interface to man2html(1) that allows you to enter man page requests at the command line and view the output in your favourite browser. The behaviour reminds of that of man(1) so that many people will be able to alias hman to man. If the browser used is netscape, and an incarnation of netscape is running already, hman will pass the request to the existing browser. OPTIONS
-P browser Specify which browser (like lynx, xmosaic, arena, chimera, netscape, amaya, ...) to use. This option overrides the MANHTMLPAGER environment variable. The default is the non-httpd version of lynx, or sensible-browser if lynx cannot be found. -H host Specify from what host to get the man pages. This option overrides the MANHTMLHOST environment variable. The default is localhost. ENVIRONMENT
MANHTMLPAGER The default browser to use is selected using this environment variable. MANHTMLHOST The default host to use is selected using this environment variable. SEE ALSO
man(1), man2html(1), arena(1), lynx(1), sensible-browser(1), netscape(1), xmosaic(1), glimpse(1) http://www.mcom.com/newsref/std/x-remote.html 19 January 1998 hman(1)
All times are GMT -4. The time now is 11:01 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy