What do I put in a hyperlink to close a page?, Close a web page |
What do I put in a hyperlink to close a page?, Close a web page |
jmk909er |
Apr 29 2015, 05:06 PM
Post
#1
|
Newbie Group: Members Posts: 12 Joined: 29-July 14 Member No.: 21,321 |
I have a simple single web page and I want to have a hyperlink at the bottom to close the page as follows:
QUOTE "No thanks, I understand these offers will never be made to me again..." I want to hyperlink the sentence to close the page. I have found some solutions on the web but none seem to work. |
pandy |
Apr 29 2015, 05:33 PM
Post
#2
|
🌟Computer says no🌟 Group: WDG Moderators Posts: 20,731 Joined: 9-August 06 Member No.: 6 |
You can only do that with JavaScript. But JavaScript can only close a window that's opened by JavaScript, i.e. a classic popup window. Is that what you have?
If you want to close the main window, or any window not opened by JavaScript, it can't be done. |
pandy |
Apr 29 2015, 05:35 PM
Post
#3
|
🌟Computer says no🌟 Group: WDG Moderators Posts: 20,731 Joined: 9-August 06 Member No.: 6 |
Wait, maybe I misunderstood. What do you mean with closing a page? Close the window or just leave the page and go somewhere else?
|
jmk909er |
Apr 29 2015, 05:35 PM
Post
#4
|
Newbie Group: Members Posts: 12 Joined: 29-July 14 Member No.: 21,321 |
No its just simple HTML
|
jmk909er |
Apr 29 2015, 05:36 PM
Post
#5
|
Newbie Group: Members Posts: 12 Joined: 29-July 14 Member No.: 21,321 |
I would like to close the page
|
Christian J |
Apr 29 2015, 06:32 PM
Post
#6
|
. Group: WDG Moderators Posts: 9,656 Joined: 10-August 06 Member No.: 7 |
QUOTE "No thanks, I understand these offers will never be made to me again..." That sounds like the kind of content you'd find in a popup (or today's javascript+CSS equivalents), not in the main browser window. If it's in the main window the user would close his entire browser, which is probably not wanted. In either case javascript is the only solution, it can't be done with HTML alone. |
pandy |
Apr 29 2015, 06:59 PM
Post
#7
|
🌟Computer says no🌟 Group: WDG Moderators Posts: 20,731 Joined: 9-August 06 Member No.: 6 |
|
jmk909er |
Apr 29 2015, 09:04 PM
Post
#8
|
Newbie Group: Members Posts: 12 Joined: 29-July 14 Member No.: 21,321 |
I would like to close the page just like you would go to the top right and click on the X
It doesn't look like this can be done |
pandy |
Apr 30 2015, 10:10 AM
Post
#9
|
🌟Computer says no🌟 Group: WDG Moderators Posts: 20,731 Joined: 9-August 06 Member No.: 6 |
OK, then you mean close the WINDOW. Alas my first answer is valid then. You can only do this if the window was opened by JavaScript. So if it is a popup window you can do it, if it isn't you can't.
|
Lo-Fi Version | Time is now: 26th April 2024 - 11:15 AM |