473,386 Members | 1,883 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

don't open new window


Is there the possibility of not permiting the user of opening
two windows of the same web site?

Thanks
+---------------------------------------------+
| Jayme Assuncao Casimiro |
| Graduado em Ciência da Computação |
| Estudante de Mestrado em Computação |
| Universidade Federal de Minas Gerais - UFMG |
+---------------------------------------------+

Jul 17 '05 #1
9 3832
Jayme Assuncao Casimiro:

Is there the possibility of not permiting the user of opening
two windows of the same web site?


No.

André Næss
Jul 17 '05 #2
Jayme Assuncao Casimiro <ja***@dcc.ufmg.br> schrieb:
Is there the possibility of not permiting the user of opening
two windows of the same web site?


No. You can't control the user and the users browser(s) and computer(s).

Regards,
Matthias
Jul 17 '05 #3
Matthias Esken wrote:

No. You can't control the user and the users browser(s) and computer(s).


Perhaps you could (with a complicated session-based tracker, or by
tracking IPs), but the point is that you *should not* control the user's
browser, that's not the purpose of a website!

-adi

Jul 17 '05 #4
Adi Schwarz wrote:
Matthias Esken wrote:

No. You can't control the user and the users browser(s) and computer(s).


Perhaps you could (with a complicated session-based tracker, or by
tracking IPs), but the point is that you *should not* control the user's
browser, that's not the purpose of a website!

-adi


I would say it's not even possible then. The client most probably caches
the page and when a new window is opened just opens it from cache. You
*may* be able to do it with JavaScript (if you are really anal, a
combination of javascript and PHP), but again, there is no reason you
should be limiting how many windows a client has open. You shouldn't care,
your PHP code should be robust enough to handle submissions/track where a
user is if they have multiple pages open, plus thats just one thing you
should mess with. A users web-browser is personal. At the point you start
making it impossible to do something, they get pissed. (Or do something
for that matter, like pop-ups). Take my advice, leave the browser alone.
-Eric Kincl
Jul 17 '05 #5
*** Eric Kincl wrote/escribió (Fri, 21 Nov 2003 01:53:38 +0000):
I would say it's not even possible then. The client most probably caches
the page and when a new window is opened just opens it from cache.


User can spoil any attempt just opening two browsers (Explorer and
Mozilla)—given that he actually care. I normally leave annoying sites
unexplored ;-)

--
--
-- Ãlvaro G. Vicario - Burgos, Spain
--
Jul 17 '05 #6
Eric Kincl <Er**@Kincl.net_NO_SPAM_> wrote in message news:<3f******@news.gvsu.edu>...
Adi Schwarz wrote:
Matthias Esken wrote:

No. You can't control the user and the users browser(s) and computer(s).


Perhaps you could (with a complicated session-based tracker, or by
tracking IPs), but the point is that you *should not* control the user's
browser, that's not the purpose of a website!

-adi


I would say it's not even possible then.


No. It's possible. As Adi said, you need complex session
processing for that. BTW, I don't mean disabling "Open new window"
option of browser---I mean if the user opens a new window, then prompt
a error message or force log off.

