Scott Fresener
asked 10 years ago

When using the Category Widget in full width – it lists “ALL” and then all the sub categories. When you click on “All” it does not take you to a complete category listing page but returns you to the home page of the site.
In your demos you show the Category Names/Headers in various colors. How do I do that?
There is a “Read More Content” check box in the widget but I don’t see that it does anything. It would be nice to have a “Read More Content” link after the links to the various posts in the sub categories.
Thanks. Love the theme!

2 Answers
DominicStaff
answered 10 years ago

Hi Scott,
1. To display the Category Names/Headers in various colors, you can change the type of categories on your site as the following guideline:
– Log in to Dashboard > Post > categories. Then select category style
See the screenshot: 
– To change the logo image, open the folder in the folder path : wp-content\themes\dw-focus\assets\colors then look for the style folder that you want to change the logo and change the logo image as you wish. (Because each style/color has its own logo)
2. To have a “Read More Content” link after the links to the various posts in the sub categories, You can add the following code to the functions.php file.

  function new_excerpt_more( $more ) {
    return ' <a class="read-more" href="'. get_permalink( get_the_ID() ) . '">Read More</a>';
}
add_filter( 'excerpt_more', 'new_excerpt_more' );

Hope this helps !

Scott Fresener
replied 10 years ago

Thanks. But, in the full width category widget one of the top selections is “ALL” followed by selections for the sub-categories. If you click on “ALL” it takes you to the home page. How can I change it so when they click on “ALL” it take them to all the posts in that category. If they click on the Category name (in color or whatever) it does that. I want the same function if they click on “ALL”.

Wilfred
answered 10 years ago

To resolve this issue please try this:
1. Open file dw-focus-categories.php in your-site > wp-content > themes > your theme> inc > widgets >  dw-focus-categories.php
2. Replace following code – line 201 

 <li><a href="" class="tab_title active" data-catid="<?php  echo $category_id; ?>" href="<?php echo $category_link ?>"><?php _e('All','dw_focus') ?></a></li>

by 

 <li><a href="<?php echo get_category_link($category_id) ?>" class="tab_title active" data-catid="<?php  echo $category_id; ?>" href="<?php echo $category_link ?>"><?php _e('All','dw_focus') ?></a></li>

Hope this helps!

Scott Fresener
replied 10 years ago

Worked great!!Thanks for the great support.

Powered by DW Question & Answer Pro