Posted By

Meander365 on 08/04/09


Tagged

errors php wordpress pretty custom permalinks


Versions (?)

Who likes this?

2 people have marked this snippet as a favorite

rickfu
umang_nine


Wordpress Pretty Permalinks on a Shared Server


 / Published in: PHP
 

URL: http://it.megocollector.com/?p=795

Create a custom 404 handler page which redirects you to the correct page.

  1. <!-- Create the file wp-404-handler.php in your base Wordpress folder. -->
  2.  
  3. <?php
  4. $_SERVER['REQUEST_URI'] = substr($_SERVER['QUERY_STRING'], strpos($_SERVER['QUERY_STRING'], ':80')+3);
  5. $_SERVER['PATH_INFO'] = $_SERVER['REQUEST_URI'];
  6. include('index.php');
  7. ?>

Report this snippet  

You need to login to post a comment.