753 Posts in 310 Topics by 289 members
|
Page:
1
|
Go to End | |
| Author | Topic: | 1692 Views |
-
Login widget

9 October 2009 at 9:13am
Hi
I have made some changes to the login widget and I'm including it on all pages with mysite/code/Page.php
function MyLogin() {
$widget = new LoginWidget();
}It is working fine but I want to exclude this widget from the forum page. How can I do that?
-- Martin
-
Re: Login widget

9 October 2009 at 10:23am
In my Login.ss
<% if ClassName = ForumHolder %>
<% else %>
do login etc...
<% end_if %> -
Re: Login widget

29 November 2009 at 12:08pm
could you please explain in detail how you put the login widget in all the pages? this would be much appreciated.
-
Re: Login widget

29 November 2009 at 1:59pm
I think I did something like this...
I used the Log In Widget from http://www.silverstripe.org/Log-in/
Then you need to add something like this to end of mysite/code/Page.php
---------------
function MyLogin() {
$widget = new LoginWidget();
return $widget->renderWith("WidgetHolder");
}
---------------Then you need to call this somewhere in your theme. It could be theme/blackcandy/templates/Pages.ss
---------------
<div id="BgContainer">
<div id="Container">
...
...
<div id="Sidebar">
$MyLogin
</div>
...
...
---------------I also think you need to call http://yoursite.com/dev/build
-
Re: Login widget

30 November 2009 at 4:12pm
Thanks so much!
i added the code into the "leftcolumn.ss" under /themes/lazydays/templates/includes/leftcolumn.ss
it works like a charm
| 1692 Views | ||
|
Page:
1
|
Go to Top |

