A URL rewrite engine is software that modifies a web URL's appearance (URL rewriting). Rewritten URLs (sometimes known as short, fancy URLs, or search engine friendly - SEF) are used to provide shorter and more relevant-looking links to web pages. The technique adds a degree of separation between ...

learn more… | top users | synonyms (1)

3
votes
1answer
178 views

Adding names to slug of URL

On webpages generated from user generated content, I create slugs for the URLs based on the title (just like stackoverflow does): http://www.example.com/photo/day_at_park If there's more than one ...
3
votes
4answers
2k views

How to create .htaccess to block access to a subdirectory that hosts a separate domain

So I am pretty noob at with creating code in .htaccess, but I know it is what I need to accomplish a pretty simple task. So here is what I want to do. I have a main domain, (me.com), and I am hosting ...
3
votes
2answers
484 views

Which URL format is better? domain.com/[id]/title OR domain.com/title/[id].html [duplicate]

Possible Duplicate: SEO : urls : best place for the id My site uses URL rewriting in both formats (for different things), but I'm wondering which one is the better approach? ...
3
votes
2answers
2k views

How to track subdomains with Google Analytics while having mod_rewrite redirect to a subdomain?

When users come directly to domain.com or www.domain.com, I am redirecting them to shop.domain.com via this .htaccess rewrite: RewriteEngine on RewriteCond %{HTTP_HOST} ^www.domain.com$ [OR] ...
3
votes
2answers
62 views

multiple IPs/webservers, single domain

Our main website is on a Windows server. We're migrating our Blogger blog to WordPress and I think I want to use a Linux-based webhost instead of our Windows server for this, just because I understand ...
3
votes
1answer
657 views

Wild card redirect in htaccess giving error this webpage has a redirect loop

In my website I changed the directory name "vehicles-cars" to "vehicles-cars-for-sale". When I tried to redirect using a wild card redirect from my old directory name to new directory name in my web ...
3
votes
2answers
3k views

Removing .html and index.html from URL

I'm having some problems trying to Remove the .html extension from URLs Removing 'index.html' from an URL 1) To remove the extension I have tried using this in my htaccess file. RewriteEngine on ...
3
votes
2answers
5k views

Rewrite for robots.txt and favicon.ico

I have setup some rules in which subdomains (my users) will default to where I have located the robots.txt, favicon.ico, and crossdomain.xml therefore if a user creates a site say ...
3
votes
1answer
1k views

Clean URLs without PHP file extension

I want to make my URLs clean, for example: http://sample.com/about-me instead of: http://sample.com/about-me.php This is my code: RewriteEngine On RewriteBase / RewriteCond ...
3
votes
1answer
373 views

Naked domain to “www” redirect in Windows Server 2008

I have a Windows server. I have several websites hosted on my server. Currently, I can only visit these websites if I include "www" (e.g., www.techtint.com). I want the naked form of the URL to ...
3
votes
1answer
2k views

How do I use IIS7 rewrite to redirect requests for (HTTP or HTTPS):// (www or no-www) .domainaliases.ext to HTTPS://maindomain.ext

I have multiple domain names assigned to the same site and I want all possible access combinations redirected to one domain. In other words whether the visitor uses http://domainalias.ext or ...
3
votes
1answer
260 views

URL rewriting via forward proxy

I have an app that runs inside my firewall and talks out to multiple end points via HTTP/HTTPS on a non-standard port e.g. http://endpoint1.domain.com:7171, http://endpoint2.domain.com:7171 What I ...
3
votes
1answer
157 views

URL rewrite and domain frame

I have registered the domain www.posti.sh at nic.sh. The website is on the server www.myskoob.com/postish. Unfortunately, nic.sh does not support frames, i.e. that the domain stays posti.sh as it ...
3
votes
1answer
277 views

Dynamically rewrite URLs upon the user's selection - is it possible?

In my PHP based web application, there's a form that generates a URL according to the user's selection. The form has 7 different fields, each one of them affects the final URL, none of them is ...
3
votes
1answer
176 views

Looking for a step by step guide to URL re-writing with mod_rewrite and other methods

I'm looking for step by step resource about how to rewrite URLs and have a few specific questions. I've read the documentation on mod_rewrite in Apache, but I still find myself a little lost. If ...
2
votes
2answers
236 views

Different urls to same page and redirect

I have 3 urls leading to same page // as most pages are in google, my previous website's version http://mysite.com/1234.aspx // shortcut http://mysite.com/1234 // SEO url ...
2
votes
2answers
2k views

