Support » Plugin: Image Widget » [Plugin: Image Widget] Image Link – Beyond Image

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Peter Chester


    you can override the widget template in your theme.

    from the readme:

    The Image Widget comes with a default template for the widget output. If you would like to alter the widget display code, create a new folder called “image-widget” in your template directory and copy over the “views/widget.php” file.

    Edit the new file to your hearts content. Please do not edit the one in the plugin folder as that will cause conflicts when you update the plugin to the latest release.

    Just the info I was looking for, is there a way of targetting this new location for a certain widgets only?

    I’ve moved the h3 below the image and linked it for a layout of one widget but as default I still want it to use the standard location file.

    Can anyone give me the code to remove the “hot link” around the image. I believe the portion that needs to be changed is:
    if ( $imageurl ) {
    echo “<img src=\”{$imageurl}\” style=\””;
    if ( !empty( $width ) && is_numeric( $width ) ) {
    echo “max-width: {$width}px;”;
    if ( !empty( $height ) && is_numeric( $height ) ) {
    echo “max-height: {$height}px;”;
    echo “\””;
    if ( !empty( $align ) && $align != ‘none’ ) {
    echo ” class=\”align{$align}\””;
    if ( !empty( $alt ) ) {
    echo ” alt=\”{$alt}\””;
    } else {
    echo ” alt=\”{$title}\””;
    echo ” />”;

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘[Plugin: Image Widget] Image Link – Beyond Image’ is closed to new replies.