Closing Doman Auctions
DNForum - Domain Sales, Domain Forum, Domain Appraisals, Domain Registrars
HomeRegisterMembershipsGetting StartedDomain Tools Domain EbooksSEO Software Domain Resellers Advertise

Go Back   DNForum - Domain Sales, Domain Forum, Domain Appraisals, Domain Registrars > Content Development > Website Development and Design Discussion > Coding/Programming/Languages
Register Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old 07-12-2007, 09:31 AM   #1 (permalink)
Platinum Lifetime Member
 
darmar's Avatar
 
Name: Darko Martic
Last Online: 08-03-2009 02:07 AM
iTrader: (1)
Join Date: Dec 2006
Posts: 90
DNF$: 100
Location: Zagreb, Croatia
Country:

Send a message via ICQ to darmar Send a message via MSN to darmar Send a message via Yahoo to darmar Send a message via Skype™ to darmar

HTACCESS RewriteRule problem

I need some more help....

I can't get to "reuse" variables I'm passing through....

here's my example:
Quote:
RewriteEngine On
RewriteRule ^[a-zA-Z]{5}$ /test.php?myvar=%1 [R=301,L]
(yes, I'm trying to redirect all "www.example.com/abcde" calls to a specific PHP script, with that "abcde" pass as variable)

with this, I get redirected to: "test.php?myvar=" and no value for this variable "myvar"....

I also tried using "$" instead of "%" in RewriteRule statement - but I get the same....

could anybody post a working example of passing variables to script you're redirecting with RewriteRule ?


thank you



=================
reply added:
=================

here's the solution for my latest problem:

Quote:
RewriteEngine On
RewriteRule ^([a-zA-Z]{5})$ /test.php?myvar=$1 [R=301,L]
I forgot to use ( ) and I should use $ instead if %
__________________
Martic.net - Talking in binary since 1980.
TXTberry.com - Text-based services for blackberry and other mobile devices (whois, etc.).

Last edited by darmar; 07-12-2007 at 10:43 AM.. Reason: Automerged Doublepost
darmar is offline   Reply With Quote
Sponsored Ads
Old 07-22-2008, 04:57 AM   #2 (permalink)
Platinum Lifetime Member
 
darmar's Avatar
 
Name: Darko Martic
Last Online: 08-03-2009 02:07 AM
iTrader: (1)
Join Date: Dec 2006
Posts: 90
DNF$: 100
Location: Zagreb, Croatia
Country:

Send a message via ICQ to darmar Send a message via MSN to darmar Send a message via Yahoo to darmar Send a message via Skype™ to darmar

here's a nice simple tutorial I wrote:
friendly url
__________________
Martic.net - Talking in binary since 1980.
TXTberry.com - Text-based services for blackberry and other mobile devices (whois, etc.).
darmar is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Strange and mysterious problem => I'm a bit worried now ... DomainEmpire.com Help Wanted! 9 03-13-2007 02:45 AM
Need htaccess help please.... slobizman Search Engines and Traffic Building 1 07-04-2006 11:31 AM
Adsense Problem Stinos DNForum PPC Templates 11 03-19-2005 06:07 AM
SECURITY ALERT: Bogus Whois Problem Reports Domagon Domain Registration Discussion 2 11-05-2004 06:10 PM
BIG Problem Accessing This Site Duke Gold Cafe 6 09-21-2002 04:27 PM


All times are GMT -5. The time now is 01:01 AM.
Copyright @2001-2009 DNForum.com