Example #1
0
/**
* Get a link to a view, the link is taken by the url mapping
*
* @param string|object $viewClass The View Class
* @param mixed $params Parameters for a regex url
* @param int $priority The priority of the mapped url
* @param string $language If set than you can override the language, otherwise the current language is taken
* @return string
*/
function l($viewClass, $params = null, $priority = 0, $language = null)
{
    return CHOQ_View::linkToView($viewClass, $params, $priority, $language);
}
Example #2
0
<?php

/**
 * This file is part of Choqled PHP Framework and/or part of a BFLDEV Software Product.
 * This file is licensed under "GNU General Public License" Version 3 (GPL v3).
 * If you find a bug or you want to contribute some code snippets, let me know at http://bfldev.com/nreeda
 * Suggestions and ideas are also always helpful.

 * @author Roland Eigelsreiter (BrainFooLong)
 * @product nReeda - Web-based Open Source RSS/XML/Atom Feed Reader
 * @link http://bfldev.com/nreeda
**/
if (version_compare(PHP_VERSION, '5.3.0', '<')) {
    die("You must have at least PHP 5.3.0 installed, your version is " . PHP_VERSION);
}
if (!function_exists("mb_strlen")) {
    die("You must enable the 'mbstring' extension in your PHP config");
}
try {
    define("CHOQ_ACTIVE_MODULE", "RDR");
    require __DIR__ . "/modules/CHOQ/class/Core.class.php";
    CHOQ_Core::initialise();
    CHOQ::get(CHOQ_ACTIVE_MODULE);
    CHOQ_View::loadViewForCurrentUri();
} catch (Exeption $e) {
    CHOQ_Exception::exceptionHandler($e);
}