WordPress.org

Ready to get started?Download WordPress

Forums

Front-end Editor
[resolved] No "Change Image" button for editable_image() (9 posts)

  1. Dylan Kuhn
    Member
    Posted 4 years ago #

    The editable_image() template tag is very cool, but I can't get the "Change Image" button to show up reliably in the media uploader. In FireFox I it appears in the "Media Library" tab but not the "From Computer" tab. In IE8, I get "Permission Denied" errors in "Media Library".

    I put some effort into solving this, but failed so far. IE8 especially stymies me.

    I believe the relevant code is in editor/editor.dev.js:307 replace_button(). I found that since the media uploader is loaded for post ID 0, there is no submit button to be replaced. I tried appending it instead, but the livequery didn't seem to fire reliably.

    This would be great to get working, but I'm unsure what to try next.

  2. scribu
    Member
    Plugin Author

    Posted 4 years ago #

    In FireFox I it appears in the "Media Library" tab but not the "From Computer" tab.

    Fixed: http://plugins.trac.wordpress.org/changeset/281890/front-end-editor

  3. Dylan Kuhn
    Member
    Posted 3 years ago #

    Fixed: http://plugins.trac.wordpress.org/changeset/281890/front-end-editor

    That's essentially what I tried too, but I get odd behavior. In FF 3.6.8, I upload the new image, and the media-item div shows up, but the button doesn't. If I then scroll the background frame a little, the button shows up. In Chrome and IE8 the button doesn't show up even then.

    I tried grabbing an uncompressed livequery.js and stepping through that, but I haven't figured out what's going on yet.

  4. scribu
    Member
    Plugin Author

    Posted 3 years ago #

    In FF 3.6.8, I upload the new image, and the media-item div shows up, but the button doesn't. If I then scroll the background frame a little, the button shows up.

    Ah, I remember that bug. I stopped trying to fix it long ago. Maybe you have better luck. I assume it has something to do with the CSS too.

  5. Dylan Kuhn
    Member
    Posted 3 years ago #

    I'm not sure about the CSS, it seemed to me like something goes wrong in livequery. I never figured out exactly why it fires on a scroll or resize and not on a timer, but I think with some more study of the livequery code I could work it out. Unfortunately I'm out of time for now, but it's such a good feature that I may be able to wrangle some more time to work on it later.

    In one of my plugins I've resorted to adding a script to the HTML in the media_meta filter to accomplish something similar. That might work more widely than the livequery approach, but there could be drawbacks I'm not aware of.

  6. jrb04c
    Member
    Posted 3 years ago #

    Having the exact same issue with dev version. Any progress on this, sir?

  7. Dylan Kuhn
    Member
    Posted 3 years ago #

    None from me yet - I'll look again when I get a project that uses this.

  8. andradenation
    Member
    Posted 3 years ago #

    Hi, all.

    Wanted to check back in to see if there was a resolution on this one.
    Same issue.

    I am using the 1.9.3-alpha3 version available.
    It was happening with the release offered from the WP Repository so tried the dev version.

    Is there any place I can start a search for more digging or assistance?

  9. scribu
    Member
    Plugin Author

    Posted 3 years ago #

    A while ago, I modified the JavaScript so that the manipulation occurs the instant you hover your mouse over the image div. Haven't had problems since.

    To make sure you have this change, download the development version again.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic