Home › Forums › Calendar Products › Events Calendar PRO › Customize no future events page
- This topic has 11 replies, 2 voices, and was last updated 13 years ago by
Jonah.
-
AuthorPosts
-
April 2, 2013 at 10:19 am #44631
Joshua
ParticipantI would like to customize what is seen when there are no future events on my events page. I’ve been able to edit a line of text on the list view when there is no available events, but how can I add extra customization such as an image.
April 2, 2013 at 3:10 pm #44687Jonah
ParticipantHi Joshua,
You would need to add the code for your image to the list.php file. To make changes to that file, make a copy of /wp-content/plugins/the-events-calendar/views/list.php and place in an ‘events’ folder in your active theme. Then you can add whatever code you want.
I hope that helps.
– Jonah
April 2, 2013 at 3:54 pm #44699Joshua
ParticipantHey Jonah. I’ve been able to do that. I have a custom list.php live on my site and have managed to customize the warning text line – however, I haven’t been able to add any extra code. Would it be possible for you give me an example of where custom code would go on list.php to make this work?
April 2, 2013 at 8:58 pm #44713Jonah
ParticipantHi Joshua,
Sure. Take a look at this example modifying lines 130-137: http://snippi.com/s/9o55xv5
Does that help?
April 3, 2013 at 6:44 am #44731Joshua
ParticipantHey Jonah. For some reason this code is not working. You can see my code here: http://snippi.com/s/5bz3p4j and the result here: http://new.escoladabiblia.com/cursos/
April 3, 2013 at 4:13 pm #44810Jonah
ParticipantHi Joshua,
That’s strange. Are you sure the list.php you made the changes to is in an ‘events’ folder in your active theme? Can you tell me the full path the file and verify it is within your active theme?
April 4, 2013 at 7:49 pm #44921Joshua
ParticipantHey Jonah. Yes, it is in the events folder within my active theme. I have made changes in the past to both the list.php and single.php – both of which are live and working. For some reason, any code modifying that warning doesn’t work. Don’t really know what to do!
April 5, 2013 at 7:16 am #44969Jonah
ParticipantHi Joshua,
I’m not sure what else to tell you. You’ll need to troubleshoot this by trying to make the same modifications to the core list.php file to see if that shows and/or trying the same things with the default WordPress theme (creating the events folder, etc.) to see if that works. It works fine for me so there must be something you’re not doing right…
I hope that helps!
– Jonah
April 5, 2013 at 2:04 pm #45018Joshua
ParticipantHey Jonah, I sort of figured out what is going on. When I use my theme’s page template for the list view, the custom html does not appear. If I go into the plugin’s settings and resort to the plugin’s default page template, than I can see the custom html. The problem is that I need to use my theme’s page template to view the events. How can I keep this from disabling any custom html?
April 5, 2013 at 2:31 pm #45025Jonah
ParticipantHi Joshua,
The Default Events Template contains the tags for displaying the custom HTML you’ve added (tribe_events_before_html() and tribe_events_after_html()). If you want to use your custom HTML you’ll need to add those template tags somewhere in your theme’s page.php template or whatever other template you have selected to use.
Does that make sense?
April 6, 2013 at 1:43 pm #45085Joshua
ParticipantHey Jonah, I think I confused things by saying custom html. I added the custom message and image to my list.php. However, these additions are only visible when I choose the default template within The Calendar plugin’s settings. If I choose the setting to use the page template from my theme (which is what I want) – than the custom message and image codes are stripped from view. Why is this only visible on the default template and not on my theme’s page?
April 8, 2013 at 11:03 am #45227Jonah
ParticipantHi Joshua,
I’m not sure what the problem could be, it’s working fine for me using either the Default Page Template or Default Events Template. Have you tried deactivating all other plugins or reverting to the default WordPress theme? If you revert to the default WordPress theme, remember you will need to re-copy in the list.php file into an events folder. It could be a conflict with either your theme or another plugin. Try that and let me know if that works.
– Jonah
-
AuthorPosts
- The topic ‘Customize no future events page’ is closed to new replies.
