Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #494428

    Hi and thx again for this awesome theme.

    I would like to modify the template for every single pages of portfolio (page with the detail of 1 specific portfolio) to add some html at the beginning of the portfolio content section (below header and over portfolio detail)

    I am using a child theme so basically i tryed to copy single-portfolio.php to my child theme and write things in it but nothing shows… So i also tryed to copy includes/loop-portfolio-single.php to my child theme and add content to it and also nothing show…

    Do you have any Idea about what could be the problem or where should i add my code?

    Thanks in advance

    #494489

    Hey lepetitweb!

    Do you need to add those infos after the body?
    What code is it?

    Thank u

    Best regards,
    Basilis

    #494523

    i want to add a slideshow and a short text block below the breadcrumb bar. I dont want to have to change it on all portfolio if it change so i want it to be in the portfolio single page template.

    I actually achieved to do it in a dirty way a few mins ago after finding more info on the forum

    I added this code in template-builder.php

    if (is_singular('portfolio')){
    	$laposition = strpos($content, "'container'");
    	$temp = substr($content, 0, $laposition-11);
    	$temp .= do_shortcode("[av_layerslider id='99']");
    	$temp .= substr($content, $laposition-11, strlen($content));
    	$content = $temp;
    }
    echo $content;
    

    Finding a string in the content, targeting the spot where i want my stuff and then insert my content in it, but there must be a cleaner way to do it, maybe with a hook or a filter

    #496022

    Hey!

    Why not just use the layout builder to add it to your portfolio post content at the top? If your just trying to add the same content to each post to make it easier on yourself then you would have to edit the portfolio single template file like how your doing.

    Best regards,
    Elliott

    #496026

    Hi and thanks to have had a look at my question.

    We have 568 portfolios in french and english languages so over 1100 at total… the header we want to add will change from time to time so we dont want to have to change each portfolio 1 by 1 using the builder…

    Anyway the way i done it works… It’s kinda dirty but it does work and i’ll keep it like that then

    Thanks for your help

    #496260

    Hi,

    Glad you got it fixed, please let us know if you should need any more help on the topic.

    Regards,
    Rikard

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.