Buy Sell Discuss UK Domain Names at AcornDomains.co.uk Domain Monster Domain Name Registration

Today's Drop Dates are: 19-02-2012 or 26-02-2012   All times are GMT. The time now is 12:47:54 PM.
Domain Name Sales Domain Software Calculate UK Domain Drop Dates Domain Registration NameDrive Domain Parking Subscribe to our Domains For Sale newsletter
Go Back   Domain Forum Acorn Domains Buy Sell Auction UK Domains > Website Design and Promotion > Website Design > Scripts and Coding
Connect with Facebook

Scripts and Coding PHP, MySQL, scripts

Closed Thread
 
LinkBack Thread Tools Display Modes
Old 11-11-2011, 11:59:00 PM     #1 (permalink)

 
Rob_F's Avatar
 
Join Date: Apr 2007
Posts: 1,085
Rob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond repute
Classified Rating: 100% (1)

Quick htaccess redirect question

RewriteCond %{HTTP_HOST} ^domain.co.uk$ [OR]
RewriteCond %{HTTP_HOST} ^www.domain.co.uk$
RewriteRule ^/?$ "\/domain\.php" [R=301,L]

What would I need to add to the above to forward domain.co.uk/anything to domain.php?

Thanks for your time.

- Rob
Rob_F is offline  
Old 12-11-2011, 12:42:26 PM     #2 (permalink)
Administrator
 
admin's Avatar
 
Join Date: Jun 2004
Posts: 8,601
admin has disabled reputation

Does this help?

http://seo-website-designer.com/HtAc...rect-Generator
admin is offline  
Old 12-11-2011, 01:33:46 PM     #3 (permalink)

 
davedevelopment's Avatar
 
Join Date: May 2009
Location: Brough, East Yorks
Posts: 993
davedevelopment has a reputation beyond reputedavedevelopment has a reputation beyond reputedavedevelopment has a reputation beyond reputedavedevelopment has a reputation beyond reputedavedevelopment has a reputation beyond reputedavedevelopment has a reputation beyond reputedavedevelopment has a reputation beyond reputedavedevelopment has a reputation beyond reputedavedevelopment has a reputation beyond reputedavedevelopment has a reputation beyond reputedavedevelopment has a reputation beyond repute

Quote:
Originally Posted by Rob_F View Post
RewriteCond %{HTTP_HOST} ^domain.co.uk$ [OR]
RewriteCond %{HTTP_HOST} ^www.domain.co.uk$
RewriteRule ^/?$ "\/domain\.php" [R=301,L]

What would I need to add to the above to forward domain.co.uk/anything to domain.php?

Thanks for your time.

- Rob
Try:

Code:
RewriteCond %{HTTP_HOST} ^domain.co.uk$ [OR]
RewriteCond %{HTTP_HOST} ^www.domain.co.uk$
RewriteRule ^ /domain.php [R=301,L]
davedevelopment is offline  
Old 12-11-2011, 02:07:38 PM     #4 (permalink)

 
Rob_F's Avatar
 
Join Date: Apr 2007
Posts: 1,085
Rob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond repute
Classified Rating: 100% (1)

Quote:
Originally Posted by davedevelopment View Post
Try:

Code:
RewriteCond %{HTTP_HOST} ^domain.co.uk$ [OR]
RewriteCond %{HTTP_HOST} ^www.domain.co.uk$
RewriteRule ^ /domain.php [R=301,L]

Thanks Dave, however that doesn't appear to work...

---
The page isn't redirecting properly

Firefox has detected that the server is redirecting the request for this address in a way that will never complete.

---

The clarify what I'm trying to do...

At the moment I have quite a few domains parked with my hosting account and redirected to personalised landers...

e.g. connexity.co.uk redirects to /connexity.php

The problem is that if I tack /index.htm on to the end of connexity.co.uk, it redirects to my main domain index page, which is causing indexing problems in google.

I was hoping there would be a way for me wildcard any /whateverfile traffic to the correct connexity.php page?

Thanks,
- Rob
Rob_F is offline  
Old 12-11-2011, 03:37:50 PM     #5 (permalink)
dta

 
Join Date: Jul 2009
Posts: 388
dta has much to be proud ofdta has much to be proud ofdta has much to be proud ofdta has much to be proud ofdta has much to be proud ofdta has much to be proud ofdta has much to be proud ofdta has much to be proud ofdta has much to be proud ofdta has much to be proud of

use:
RewriteRule ^(.*)$ domain.php?val=$1 [L]

you can pick up the val variable to do some conditional processing if you need.
if not just remove the ?val=$1 from above and it will still work
dta is offline  
Old 12-11-2011, 03:49:46 PM     #6 (permalink)

 
Nick's Avatar
 
Join Date: Apr 2008
Posts: 730
Nick has a reputation beyond reputeNick has a reputation beyond reputeNick has a reputation beyond reputeNick has a reputation beyond reputeNick has a reputation beyond reputeNick has a reputation beyond reputeNick has a reputation beyond reputeNick has a reputation beyond reputeNick has a reputation beyond reputeNick has a reputation beyond reputeNick has a reputation beyond repute

Is there a reason you need connexity.php?

Why couldn't you just use www.connexity.co.uk and map everything through index without any .php file would be much cleaner and google would prefer
Nick is online now  
Old 12-11-2011, 04:14:26 PM     #7 (permalink)

 
Rob_F's Avatar
 
Join Date: Apr 2007
Posts: 1,085
Rob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond repute
Classified Rating: 100% (1)

Quote:
Originally Posted by dta View Post
use:
RewriteRule ^(.*)$ domain.php?val=$1 [L]

you can pick up the val variable to do some conditional processing if you need.
if not just remove the ?val=$1 from above and it will still work
That doesn't appear to work for me, unless I'm compiling the code incorrectly.

- Rob
Rob_F is offline  
Old 12-11-2011, 04:21:36 PM     #8 (permalink)

 
Rob_F's Avatar
 
Join Date: Apr 2007
Posts: 1,085
Rob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond reputeRob_F has a reputation beyond repute
Classified Rating: 100% (1)

Quote:
Originally Posted by nick279 View Post
Is there a reason you need connexity.php?

Why couldn't you just use www.connexity.co.uk and map everything through index without any .php file would be much cleaner and google would prefer
The landers use a lot of php includes, which I like because I can make changes across all landers in one shot. To be honest, would be a pain to change things now. Google doesn't appear to mind so far (well over a year). Most of the domains that resolve to these landers rank fairly well.

It is however causing problems for the reasons outlined above. This is a recent problem by the way. Google handled things just fine until a week or so ago.

- Rob

Last edited by Rob_F; 12-11-2011 at 04:29:30 PM.
Rob_F is offline  
Closed Thread



Bookmarks

Thread Tools
Display Modes

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

Similar Threads
Thread Thread Starter Domain Name Community Replies Last Post
Amazon Associates - Quick Question mattharwood Affiliate Marketing 4 16-11-2010 11:36:55 PM
htaccess redirect question... mat Website Design 5 01-07-2010 09:46:57 AM
Quick Question For A Solicitor retired_member6 General Board 1 11-10-2009 01:32:45 PM
quick question on bad faith Mendis Domain Name Disputes 4 22-03-2006 09:59:30 PM

Web Hosting from UK2 from just 99p


All times are GMT. The time now is 12:47:54 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.6.0 RC 2
All content on Acorn Domains is member generated and is not moderated before posting. All content is viewed and used by you at your own risk and AD does not warrant the accuracy or reliability of any of the information. The views expressed are those of the individual contributors and not necessarily those of AD. Please contact us to report any issues or send a PM to "Admin".