Use .htaccess to rewrite requests for a PNG as a PHP GET variable

I'm REALLY bad with .htaccess files, and reading through the existing questions on SO only confuse me more (mainly because they're all situation-specific and don't exactly apply to my situation at ...
2
votes
2answers
275 views

Can you rewrite the root?

Not sure how to word this one but will explain most I can. I am trying to make the following happen. Re-write this http://domain.name To this http://domain.name/home/ Is it possible ? update ...
2
votes
1answer
68 views

Force google to just index rewrited urls

Let's think we have a website with a URL like http://www.domain.com/webdesign/ that rewrites http://www.domain.com/?article=1. now when i search my keyword in Google, it will show up ...
2
votes
2answers
91 views

When is it worth it to make my URLs “pretty”?

We are in 2011, search engines are now using hundreds or thousands of parameters to weight a page. The URL is only one of them, is it still so much of an impact in the search results? People are ...
2
votes
1answer
16k views

Apache: Virtual Host and .htacess for URL Rewriting not working

I have configured a virtual host in my local machine and every thing is working fine. Now I want to use SEO friendly urls. To achieve this I have used the .htaccess file. My virtual host ...
2
votes
2answers
74 views

URL rewrite - Cross domain javascript

I have a site site.domain1.com that needs to launch content from another domain - content.domain2.com but I encounter cross-domain JS issues when doing this directly. I basically need to make ...
2
votes
2answers
83 views

URL re-write for indexed pages [duplicate]

I have a blog with around 40 posts, and i want to change the URL structure these posts. this is my old URL something like: http://domain.com/blog/2013/02/04/string-here.html i want to set the URL ...
2
votes
1answer
4k views

how to rewrite %20 in .htaccess

I need to perform an equivalent rewrite to: RewriteRule ^/this%20file.pdf http://www.example.com/ How do I handle the %20? I have tried RewriteRule ^/this\%20file.pdf http://www.example.com/ ...
2
votes
1answer
1k views

Google on capital letters in url

I created one of my websites with the following url structure: http://domain.com/Animal/Pig http://domain.com/Pigs If I change the url map to lower case letters instead, will google reindex those ...
2
votes
2answers
972 views

apache rewriting url doesn't work(using godaddy hosting)

I'm using a framework to create my website(codeigniter) by default the urls are like this:mysite.com/index.php?/etc/etc/etc. And I'm trying to remove the index.php?, I tried to remove it by doing ...
2
votes
1answer
456 views

Htaccess - Rewrite png to php file

I currently use trans.png.php?id=1&campaign=test to track my newsletter campaigns. I want to use trans.png instead as it's the src of an img tag. How can i do this in htaccess? Also is there any ...
2
votes
1answer
953 views

In IIS what is the difference between rewrite rules managed by URL Rewrite Module versus those only in web.config?

In IIS what is the difference between rewrite rules managed by URL Rewrite Module versus those which are only in the web.config file and do not appear in the URL Rewrite Module? Using the URL Rewrite ...
2
votes
1answer
148 views

Changing file extensions in URIs - Server Error after Apache upgrade

Please can anyone help to identify flaw or incompatibility in .htaccess code causing server error? In the process of changing over from static to dynamic website, I had to maintain some static files ...
2
votes
2answers
65 views

Google Analytics Campaigns - cleanup URL after arriving to webpage?

After visitor lands to my webpage using campaign url: http://www.mydomain.com?utm_source=signature&utm_medium=email&utm_campaign=myname Is it possible to do a rewrite to ...
2
votes
1answer
84 views

301 redirects, query strings and SEO

