homepage Welcome to WebmasterWorld Guest from 54.167.173.250
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member

Home / Forums Index / Code, Content, and Presentation / Apache Web Server
Forum Library, Charter, Moderators: Ocean10000 & incrediBILL & phranque

Apache Web Server Forum

    
RewriteMap not working? Why?
brand404




msg:4644734
 10:15 am on Feb 13, 2014 (gmt 0)

I am trying to figure out why my server doesnt work with RewriteMap directive (ie, "RewriteMap myunescape int:unescape).

More specifically i am trying to use the "unescape" feature. I've tried very simple examples (as found on Apache site) and the results are as if the use of ${myunescape:$1} is being ignored. It's like it doesnt understand the "${..}" part and just fails.

Any ideas?

 

phranque




msg:4644798
 2:08 pm on Feb 13, 2014 (gmt 0)

if you have access to the server config you could turn on rewrite logging.

i would also check the server error log.

lucy24




msg:4644824
 3:17 pm on Feb 13, 2014 (gmt 0)

Is it your own server, or do you mean simply the server that your site is hosted on? The difference is crucial when it comes to RewriteMaps.

brand404




msg:4645017
 5:14 am on Feb 14, 2014 (gmt 0)

thanks for the heads up as i discovered by asking the admin (im hosting on a shared server) and he made me aware that one needs access to the server .conf file since it is not available via httacess file :(

Not a big deal since i decided to just recreate the same thing within php.

phranque




msg:4645021
 5:38 am on Feb 14, 2014 (gmt 0)

oops!

i forgot about that part.

http://httpd.apache.org/docs/current/mod/mod_rewrite.html#rewritemap
Syntax: RewriteMap MapName MapType:MapSource
Context: server config, virtual host

lucy24




msg:4645104
 9:53 am on Feb 14, 2014 (gmt 0)

You can USE a RewriteMap in htaccess-- but only if it has been declared in config AND you know the name it has been given. This is not the kind of thing that a shared host would usually bother to do. (I once asked mine, and learned that they simply hadn't installed the RewriteMaps. You need at least a VPS.)

brand404




msg:4645609
 7:37 pm on Feb 15, 2014 (gmt 0)

Thanks phranque and lucy24 for both your excellent help!

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / Apache Web Server
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved