Jump to content

Converting dynamic URLs to static URLs.


poleposters

Recommended Posts

Hi,

 

I'm working on quite a large project, and I want to add a professional touch to it. I want to convert all dynamic URLs to static.

 

ie http://www.domain.com/blog/article?id=1 to http://www.domain.com/blog/articleone.html(or close enough)

 

The site is hosted on a third party server, so I don't have access to mod_rewrite.

 

I found a great article on sitepoint, however its quite limited. Its only shown me how to turn http://www.domain.com/blog.php to http://www.domain.com/blog

 

An example of what I'd like to do is found on

 

http://www.mikebaird.com.au/interactive/mikes_blog/sat_21_march.html

 

I know that the blog articles are created from a  database. And that a file called sat_21_march.html hasn't been specifically written.What I don't know is how its being done?

 

Can someone point me in the right direction.

 

Cheers,

 

Matt

 

 

 

 

Link to comment
https://forums.phpfreaks.com/topic/165571-converting-dynamic-urls-to-static-urls/
Share on other sites

Thanks. I think you're right about it being an uphill battle.

 

I've created a .htaccess file and I get a server error when i try to use it.

 

I'm pretty sure I've named it correctly. I'm putting in my htdocs folder.

 

Below is the total contents of the file:

 

Options +FollowSymLinks

RewriteEngine on

RewriteRule index/(.*)/(.*)/$ /blog/index.php?$1=$2

 

Am i doing something wrong? Do i need to change something in my php.ini file?

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.