Help in setting up the htaccess file, I don’t understand anything at all. You must redirect domain.com/LxTy links to domain.com/link.php?address=LxTy. Is it possible and if so how? Appreciate any answers.
1 answer
.htacess
# Turn Rewrite Engine On RewriteEngine on # Rewrite for projects.php RewriteRule ^custom$ projects.php [NC,L] # NC makes the rule non case sensitive # L makes this the last rule that this specific condition will match # $ in the regular expression makes the matching stop so that "customblah" will not work # Rewrite for user.php?u=xxxxx RewriteRule ^user/([0-9a-zA-Z]+)$ user.php?u=$1 [NC,L] # Rewrite for article.php?id=1&title=Title-Goes-Here RewriteRule ^article/([0-9]+)/([0-9a-zA-Z_-]+)$ article.php?id=$1&title=$2 [NC,L] So now by the code: the first RewriteRule ^ custom $ projects.php [NC, L] it will redirect projects.php to your site type. rf / user / anton or if there is your website. rf / user.php there? u = 38 will redirect to your website. rf / user / 38
and the third rule is to turn into yoursite.rf / article / 1 / Hello-World, for example. And if you know English, watch the video - there is clearly the same thing https://www.youtube.com/watch?v=1pbAV6AU99I
- Thank you very much for the second rule)) - AtCliff_
|
LxTy? - de_frag