shortcodes in page template

Home Forums Calendar Products Events Calendar PRO shortcodes in page template

Viewing 8 posts - 1 through 8 (of 8 total)
  • Author
    Posts
  • #30597
    Greg
    Participant

    I followed the instructions on https://theeventscalendar.com/support/forums/topic/other-plugin-shortcodes-in-add-html-before-calendar/ to add a shortcode above my calendar, and could not seem to get my shortcode to work. I have a feeling I am doing something wrong because when I just put some text in the same spot in that file, it did not display. I put it right after:

    #30602
    Jonah
    Participant

    Hi Lindy,

    Make sure are using the Default Events Template in Events > Settings > Template and that you’ve put the code in an override copy of /wp-content/plugins/the-events-calendar/views/ecp-page-template.php placed in an ‘events’ folder in your theme. You might also need to wrap that PHP code in PHP tags like the other code.

    Does that help?

    – Jonah

    #30609
    Greg
    Participant

    I see, I was using the default page template, not the default events template. I switched to this, and I see the code I added is there, which is great. However, the page looks like crap. Do you have any tips on cleaning the page template up? I am using Genesis.

    #30613
    Jonah
    Participant

    Hey Lindy,

    Well here’s what you can do that may be easier. Go back to using the default page template and then edit your page.php template in your theme (which is the default page template) with your custom code.

    – Jonah

    #30800
    Greg
    Participant

    Well that’s what I was originally trying to do and it was producing strange results. Maybe I am going about this wrong. What I need is to allow a user with an “Editor” role to edit copy above the calendar – on the calendar page only (not the individual events). I was trying to use this plugin – http://wordpress.org/extend/plugins/improved-include-page/installation/ – I realize it’s pretty old, but it’s worked for me in many other scenarios when I needed to let a client edit a specific area of a site that wasn’t a normal page or post.

    #30801
    Jonah
    Participant

    Hey Lindy,

    I would suggets using the awesome http://www.advancedcustomfields.com/ plugin. There’s an Options page add-on that costs $25 but it let’s you easily create options pages and then add your custom fields to that page and then display the data wherever you want on your website. You can limit the custom fields display by Role too. That’s going to be your best bet.

    I hope that helps!

    – Jonah

    #30805
    Greg
    Participant

    Thanks! I have used that plugin before but did not know about the add-on. I will check it out!

    #30866
    Jonah
    Participant

    Sounds good Lindy, let us know if you need anything else.

    – Jonah

Viewing 8 posts - 1 through 8 (of 8 total)
  • The topic ‘shortcodes in page template’ is closed to new replies.