-
-
When I add a featured image for a blog the alt tags are not in the page code. How do I keep my image alt tags for featured images?
-
Hello,
Sorry for the late reply.
Please go to file includes/view/blog/loop-index.php and find these lines:<img src="<?php echo esc_url(codeless_image_by_id(get_post_thumbnail_id(), 'blog', 'url')) ?>" alt="">
And replace with these:
Best regards!
- This reply was modified 8 years, 2 months ago by Mirela.
-
This does not work. When I replace the code snippet I get the new code snippet in the location where the featured image should display.
-
Hello,
Maybe you pasted it wrong. An unclosed quote or missing comma can cause the code not to work. Please send us your wp credentials in a private reply. So we can give it a closer look.
Best regards!
-
I was very careful to only replace the information you indicated. I also had another person check my work. These are credentials to our production site. I have it backed up, but please be careful.
sftp://<span style=”color: #162a33; font-family: ‘Open Sans’, Arial, Helvetica, sans-serif; font-size: 14px; line-height: 20px;”>166.78.99.121</span>
ID: iqense-codeless
Password: %!1WebMarketing@
Port: 2222
-
-
Hello,
Can you please check the credentials again? I can’t log in.
Best regards!
-
-
I have the same question, but for the staff images. How do I get the alt text to show up in the page code for the staff images?
-
Hello,
@pyantus,
I still can not connect. Please go to file includes/view/blog/loop-grid.php and find this line:
<img src="<?php echo esc_url(codeless_image_by_id(get_post_thumbnail_id(), '', 'url')) ?>" alt="">
Replace with this:
<?php echo codeless_image_by_id(get_post_thumbnail_id(), '', 'alt') ?>
Best regards!
-
I tried this and it didn’t work. I’m not using the loop grid at the top of the blog page. I’m simply looking for the individual posts to include the Alt from the featured image.
I find it hard to believe this key SEO issue is not covered with this theme, or that I’m the only person experiencing the issue.
-
Hello,
Can you show us your site url? So I can see what blog layout have you used.
Best regards!
-
The site is https://through-channel.com. The blog can be found at https://through-channel.com/blog/
-
Hello,
Please go to file includes/view/blog/loop-index.php find these lines:
<?php if(!is_single() || (is_single() && $cl_redata['use_featured_image_as_photo']) ): ?> <img src="<?php echo esc_url(codeless_image_by_id(get_post_thumbnail_id(), 'blog', 'url')) ?>" alt=""> <?php endif; ?>
Replace with these:
<?php if(!is_single() || (is_single() && $cl_redata['use_featured_image_as_photo']) ): ?> <?php echo codeless_image_by_id(get_post_thumbnail_id(), '', 'alt') ?> <?php endif; ?>
Ps: this is a tested code so it should not give any issue if pasted right. If you still can not do it, then send us your wordpress credentials in a private reply. We will do it for you. (the ftp data is not valid, i can not connect)
Best regards!
-
When I make that change no content appears on https://through-channel.com/blog/
-
-
Hello,
The ftp gives me error upon file upload(screenshot). Send us only the wordpress credentials (https://through-channel.com/wp-login.php) so i can edit the file from wordpress dashboard.
Best regards!
-
-
-
-
Hello,
Sorry for the late reply.
Did you made any changes later? Or did you update theme after my edit? i see the change i made to file includes/view/blog/loop-index.php is reversed back to the original form. That is why the alt is not displaying.
I edited it again.
In other posts featured images, you have only the title set up. Not the alt’s. I added alt text to this post‘s featured image. It shows here (screenshot).Best regards!
-
Yes, when I didn’t hear back from you I updated the theme. I was hoping the new version might address the issue. The post you created still has an alt issue.
See this screenshot: https://through-channel.com/wp-content/uploads/2016/04/Alt-issue.png
-
Hello,
Please see screenshot: https://pho.to/A7pQZ for more explanations.
Theme is already SEO optimized and you can also install any SEO plugin to enhance it.Best regards!
-
I can’t see how you can claim your theme is SEO optimized if it can’t even handle an alt tag of a featured image on a blog post.
I also can’t believe you posted content to my live site and social feeds without my permission.
I’ve had enough of this awful support. I’m going to move off this theme as soon as possible, and would strongly recommend others do the same.
-
Hello,
I am sorry for your frustration. I am always trying to help. The only content added to your site is just one post for me to be able to show the changes made. No changes was made to the socials. If this has caused you troubles, i sincerely apologize. There was no harm intended!
Theme is indeed SEO optimized because it has a lot of other features incorporated that help you rank in google search. As for the alt’s, this is our developer’s team choice for the theme.
You can suggest us new features and improve the existing by writing us at this forum.
Let us know.Best regards and Happy Easter!
-
You must be logged in to reply to this topic.