Posted: January 6, 2017 at 7:06 am
|
We are trying to setup a custom template, as told Is this a common error? child theme folder discription: There are two files that will need to be deactivated since they are for the twenty fourteen theme: Change the name to this: Then duplicate a page.php theme template and rename to single-espresso_events.php. Now open that file for editing. Towards the middle you should see a call for the content. That should be changed to this and save changes: espresso_get_template_part( ‘content’, ‘espresso_events’ ); The next edit is for the archive-espresso_events.php file. Duplicate a page.php file and rename to archive-espresso_events.php. Then open the file for editing. espresso_get_template_part( ‘loop’, ‘espresso_events’ ); |
Hi there, Where do you find that documentation?
No but it depends solely on both your child and parent theme. Before moving forward, do you want full control over the single event output or just specific sections? If you can you let me know some specific on what your trying to do, there may be another, easier method to do what you need. |
|
Hi there, Those steps seem unnecessary, and incorrect in a few places. May I ask what exactly you’re trying to accomplish by making custom templates? Many times you can use specific hooks and filters to make customizations without building sets of custom templates. |
|
|
What I want: Event list page: – single event page |
Those sound like CSS changes to me, the above allows you to change the structure of the page which does not appear to be what you need. For example: article.espresso_events { border: 1px solid #000; padding: 20px; margin: 10px; width: 700px; } Applies a boarder, margins, padding and sets the width to match your ‘wrapper’ elements width for both the event list and single event page. You can add the custom CSS to your site through the customizer. Dashboard -> Appearance -> Customize -> Additional CSS. |
|
|
That’s great Tony, 02 what if I want to remove or add an element, |
You can use something like firebug: https://www.youtube.com/watch?v=tdIk2PztcL0 Or Chrome Dev Tools.
You can usually hide elements with css by setting Adding new fields depends on what you want to ad and where however EE has plenty of hooks that allows you to add additional details if needed, what are you looking to add? |
|
|
i am familiar with dev tools a problem for me is that I can’t find the element: |
|
BTW this CSS works! |
That it has, thank you. Personally I use Chrome but either will work fine for this.
Why are you looking for You won’t find any elements with those classes, it needs to be:
|
|
|
i ment article.espresso_events I got it now, it was my lak of knowledge of CSS |
Great 🙂 Please do let us know if you have any further questions. |
|
|
Thank you very much, |
The support post ‘CSS not loading with custom template’ 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.