- This topic has 10 replies, 2 voices, and was last updated 4 years, 7 months ago by Skandha.
-
AuthorPosts
-
August 29, 2019 at 3:55 pm #180789the brinkParticipant
Hi,
I added category descriptions a few days ago while I was begining to work with this theme and I could have sworn that they appeared below the page title on the archive page for each category.
However, the descriptions are no longer visible there. I was wondering if I have accidentally toggled some simple option or if I am wrong and the descriptions were never shown on this theme.
I did try to use the solution provided in this thread, but my child theme doesn’t yet have an “archive.php” file and I don’t even know what I should write in it so that it behaves correctly. Or should I just copy the parent theme’s “archive.php” file wholesale? That seems messy to me.
Hope you can help,
Thanks
Rosie
August 30, 2019 at 12:47 am #180812SkandhaParticipant@the-brink: Hello Rosie,
The category description should automatically show up if you have added the description for any category.
Let me know for which category you have added the description so that I can check it out.Kind Regards,
SkandhaAugust 30, 2019 at 12:56 pm #180874the brinkParticipantThe categories for which I have written descriptions are all the sub-categories under Video i.e.:
Migrant Caravan
Messages to Trump
Changing TackCheers
Rosie
September 1, 2019 at 3:22 am #180973SkandhaParticipant@the-brink: Hello Rosie,
I checked the Category links and the category description are showing up right under the Category Title.
Can you check it and let me know if the issue is resolved?Kind Regards,
SkandhaSeptember 2, 2019 at 12:20 am #181042the brinkParticipantHi,
Yeah I’ve managed to make them visible by adding in a bit of code to the category.php file of my child theme as suggested in another forum. I was a little wary about this as I don’t know anything about php but it seems to have worked.
In case you have any advice or warning about this the code I added was:
<?php
the_archive_description( ‘<div class=”taxonomy-description”>’, ‘</div>’ );
?>on line 27 just under the <header> division.
Anything I’ve missed here?
Anything it might mess up?Thanks a lot,
Rosie
September 2, 2019 at 12:37 am #181049SkandhaParticipant@the-brink: Hello Rosie,
Adding the code in the child theme shouldn’t be necessary as the same code is used if you see in line no 24 in the archive.php file.Can you remove the code from the child theme and let me know?
Kind Regards,
SkandhaSeptember 2, 2019 at 12:56 am #181051the brinkParticipantHi,
I have removed the line of code I added from category.php and the category descriptions have vanished.
here are lines 20 to 30 of my archive.php file if that’s any help:
<header class=”page-header”>
<?php the_archive_title( ‘<h1 class=”page-title”>’, ‘</h1>’ ); ?>
</header><!– .page-header –>
<div class=”square”><?php echo cleanportfolio_get_svg( array( ‘icon’ => ‘square’ ) ); ?><span class=”screen-reader-text”><?php esc_html_e( ‘Square’, ‘cleanportfolio’ ); ?></span></div>
<?php the_archive_description( ‘<div class=”archive-description”>’, ‘</div>’ ); ?>
</div><!– .archive-heading-wrapper –><?php
$blog_display = get_option( ‘jetpack_content_blog_display’);if ( ‘content’ == $blog_display ) : ?>
September 2, 2019 at 4:09 am #181060SkandhaParticipant@the-brink: Hello Rosie,
I will need to have a look at your site to debug the issue. For that I will need your WP Admin Credentials. I will contact you shortly by email.Kind Regards,
SkandhaSeptember 2, 2019 at 4:13 am #181061SkandhaParticipant@the-brink: Hello Rosie,
Never mind I found out why the description was not showing up. The description color was set to transparent.Go to => Appearance => Customize => Additional CSS and add the following CSS Code.
.archive-description { color: #555 !important; }
Kind Regards,
SkandhaSeptember 2, 2019 at 10:00 pm #181120the brinkParticipantah great. thanks for that.
September 3, 2019 at 12:11 am #181130SkandhaParticipant@the-brink: Glad that worked out!
Kind Regards,
Skandha -
AuthorPosts
- The topic ‘make category descriptions visible’ is closed to new replies.