strip - Stripping "&Itemid=XX" out of my URLS using .htaccess -
i need strip out part of urls being generated , want use .htaccess.
some links being appended "&itemid=xx" after .html.
example: http://www.site.com/conferences-and-events.html&itemid=xx
xx 1 digit or 4 guess need wild card part. know other questions have been answered related stripping out parts of urls using .htaccess can't seem figure out how specific string stripped out. appreciated , sorry being redundant , dense.
you'll want use url rewriting that, should work;
rewriteengine on rewriterule (.*)&itemid=\d{1,4}(.*) $1$2 [r] explanation: regular expression matches ((.*)) followed &itemid= [1 4 decimals], followed (another (.*)), , redirects ([r]) first concatenated second anything, taking out &itemid=xx part.
Comments
Post a Comment