Home › Forums › Calendar Products › Events Calendar PRO › shortcodes in page template
- This topic has 7 replies, 2 voices, and was last updated 13 years, 3 months ago by
Jonah.
-
AuthorPosts
-
January 10, 2013 at 11:16 am #30597
Greg
ParticipantI 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:
January 10, 2013 at 12:39 pm #30602Jonah
ParticipantHi 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
January 10, 2013 at 2:15 pm #30609Greg
ParticipantI 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.
January 10, 2013 at 3:01 pm #30613Jonah
ParticipantHey 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
January 14, 2013 at 2:27 pm #30800Greg
ParticipantWell 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.
January 14, 2013 at 2:47 pm #30801Jonah
ParticipantHey 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
January 14, 2013 at 3:27 pm #30805Greg
ParticipantThanks! I have used that plugin before but did not know about the add-on. I will check it out!
January 15, 2013 at 8:28 am #30866Jonah
ParticipantSounds good Lindy, let us know if you need anything else.
– Jonah
-
AuthorPosts
- The topic ‘shortcodes in page template’ is closed to new replies.
