Jump to:

10851 Posts in 2517 Topics by 1793 members

All other Modules

SilverStripe Forums » All other Modules » Calendar event module - upcoming events on homepage?

Discuss all other Modules here.

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

Page: 1 2 3 4 5
Go to End
Author Topic: 5647 Views
  • dreamstudio
    Avatar
    Community Member
    48 Posts

    Re: Calendar event module - upcoming events on homepage? Link to this post

    Im trying to add a similar thing... on every page have a upcoming events.. lets say the next 5 and put it into a side panel.... I looked at the code given above but it didnt work and wanted to know... do the pages have to be event page types or can it be put on any page and can you shed a little more light on where to add the code

    Also ... is there a way to modify the look / size of the calender and then put that in the sidebar too

    one other thing... when i click on the calendar for a date that has something.. it doesnt goto the correct url... it drops part of the url so instead of http://79.170.40.231/domainname.co.uk/events/2009-03-24 it goes to http://79.170.40.231/events/2009-03-24

    if you actually click on an event it works ok just not on the calendar

    is there a way to change the look of the calendar on the right side.. ie colours etc?

  • UncleCheese
    Avatar
    4085 Posts

    Re: Calendar event module - upcoming events on homepage? Link to this post

    Do you have the event_calendar module or the calendar module? Just making sure.. the code I sent you works for the event_calendar module.

    To change the look and feel of the calendar widget, just edit your CSS file. It's all styled in an external stylesheet that is meant to be overridden.

    To get the upcoming events on every page, just add this to your Page_Controller:

    function UpcomingEvents()
    {
    return DataObject::get_one("Calendar")->upcomingEvents(5);
    }

    And you'll be able to do a <% control UpcomingEvents %> on any page.

    The bug that was causing the calendar to redirect to the wrong URL was fixed a few versions ago. Make sure you do an SVN update.

  • dreamstudio
    Avatar
    Community Member
    48 Posts

    Re: Calendar event module - upcoming events on homepage? Link to this post

    I tried getting the latest version that I can see at http://svn.codespaces.com/bluehousegroup/event_calendar but it asks for a username and password

    the version I got was on your bluehouse group website... so not sure what version im running but cant get the latest due to passwording on the link

    Also, forgive my ignorance... im picking up SS well but not sure when you say to put that code into the page controller.. do you mean the code

    function UpcomingEvents()
    {
    return DataObject::get_one("Calendar")->upcomingEvents(5);
    }

    into page.ss under my theme or another location?

  • UncleCheese
    Avatar
    4085 Posts

    Re: Calendar event module - upcoming events on homepage? Link to this post

    That's really weird that the SVN is trying to authenticate you. I have anonymous checkout set up.

    I posted a new SVN export to extensions.bluehousegroup.com. Try that.

  • dreamstudio
    Avatar
    Community Member
    48 Posts

    Re: Calendar event module - upcoming events on homepage? Link to this post

    I tried downloading that file but all the files inside the zip are 0.... so it cant export them

  • dreamstudio
    Avatar
    Community Member
    48 Posts

    Re: Calendar event module - upcoming events on homepage? Link to this post

    I moved the files out of the zip by hand as a few files were 0 byte empty files.. which seems to have worked..

    The only question is where do i copy the code you mentioned, which pages to load them to

  • banal
    Avatar
    Community Member
    901 Posts

    Re: Calendar event module - upcoming events on homepage? Link to this post

    Hi UncleCheese

    I just tried to download and install your calendar module and encountered the same SVN authentication problem as "dreamstudio" did.
    Here's the command i used:

    svn co http://svn.codespaces.com/bluehousegroup/event_calendar ~/Sites/SilverStripe-v2.3.1-rc2/event_calendar
    Authentication realm: <http://svn.codespaces.com:80>; Code Spaces Subversion Repository Authentication
    Password for 'roman':

    Any idea what could cause this?
    Best - Roman

  • dreamstudio
    Avatar
    Community Member
    48 Posts

    Re: Calendar event module - upcoming events on homepage? Link to this post

    After getting the zip file from your website working... installed and works ok, however couple of questions

    On the documentation it says about blind down on the configuration menu... my install doesnt have that just the number of events, default date header and future dates.. so could it be the file i downloaded from your website is still an old version

    Also you mentioned orignally about being able to put the upcoming events details on a homepage.... so is it possible to put the calendar widget on ANY page of a SS site... ie I want to put it down the side so people can go through the calendar and click a date.. as well as upcoming dates listed below that on the sidebar - is it possible or can you only drop calendar features on calendar pages

    Lovely module by the way....

    5647 Views
Page: 1 2 3 4 5
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.