Jump to content

Archived

This topic is now archived and is closed to further replies.

sheilahoff

Product Catgory Results need unique headings

Recommended Posts

sheilahoff

We have pages that are setup to display only one category. To clarify, under Products and then Levels there are 3 levels. Each one brings up a page with just that category of products. http://perfectimage-llc.com/product-category/level-system/level-1/and http://perfectimage-llc.com/product-category/level-system/level-2/.

 

Initially the page heading all said  "Search Results" because that's what I added in a text box. All the levels use the same template. So I went in and unlinked the template and saved a level 1 and a level 2 but I can NOT make them each say their own unique text heading. Where are they also linked? How can I achieve this?

 

I don't know what you'll see when you check as I'm in the middle of trying to figure this out. At the moment they all say the same thing...Product Recommendations...even though I've unlinked their templates and made a unique Level 1 and Level 2 template. And I'm realizing now it is NOT just the Product Levels but all products with this issue. SO...I hope someone can help me sort this out. Thanks.

 

WP4.1.1 and DMS 2.1.9.3


Sheila Hoffman | Hoffman Graphics | Seattle

Share this post


Link to post
Share on other sites
Danny

Hi,

 

DMS does not support the ability to assign individual templates on a category by category basis. Therefore, if you configure a section on one category, that sections configuration will appear on all category pages.

The only way to do this would be to use the NextBox section and use the WordPress function https://codex.wordpress.org/Function_Reference/single_cat_title


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
sheilahoff

Thanks Danny. I've tried this and get this error: Looks like your NexBox PHP resulted in an error :/

I've checked Activate PHP execution.

 

I've tried both the default usage provided and the example provided to no avail. What am I missing? Would LOVE to make this work w/o hiring someone to do it in the template. THANKS!

<p><?php single_cat_title('Currently browsing '); ?>.</p>

and

 

<h2><?php single_cat_title( '', true ); ?></h2>


Sheila Hoffman | Hoffman Graphics | Seattle

Share this post


Link to post
Share on other sites
Danny

You can not use <?php or ?> in the NextBox section, nor can you use HTML wrapped around PHP.

 

So try this:

 

single_cat_title('Currently browsing ');


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
sheilahoff

YES! That works! Thanks so much.

I don't see how to mark this as solved.


Sheila Hoffman | Hoffman Graphics | Seattle

Share this post


Link to post
Share on other sites
sheilahoff

Danny, you'd think the client would be happy now! NO! Now he's asking me for something else and I'm hoping you can tell me if this is doable also.

 

He wants each results to have a unique intro paragraph. So my non-dev thought was that I'd need to create a new page for each of these and then put that text block above the product category archive. But I'm not sure if there's a way to do that so each page gets only that one category pulled into it. This is a little over my head. But I suspect I'm making it too complicated and that it IS doable.

 

Thanks,

Sheila


Sheila Hoffman | Hoffman Graphics | Seattle

Share this post


Link to post
Share on other sites
sheilahoff

I've got it...I was able to make this work by creating a new page and using WooCommerce shortcodes for the categories. It's 21 new pages with a loop for the intro text as well as a NextBox for the shortcode. Then I just need to relink all the menu items. Lots of work but, hey, the client is always right. Thanks.


Sheila Hoffman | Hoffman Graphics | Seattle

Share this post


Link to post
Share on other sites
Danny

No problem.


Please search our forums, before posting!

Share this post


Link to post
Share on other sites

×