protected function redirect_to_return_to()
 {
     #if (isset($this->return_to)) {
     #	$return_to = $this->return_to;
     #} elseif (isset($_GET['return_to'])) {
     #	$return_to = $_GET['return_to'];
     #} else {
     #	$return_to = $this->get_current_url_file_str();
     #}
     #
     ##echo $return_to;
     ##exit;
     #
     #header("Location: $return_to");
     #exit;
     $return_to_url = $this->get_return_to_url();
     #print_r($return_to_url); exit;
     #$return_to_url->make_absolute_for_current_server();
     PublicHTML_RedirectionHelper::redirect_to_url($return_to_url);
 }
Пример #2
0
<?php

/**
 * Send people to the right place.
 *
 * @copyright RFI 2008-02-24
 */
#$cmf = HaddockProjectOrganisation_ConfigManagerFactory::get_instance();
#$config_manager = $cmf->get_config_manager('haddock', 'public-html');
#
##PublicHTML_RedirectionHelper::redirect_to_absolute_location('/db-pages/home.html');
#
#PublicHTML_RedirectionHelper::redirect_to_absolute_location($config_manager->get_default_url());
/*
 * Find the default location and redirect there.
 */
$default_location = PublicHTML_DefaultLocationHelper::get_default_location();
if (DEBUG) {
    echo DEBUG_DELIM_OPEN;
    echo 'File: ' . __FILE__ . PHP_EOL;
    echo 'Line: ' . __LINE__ . PHP_EOL;
    echo '$default_location: ' . $default_location . PHP_EOL;
    echo DEBUG_DELIM_CLOSE;
}
PublicHTML_RedirectionHelper::redirect_to_absolute_location($default_location);
Пример #3
0
<?php

/**
 * Send people to the right place.
 *
 * @copyright RFI 2008-02-24
 */
$cmf = HaddockProjectOrganisation_ConfigManagerFactory::get_instance();
$config_manager = $cmf->get_config_manager('haddock', 'public-html');
#PublicHTML_RedirectionHelper::redirect_to_absolute_location('/db-pages/home.html');
PublicHTML_RedirectionHelper::redirect_to_absolute_location($config_manager->get_default_url());
 public static function redirect_to_log_in_page()
 {
     PublicHTML_RedirectionHelper::redirect_to_url(self::get_log_in_page_url());
 }