Support

Home Forums Events Calendar Add-on Calendar customization

Calendar customization

Posted: November 8, 2013 at 2:25 am

Viewing 6 reply threads


Ricardo Griffin

November 8, 2013 at 2:25 am

Hello,

I managed to get my calendar working the other other day. I have styled it and it looks really nice.

I would like to make the following changes and am thinking I may need to adjust some core code.

The calendar to default to a specific month/date?

Exclude one category of events from the calendar?

Any pointers will be greatly received.


Dean

November 8, 2013 at 5:40 am

Hi Ricardo,

Regarding the specific month, you are right, it does need a code edit. Check out this forum thread – https://eventespresso.com/topic/display-next-months-calendar/

It isn’t possible to exclude categories, at least not without a level of customisation that is beyond what support can provide.

The next version of the Calendar Add On does have a front end filtering system though, so a user can select the category and the calendar only displays those categories – sneak peak http://d.pr/i/uEG8

Otherwise you would need a developer – https://eventespresso.com/developers/event-espresso-pros/


Ricardo Griffin

November 8, 2013 at 9:42 am

Thank you very much, the default month worked perfectly.

I was looking through the code and saw some lines like:
$sql .= ” AND e.event_status != ‘X’ “;

and was wandering if a cheeky:
$sql .= ” AND c.id != 21 “;
or similar, so there is just one category that isn’t displayed, that didn’t work but maybe near to a hard and fast workaround?


Ricardo Griffin

November 9, 2013 at 3:09 pm

So as a work around I added a category call calendar, then just placed all the events I wanted to be displayed in it and used the cat_id filtering short code.

My next question is how to filter the search?

Even if you could tell me the php pages responsible for the search results and results in the ajax autofill?

This would be a great help please.


Dean

November 11, 2013 at 2:47 am

Hi Ricardo,

That’s was a good idea, what I did was add

if($event->category_id =="1") {continue;}

after the

foreach ( $events_data as $event ) {

to effectively skip the events with that category.

The search, I am assuming the [EVENT_SEARCH] shortcode.

If so, then that is found in event-espresso/includes/shortcodes.php. YOu may be best copying that shortocde to the custom files addon and changing its name/shortcode tag to make a new shortcode and edit it there. It will stop it from being over written by updates.


Ricardo Griffin

November 11, 2013 at 10:38 am

I excluded the events in the autocomplete by adding:

$SQL .= ” AND e.id NOT IN (78,79,80,81,82,83,84,85) “;

Great that worked, however I need to filter the search results page?

Thanks


Ricardo Griffin

November 11, 2013 at 2:28 pm

Don’t worry I made a similar edit to event-espresso/templates/event_list.php.

Thanks

Viewing 6 reply threads

The support post ‘Calendar customization’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso