WordPress.org

Forums

SEO Friendly Images
Plugin is Broken, Here is a fixed version (18 posts)

  1. styledev
    Member
    Posted 3 years ago #

    I had to fix this plugin for a client so here is the updated code for seo-friendly-images.php

    http://pastie.org/3205156

    The author should update accordingly.

    http://wordpress.org/extend/plugins/seo-image/

  2. Moogle Stiltzkin
    Member
    Posted 3 years ago #

    thk u for sharing bro :}

  3. fotogenico
    Member
    Posted 3 years ago #

    can anyone explain simply how it should work? so far i can't see any change.

  4. styledev
    Member
    Posted 3 years ago #

    The plugin simply gives all your images on your site alt and title tags and fills them in automatically for you. So view the source of the page or use a browser debugger to look at an image and it should have ALT="something" and TITLE="something"

    To use the patch above go to the Pastie link and click the raw button, copy it and us that to replace the contents of seo-friendly-images with it.

    I did notice I forgot to delete the print_r($status); on line 242, so you should remove that. Basically I fixed all the errors that the plugin spits out when you turn on WP_DEBUG in wp-config.php.

  5. fotogenico
    Member
    Posted 3 years ago #

    i think this is exactly what i did but my alt and titles haven't changed; will try again later today, thanks

  6. fotogenico
    Member
    Posted 3 years ago #

    but still nothing; should i do sth else like change some configurations;

  7. styledev
    Member
    Posted 3 years ago #

    This is what my SEO Friendly Images setting page looks like: http://cl.ly/2Z3b000p383E242s2m0c

    I would set WP_DEBUG to true and make sure you do not have any other erros, maybe from another plugin.

  8. fotogenico
    Member
    Posted 3 years ago #

    my setting page looks exactly the same, it just doesn't change anything in
    my images. what is wp_debug? thanks again for your time.

  9. styledev
    Member
    Posted 3 years ago #

  10. thatwastaxing
    Member
    Posted 3 years ago #

    Unfortunately, the fix didn't work for me either.

  11. southcast
    Member
    Posted 2 years ago #

    Fix did not work, could you please spare a few moments for us, as the developer seems to have abandoned the project. Its a good contribution but what good is it if it does not work.
    Some expert gotta take up this issue now, coz there are far too many people whom this is not working for.

    P.S - I use wp - 3.3.2.. thnks.

  12. styledev
    Member
    Posted 2 years ago #

    Hey Guys,

    I downloaded the latest version. When I posted my fix I think this one wasn't out. Regardless this one showed errors with WP_Debug mode on. I updated the following code and everything works for me.

    Full code: https://gist.github.com/2698146

    In function seo_friendly_images_options_page():
    // Author did not account for $status being an empty array.
    // I am checking to see if the value exists if not I set the vars to empty.
    $theVersion = ( isset($status[1]) ? $status[1] : '');
    $theMessage = ( isset($status[3]) ? $status[3] : '');

    In function seo_friendly_images_options_page():
    // Author created variable $actionurl but then called $action_url.
    // I updated the variable name to reflect the call as it is easier to read this way.
    $action_url=$_SERVER['REQUEST_URI'];

    Note: I will try to get the author to incorporate these changes and release a new version so we won't have to bother with this.

    Full code: https://gist.github.com/2698146

  13. southcast
    Member
    Posted 2 years ago #

    @styledev..deeply appreciate your help. But, It somehow did not work for me due to post-type issues, I guess. My post types are image.

    This is a link to one of my posts

    If you see in the source code the featured image is still missing an alt tag, while I have the plugin activated in the back-end, with original code replaced with yours. May I also bring to your attention that my theme shows a re-sized image as the featured image in the post.

    I know the chances are remote but any kind of help will be appreciated.
    thank you, kindly.

  14. styledev
    Member
    Posted 2 years ago #

    @southcast - I think the issue here is you are running a WooThemes plugin/theme that may have last say in how the images are printed. I would suggest making a page and assigning a featured image to it and adding an image into the body and checking those images to see if the plugin works. They should not have a woo-image class.

  15. southcast
    Member
    Posted 2 years ago #

    @styledev - thank you for your valuable time, I have hired a wordpress expert to take a look at it.
    Again, Thank you !

  16. artdias90
    Member
    Posted 2 years ago #

    for me the alt field gets the post title, but the title field still gets the image title, how to make it get the post title as well?

  17. artdias90
    Member
    Posted 2 years ago #

    for ALT I want the file title, but the closest option is file name which is not the same

  18. glieberman
    Member
    Posted 2 years ago #

    Neither the plugin or the fix works for me.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic