Apache Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsSystem AdministrationApache Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old December 17th, 2001, 02:31 PM
Paulblo Paulblo is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Nov 2000
Location: San Jose, CA
Posts: 57 Paulblo User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 13 m 14 sec
Reputation Power: 8
Entrance Page (always the same)

Is it possible to configure apache so no matter what page is requested, weather it is the index.html or the otherpage.html
that apache would automatically sent them to a page that would collect data or check for plugins, browser, etc then send them back to the originally requested page?

Here is a illistration:

If I go to www.domain.coom/coolpages/page3.html I will be refered to www.domain.coom/check.html then depending on the users information it will send them to the flash version or graphic version or a certain browser configured page.

I know I can do this if somone goes to a specific page like www.domain.coom/index.html, but what if they drop in on another page?

Any tips?
__________________
Thank you,

Paul B Hepworth

Questions & Answers http://www.lds.org

Reply With Quote
  #2  
Old December 17th, 2001, 02:56 PM
freebsd freebsd is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2001
Posts: 5 freebsd User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
>> apache would automatically sent them to a page that would collect data

That's the power of web programming language. You can do dynamic site with Perl, PHP or whatever u like.

>> then send them back to the originally requested page?

Wrong concept.

>> I will be refered to www.domain.coom/check.html

That's external redirect. If you'd like to do it with Apache's mod_rewrite, you need to use internal redirect.

>> will send them to the flash version or graphic version or a certain browser configured page

You need to make up your mind what is the exact info you need to get from visitors. For flash, you'd need to use dynamic page approach or perhaps plus the addition of JavaScript. Internal redirect can only check for server-side environment variables like REMOTE_ADDR.

Reply With Quote
  #3  
Old December 17th, 2001, 03:53 PM
Paulblo Paulblo is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Nov 2000
Location: San Jose, CA
Posts: 57 Paulblo User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 1 h 13 m 14 sec
Reputation Power: 8
Thanks however

Thanks Freebsd for your help,

I am very proficient in php. I have no problem with the detection of flash plug-in, browsers, etc. The area where I am not so proficient in is the last part you touched on.

>> That's external redirect. If you'd like to do it with Apache's
mod_rewrite, you need to use internal redirect.

How would I get mod rewrite to check the landing page only and not on every page request? I guess that was my main point. I am not sure mod_rewrite will do that will it? I know that it will redirect internally but how will it determine weather or not that was their fist page request?

I really appreciate your help.

Reply With Quote
  #4  
Old December 18th, 2001, 07:13 AM
freebsd freebsd is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Jan 2001
Posts: 5 freebsd User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Do a search in this forum using the search keyword: internal redirect.

>> How would I get mod rewrite to check the landing page only and not on every page request?

mod_rewrite can intercept all request URI or a particular page (the landing page).

>> how will it determine weather or not that was their fist page request?

Check HTTP_REFERER. If it's not within your domain, internal redirect them to the landing page. But using mod_rewrite is not the right approach, you should use cookie instead. Say visitors get to select a default language on the landing page, you definitely don't want them to redo all this on next visit. So I suggest you to use PHP approach.

Reply With Quote
Reply

Viewing: Dev Shed ForumsSystem AdministrationApache Development > Entrance Page (always the same)


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 2 hosted by Hostway
Stay green...Green IT