WordPress.org

Ready to get started?Download WordPress

Forums

MudSlideShow
[resolved] Malformed generated code problem (1 post)

  1. brucknerite
    Member
    Posted 2 years ago #

    Hi!

    I set up to try your plugin but found a problem with the code generated for galleries in a page. For instance:

    [mudslide:flickr,0,89687103@N00,72157615386874737]

    I pinpointed the problem to a quote escaping problem on mudslideshow.php function muds_gallery. When assigning the variable $updatelink bogus <br /> were being inserted in the javascript for the onclick attribute of the generated a tag.

    The obvious solution was to convert said javascript into a one-liner and replace quotes with the corresponding entity &quot;. The result is somewhat less legible, but it works on my server:

    $updatelink = "<div id='throbber-msspage$rand' class='throbber-off'><a style='cursor : pointer;' id='mss-update-$rand' onclick='var aux = document.getElementById(&quot;throbber-msspage$rand&quot;);aux.setAttribute(&quot;class&quot;, &quot;throbber-on&quot;);aux.setAttribute(&quot;className&quot;, &quot;throbber-on&quot;);muds_update( &quot;gallery&quot;, {$aux['id']},&quot;{$aux['type']}&quot;, &quot;{$aux['user']}&quot;, &quot;{$aux['gallery']}&quot;, $first, $last, $conf, $rand );'>".__('Update','mudslide')."</a></div>";

    I have noticed other problems (i.e.: including descriptions in galleries seem to break them, skipping random images), but with this tiny fix I can use your plugin. Thank you for your effort!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic