31 lines
795 B
PHP
31 lines
795 B
PHP
<?php
|
|
/**
|
|
* @package Easyway Shop
|
|
* @copyright Copyright (C) 2005 - 2011 TA-EDV
|
|
* @license proprietary
|
|
* @author John T. Daly <jd@ta-edv.de>
|
|
*
|
|
* Easyway Shop is a web e-commerce system
|
|
*/
|
|
|
|
class website_internal_link {
|
|
|
|
private $base_object;
|
|
private $layout_object;
|
|
|
|
public function __construct($base_object, $layout_object) {
|
|
$this->base_object = $base_object;
|
|
$this->layout_object = $layout_object;
|
|
}
|
|
|
|
public function run($structure_id) {
|
|
$structure_object = new Structure($this->base_object);
|
|
$structure_data = $structure_object->get_data($structure_id);
|
|
$new_site_structure_data = $structure_object->get_data($structure_data->link_reference);
|
|
$short_uri = $new_site_structure_data->short_uri;
|
|
header('location: ' . '/'.$short_uri.'/');
|
|
exit();
|
|
}
|
|
|
|
}
|