ImgPopUp

Summary: Extension to image uploading
Version: 1.2.9 (2009-06-21)
Prerequisites: Requires at least PmWiki version: 2beta; last tested on PmWiki version: 2.2.1
Status: stable
Maintainer: kt007
Categories: Images
Discussion: ImgPopUp-Talk

Goal

  • Scale down the view of images wider than certain width
  • Open the scaled down image in a new window
  • Provide an upload link for already uploaded images
  • No new markup or clutter by additionally generated (thumbnail) files

Install

  1. download imgpopup.phpΔ
  2. in your config file include the imgpopup.php:
    include_once("$FarmD/cookbook/imgpopup.php");

Under the scaled images is a link to the the pop up window. You can also add a magnifier image by putting magnifier.png into pub/cookbook/imgpopup. You can download magnifier.png and test this cookbook here.

Optional Parameters

$ImgPopUpMaxImgWidth = 200
sets the max. image width in pixel
$ImgPopUpSkinDirUrl = "cookbook/imgpopup"
sets the directory for the magnifier image to "/pub/cookbook/imgpopup"
$ImgPopUpProvideUploadLink = true
sets if a upload link should be provided in the popup
$ImgPopUpNoZoomLink = false
sets if a Zoom Image link is shown under the scaled down image
$ImgPopUpIgnoreUnscaledImages = false
sets if unscaled images get a link to a popup window
$ImgPopUpSameWindow = false
sets if the zoomed image is shown in a new or the same window
$ImgPopUpShowZoomLinkTreshold = 1.0
sets a threshold before a zoom link is provided to prevent images only a few pixels larger than $ImgPopUpImgWidth to get zoomed. This value is multiplied with $ImgPopUpMaxImgWidth.

Usage

You can use (:ImgPopUpNoZoomLink:) to hide the Zoom Image links on a side.

Notes

Note: The preview of the images are only scaled down by CSS. So you have to load the full image. That increases load times on pages with many/huge images or if you on a slow internet connection. On the other hand your browser has cached the image already when you want to view it in full size.

Known Problems/Bugs

Development

imgpopup_archive.zipΔ

See Also

Contributors

Comments

See discussion at ImgPopUp-Talk

User notes? : If you use, used or reviewed this recipe, you can add your name. These statistics appear in the Cookbook listings and will help newcomers browsing through the wiki.