| 1 |
<?php |
<?php |
| 2 |
|
|
| 3 |
//$Id: customerror.module,v 1.17.2.3 2008/09/13 02:54:01 kbahey Exp $ |
//$Id: customerror.module,v 1.17.2.4 2008/10/06 01:03:09 kbahey Exp $ |
| 4 |
|
|
| 5 |
// Copyright 2005 Khalid Baheyeldin http://2bits.com |
// Copyright 2005 Khalid Baheyeldin http://2bits.com |
| 6 |
|
|
| 218 |
if (isset($src) && isset($dst)) { |
if (isset($src) && isset($dst)) { |
| 219 |
$src = str_replace("/", "\\/", $src); |
$src = str_replace("/", "\\/", $src); |
| 220 |
$dst = str_replace("\r", "", $dst); |
$dst = str_replace("\r", "", $dst); |
| 221 |
if (preg_match('/'. $src .'/', $destination)) { |
// In case there are spaces in the URL, we escape them |
| 222 |
|
$orig_dst = str_replace(" ", "%20", $destination); |
| 223 |
|
if (preg_match('/'. $src .'/', $orig_dst)) { |
| 224 |
$_REQUEST['destination'] = $dst; |
$_REQUEST['destination'] = $dst; |
| 225 |
drupal_goto($dst); |
drupal_goto($dst); |
| 226 |
} |
} |