Jump to content
php.lv forumi

RewriteRule neizprotu


Wuu

Recommended Posts

RewriteEngine on
RewriteRule ^users/([^/\.]+)/?$ index.php?page=users&search=$1 [L]

 

^users/ - ja pieprasījums sākas ar users tad izpildīs to rūli je ne tad nē

([^/\.]+) - šis atļauj vienu vai vairākus simbolus kas nav sleš vai punkts

/?$ - nodrošina to ka pēc tam drīkst sekot tikai sleš un nekas cits

index.php?page=users&search=$1 - $1 tiks aizstāts ar iepriekš iegūto rezultātu

[L] - pasaka serverim lai neturpina izpildīt citus rūļus ja šis ir bijis veiksmīgs

shitaa vajadzeetu darboties....

Edited by gaziks52
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...