SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Member
    Join Date
    Sep 2009
    Posts
    6
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Wallpaper site problem

    Does any know how add a link to the image?

    At the moment when I click on the wallpaper image there is no link.

    Here is the code:



    if ($Wallpaper1 != NULL) {
    $size='';
    $size=getimagesize("images/wallpapers/".$Wallpaper1);
    if ($Settings['Enable_Watermark'] == '1') {
    $dHTML .= '<a href="'.$image_path.'images/wmwallpapers/'.str_replace(" ","-",$Title).'-1.jpeg" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';
    } else {
    $dHTML .= '<a href="'.$image_path.'images/wallpapers/'.$Wallpaper1.'" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';
    }
    }

  2. #2
    SitePoint Addict peterb's Avatar
    Join Date
    Jun 2003
    Location
    Athens, Greece
    Posts
    283
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    That's not a php question but here's an example.

    Code:
    <a href="moda.php">
    <img src="images/diakosmisi/3.jpg" title="" width="18" height="17" border="0" />
    </a>

  3. #3
    SitePoint Member
    Join Date
    Sep 2009
    Posts
    6
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Its from a php script.

    here is the rest of the relevant code:

    $WallpaperNav=$aWallpaperNav.$WallpaperNav."</span>";

    }



    if ($Wallpaper1 != NULL) {

    $size='';

    $size=getimagesize("images/wallpapers/".$Wallpaper1);

    if ($Settings['Enable_Watermark'] == '1') {

    $dHTML .= '<a href="'.$image_path.'images/wmwallpapers/'.str_replace(" ","-",$Title).'-1.jpeg" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';

    } else {

    $dHTML .= '<a href="'.$image_path.'images/wallpapers/'.$Wallpaper1.'" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';

    }

    }

    if ($Wallpaper2 != NULL) {

    $size='';

    $size=getimagesize("images/wallpapers/".$Wallpaper2);

    if ($Settings['Enable_Watermark'] == '1') {

    $dHTML .= '<a href="'.$image_path.'images/wmwallpapers/'.str_replace(" ","-",$Title).'-2.jpeg" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';

    } else {

    $dHTML .= '<a href="'.$image_path.'images/wallpapers/'.$Wallpaper2.'" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';

    }

    }

    if ($Wallpaper3 != NULL) {

    $size='';

    $size=getimagesize("images/wallpapers/".$Wallpaper3);

    if ($Settings['Enable_Watermark'] == '1') {

    $dHTML .= '<a href="'.$image_path.'images/wmwallpapers/'.str_replace(" ","-",$Title).'-3.jpeg" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';

    } else {

    $dHTML .= '<a href="'.$image_path.'images/wallpapers/'.$Wallpaper3.'" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';

    }

    }

    if ($Wallpaper4 != NULL) {

    $size='';

    $size=getimagesize("images/wallpapers/".$Wallpaper4);

    if ($Settings['Enable_Watermark'] == '1') {

    $dHTML .= '<a href="'.$image_path.'images/wmwallpapers/'.str_replace(" ","-",$Title).'-4.jpeg" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';

    } else {

    $dHTML .= '<a href="'.$image_path.'images/wallpapers/'.$Wallpaper4.'" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';

    }

    }

    if ($Wallpaper5 != NULL) {

    $size='';

    $size=getimagesize("images/wallpapers/".$Wallpaper5);

    if ($Settings['Enable_Watermark'] == '1') {

    $dHTML .= '<a href="'.$image_path.'images/wmwallpapers/'.str_replace(" ","-",$Title).'-5.jpeg" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';

    } else {

    $dHTML .= '<a href="'.$image_path.'images/wallpapers/'.$Wallpaper5.'" style="text-decoration: underline;">'.$size[0].'x'.$size[1].'</a> ';

    }

    }

    Any help?


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •