473,545 Members | 2,042 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Speed Bumps

anyone know how to set up a 'speed bump'.

once someone clicks on an external link on my website, I want a page to come
up that says you are leaving my site, with an OK button. once the OK button
is clicked I want to go to the original link that was clicked on.

any ideas.
May 12 '06 #1
17 2497

<sl****@charter .net> wrote in message
news:44******** **************@ news.astraweb.c om...
anyone know how to set up a 'speed bump'.

once someone clicks on an external link on my website, I want a page to come up that says you are leaving my site, with an OK button. once the OK button is clicked I want to go to the original link that was clicked on.

any ideas.


It feels like my eyes being removed by chopsticks.
May 13 '06 #2
sl****@charter. net wrote:
anyone know how to set up a 'speed bump'.

once someone clicks on an external link on my website, I want a page to come
up that says you are leaving my site, with an OK button. once the OK button
is clicked I want to go to the original link that was clicked on.

any ideas.


Can't do it. The external link will go to the other server. Your server won't
even know it happened.

And you should ask in alt.html. This isn't a PHP question (since PHP is
server-side only).

--
=============== ===
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attgl obal.net
=============== ===
May 13 '06 #3
This isn't PHP, but you'd probably want to use JavaScript.
Try something like this (attributes removed for readability):

<html>
<head>
<script>
function speedBump(){
/*---------Code to delay exit--------*/
}
</script>
</head>
<body onunload="speed Bump()">
</body>
</html>

May 13 '06 #4
sl****@charter. net wrote:
anyone know how to set up a 'speed bump'.

once someone clicks on an external link on my website, I want a page to come
up that says you are leaving my site, with an OK button. once the OK button
is clicked I want to go to the original link that was clicked on.
You're trying to slow down the people who are "leaving" by
second-guessing them? (Metaphors are fun but can mislead: I can
follow an external link without "leaving" your page.) In a world where
people are always in a rush, standing in their way could well earn you
a punch in the nose!
any ideas.


Pub?

--
Jock

May 13 '06 #5
I think a better option would to use framing, have your own top frame saying
it aint your website, and maybe a link to go back to your website. An
option?

<sl****@charter .net> wrote in message
news:44******** **************@ news.astraweb.c om...
anyone know how to set up a 'speed bump'.

once someone clicks on an external link on my website, I want a page to
come
up that says you are leaving my site, with an OK button. once the OK
button
is clicked I want to go to the original link that was clicked on.

any ideas.

May 13 '06 #6
Carved in mystic runes upon the very living rock, the last words of
<sl****@charter .net> of comp.lang.php make plain:
anyone know how to set up a 'speed bump'.

once someone clicks on an external link on my website, I want a page
to come up that says you are leaving my site, with an OK button. once
the OK button is clicked I want to go to the original link that was
clicked on.

any ideas.


Yep -- don't do it. It can be done quite easily with PHP, but if I were
on your site and ran into your "speed bump", I doubt I'd be back. If I
clicked the link in the first place, that's where I want to go. Making me
click again is only going to be annoying.

--
Alan Little
Phorm PHP Form Processor
http://www.phorm.com/
May 13 '06 #7
Carved in mystic runes upon the very living rock, the last words of Alan
Little of comp.lang.php make plain:
Carved in mystic runes upon the very living rock, the last words of
<sl****@charter .net> of comp.lang.php make plain:
anyone know how to set up a 'speed bump'.

once someone clicks on an external link on my website, I want a page
to come up that says you are leaving my site, with an OK button.
once the OK button is clicked I want to go to the original link that
was clicked on.

any ideas.


Yep -- don't do it. It can be done quite easily with PHP, but if I
were on your site and ran into your "speed bump", I doubt I'd be back.
If I clicked the link in the first place, that's where I want to go.
Making me click again is only going to be annoying.


Actually, upon further consideration, I can think of a situation where it
might be valid, if you want to make it clear that the visitor is leaving
your site, and you have no connection with the site they're going to. For
example, if you were writing an article on hate groups, and wanted to
link to some of their sites.

So, just write a script that takes a URL in the query string, display
your warning, and output the URL in a link. Then link to that in your
article or whatever.

But if it's just for, "Aww, shucks -- are you sure you want to leave my
excellent site????" -- don't do it. You will be regarded with contempt by
your visitors.

--
Alan Little
Phorm PHP Form Processor
http://www.phorm.com/
May 13 '06 #8
Rik
Alan Little wrote:
Carved in mystic runes upon the very living rock, the last words of
Alan Little of comp.lang.php make plain:
Carved in mystic runes upon the very living rock, the last words of
<sl****@charter .net> of comp.lang.php make plain:
anyone know how to set up a 'speed bump'.

once someone clicks on an external link on my website, I want a page
to come up that says you are leaving my site, with an OK button.
once the OK button is clicked I want to go to the original link that
was clicked on.

any ideas.


Yep -- don't do it. It can be done quite easily with PHP, but if I
were on your site and ran into your "speed bump", I doubt I'd be
back. If I clicked the link in the first place, that's where I want
to go. Making me click again is only going to be annoying.


Actually, upon further consideration, I can think of a situation
where it might be valid, if you want to make it clear that the
visitor is leaving your site, and you have no connection with the
site they're going to. For example, if you were writing an article on
hate groups, and wanted to link to some of their sites.


Another valid reason would be a (more or less secure) "logged in" area, and
displaying a warning you're leaving that area.
It could be done in PHP, but it would mean converting all your links, which
is a hassle. A quick temporary solution would be to turn on outbut
buffering, and searsching replacing links with preg_replace(). It's not
something I'd choose as a permanent solution though, it's unneccesary extra
memory and processing compared to doing it correctly.

Grtz,
--
Rik Wasmus
May 13 '06 #9
sl****@charter. net wrote:
anyone know how to set up a 'speed bump'.

once someone clicks on an external link on my website, I want a page to come
up that says you are leaving my site, with an OK button. once the OK button
is clicked I want to go to the original link that was clicked on.

any ideas.


<a href="http://www.google.com/" onClick="alert( 'You are about to leave
this site.')">Go To Google</a>

Regards

May 13 '06 #10

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

Similar topics

13
23018
by: Yang Li Ke | last post by:
Hi guys, Is it possible to know the internet speed of the visitors with php? Thanx -- Yang
8
2964
by: Rob Ristroph | last post by:
I have tried out PHP 5 for the first time (with assistance from this group -- thanks!). The people I was working with have a site that uses lots of php objects. They are having problems with speed. They had a vague idea that PHP5 has improved handling of objects over PHP4, so it would probably be faster also. In fact it seems slower. ...
34
2438
by: Jacek Generowicz | last post by:
I have a program in which I make very good use of a memoizer: def memoize(callable): cache = {} def proxy(*args): try: return cache except KeyError: return cache.setdefault(args, callable(*args)) return proxy which, is functionally equivalent to
8
1745
by: Fabri | last post by:
I have to move 2 layers (one from up to center and one from bottom to center) and I found this way: <div id="up" style="position:absolute;left:10px;top:-20px">Up</div> <div id="down" style="position:absolute;left:10px;top:200px">Down</div> function movediv(){ var u = document.getElementById("up") var d = document.getElementById("down")...
7
3038
by: YAZ | last post by:
Hello, I have a dll which do some number crunching. Performances (execution speed) are very important in my application. I use VC6 to compile the DLL. A friend of mine told me that in Visual studio 2003 .net optimization were enhanced and that i must gain in performance if I switch to VS 2003 or intel compiler. So I send him the project and...
6
2018
by: Ham | last post by:
Yeah, Gotto work with my VB.Net graphic application for days, do any possible type of code optimization, check for unhandled errors and finally come up with sth that can't process 2D graphics and photos at an acceptable speed. I have heard things about the virtual machine of Mr. Net, that it can run my app at a high speed....but could never...
6
6234
by: Jassim Rahma | last post by:
I want to detect the internet speed using C# to show the user on what speed he's connecting to internet?
11
6476
by: kyosohma | last post by:
Hi, We use a script here at work that runs whenever someone logs into their machine that logs various bits of information to a database. One of those bits is the CPU's model and speed. While this works in 95% of the time, we have some fringe cases where the only thing returned is the processor name. We use this data to help us decide which...
4
8597
by: nestle | last post by:
I have DSL with a download speed of 32MB/s and an upload speed of 8MB/s(according to my ISP), and I am using a router. My upload speed is always between 8MB/s and 9MB/s(which is above the max upload speed), ALWAYS. However, my download speed doesn't go over 25MB/s. And when my brother turns on the internet from his computer and takes up half the...
0
7410
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 effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7668
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
7923
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7437
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7773
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
5984
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
4960
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
1
1025
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
722
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

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.