Deprecated: Function get_currentuserinfo is deprecated since version 4.5.0! Use wp_get_current_user() instead. in /var/www/html/wp-includes/functions.php on line 5383

Multiple Pages with different Portfolio page

New Front EN Support Forums Ikebana Theme Support Multiple Pages with different Portfolio page

Viewing 10 posts - 1 through 10 (of 22 total)
  • Author
    Posts
  • #1691
    chao
    Participant

    As per title, can I do that? How?

    #1699
    mmsatori
    Keymaster

    Hey Chao,

    I am not sure I understood what you mean – please clarify, did you have in mind several portfolio pages each displaying its own portfolio items?

    Sincerely,
    Andrew / Satori Studio

    #1719
    chao
    Participant

    Yes, can we make multiple portfolio pages, each has different portfolio items.

    #1722
    mmsatori
    Keymaster

    Hey Chao,

    Ikebana envisages only one template for the portfolio page, and all pages with that template will display all “project”-type items. One possible workaround is to use portfolio tag archive pages, e.g. this one in the demo. The tag archives are generated automatically and display portfolio items belonging to a particular tag; they have an URL of the form: yourwebsite.com/tag-portfolio/name where “name” is the name of the portfolio tag. You can add portfolio tag archive pages to the menu in “Appearance -> Menus” (in case tags are not shown among the menu insertion options, please click the top-right “Screen Options” tab and choose both “Tags” checkboxes from the list.

    Please let me know if this addresses your needs!

    Sincerely,
    Andrew / Satori Studio

    #1733
    chao
    Participant

    All right, I didn’t think about that.

    #2817
    sdanpo
    Participant

    Andrew ,

    I have a question.
    I tried this solution and it seemed like the project always showed on both the tag page and the portfolio page.
    Is it possible to make it appear only on the tag page and Not on the Portfolio page ?

    Thanks,
    Dan

    #2820
    mmsatori
    Keymaster

    Hey Dan,

    in principle, the portfolio page template displays all projects there are, and the tag archive pages display only the projects with a specific tag. There are two ways to proceed here – either use tag archive pages in both cases, so that projects are always separated according to their tags, or customize the WP_Query object in the “page_portfolio.php” template to exclude projects with a certain tag. If you choose the second path, I might be able to help you in constructing the custom query.

    Sincerely,
    Andrii / Satori Studio

    #2822
    sdanpo
    Participant

    Hey,

    Thanks a lot for the answer .
    I highly appreciate your will to help!
    Will be in touch later on when I have the need complete in my8 head.

    Thanks,
    Dan

    #3360
    oren
    Participant

    Hello Andrew,

    This is exactly what I want to achieve!

    But, I can’t find the way to exclude certain “tagportfolio” ID from the general portfolio… can you please give me a hint?

    in the “page_portfolio” template I tried:

    $stycky_query = new WP_Query( array( ‘post_type’ => ‘project’, ‘meta_key’ => ‘satori_post-sticky’, ‘tagportfolio__not_in’ => array( 34 )) );

    …to exclude the projects tagged with tagportfolio’s ID: 34.

    not working :(

    Your help is much appreciated!

    Oren

    #3364
    mmsatori
    Keymaster

    Hey Oren,

    the WP_Query object has an option to include or exclude certain items of custom taxonomies, but you’d need to use the tax_query parameter in this case, e.g. on line 69 in the page_portfolio.php theme file:

    $wp_query = new WP_Query( array( 'posts_per_page' => $ppp , 'post_type' => 'project' , 'paged' => $paged , 'post__not_in' => $exclude_ids, 'order' => $order, 'orderby' => $orderby, 'tax_query' => array(
    		array(
    			'taxonomy' => 'tagportfolio',
    			'field' => 'slug',
    			'terms' => array( 1, 2, 3 ),
                            'operator' => 'NOT IN'
    		)
    	) ) );
    

    replacing the “1”, “2”, “3” etc with the slugs of the portfolio tags (“Portfolio -> Tags” admin section) you wish to exclude from the portfolio page.

    Sincerely,
    Andrii / Satori Studio

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