help me url rewriting !

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
User avatar
itsmani1
Forum Regular
Posts: 791
Joined: Mon Sep 29, 2003 2:26 am
Location: Islamabad Pakistan
Contact:

help me url rewriting !

Post by itsmani1 »

i am using hn_urlrewrite.class.php and tying url rewrite script/class and having some problems using
it.
first of all i want to know :

what is htaccess-password protected script?
what is a registered_scripts array?
which is the DEFAULT MODE of rewriting all URLs
what is own serverhost?
--------------------------------------------------
4) How to configure the webserver

In the root directory you need a htaccess file with an entry like:

<Files goto>
ForceType application/x-httpd-php
</Files>

where 'goto' is the name of the rewrite-script, which resides also
in the root dir. In class configuration you have to register this
scriptname also in constant named: URL_REWRITE_SCRIPT, but here
you must add the leading slash: define('URL_REWRITE_SCRIPT','/got');

This forces apache to call the rewriter script for every request,
beginning with /goto. ????????????

what is goto?
define('URL_REWRITE_SCRIPT','/got'); ?? what is this?
-----------------------------------------------------

Code: Select all

<?PHP
header("Cache-control: private"); 
?>
what this hader will do?
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

itsmani1 wrote:RewriteEngine on
RewriteRule ^pag/([^/\.]+)/?$ index.php?pag=$1 [L]
RewriteRule ^catid/([^/\.]+)/?$ index.php?catid=$1 [L]

i am using above code in my .htaccess file...
problem is ::
RewriteRile ^pag/([.....])...........
is working but 3rd line is not working???
i need helppppppppp
This was posted in the wrong thread.

Read the documentation on mod_rewrite again.

http://httpd.apache.org/docs/mod/mod_rewrite.html
Post Reply