Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

All other Modules

Discuss all other Modules here.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Calendar event module - upcoming events on homepage?


Reply

36 Posts   5962 Views

Avatar
UncleCheese

20 March 2009 at 6:39am 4085 Posts

So sorry about this, guys. I don't know what's wrong with that SVN. I've set anonymous checkouts, but it's just not working, so I've migrated to a better SVN host. Please delete your working copies and do a fresh checkout from

http://bluehousegroup.svn.beanstalkapp.com/modules/trunk/event_calendar

@dreamstudio -- To put a calendar widget anywhere on the site... It looks like this will be a little clunky, but I could use the testing.

PageController.php

function CalendarWidget()
{
return new CalendarWidget(
DataObject::get_one("Calendar"), // controller
null, // start date
null, // end date
true // default view
);
}

Try that and let me know how it goes.

Avatar
dreamstudio

20 March 2009 at 7:01am Community Member, 48 Posts

That download worked a treat.

I tried finding the pagecontroller.php file and I cant see it anywhere in the site directory

Also the install still doesnt show the bind down option... is that an old feature thats been removed

Avatar
UncleCheese

20 March 2009 at 7:35am (Last edited: 20 March 2009 7:35am), 4085 Posts

It's an old feature that's been removed. That level of presentation should not be controlled in the CMS.

PageController will be in Page.php, which is in mysite/code/

Or if you're using a theme it might be themes/mytheme/code/.. not sure, though.. one of those two.

Avatar
dreamstudio

20 March 2009 at 10:09am Community Member, 48 Posts

I added the function code you listed for the calendar widget to the mysite/code/page.php file and added in $CalendarWidget to my page.ss under themes.... nothing appeared though....

Im running the latest version of SS so not sure if that could affect it

Avatar
UncleCheese

20 March 2009 at 10:17am 4085 Posts

Please post your Page.php code and the template you're using.

Avatar
dreamstudio

20 March 2009 at 10:44am Community Member, 48 Posts

page.php attached... I made my own theme but i also tried it on blackcandy and added $CalendarWidget to page.ss under templates/layout

Avatar
UncleCheese

20 March 2009 at 10:47am 4085 Posts

I'm debugging this right now. Looks like it wasn't quite built to do this. I'll have something in a sec for you.

Avatar
UncleCheese

20 March 2009 at 10:49am 4085 Posts

Okay, try an SVN update and do it again. Haven't tested it yet, but I think it will work.