Ver Mensaje Individual
  #2 (permalink)  
Antiguo 22/04/2016, 10:28
Avatar de petit89
petit89
 
Fecha de Ingreso: marzo-2011
Mensajes: 1.135
Antigüedad: 13 años, 2 meses
Puntos: 170
Respuesta: Escribir reglas para urls amigables

prueba asi:

Código Apache:
Ver original
  1. RewriteEngine on
  2.  
  3. RewriteCond %{SCRIPT_FILENAME} !-d
  4. RewriteCond %{SCRIPT_FILENAME} !-f
  5. RewriteCond %{REQUEST_FILENAME} !-f
  6. RewriteCond %{REQUEST_FILENAME} !-d
  7.  
  8. RewriteBase /
  9. RewriteRule ^work/([a-zA-Z0-9_-]+)$ index.php?ty=$1 [L]

recibelo como:

Código PHP:
Ver original
  1. $ty = "";
  2. if(isset($_GET['ty'])  && !empty($_GET['ty'])){
  3. $ty = $_GET['ty'];
  4. }
  5. echo $ty;
__________________
█ WebHosting / Reseller a bajo costo | Uptime Garantizado | Soporte en Español e Ingles
¿Te sirvió la respuesta? Deja un +1 (Triangulo negro al lado derecho)