Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Brian Moon's Blog:
ForceType for nice URLs with PHP
Oct 04, 2007 @ 14:37:00

On his blog today, Brian Moon talks about setting up ForceType directives in Apache, specifically how to make "friendly URLs" without having to use mod_rewrite (which might not be installed on your server).

This has been covered before, but I was just setting up a new force type on our servers and thought I would mention it for the fun of it. You see lots of stuff about using mod_rewrite to make friendly URLs or SEO friendly URLs. But, if you are using PHP (and I guess other Apache modules) you can do it without mod_rewrite.

There's three steps to the process - adding the directive to your Apache config, making the script able to handle the request, avoiding duplication of content and returning a 404 error when there's no matching data.

tagged: forcetype url modrewrite duplicate content forcetype url modrewrite duplicate content

Link:

Brian Moon's Blog:
ForceType for nice URLs with PHP
Oct 04, 2007 @ 14:37:00

On his blog today, Brian Moon talks about setting up ForceType directives in Apache, specifically how to make "friendly URLs" without having to use mod_rewrite (which might not be installed on your server).

This has been covered before, but I was just setting up a new force type on our servers and thought I would mention it for the fun of it. You see lots of stuff about using mod_rewrite to make friendly URLs or SEO friendly URLs. But, if you are using PHP (and I guess other Apache modules) you can do it without mod_rewrite.

There's three steps to the process - adding the directive to your Apache config, making the script able to handle the request, avoiding duplication of content and returning a 404 error when there's no matching data.

tagged: forcetype url modrewrite duplicate content forcetype url modrewrite duplicate content

Link:

True Hacker! Blog:
Digg style clean URLs with PHP and Apache
Nov 29, 2006 @ 15:57:00

The 'true hacker!' blog has a new post today that gives you a quick four step process for creating some clean, Digg-style URLs for your site with some simple Apache configuration changes (mod_rewrite).

You might have noticed that Digg has a cool way of maintaining clean URLs. Digg actually uses LAMP - Linux/Apache/MySQL/PHP. But where are the .php extensions? The answer is here. 4 steps to implement your own Digg style clean URLs.

His method turns on Apache's rewrite engine (you do have mod_rewrite enabled, don't you?) and adds a rule to push all of the requests to two default PHP files. There's also a ForceType method that can be used to achieve the same effect. One .htaccess file later, you're in business and the PHP script only needs to access the $_SERVER['REQUEST_URI'] value to get the parameters.

tagged: digg style clean url apache modrewrite rule forcetype digg style clean url apache modrewrite rule forcetype

Link:

True Hacker! Blog:
Digg style clean URLs with PHP and Apache
Nov 29, 2006 @ 15:57:00

The 'true hacker!' blog has a new post today that gives you a quick four step process for creating some clean, Digg-style URLs for your site with some simple Apache configuration changes (mod_rewrite).

You might have noticed that Digg has a cool way of maintaining clean URLs. Digg actually uses LAMP - Linux/Apache/MySQL/PHP. But where are the .php extensions? The answer is here. 4 steps to implement your own Digg style clean URLs.

His method turns on Apache's rewrite engine (you do have mod_rewrite enabled, don't you?) and adds a rule to push all of the requests to two default PHP files. There's also a ForceType method that can be used to achieve the same effect. One .htaccess file later, you're in business and the PHP script only needs to access the $_SERVER['REQUEST_URI'] value to get the parameters.

tagged: digg style clean url apache modrewrite rule forcetype digg style clean url apache modrewrite rule forcetype

Link:

phpRiot.com:
Creating search engine friendly URLs in PHP
Jan 11, 2006 @ 13:03:54

PHPRiot.com has a new tutorial today dealing with the creation of "search engine friendly" URLs for your site.

One of the major reasons for using a server-side language such as PHP is for the ability to generate dynamic content. Often this will lead to single scripts that produce their content based on the input parameters (that is, the variables in the URL).

This article covers various techniques and methods for representing these parameters in the URL in a clean and "friendly" manner, as well as then how to read the parameters.

They start off with some examples of what they look like, and move right into how to use the Apache mod_rewrite functionality to take in the URL parameters and map them back to a PHP script. They also use the ForceType keyword in Apache to get the server to parse the URL string correctly. They then wrap it all up with the creation of a custom 404 page to handle the errors that might come up, and a summary of the whole project...

tagged: search engine friendly URL apache mod_rewrite ForceType search engine friendly URL apache mod_rewrite ForceType

Link:

phpRiot.com:
Creating search engine friendly URLs in PHP
Jan 11, 2006 @ 13:03:54

PHPRiot.com has a new tutorial today dealing with the creation of "search engine friendly" URLs for your site.

One of the major reasons for using a server-side language such as PHP is for the ability to generate dynamic content. Often this will lead to single scripts that produce their content based on the input parameters (that is, the variables in the URL).

This article covers various techniques and methods for representing these parameters in the URL in a clean and "friendly" manner, as well as then how to read the parameters.

They start off with some examples of what they look like, and move right into how to use the Apache mod_rewrite functionality to take in the URL parameters and map them back to a PHP script. They also use the ForceType keyword in Apache to get the server to parse the URL string correctly. They then wrap it all up with the creation of a custom 404 page to handle the errors that might come up, and a summary of the whole project...

tagged: search engine friendly URL apache mod_rewrite ForceType search engine friendly URL apache mod_rewrite ForceType

Link:


Trending Topics: