Support only during business hours : Monday to friday, from 8:30 am – 5:30 pm CEST

In regards to the COVID-19 situation

Your support team is currently doing their best to offer the best support possible despite the current COVID-19 situation. However during these exceptional circumstances, please note that you should expect a response time of 2-3 business days, until further notice.Rest assured that we will still do our best to handle your requests as soon as possible! Everyone stay safe and healthy! 😷

Adding shortcode in theme

This topic is resolved
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • Dyflo
    Participant
    • 2 Topics
    • 6 Posts

    Hi,

    I have a shortcode that I would like to add in the header of my articles near the title as well as on each article blocks of my blog page.

    Could you tell me where the blog template php files and single blog page are located and where can I add them for both ?

    I looked for template-functions.php but the shortcode does not appear in the header, don’t know why. It’s this php line : <?php if( function_exists(‘dot_irecommendthis’) ) dot_irecommendthis(); ?> provided by the plugin I Recomend This.

    Thanks for helping,

    Regards,

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 2223 Posts

    Hi Dyflo,

    To add/change this feature to your website, the best practice is to create your own child theme and override the template. Did you created one?

    For more about creating child themes, please read the following post:

    Creating a Child Theme

    If you have never done this before, we recommend you to require the services from a nearby web developer or from Envato Studio freelancers (https://studio.envato.com/explore/websites-programming). This web platform gives you access to developers who have already experience with theme customizations, and for very competitive prices.

    Best regards,

    Dyflo
    Participant
    • 2 Topics
    • 6 Posts

    Hi Manathan,

    Yes I am already using the Cera child theme.

    I just wanted to know where the template of the single post page was located in the Cera theme. So I can modify it and copy it in the child theme.

    Thanks 🙂

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 2223 Posts

    Hi Dyflo,

    Thank you for your feedback.

    To edit the single post header, copy the ‘single.php’ file located in the cera theme to your child theme. In the case you want to edit de blog header, you’ll have to edit the ‘archive.php’ file.

    If you want to use a shortcode, we suggest you to use the ‘do_shortcode’ function.

    hope this will help you get what you’re trying to achieve.

    Cheers,

    Dyflo
    Participant
    • 2 Topics
    • 6 Posts

    Hi Manathan,

    Thank you for your reply, that’s helped me, I was able to add my shortcode successfully !

    Thank you for your help and support !

    Have a nice day 🙂

    Cheers,

    Manathan
    Keymaster
    Themosaurus Support
    • 0 Topics
    • 2223 Posts

    You’re welcome Dyflo! 🙂

    If you’re happy with our theme, feel free to review our theme on our Themeforest page:
    https://themeforest.net/item/cera-intranet-community-theme/24872621

    It’s very appreciated and it helps us making our products more known to new potential customers, which allow us more time to improve the quality over time and develop new features. It’s a win-win !

    And by doing this, you will be making a great contribution to our community! #SharingIsCaring 💪🏻

    Thank you!

Viewing 6 posts - 1 through 6 (of 6 total)

The topic ‘Adding shortcode in theme’ is closed to new replies.

Troubleshooting Demo Imports

You're trying to setup your theme but you're experiencing errors when importing the demo content? Or you've just followed the setup guide but your website doesn't look exactly like our demo? These are common issues for which you can find easy and quick fixes.

Happy With our Support So Far?

Feel free to review our theme on Themeforest! It helps us making our products more known to new potential customers, which allow us more time to improve the quality and develop new features. #SharingIsCaring ❤️