clean-urls

Apache .htaccess mod_rewrite and clean urls

Ok. So I'm building this site which is accessible through two different domains. So I can't use RewriteBase in my .htaccess. The rules (below) I use to work around this problem seem to work fine. However, when I use the below .htaccess settings on my local box with clean URLS (WAMP) it all works fine but the moment I use this on the live...

Why should I use "Web 2.0"-style URLs?

In short, why use something like http://stackoverflow.com/badges/6/supporter instead of something "simpler" (and subjectively, at that) like http://stackoverflow.com/badges/6/. Even on my own site I've just been using /post/6/ to reference posts (by IDs, even though I still store a slug.) Instead of /post/6/small-rant-on-urls, and in so...

How do I turn off viewstate for good?

Coming from a PHP background I love using clean URLs to grab data from one service to another. However, on some of my ASP.NET projects I get the horrible ViewState parameter in my URLs. Is there a way to turn this off globally? What affect will this have on my ASP.NET app? ...

How does one encode and decode a string with Python for use in a URL?

Hi, I have a string like this: String A: [ 12234_1_Hello'World_34433_22acb_4554344_accCC44 ] I would like to encrypt String A to be used in a clean URL. something like this: String B: [ cYdfkeYss4543423sdfHsaaZ ] Is there a encode API in python, given String A, it returns String B? Is there a decode API in python, given String B,...

Remove .php extension with PHP

Hello fellows! I could use some help here. I'm using this to fix my URL but I can't figure out how to remove the .php extension. The URL looks like this now: http://mydomain.com/page.php/foo/123/bar/456 function decode_URL_parameters() { $path = @$_SERVER['PATH_INFO']; $url_array=explode('/',$path); array_shift($url_array); ...

using seo user friendly in php

Hi, this is the URL path I currently use: /index.php?page=1&title=articles I want to get the URL path as /index/page-1/title-articles using SEO user friendly URLs in PHP. And how to get the value of the "title"? Any one can help me pls. ...

Should I use mod_rewrite for my site's URLs?

My site currently handles URL's like this... /?p=home /?p=profile&userid=1 /?p=users.online /?p=users.online&page=23 /?p=mail.inbox /?p=mail.inbox&page=12 ... and so on, there is probably at least 120-150 different pages, on my site a page is built like this, index.php includes a main config file which then includes func...

Is there a better way to do this regex?

I finally figured out a good/easy way to make clean URLs with regex on my site in this format below, however it will require a very large .htaccess file, I know from the post on here that it is supposed to not be to bad on performance to use mod_rewrite but I have never really seen it used where the way I am, with a seperate entry for al...

in MOD_Rewrite / ISAPI_Rewrite, how do I make rules affect specific domains?

I just recently migrated from a linux host to a dedicated server with windows 2003, I had only one site using Mod_rewrite, but with ISAPI _Rewrite 3 free, the rules are global. How do I write a condition to affect only "mysite.com" and not the others? this is my httpd.conf file # Helicon ISAPI_Rewrite configuration file # Version 3.1....

Simple htaccess rules for clean URLs not showing static media

After looking at 4-5 different ways to get simple clean URLs for static files, we found one that was simple and easy to implement/maintain over multiple folder and files. One problem, it wont load the js/css/images from that folder it is looking at. Here is the rule - it loads the html ok, but not the images, etc which are in the /ima...

Clean PathInfo URLs and Query Strings on IIS 5.1 and PHP 5

I'm trying to get 'clean' PathInfo style URLs with query string parameters working on PHP 5.3 and IIS 5.1 using FastCGI. I've found that I can use: (1) http://www.example.com/index.php?/path/to/foo/ but not: (2) http://www.example.com/index.php/path/to/foo/ (Note the missing ?) Which isn't a big issue until I want to mix URLs with a ...

Tomcat, Groovy and clean urls

I'm trying to get Groovy running inside Tomcat with clean urls. Since my knowledge of Tomcat's url mapping and filters is quite limited, I'm running into a brick wall. What I'd like is to create a front-controller called index.groovy that handles all incoming requests. The problem is that I can't seem to figure out how to create the cor...

Apache rewrite URL but don't rewrite certain folder

I am using Apache to rewrite my URLs into clean URLs. RewriteRule ^(.*) index.php Currently this rewrites directories too, which is what I want, since I want everything run through my router/index.php file. What I would like to do however, is have one folder that I can access directly. This is for lib files such as .js and .css file...

Why would Apple.com and other sites have some pages end with .html and have clean links for others. Usability advantages?

Hi, I was wondering if anyone knew the thinking behind there decision to do this: Alot of pages on Apple.com have clean links such as: http://www.apple.com/wifi/ however some of there pages end with .html http://www.apple.com/airportexpress/features/airtunes.html I find it unlikely that these pages are static html pages so.... Why...

Java library/class to parse clean URLs and get its different components

I am looking for a java library/class to parse clean URL's and get all the properties like query, port, host , domain, subdomain etc. Essentially most of the functionality that java.net.URI does but even for clean URLs. I am guessing since this is a pretty common requirement, there might be some libraries already built to handle this. He...

Need to setup cleaner links - currently links too long - Zend framework

Hi guys, I'm using the zend framework for my project - I've tried to set up using clean links - however I've noticed that my links seem to be getting really really long and wonder if at this point there would be a way to incorporate a structure where I could user smaller links. Heres an example my website has a directory controller, whi...

Cannot enable Clean URLs on Drupal after upgrading from 6.12 to 6.15

Dear All, I have a setup with Drupal 6.12 installed on Ubuntu 9.10. It took me a while to figure out how to enable the Clean URL... but after I upgrade from 6.12 to 6.15... the radio on Clean URL was disabled and I tried so many different ways I found from google and drupal.org and was no help... Can someone please tell me is there i...

Some basic questions about Django, Pyjamas and Clean URLs

I am farily new to the topic, but I am trying to combine both Django and Pyjamas. What would be the smart way to combine the two? I am not asking about communication, but rather about the logical part. Should I just put all the Pyjamas generated JS in the base of the domain, say http://www.mysite.com/something and setup Django on a sub...

How to perform a 301 redirect of all .php URLs to clean URLs?

My htaccess isn't quite working the way I want it to. I've seen some similar threads on here but they aren't quite what I need and I don't know enough yet about htaccess to modify the code to suit my needs. This is what I have working so far: I've got all non-www URLs redirecting to www URLs and I'm doing an internal rewrite of all URLs...

How can I view the all inherited url-resolution rules affecting a given directory?

I work on two sites hosted on the same server, using the same CMS configurations and identical .htaccess files in their respective document roots. One site is letting me use the CMS's clean-url mode, and the other isn't. Site #2 functions fine in ?=messy-url mode, but when I turn clean urls on in the admin panel, and request a rewritten ...