On Thu, Jul 23, 2009 at 11:57:51AM +0800, ?????? wrote: > Hi everyone: > > I've been studying the codes of Mediawiki for some time. > > I'm convinced that the file "index.php" is the only entrance to the whole > site. > > But I cannot help myself with the url pattern : > /somepath_to_mediawiki/index.php/pagetitle. > > How can this kind of url be parsed to the file "index.php" and the > "pagetitle" be parsed as params? > > Why the web server not go straight into path "index.php/" and look for the > file named "pagetitle" ? > This type of thing is common for sites using the "MVC" or "Model-View-Controller" paradigm. The index.php file is what's called a "front controller". A front controller is usually the entrance to all the other pages of a site. URLs like this often take advantage of an Apache feature called "mod_rewrite", which tells Apache how to handle URLs which look like this. You can look on wikipedia.org for these terms or google for them, and find full explanations. Paul -- Paul M. Foster -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php