Customize Event Calendar Pro mini Calendar widget click

Home Forums Calendar Products Events Calendar PRO Customize Event Calendar Pro mini Calendar widget click

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #41886
    hoangker
    Participant

    Hi, with respect to the current mini calendar widget in Event Calendar Pro I’d like to instead of doing a page redirect to the event page, on date clicked, I want to load a div say #eventdetails, on my current custom page template, using jquery with the event details (ex.time,place,description,full size photo of event?). To do this I realize that I first need to hook / override a calendar widget php file by copying this widget calendar php file (I don’t know which) into my own /events folder.

    Then once I’ve done that I need to override the corresponding JavaScript by copying it into the /events folder for my current theme as well – I also don’t know which file that is. I think these files are table-mini.php and event.js so I copied both files to my /events folder, made my modifications “echo ‘YOYOYO'” and “Alert(‘YOYOYO’)” to table-mini.php and event.js respectively, but, they didn’t get called. I then just made changes to the original files and it worked. What am I missing to correctly override these files? unregister/register in functions.php? What is the classname to unregister? what is the classname to register? What are the files I need to copy to my /events folder (i will be needing to change the style of the mini calendar widget so which css file do I copy to override as well?)

    Could you please give me step-by-step instructions on how to go about with my customization?

    Thank you very much,

    Tin

    #41891
    Barry
    Member

    There are excellent instructions on templating/theming here:

    Javascript is a slightly different kettle of fish – there’s a brief overview here, just keep in mind that – for what you want to accomplish – you may not need to dequeue the scripts put in place by The Events Calendar.

    #41899
    hoangker
    Participant

    hi Barry,

    thanks for the reply. But, you still left out why my overriding might not be working. I created the /events folder in my theme’s directory and copied table-mini.php and event.js, but, my changes to ~/theme/events/table-mini.php and ~/theme/events/event.js were not applied.

    Also, why do you say I might not need to dequeue the javascript?

    If I have the event $post->ID what function can I call to return me the details of the event (ex. event name, event date, thumbnail etc?)

    Thanks,

    Tin

    #41909
    Barry
    Member

    But, you still left out why my overriding might not be working.

    It’s hard to answer. If you have carefully followed the steps in the links I provided then it ought to be working. Can you share a link to your site and/or the code in your custom templates?

    #41911
    Barry
    Member

    Also, why do you say I might not need to dequeue the javascript?

    Because it sounds as if you want to add new behaviour (showing the event details in a “modal” window, for instance, and prohibiting navigation via the mini-calendar to individual event pages) rather than wanting to strip away existing functionality.

    The decision of course is yours, you will have a more complete understanding of what you want to achieve than I do 🙂

    #41912
    Barry
    Member

    If I have the event $post->ID what function can I call to return me the details of the event (ex. event name, event date, thumbnail etc?)

    Take a look at our technical documentation (there’s a link in the Useful Resources widget over on the right) – from there you can find details of various template tags that you may be interested in here.

    #41913
    hoangker
    Participant

    Thhanks Barry. You’ve given me some ideas. I might just scrap the loading my div#eventdetail and just override the single event view that the calendar widget redirects me to. What view is single event view php file that I would need to override Barry?

    Thanks,

    Tin

    #41914
    Barry
    Member

    single.php

Viewing 8 posts - 1 through 8 (of 8 total)
  • The topic ‘Customize Event Calendar Pro mini Calendar widget click’ is closed to new replies.