Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

423
Vistas
URL Re-Writing with .htaccess in custom php (xampp) on windows 10

I want to re-write the following url from:

www.phcc.com/reports/caseFullDtlByCaseSno.php?case_sno=1

  To

http://www.phcc.com/reports/1/caseFullDtlByCaseSno.html

For this i have written the following .htaccess file inside the reports directory which is the sub-directory of the website root:

RewriteEngine on  
RewriteBase /reports/

RewriteRule ^(.*)/(\d+)\.php $1=case_sno&$2.html [NL,L]  
RewriteRule ^(.*)/(\d+)\.html $1=case_sno&$2.php [L]

but it does not complete the request as i need it. What should i do?

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

Try with below, I am assuming the html files are not existent.

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([\d]+)/([\w-]+)\.html$ $2.php?case_sno=$1 [L]
over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda