Jump to:

10850 Posts in 2517 Topics by 1793 members

All other Modules

SilverStripe Forums » All other Modules » Preview: Event Calendar Module

Discuss all other Modules here.

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

Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37
Go to End
Author Topic: 39412 Views
  • Xeal
    Avatar
    Community Member
    37 Posts

    Re: Preview: Event Calendar Module Link to this post

    Now I have something else acting weird... haha you're going to love me after all this
    Alright, now when I try to add Announcements, it acts as if it the announcement is saved, but nothing goes into the database nor the form itself (the cms). Not exactly sure why it's doing this. I tried looking through the code and still am, a little lost though, but I thought I'd post just in case someone else had this problem and knows how to fix it.

    I Appreciate the hard work you put in to this module. keep up the good work =)

  • UncleCheese
    Avatar
    4085 Posts

    Re: Preview: Event Calendar Module Link to this post

    Should have been fixed in the latest revision. Can you make sure you're up to date?

  • Victor
    Avatar
    Community Member
    128 Posts

    Re: Preview: Event Calendar Module Link to this post

    Tutorial: Extending Event_Calendar (wiki)

    Missing in WorkshopHolder.ss

    <% control Events %>

    <% end_control %>

    enveloping Image, Sponsor

  • UncleCheese
    Avatar
    4085 Posts

    Re: Preview: Event Calendar Module Link to this post

    I'm not sure what you're talking about?

  • Xeal
    Avatar
    Community Member
    37 Posts

    Re: Preview: Event Calendar Module Link to this post

    in the WorkshopHolder The problem is the wiki doesn't explain it rather well.
    there's a tag    <% control Events %>
    if you place it after that you can access the Image and Sponsor like this
    ex. $Event->Image
    $Event->Sponsor
    look at line 52 I added it after this
    <% control Event %>$Content.LimitWordCount(60)<% end_control %> <a href="$Link"><% _t('EVENTCALENDAR.MORE','more...') %></a>
    Someone correct me if I'm way off but I'm pretty sure that's right, well it works for me =)
    Hope that clears things a little for others who might be following the tutorial

  • Xeal
    Avatar
    Community Member
    37 Posts

    Re: Preview: Event Calendar Module Link to this post

    To make a long story short. I extended the Calendar to make it work for my needs, but now I can't add any announcements to my calendar. Events work fine though, and on the Basic Calendar announcements work fine. I don't think I changed any code that could mess with the announcements, but I'll double check to make sure.

    Attached Files
  • UncleCheese
    Avatar
    4085 Posts

    Re: Preview: Event Calendar Module Link to this post

    That is a confusing part of the Events control. It actually returns DateTime objects, so to access your Event properties, you need to do $Event.Property, e.g. $Event.Sponsor.

    Victor, I hope you meant to write <% control Event %> and not <% control Events %>.. They return very different things in that context.

  • Victor
    Avatar
    Community Member
    128 Posts

    Re: Preview: Event Calendar Module Link to this post


    Victor, I hope you meant to write and not <% control Events %>.. They return very different things in that context.

    I suspect that <% control Event %> is correct and <% control Events %> is not but the former does not work and the latter does

    But it envelopes $Event.Sponsor, not $Events.Sponsor. This is really confusing

    39412 Views
Page: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37
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.