Skip to content
This repository was archived by the owner on May 5, 2021. It is now read-only.

Commit 6c63f67

Browse files
author
claudiuvertistudio
committed
Fixed #56 Image alt text issue
1 parent 8066d64 commit 6c63f67

File tree

4 files changed

+20
-6
lines changed

4 files changed

+20
-6
lines changed

functions.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,7 @@ function zillah_php_style() {
441441
$zillah_c2 = $zillah_picker->color2;
442442
$zillah_c3 = $zillah_picker->color3;
443443
$zillah_c4 = $zillah_picker->color4;
444-
// $zillah_c5 = $zillah_picker->color5;
444+
$zillah_c5 = $zillah_picker->color5;
445445
}
446446

447447
if( isset( $zillah_c5 ) ) {

inc/widgets/about-me.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ public function widget( $args, $instance ) {
2020
}
2121

2222
if ( $image_url ) {
23-
echo '<div class="photo-wrapper"><img class="about-photo" src="' . $image_url . '" alt="' . $title . '"/></div>';
23+
echo '<div class="photo-wrapper"><img class="about-photo" src="' . $image_url . '" '. ( $title ? 'alt="'.$title.'"' : '' ) . '/></div>';
2424
}
2525

2626
?>

style.css

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2162,6 +2162,10 @@ object {
21622162
color: #7fcaad;
21632163
}
21642164

2165+
.sd-social-icon .sd-button span.share-count {
2166+
display: none !important;
2167+
}
2168+
21652169
div.sharedaddy h3.sd-title:before {
21662170
display: none !important;
21672171
}

template-parts/content-single.php

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,19 @@
6161
<div class="author-details-img-wrap">
6262
<?php echo get_avatar( get_the_author_meta( 'user_email' ), '100' ); ?>
6363
</div>
64-
<div class="author-details-title">
65-
<?php echo get_the_author_meta( 'first_name' ) . ' ' . get_the_author_meta( 'last_name' ); ?>
66-
</div>
67-
<div class="author-details-content"><?php echo nl2br(get_the_author_meta('description')); ?></div>
64+
<?php
65+
$author_first_name = get_the_author_meta( 'first_name' );
66+
$author_last_name = get_the_author_meta( 'last_name' );
67+
if( $author_first_name!=='' || $author_last_name!=='' ) {
68+
echo '<div class="author-details-title">';
69+
echo $author_first_name . ' ' . $author_last_name;
70+
echo '</div>';
71+
}
72+
73+
$author_description = nl2br( get_the_author_meta('description') );
74+
if( $author_description!=='' ){
75+
echo '<div class="author-details-content">' . $author_description . '</div>';
76+
}
77+
?>
6878
</div>
6979
</div>

0 commit comments

Comments
 (0)