Jump to content
php.lv forumi

mapei cita adrese ar mod_rewrite


Rich Bitch

Recommended Posts

Man ir pieņemsim mājas lapai administrācija folderī "administration", vai ir iespējams sataisīt, tā ka rakstot, piemēram, un tikai "adminka" tiek administrācijā? Reāli gribētos, lai fiziski administrācija atrodas folderī http://domens.lv/administration,'>http://domens.lv/administration, bet lietotājs raksta un lieto kā http://domens.lv/adminka, bet ievadod http://domens.lv/administration aiziet uz http://domens.lv.

 

Šo laikam varētu dabūt ar mod_rewrite, bet nemācēšu to izveidot.

Edited by Rich Bitch
Link to comment
Share on other sites

.htaccess faila jāskatās šādi,vajag par baudīt admins vai users jābūt ifam

RewriteEngine On

RewriteRule ^adminka$ admin.php [L]

 

re kur html tags ka aizsūta user uz tavu lapu

<meta http-equiv="refresh" content="0; url=http://http://domens.lv" />

Edited by gta1151
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...