![]() |
![]() |
![]() |
||||
Welcome to the GoFuckYourself.com - Adult Webmaster Forum forums. You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content and access many other special features. Registration is fast, simple and absolutely free so please, join our community today! If you have any problems with the registration process or your account login, please contact us. |
![]() ![]() |
|
Discuss what's fucking going on, and which programs are best and worst. One-time "program" announcements from "established" webmasters are allowed. |
|
Thread Tools |
![]() |
#1 |
Confirmed User
Join Date: Jan 2005
Posts: 1,648
|
Is using PHP faster than htaccess?
Say I wanted to 301 redirect traffic to different page depending on HTTP referer, will using PHP be better?
Under high traffic (200k uniques per day). |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#2 |
Confirmed User
Join Date: Oct 2004
Location: up in gang bang heaven
Posts: 3,726
|
you wouldnt think so since .htaccess is a coded part of apache and other web servers, i never have tried, give it a try and see how it works out.
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#3 |
<&(©¿©)&>
Industry Role:
Join Date: Jul 2002
Location: Chicago
Posts: 47,882
|
.htaccess should be faster...
__________________
Custom Software Development, email: woj#at#wojfun#.#com to discuss details or skype: wojl2000 or gchat: wojfun or telegram: wojl2000 Affiliate program tools: Hosted Galleries Manager Banner Manager Video Manager ![]() Wordpress Affiliate Plugin Pic/Movie of the Day Fansign Generator Zip Manager |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#4 |
Confirmed User
Join Date: Apr 2003
Location: Loveland, CO
Posts: 5,526
|
If possible, modify your apache VirtualHost which would be the fastest since it's not checked on each page request. However, I'm not 100% certain that the .htaccess file is.
So don't read this post, because I dunno what I'm saying. Sorry. ![]()
__________________
Your post count means nothing. |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#5 |
Too lazy to set a custom title
Join Date: Jan 2005
Posts: 2,961
|
htaccess is much faster than php, at the (small) expense of having to run mod_rewrite
__________________
![]() ZangoCash - Turn Your Traffic Into Ca$h. $.40 Per Install - No Tier |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#6 |
Confirmed User
Join Date: Dec 2002
Location: Sweden/Spain you sum bitch!
Posts: 6,576
|
Php doesnt stand a chance
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#7 |
Too lazy to set a custom title
Industry Role:
Join Date: May 2004
Location: West Coast, Canada.
Posts: 10,217
|
If you can (dedicated server for example), put anything "permanent" into your web server config file and not the htaccess file... the htaccess file has to be loaded for each request... That will be the absolute fastest.
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#8 |
Confirmed User
Join Date: Feb 2005
Location: Manila
Posts: 400
|
put the config line in httpd.conf first - this is faster because the settings are loaded into memory after apache was started. unlike .htaccess which are loaded everytime the page is access.
php vs htaccess = i think php, but not 100% sure
__________________
![]() | offshore solutions | manual labor | staff leasing | and more! Dedicated -Motivated-Managed Employees icq.: 309570461 live chat |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#9 | |
Confirmed User
Join Date: Jan 2005
Posts: 1,648
|
Quote:
![]() |
|
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#10 |
Too lazy to set a custom title
Join Date: Jun 2004
Location: Brasil
Posts: 15,778
|
I have absolute no clue about it....but it would be interesting to find out...
__________________
Do you need cheap, fast and reliable porn website hosting? Host Head is the way to go!! Asian Gay Special | Live on MSN - Live Webcam Chat | Live Adult Webcam Performances | MY SWEET BLACKS LIVE ON CAM Pukka Tranny | Tattooed Shemales | She's A He | Menu Porno | Porn Performances | All Chubby MY ICQ# 169833797 |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#11 |
Confirmed User
Join Date: Jan 2002
Posts: 971
|
can i have an image directory protected from the httpd.conf instead with an .htaccess file when the .htaccess file in the domain.com/images/ directory looks like:
RewriteEngine On RewriteCond %{HTTP_REFERER} !^http://(www\.)?domain\.com/ [NC RewriteCond %{HTTP_REFERER} !^$ RewriteRule \.(jpe?g|gif|bmp|png)$ http://www.domain.com/ [L] and what would that code be? many thanx.
__________________
Signature Spot - USD 5000 / month |
![]() |
![]() ![]() ![]() ![]() ![]() |
![]() |
#12 |
Too lazy to set a custom title
Industry Role:
Join Date: Aug 2002
Posts: 55,372
|
there is a lot you can do with mod_rewrite.
you can go really deep into it. there are some really good docs on it
__________________
Since 1999: 69 Adult Industry awards for Best Hosting Company and professional excellence. ![]() WP Stuff |
![]() |
![]() ![]() ![]() ![]() ![]() |