expTheme.php - looks for loginmodule instead of loginController
Reported by Richard Toohey | November 18th, 2011 @ 02:01 AM | in 2.0.3 (closed)
Migrating old site - which had code like this:
exponent_theme_showModule("loginmodule","Expanded");
In the docs ...
http://docs.exponentcms.org/docs/2.0.2/theme-template-structure
... it suggests that I should use something like this:
// hard coding a controller
expTheme::module(array(
"controller"=>"links", // the name of controller (exp2 mod) to display
"action"=>"showall",
...
So I try that for the login:
expTheme::module(array("controller"=>"login","action"=>"showlogin","view"=>"showlogin"));
Doesn't work.
Tracked it down to framework/core/subsystems/expTheme.php
607 public static function showModule($module,$view="Default",$title="",$source=null,$pickable=false,$section=null,$hide_menu=false,$params=array()) {
608 if (!AUTHORIZED_SECTION && $module != 'navigationmodule' && $module != 'loginmodule' && $module != 'loginController') return;
In line 608 I added the loginController part - success ... I can hard-code the login module.
It also means the example code (in the simple theme) works:
expTheme::showController(array("controller"=>"login","action"=>"showlogin","view"=>"showlogin_flyoutYUI"));
HTH.
Comments and changes to this ticket
-
expNinja November 18th, 2011 @ 12:33 PM
- State changed from new to resolved
- Milestone set to 2.0.3
- Milestone order changed from 124 to 0
(from [29c24877a0914e91247dc757fb82943cb39cb52c]) Replaces deprecated 'loginmodule' with 'loginController' which NOW allows the navigation & login module to appear on unauthorized pages, since the loginmodule was deprecated, the loginController was not allowed as a valid module on those restricted pages. [#402 state:resolved milestone:2.0.3 owner:dleffler] https://github.com/exponentcms/exponent-cms/commit/29c24877a0914e91...
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป
Bug Tracker for Exponent CMS