Welcome to WebmasterWorld Guest from 54.146.201.80

Forum Moderators: Ocean10000 & incrediBILL & phranque

Message Too Old, No Replies

how to hide the redirect query string in httpd.conf file?

     
11:07 am on Sep 4, 2013 (gmt 0)

New User

joined:Aug 31, 2013
posts: 17
votes: 0


RedirectMatch /(.*)/(.*)/(.*)/ http://example.com/myphp/redirect.php?$0

when i redirect to that particular redirect page..that Query string value need to hide... no one see..but inside i want that query string value also..any option inside there RedirectMatch.

Thank u

[edited by: phranque at 11:19 am (utc) on Sep 4, 2013]
[edit reason] Please Use Example.com [webmasterworld.com] [/edit]

11:18 am on Sept 4, 2013 (gmt 0)

Administrator

WebmasterWorld Administrator phranque is a WebmasterWorld Top Contributor of All Time 10+ Year Member Top Contributors Of The Month

joined:Aug 10, 2004
posts:10544
votes: 8


you have to use mod_rewrite directives (RewriteRule/RewriteCond) to examine or remove the query string.

http://example.com/myphp/redirect.php?$0

$0 has no value
11:22 am on Sept 4, 2013 (gmt 0)

New User

joined:Aug 31, 2013
posts: 17
votes: 0


While redirecting me only pass that values..Go to someother page..

redirect /something/here these two values i passed to one php file..that query string i get it..that quyery string hide only not need to remove
11:31 am on Sept 4, 2013 (gmt 0)

Senior Member from US 

WebmasterWorld Senior Member lucy24 is a WebmasterWorld Top Contributor of All Time Top Contributors Of The Month

joined:Apr 9, 2011
posts:12716
votes: 244


Edit: Whoops! Whole long discussion took place while I had another tab open.


mod_alias (Redirect by that name) doesn't do query strings. For that you need mod_rewrite (RewriteRule with [R] flag). Which, in turn, means that any existing redirects need to be changed over from mod_alias to mod_rewrite.

You can't hide a query string; you can only disguise it as something else, like

example.com/aa/bb/cc >> example.com/index.php?one=aa&two=bb&three=cc

There's no {display: none;} for URL elements :(
 

Join The Conversation

Moderators and Top Contributors

Hot Threads This Week

Featured Threads

Free SEO Tools

Hire Expert Members