Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

ASP.NET Forum


You are currently viewing our ASP.NET Forum as a guest. Please register to participate.
Login



Reply
Old 03-18-2005, 01:11 PM global.asa
netcrawler's Avatar
Average Talker

Posts: 27
Location: QC, Canada
Trades: 0
Is there a way to a variable to a global.asa that would determine if a existing website link is internal or external and if internal it will let it pass but if it's a external link it will send it to a disclaimer page then redirect it to the link the user clicked?

Could i have a sample script as what would do this and that will be added to my global.asa file.

Thanks in advanced for your help.
netcrawler is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 03-19-2005, 08:45 AM
Minaki's Avatar
Defies a Status

Posts: 1,626
Location: Guildford, UK
Trades: 0
No. When you click an external link, a request is not made to your server so global.asa would never be executed.

Why not point all external links to the disclaimer page, passing the URL that they should go to as a parameter?
__________________
Minaki Serinde MCP
"Wow, Linux is nearly on-par with Windows ME!"

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
Minaki is offline
Reply With Quote
View Public Profile Visit Minaki's homepage!
 
Old 03-21-2005, 08:44 AM
netcrawler's Avatar
Average Talker

Posts: 27
Location: QC, Canada
Trades: 0
I thought of that already but our site has 2484 links... it's pretty time consuming that's why i was looking for an easier way

Thanks..
netcrawler is offline
Reply With Quote
View Public Profile
 
Old 03-21-2005, 03:39 PM
Minaki's Avatar
Defies a Status

Posts: 1,626
Location: Guildford, UK
Trades: 0
You might be able to use a text editor with regular expression find/replace. As long as you coded internal links as relative (<a href="/images/pic.jp">), and external links absolute (<a href="http://www.site.com/images/pic.jpg">) then it should be doable.

I can't help you specificly with what RegEx to use cos I've only just started learning them myself and havn't taken it all in yet. 0beron is fairly good at them though... he may be able to write you one.
__________________
Minaki Serinde MCP
"Wow, Linux is nearly on-par with Windows ME!"

Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
Minaki is offline
Reply With Quote
View Public Profile Visit Minaki's homepage!
 
Reply     « Reply to global.asa
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.28930 seconds with 12 queries