Ejemplo n.º 1
0
        } else {
            $links[] = $this->content_tag("span", $next_content_disabled, array("class" => "disabled"));
        }
        foreach ($links as $link) {
            $content .= $this->content_tag("li", $link, array("class" => "pagination_link"));
        }
        return $this->content_tag("ul", $content, array("class" => "pagination clearfix"));
    }
    public function paginate_url($param, $page)
    {
        $vals = $_GET;
        $url_base = "/" . $vals["route"];
        unset($vals["route"]);
        $vals[$param] = $page;
        return $url_base . "?" . http_build_query($vals, false, "&");
    }
    private function url($val)
    {
        return WXRoute::get_url_val($val);
    }
}
Autoloader::include_from_registry('AssetTagHelper');
Autoloader::include_from_registry('FormHelper');
Autoloader::include_from_registry('FormTagHelper');
Autoloader::include_from_registry('FormOptionsHelper');
Autoloader::include_from_registry('UrlHelper');
Autoloader::include_from_registry('FormBuilderHelper');
Autoloader::include_from_registry('WaxCacheHelper');
Autoloader::include_from_registry('RequestHelper');
Autoloader::include_from_registry('WaxPartialHelper');
Ejemplo n.º 2
0
    define('FRAMEWORK_DIR', WAX_PATH . "/phpwax/releases/" . WAX_VERSION . "/wax");
} else {
    ini_set('include_path', ini_get("include_path") . ":" . WAX_PATH . "/phpwax/releases/latest/wax");
    define('FRAMEWORK_DIR', WAX_PATH . "/phpwax/releases/latest/wax");
}
ini_set('include_path', ini_get("include_path") . ":" . WAX_ROOT);
require_once FRAMEWORK_DIR . "/AutoLoader.php";
/*********************************************************************************************/
/************ Application Error Handling *******************************************************
*
*  When you're running in production mode, you don't want your errors displayed to users.
*  The following commands can be uncommented to handle errors professionally.
*  Firstly the routing redirect_on_error gives a location for a 404 error (page not found)
*  The second redirect_on_error is an application error page.
*  Both of these can be either actions in your application or static pages.
*  
*  Finally email_on_error accepts an email address and email_subject_on_error a text subject.
*  If these are set a copy of the error trace will be emailed to the address. */
WXRoutingException::$redirect_on_error = "/404.html";
// Page not found error
// Application Error and an email address and subject to send details to.
WXException::$redirect_on_error = "/error.html";
//WXException::$email_on_error="";
//WXException::$email_subject_on_error="";
/*********************************************************************************************/
/*********************************************************************************************/
/*********** Your Additional Application Configuration ***************************************
*  This file is run at boot time so if you want to set any systemwide configuration values, 
*  you can do so below this point */
Autoloader::include_from_registry('SiteHelper');
Autoloader::register_helpers();
Ejemplo n.º 3
0
<?php

/* Each plugin can make use of a a file called setup.php which can be used to initialise
	 any required setup.
*/
define("CMS_VERSION", "0.5-devel");
define("CMS_DIR", dirname(__FILE__));
CMSApplication::register_module("home", array("display_name" => "Dashboard", "link" => "/admin/home/", 'auth_level' => 0));
CMSApplication::register_module("settings", array("display_name" => "Settings", "link" => "/admin/settings/", 'auth_level' => 30));
CMSApplication::register_module("sections", array("display_name" => "Site Sections", "link" => "/admin/sections/", 'auth_level' => 30));
CMSApplication::register_module("categories", array("display_name" => "Categories", "link" => "/admin/categories/", 'auth_level' => 20));
CMSApplication::register_module("content", array("display_name" => "Content", "link" => "/admin/content/", 'auth_level' => 10));
CMSApplication::register_module("comments", array("display_name" => "Comments", "link" => "/admin/comments/", 'auth_level' => 5));
CMSApplication::register_module("files", array("display_name" => "Files", "link" => "/admin/files/", 'auth_level' => 0));
CMSApplication::register_module("users", array("display_name" => "CMS Users", "link" => "/admin/users/", 'auth_level' => 30));
//CMSApplication::register_module("email", array("display_name"=>"Email", "link"=>"/admin/email/", 'auth_level'=>30));
Autoloader::include_from_registry('CMSHelper');
Autoloader::register_helpers();