WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: NextGEN Gallery] Failing XHTML Validation for an empty span tag (1 post)

  1. Pepe Huerta
    Member
    Posted 5 years ago #

    Hi,

    First, thanks for an excelent plugin! One of the best I've ever seen tbh.

    To the point... There is a small detail concering xhtml validation when a gallery does not have a description attached to at least one picture.

    The script prints an empty span tag (<span></span>) wich does not validates as correct xhtml.

    Just to hot fix it, I've added a transparent 1 pixel image to the function wich inserts this span tags.

    nggfunctions.php (Line 356)

    $out .= '<span>'.html_entity_decode(stripslashes($picture->description)).'<img src="css/monsterpixel.gif" alt="" /></span>'."\n";

    That solves the validation problem but will be nice to have an official code solution for pictures without descriptions like removing the span tag if there is no description present for the image.

    Cheers!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.