# Extreme Mod rewrite for clean URLS?

**URL:** <https://forum.kirupa.com/t/extreme-mod-rewrite-for-clean-urls/223502>\
**Category:** programming\
**Created:** [April 23, 2007, 12:14pm UTC](https://forum.kirupa.com/t/extreme-mod-rewrite-for-clean-urls/223502 "2007-04-23T12:14:39Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![duncanhall](https://avatars.discourse-cdn.com/v4/letter/d/ad7895/32.png) [@duncanhall](https://forum.kirupa.com/u/duncanhall)\
**Post date:** [April 23, 2007, 12:14pm UTC](https://forum.kirupa.com/t/extreme-mod-rewrite-for-clean-urls/223502/1 "2007-04-23T12:14:39Z")

</div>

I’ve read through Mirans new article on this, and it was definately useful, but not quite what I’m looking for.

I’m developing a site for a college, which will cater for around 100 students. At the moment, each of them has a portfolio page which is accessed with something like this:

portfolio.php?student=34

where the ‘student’ variable is obviously used to extract their details from a database. Using foodpks article, I could redirect

[COLOR=Green]“[college.com/portfolio/34](http://college.com/portfolio/34)”[/COLOR] to[COLOR=Green] “[college.com/portfolio.php?student=34](http://college.com/portfolio.php?student=34)”[/COLOR]

which is lovely, but what I \*\*really \*\*want to be able to do is redirect something like

[COLOR=Green]“[college.com/portfolio/jimmy\_johnson](http://college.com/portfolio/jimmy_johnson)”[/COLOR]  
to  
[COLOR=Green]“[college.com/portfolio.php?student=34](http://college.com/portfolio.php?student=34)”

[COLOR=Black]Is there any sensible way of being able to do this, without having to use the student names to access the details?

[/COLOR][/COLOR][COLOR=Green][/COLOR]

[COLOR=Green][COLOR=Black]  
[/COLOR][/COLOR]
