Jump to:

11002 Posts in 2734 Topics by 1823 members

All other Modules

SilverStripe Forums » All other Modules » Add Venue to Event Calendar Module

Discuss all other Modules here.

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

Page: 1
Go to End
Author Topic: 391 Views
  • nmshah
    Community Member
    21 Posts

    Add Venue to Event Calendar Module Link to this post

    I am using silverstripe 3.0.3 and Uncle Cheese's EventCalendar module and am trying to add location to the calendarevent using the following tutorial.


    After following the tutorial when I try to rebuild the database I get the following error:

    Parse error: syntax error, unexpected T_PUBLIC in C:\Program Files\EasyPHP-12.0\www\ichars\mysite\code\WorkshopDateTime.php on line 14

    Line 14 on the above mentioned page are

    public function extendTable()

    I know the tutorial is for older version of the module but I couldn't find anything else. Kindly suggest...

  • nmshah
    Community Member
    21 Posts

    Re: Add Venue to Event Calendar Module Link to this post

    Have this working now. This is what I did:
    Created a new page CalendarDetails.php in mysite/code/ with the following content:

    class CalendarDetails extends DataExtension
       static $db = array(
          'Venue' => 'Text',
          'City' => 'Text',
          'Ticket' => 'HTMLText',

       static $has_one = array (
          'Event' => 'CalendarEvent'

       public function updateCMSFields(FieldList $fields) {

          $fields->push(new TextField('Venue', 'Venue'));
          $fields->push(new TextField('City', 'City'));
          $fields->push(new TextareaField('Ticket', 'Ticket'));

    and in _config.php added the following line:

    Object::add_extension(‘CalendarDateTime’, ‘CalendarDetails’);

Page: 1
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.