SHARE
TWEET

Untitled

a guest Jun 24th, 2019 65 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2.  
  3. if ($_GET['id']) {
  4.  
  5.     echo "post page";
  6.  
  7. } elseif ($_GET['user']) {
  8.  
  9.     echo "user page";
  10.    
  11. } elseif ($_GET['do'] == 'upload') {
  12.  
  13.     echo "upload page";
  14.  
  15. } else {
  16.  
  17.     echo "home page";
  18.  
  19. }
  20.  
  21. ?>
  22.  
  23. .htaccess:
  24.  
  25. AddDefaultCharset utf-8
  26. DirectoryIndex index.php
  27.  
  28. RewriteEngine on
  29.  
  30. RewriteRule ^login login.php
  31. RewriteRule ^([a-z0-9]+)$ ?user=$1
  32. RewriteRule ^p/([0-9]+)$ ?id=$1
  33.  
  34. RewriteRule ^upload ?do=upload
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top