My bank ( http://www.icicibank.com/ )have such option. They won't
allow you to use "Stop button", or "Refresh button" or "Ctrl+N" or
"Open link in new window". If you do so, then they will force log off
telling that it's for security purpose.

---
"One who mix sports and patriotism is a barbarian"
Email: rrjanbiah-at-Y!com
Jul 17 '05 #7
R. Rajesh Jeba Anbiah:
Eric Kincl <Er**@Kincl.net_NO_SPAM_> wrote in message
news:<3f******@news.gvsu.edu>...
Adi Schwarz wrote:
> Matthias Esken wrote:
>
>>
>> No. You can't control the user and the users browser(s) and
>> computer(s).
>
> Perhaps you could (with a complicated session-based tracker, or by
> tracking IPs), but the point is that you *should not* control the
> user's browser, that's not the purpose of a website!
>
> -adi


I would say it's not even possible then.


No. It's possible. As Adi said, you need complex session
processing for that. BTW, I don't mean disabling "Open new window"
option of browser---I mean if the user opens a new window, then prompt
a error message or force log off.

My bank ( http://www.icicibank.com/ )have such option. They won't
allow you to use "Stop button", or "Refresh button" or "Ctrl+N" or
"Open link in new window". If you do so, then they will force log off
telling that it's for security purpose.


Well they can obviously do that because you have to log in and thus they can
link all your actions to you as a person. But in the general case you don't
have that luxury.

But really, instead of disallowing the Stop, Refresh and CTRL-N buttons the
bank should get a fucking clue and implement their system so that it can
handle those sorts of things. Doesn't sound like a bank I would want to
use. "Our security depends on the user's ability to not make mistakes.".
Right.

André Næss
Jul 17 '05 #8
ng**********@rediffmail.com (R. Rajesh Jeba Anbiah) schrieb:
Eric Kincl <Er**@Kincl.net_NO_SPAM_> wrote in message news:<3f******@news.gvsu.edu>...
I would say it's not even possible then.


No. It's possible. As Adi said, you need complex session
processing for that. BTW, I don't mean disabling "Open new window"
option of browser---I mean if the user opens a new window, then prompt
a error message or force log off.

My bank ( http://www.icicibank.com/ )have such option. They won't
allow you to use "Stop button", or "Refresh button" or "Ctrl+N" or
"Open link in new window". If you do so, then they will force log off
telling that it's for security purpose.


Which information do they use for this? IPs can change (Proxy!) and
browsers can change.

Regards,
Matthias
Jul 17 '05 #9
Matthias Esken <mu******************@usenetverwaltung.org> wrote in message news:<bp**********@usenet.esken.de>...
ng**********@rediffmail.com (R. Rajesh Jeba Anbiah) schrieb:
Eric Kincl <Er**@Kincl.net_NO_SPAM_> wrote in message news:<3f******@news.gvsu.edu>...
I would say it's not even possible then.


No. It's possible. As Adi said, you need complex session
processing for that. BTW, I don't mean disabling "Open new window"
option of browser---I mean if the user opens a new window, then prompt
a error message or force log off.

My bank ( http://www.icicibank.com/ )have such option. They won't
allow you to use "Stop button", or "Refresh button" or "Ctrl+N" or
"Open link in new window". If you do so, then they will force log off
telling that it's for security purpose.


Which information do they use for this?


I don't know about their implementation. The pages are in JSP. I
think, they're doing this with session. Also, their system is somewhat
buggy---sometimes the system fails to recognize the use of "Stop
button" or "Refresh button" or "Ctrl+N"...

Here is my simple, quick (but buggy) solution:

<?php
session_start();
header('Cache-Control: no-store, no-cache, must-revalidate'); //don't
cache the page

if (isset($_SESSION[$_SERVER['PHP_SELF']]))
{
echo 'Error: You cannot see a page more than once or open more
than one window.';
}
else //no problem...
{
$_SESSION[$_SERVER['PHP_SELF']] = 1;
echo 'Hello, World!.';
//show other contents...
}
?>

---
"There are two kinds of people, those who do the work and those who
take the credit. Try to be in the first group; there is less
competition there."---Indira Gandhi
Email: rrjanbiah-at-Y!com
Jul 17 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Michael | last post by:
I have broken PythonWin and I don't know how or why. It worked great until recently. I have installed / removed several apps since it worked last. I could have a virus unknown to my antivirus...
6
by: Les | last post by:
Hi, I'd like to find out how to use the window.open() script in Fireworks MX. I have posted my question in the Fireworks forum but didn't get any replies. Since it's javascript, maybe someone...
10
by: Marshall Dudley | last post by:
When I do the following line in Netscape, the popup loads as it should, but the parent window usually, but not always, reloads as well. <a href="#"...
2
by: Larry R Harrison Jr | last post by:
I have pull-down menus in javascript and I have the code for opening a link in a new window. But I want it to open a full-sized window. I can't figure out the syntax. What I have so far: ...
8
by: Dominic Tocci | last post by:
I'm searching for a way to use window.open on my web page to open a window in firefox that allows the sidebars to work (bookmarks, history, etc). When I use the following: var...
19
by: LP | last post by:
I am using (trying to) CR version XI, cascading parameters feature works it asks user to enter params. But if page is resubmitted. It prompts for params again. I did set...
4
by: danielmcbrearty | last post by:
Hi Can anyone tell me why the following javascript code doesn't work with IE6? (It's fine with Firefox of course ...) (in teh document head) <script type="text/javascript"...
4
by: jwlum | last post by:
I have the following problem under Internet Explorer only: 1. User fills out form data (myform.php) and clicks a button that fires myFunction() 2. myFunction() spawns a "hello, world" popup page...
13
by: Geoff Fox | last post by:
I am in the final moments of designing a new website. One of the pages (http://www.auditionfactory.com/samples.php) has four links to show sample work. I would like these links to open new...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.