Questions tagged [friendly-url]

A friendly URL is a website address that does not contain a query string or complex strings in the URI, instead relying on a human-readable, SEO-friendly resource path after the website authority (e.g. https://www.stackoverflow.com/questions/tagged/friendly-url).

A friendly URL is a website address that does not contain a query string, instead relying on a human-readable, SEO-friendly resource path after the website authority (e.g. https://www.stackoverflow.com/questions/tagged/friendly-url).

Most of the time it is achieved with the help of a Rewrite Engine, such as mod_rewrite for Apache or mod_rewrite for Lighttpd. Many content management frameworks have the ability to generate friendly URL's built in.

1221 questions
0
votes
2 answers

Create elegant urls avoiding querystrings using native RegisterRoutes

this is the url that currently is generated for a property detail page. http://localhost:61346/Property/Details?strap=0001020005 I want this to read http://localhost:61346/Property/Details/0001020005 Here are my registered routes. Is this…
Doug Chamberlain
  • 11,192
  • 9
  • 51
  • 91
0
votes
3 answers

Friendly URLs for Sinatra

Is there anyway to achieve friendly URLs for sinatra for e.g., I want the user to see http://xyz.io/username/title instead of http://xyz.io/username/posts/xdsfsdfsdfsd/title but still route to the second URL. Is there a of achieving this…
0
votes
1 answer

Pretty URL using mod_rewrite path issue

I am using MOD_REWRITE to channel all URLs through a single file. The aim is to allow pretty urls like: http://mysite.com/shop/electrical/hoover or http://mysite.com/shop/checkout etc etc I achieve this using the following .htaccess file: # Turn on…
Relaxing In Cyprus
  • 1,976
  • 19
  • 25
0
votes
2 answers

Need silent rewrite URL in Apache

I'm running tomcat behind apache. now my need is to apply friendly url by removing parameters names from URL. i want http:////QWERTY these internally should works as http:////vid=QWERTY so in…
Gnanz
  • 1,833
  • 5
  • 24
  • 51
0
votes
1 answer

How do i get friendly url in php only?

I've wrote function in php function siteContent() { $path = array(); $strDefaultPath = '/sites/'; $_SERVER['PATH_INFO'] = isset( $_SERVER['PATH_INFO'] ) ? $_SERVER['PATH_INFO'] : $strDefaultPath; $path = explode( '/', substr(…
arclite
  • 528
  • 1
  • 6
  • 23
0
votes
2 answers

Like button - using mod re-written friendly URL and none friendly URL for count value

My site has an FB like button on a dynamic page. There are also mod re-write rules on the site to allow a friendly URL for that dynamic page. i.e the following opages are the 'same': (url 1) www.getawayearth.com/property.php?id=703 (url 2)…
0
votes
1 answer

how to "rewrite rule" for a sub-sub-directory? .htaccess/php

I have one folder named test located at www.mydomain.com/abc/files/test. I need to change the URLs from www.mydomain.com/abc/files/test/test.php?id=15&key=some-text123 to www.mydomain.com/abc/files/test/15/some-text123 this is similiar to SO urls. I…
TigerTiger
  • 10,590
  • 15
  • 57
  • 72
0
votes
1 answer

urldecode wordpress menus

Im using word press menus to show menus on my UTF-8 Hebrew site. For some reason word-press doesn't automatically implement URL decode to the links so my links are pretty ugly. %D7%9E%D7%AA%D7%9B%D7%95%D7%9F%20%D7%9E%D7%92%D7%A0%D7%99%D7%91 how can…
lior r
  • 2,220
  • 7
  • 43
  • 80
0
votes
2 answers

Htaccess rule to make urls like this ?page=1 look like /page/1 in Codeigniter

This is how my urls currently look: http://mysite.com/?page=1 How can I make this work?: http://mysite.com/page/1 There is a post on StackOverflow that asks the same question. But the accepted solution isn't working for me. Because I am using…
user967451
0
votes
1 answer

Dynamic URLs + SEO

I have a website that generates dynamic urls for all content. It uses a function to show the content on index.php page and it's called by "action". So, if the user wants to signup, there is a signup function calling it. If the user want's to browse…
Genesis
  • 1,307
  • 2
  • 13
  • 21
-1
votes
1 answer

htaccess rewrite URL website.com/?collections%5B%5D=Pandemics to website.com/Pandemics

I'm trying to learn how to rewrite URLs with htaccess but find it terribly complicated. I have a single page site that displays different content based on a submit form. I then use the parameter $_GET['collections'][0] to fetch data from a MySQL…
-1
votes
1 answer

Modify URL with .htaccess [#Q2.]

I want to modify the URL on my server using .htaccess but I'm facing some issues. In my previous question I described all the modifications I wanted. I want add some new rules along side the previous rules. RewriteEngine On # matches /site/ or…
user14817809
-1
votes
2 answers

www + http To https forward

I want to forward request like this http://www.website.com/ > https://www.website.com/ > https://website.com/ My .htaccess: RewriteEngine On RewriteBase / RewriteRule ^index\.php$ - [L] RewriteCond…
-1
votes
1 answer

Redirecting from IP Address to another with keeping other parts of url

I need help with .htaccess. I'm using apache. I want to change my server IP to another one. Example: http://127.0.0.1/files/image.png to http://192.196.1.1/files/image.png
-1
votes
1 answer

PHP and htaccess | Redirect to "page not found" if user try to directly access parameter value inside url

I have this friendly url that i'm using on my website: https://myexample.com/post/10/post-title I'm trying to do something that deny user to access directly in parameters value. For example, if user try to put another id inside url above, htaccess…
Michel
  • 15
  • 8