[ Index ]
 

Code source de eGroupWare 1.2.106-2

Accédez au Source d'autres logiciels libresSoutenez Angelica Josefina !

title

Body

[fermer]

/ -> redirect.php (source)

   1  <?php
   2      /**************************************************************************\
   3      * eGroupWare - save redirect script                                        *
   4      * idea by: Jason Wies <jason@xc.net>                                       *
   5      * doing and adding to cvs: Lars Kneschke <lkneschke@linux-at-work.de>      *
   6      * http://www.egroupware.org                                                *
   7      * --------------------------------------------                             *
   8      *  This program is free software; you can redistribute it and/or modify it *
   9      *  under the terms of the GNU General Public License as published by the   *
  10      *  Free Software Foundation; either version 2 of the License, or (at your  *
  11      *  option) any later version.                                              *
  12      \**************************************************************************/
  13      
  14      /* $Id: redirect.php 13271 2004-01-10 19:19:53Z milosch $ */
  15  
  16      /*
  17        Use this script when you want to link to a external url.
  18        This way you don't send something like sessionid as referer
  19        
  20        Use this in your app:
  21        
  22        "<a href=\"$webserverURL/redirect.php?go=".htmlentities(urlencode('http://www.egroupware.org')).'">'
  23      */
  24  
  25      if(!function_exists('html_entity_decode'))
  26      {
  27  		function html_entity_decode($given_html, $quote_style = ENT_QUOTES)
  28          {
  29              $trans_table = array_flip(get_html_translation_table( HTML_SPECIALCHARS, $quote_style));
  30              $trans_table['&#39;'] = "'";
  31              return(strtr($given_html, $trans_table));
  32          }
  33      }
  34  
  35      if($_GET['go'])
  36      {
  37          Header('Location: ' . html_entity_decode(urldecode($_GET['go'])));
  38          exit;
  39      }
  40      else
  41      {
  42          echo "this won't work!!";
  43      }
  44  ?>


Généré le : Sun Feb 25 17:20:01 2007 par Balluche grâce à PHPXref 0.7