We have recently consolidated one site into another one. We set up all of our 301s and those all work famously. The bulk of the 301s (including the old site's homepage) land on an interior page of ...
2
votes
1answer
222 views

do we have to add/remove a trailing slash for pagination page numbers in the url. how seo considers that?

My module is paginated. I want to either add a trailing slash or remove a trailing slash. For now i am thinking of adding a trailing slashes to all URLS. What will be the effect on adding a trailing ...
2
votes
1answer
415 views

How do I use htaccess to make a short URL to a MediaWiki page?

I'd like to rewrite /liam to /index.php/Liam_Edwards-Playne. I've currently written this below in the appropriate .htaccess file but it is still returning a 404: RewriteEngine On RewriteRule ^/liam$ ...
2
votes
1answer
282 views

.htaccess rewrite , parked domain on another site to read the proper domain name

I have a parked domain example.co.uk on another domain name web-space in a folder and need to rewrite the domain name in the browser URL as it currently shows the other domain name while browsing and ...
2
votes
1answer
208 views

Is there a SEO benefit of a 'reverse canonical redirect' back to the 'friendly' URL?

As far as I understand, you should have a single URL to access a given page on a website to prevent duplicate issues. With this in mind I have setup IIS7 Rewrite to point my friendly URLs to my .aspx ...
2
votes
1answer
225 views

How does Google handle “clean” URLs is the URL is always changing due to edits?

So, since some "clean" URL system pull the wording directly from content I was wondering how Google handles this? Here's an example of content changes changing the URLs: Version 1 of the Title: ...
2
votes
1answer
170 views

Debating between different kinds of URL and see if one is more seo-friendly than other…

So something like domain.com\x\y\z\t and domain.com\x?var1=y&var2=z&var3=t (var1, var2 and var3 will be replaced by legit words that make more sense). Which one is more SEO friendly? For my ...
2
votes
2answers
447 views

Removing the script extension with URL rewriting on Apache

Given a (slightly theoretical) physical disk layout of: \products\cameras\50d.jpg \products\cameras\20d.jpg \products\lenses\18-55.jpg \products\lenses\28-135.jpg \products.php At the moment, I've ...
2
votes
1answer
72 views

What's the quickest/cheapest way to get URL rewriting implemented?

Related to another question - if you need to get URL rewriting implemented ASAP, what are some methods that you've used or know of that can speed this up?
2
votes
1answer
29 views

Problem with htaccess rewrite condition

I needed to redirect site.com/var1/var2/var3/... to site.com/index.php?myvars=var1/var2/var3/... This is the code I wrote myself: RewriteEngine On RewriteCond %{REQUEST_URI} !=/index.php ...
2
votes
1answer
48 views

What HTTP header code does URL-Rewrite return?

If I used the native URL-Rewrite module to rewrite (not redirect) a URL, does it return 302, 301, or 200? Is this method OK to use for a permanent URL rewrite? Here is sample code for the redirect: ...
2
votes
1answer
31 views

What is the precise term for serving internal URLs to external ones?

Consider URLs to a public API: https://api.example.com/items https://api.example.com/add https://api.example.com/remove ... Internally, the calls are being served from local URLs, for example: ...
2
votes
1answer
135 views

Apache rewrite rule to add a directory in front of a file

I have an HTML page in my root directory, and when someone clicks it I'd like there to be a directory before the file name, that doesn't exist. For example, instead of just being able to access: ...
2
votes
2answers
115 views

Google adds useless parameters to my URL

I have recently added my website to Google, and I don't understand why he adds useless parameters to my URLs. Normal URL: build/view/2/akali/mid Google URL: build/view/2/akali/mid?role=adc ...
2
votes
1answer
325 views

DNS name/host-header specific url-pattern/security-constraint, to not require SSL with Tomcat6

I am needing to enable SSL on an application hosted through Tomcat6 and I have added the following to the tomcat web.xml: <security-constraint> <web-resource-collection> ...
2
votes
2answers
496 views

Apache Rewrites not working due to Akamai

I have a website which is setup with akamai. My domain and subdomains are mapped onto an Akamai IP. I have written an Apache rewrite which does an internal URL X to another internal URL Y. This ...
2
votes
1answer
2k views

nginx proxy rewrite not matching

I'm setting Nginx to forward requests to several backend services using proxy_pass A few of them I have to add rewrite rules to strip the folder off, however for this particular service, the rewrite ...
2
votes
2answers
283 views

Tool to generate list of redirections (sitemap for .htaccess)

Is there any good tool (preferably for Ubuntu), that can help me generate a list of URLs used on a site? I'm building new version of some site, but I don't want to get 404 errors for the old pages. ...
2
votes
2answers
84 views

Displaying “index.php” in URL

Is there a best practice/convention to have www.example.com as opposed to www.example.com/index.php in a site's URL? I made the links to the homepage relative (i.e. href="index.php") as opposed to ...
2
votes
1answer
1k views

Joomla 1.6 URL rewrite on IIS7 (removing /index.php/)

Joomla 1.6 was released today and I'm wondering if anyone knows how to get rid of the /index.php/ part? How link looks now: http://www.example.org/index.php/stuff How link would look after URL ...