[Modul] Bildergalerie - Qdig-Include

Darth-Vader
Beiträge: 661
Registriert: So 25. Jan 2004, 19:06
Wohnort: Stuttgart-Bad Cannstatt
Kontaktdaten:

[Modul] Bildergalerie - Qdig-Include

Beitrag von Darth-Vader » Do 3. Mai 2007, 19:54

Hallo zusammen,

ich habe ein kleines Modul geschrieben, welches es ermöglicht die Open Source Bildergalerie Qdig (siehe http://qdig.sourceforge.net) in Contenido zu inkludieren.

Soll keineswegs Konkurrenz zu andren Modulen darstellen, ich dachte mir nur vllt kann es ja jmd außer mir noch gebrauchen... :roll:

Hilfe dabei war mir dabei zum einen die Doku von Qdig und zum andern eine Lösung von Da Maxl zum Inkludieren der Open Source Bildergalerie pixlie.


Vorteil gegenüber der Inkludierung von z.B. pixlie ist, dass man bei Qdig die Dateien nicht aufsplitten oder code umschreiben muss wenn ein neues release von Qdig rauskommt... 8)


Live in Action und in Farbe kann man es sich unter der Baustelle meiner neuen Homepage anschauen.


so long,

Darth.

Code: Alles auswählen


<?php




/***************************************************************
* Modul name: Qdig Include
* Author: Lars D. Forseth alias Darth-Vader, <lars@forseth.de>
* Created: May 1st 2007
* Last Modified: May 3rd 2007
*
*
* Description:
*
* This module embeds the Open Source gallery Qdig,
* see http://qdig.sourceforge.net/Support/EmbeddingQdigGalleries#advanced
*
*
* Installation instructions:
*
* 1) Understand that I can't and don't give any guarantee for neither this module
*	 nor for these instructions -> It's your own risk! (TM) ;)
*
* 2) Install Qdig (you can find Qdig itself at http://qdig.sourceforge.net) and rename index.php into qdig.php, 
*         also don't forget to set a username and password in admin.php
*
* 3) Rename all occurances of the var $lang into $Qlang in qdig.php
*
* 4) Create a new module within Contenido and paste this code as the module ouput
*
* 5) Adapt the settings in the module to your needs, especially the paths. Read the comments to find out more 
*        about which settings are important to your individual needs! I placed Qdig in cms/qdig, if that works for you
*        as well than the path settings I already made should work for you too.
*
* 6) Create a template for your gallery within Cotenido and include the module created under 3)
*
* 7) Enjoy and don't blame me if it doesn't work! ;p
* 	 Feel free to ask for help in the Contenido forums though,
* 	 see the following URL for details:
* 	 --> http://contenido.org/forum/viewtopic.php?p=101130#101130
*
*
*
* Important settings for Qdig to work within Contenido:
*
* - $chroot_dir => folder where the foto albums/pictures are stored in
* - $qdig_files => folder where qdig is supposed to store resized images, thumbnails and caption texts
* - $extra_param => very important, pass the current idcat (stored in $contenidoQuery) to Qdig
* - $qdig_url => URL to use for accessing Qdig, quite important at least when using the mod-rewrite version of Contenido
* - $admin['full_url'] => URL in order of being able to request the admin script of Qdig, quite important when using the mod-rewrite version of Contenido
* - $url_base_path => important, tells Qdig which URL to use, also quite important when using with the mod-rewrite version of Contenido
* - $fs_base_path => important, tells Qdig where to find the albums when using with the mod-rewrite version of Contenido
*
***************************************************************/



/* jump into qdig directory */
chdir("qdig/");



/* function that overwrites the settings of Qdig */
function qdig_settings($version) {

	global $sess, $idcat, 
                        $copyright, $admin, $chroot_dir, $dir_nav, $ctrl_bar, $thmb_default,
			$thmb_enable, $thmb_onfly, $thmb_row, $txtlinks_default, $namelinks_disa,
			$upr_nav, $caption, $img_link, $lwr_nav, $footer, $site_link_fnt_size,
			$qdig_homelink, $sidebar_bg_clr, $sidebar_margin_top, $sidebar_height,
			$qdig_homelink, $grayout_color, $gallery_table_bg_clr, $image_table_bg_clr,
			$pre_gallery, $post_gallery, $qdig_files, $convrtd_subdir, $caption_subdir,
			$touch_captions, $convert_magick, $convert_cmd, $convert_GD, $convert_GD_ver,
			$disp_size, $default_img_size, $cnvrt_thmb, $cnvrt_alt, $cnvrt_size, $header,
			$dir_nav, $nav_lnk, $empty_gallery_msg, $ctrl_links_mesg, $img_sz_labels,
			$cnvrt_mesgs, $Qlang, $safe_captions, $check_security, $ignore_dir_links,
			$ignore_img_links, $pathname_maxlen, $imgname_maxlen, $extra_paranoia,
			$ignore_dotfiles, $ignore_dotdirs, $is_readable_disa, $file_exists_disa,
			$max_exec_time, $compat_quote, $exclude_gif, $qdig_url, $url_base_path,
			$fs_base_path, $excl_dirs, $excl_imgs, $excl_img_pattern, $excl_main,
			$extra_param, $anchor, $keep_params, $diag_messages;



	$url = $sess->url('front_content.php?idcat='.$idcat);	


 	/**
	* Copyright text (optional)
	*
	* If this is set, the text will appear at the bottom of your gallery.
	* See http://www.whatiscopyright.org/ for information about copyrights.
	*/
	$copyright['txt'] = '';

	/**
	* Admin Script
	*/
	$admin['script_file'] = 'admin.php';  // Location of Gallery Management Script
	$admin['full_url']    = '/new/cms/qdig/admin.php';           // Full URL of Gallery Management Script
	                                      // in case just script_file isn't enough.

	/**
	* Chroot Directory
	*
	* Defines the topmost directory of the gallery tree.  Commented out by default.
	* Typically used when including a gallery within a web page.
	* See http://qdig.sourceforge.net/Support/ChrootDirectory for details.
	*/
	$chroot_dir = 'albums/normal/';  	// Note: You may also want to add this path to the
	                            	// $qdig_files location (e.g. 'images/qdig-files/')


	/**
	* Directory Navigation (Contains pwd and subdirectories.)
	*/
	$dir_nav['enable']     = TRUE;    // Enable Directory Navigation.  If disabled,
	                                  // subdirectories will be isolated galleries.
	$dir_nav['small']      = TRUE;   // Use small text for Dir. Navigation row.
	$dir_nav['fname_ena']  = FALSE;   // Display the filename.
	$dir_nav['cntr_ena']   = FALSE;    // Display the counter.
	$dir_nav['path_delim'] = '&raquo;';  // Delimiter between path elements
	$dir_nav['dir_is_new'] = 5 * 24 * 60 * 60; // New if less than this many seconds
	$dir_nav['new_flag']   = '&nbsp;
	      <small style="font-size:8pt; vertical-align:top; padding-bottom:1px; text-decoration:none;
	       font-weight:normal; color:black; background-color:yellow;">&nbsp;Updated&nbsp;</small>';
	                                  // String to display with dir name if "new"
	$dir_nav['sort_age']   = FALSE;   // Sort directories by time-since-modified
	                                  // (most recent first) rather than by alpha.
	$dir_nav['sort_rev']   = FALSE;   // Reverse the sort order of directories.
	$dir_nav['icon']       = FALSE;   // Display a camera icon in directory links.
	$dir_nav['updir_ena']  = FALSE;    // Display an up-one-level link.
	$dir_nav['row_width']  = '520px';  // Width of the Directory Navigation row

	/**
	* Control Bar (Contains visitor preferences: links style and default view)
	*/
	$ctrl_bar['enable']   = FALSE;   // Enable control bar.
	$dir_nav['prefs_ena'] = FALSE;  // Display a Preferences link, which toggles
                                	// the Control Bar for a more compact gallery.


	/**
	* Thumbnail Image Links
	*/
	$thmb_default = TRUE;  // Default to thumbs view if thumbs-capable.
	$thmb_enable  = TRUE;  // Enable thumbs view.  Safe to leave TRUE.
	$thmb_onfly   = FALSE;  // Create thumbnails 'on the fly' in their
	                       // own request so pages load more quickly.
	// Wrapping -- Don't wrap only one or two thumbnails.
	$thmb_row['maxwidth'] = '520px';  // Approx. max. width of thumbnails row
	$thmb_row['softwrap'] = 75;   // A percentage, 51 to 99


	/**
	* Filename and Numeral Text Image Links
	*/
	$txtlinks_default = 'none';  // If no text-link type is specified, default
	                             // to name, num, or none.
	$namelinks_disa   = FALSE;   // Disable 'names' view option in the Control
	                             // Bar size chooser.  (Avoids the sidebar.)


	/**
	* Upper Gallery Navigation Row immediately above the image
	*
	* If nothing on the row is enabled, the navigation row is omitted.
	*/
	$upr_nav['enable']    = FALSE;
	$upr_nav['sizer']     = FALSE;  // Show resizing links.  Overrides 'full_link'.
	$upr_nav['full_link'] = FALSE;  // Show `Full Size' link if image is resized.
	$upr_nav['prv_next']  = TRUE;   // Show `Previous' / `Next' links.
	$upr_nav['wrap']      = FALSE;  // Wrap at Prev / Next at last / first image.
	$upr_nav['frst_last'] = TRUE;   // Show ` |<< ' and ` >>| ' links.
	$upr_nav['cntr']      = FALSE;  // Show `x of y' counter if no $dir_nav counter.
	$upr_nav['cntr_bold'] = FALSE;  // Bold font for `x of y' message
	$upr_nav['sml_txt']   = FALSE;  // Use small text.
	$upr_nav['width']     = '520px';  // Width of this navRow's table
	$upr_nav['pad_top']   = '10px';  // Padding above row


	/**
	* Image Display
	*/
	$caption['min_width'] = '300';    // Minimum width for an image caption
	$caption['padding']   = '5px';  // Padding around caption text
	$caption['nl2br']     = FALSE;  // Automatically insert <br /> tags in captions.
	$caption['left_just'] = TRUE;  // Left-justify caption (otherwise centered).
	$caption['above']     = FALSE;  // Place caption above the image, not below it.
	// Settings for making the displayed image an active link
	$img_link['next']    = TRUE;   // Link to the next image from the one displayed.
	$img_link['wrap']    = FALSE;  // Link back to first image from the last one.
	$img_link['wrap_up'] = FALSE;   // Link the last image to the directory above.
	// Other scripts have the following, so some people must like it.
	$img_link['full']  = TRUE;  // If the image is a resized version, link to the
	                             // full sized version.  Disables 'next' and 'wrap'.
	$img_link['file']  = TRUE;  // Full size link goes directly to the image file.

	/**
	* Lower Gallery Navigation Row below the image and caption
	*
	* If nothing on the row is enabled, the navigation row is omitted.
	*/
	$lwr_nav['enable']    = TRUE;
	$lwr_nav['sizer']     = FALSE;  // Show resizing links.  Overrides 'full_link'.
	$lwr_nav['full_link'] = FALSE;   // Show `Full Size' link if image is resized.
	$lwr_nav['prv_next']  = TRUE;   // Show `previous' / `next' links.
	$lwr_nav['wrap']      = TRUE;  //  Wrap at prev / next at last / first image.
	$lwr_nav['frst_last'] = TRUE;   // Show ` |<< ' and ` >>| ' links.
	$lwr_nav['cntr']      = TRUE;   // Show `x of y' counter if no $dir_nav counter.
	$lwr_nav['cntr_bold'] = FALSE;   // Bold font for `x of y' message
	$lwr_nav['sml_txt']   = TRUE;  // Use small text for this navigation row.
	$lwr_nav['width']     = '520px';  // Width of this navRow's table
	$lwr_nav['pad_top']   = '20px';  // Padding above row


	/**
	* Gallery Footer Row
	*/
	$footer['pad_top']     = '20px';     // Extra space above the footer line
	$site_link_fnt_size    = '10px';  // Font size for Site Home Link
	$copyright['fnt_size'] = '10px';  // Font size for Copyright Message
	$qdig_homelink['ena']  = TRUE;      // Show the Qdig Home link.
	$qdig_homelink['fnt_size'] = '10px';  // Qdig Home link Font size


	// Set these to '' to disable.
	$sidebar_bg_clr         = '';  // Sidebar background
	$sidebar_margin_top     = '';      // Margin above the sidebar
	$sidebar_height         = '';         // '' is "auto".  example: '350px'
	$copyright['color']     = '#999999';  // Copyright text
	$admin['color']         = '#FFFFFF';  // Admin link text
	$qdig_homelink['color'] = '#999999';  // Qdig Home Link text
	$grayout_color          = '#999999';  // Grayed-out text
	// Gallery Table and Image Table (Possibly for an embedded gallery)
	// Use '' for default background color.
	$gallery_table_bg_clr   = '';  // Background color of the gallery table.
	$image_table_bg_clr     = '';  // Background color of image area.
	// Arbitrary code can be inserted before or after the gallery table.
	$pre_gallery            = '';  // User-defined output before gallery
	$post_gallery           = '';  // User-defined output after gallery


	/**
	* Writable Directories
	*
	* Folders containing your original images may be read-only by the web server
	* daemon, but the script needs write permissions to write empty caption .txt
	* files and converted-image files (thumbnail and alternate-sized images).
	*/
	$qdig_files = 'qdig-files/'; // The root of the writable tree.  Setup is easy:
	                             // Create the directory.  Give it 2777 permissions
	                             // (`chmod 2777').  Visit the gallery once.  Then
	                             // change the permissions to something sane (0755).
	//$cnvrtd_dir = 'qdig-converted';  // Name of the resampled images subdirectory.
	                                   // Uncomment this and comment out $qdig_files
	                                   // for the behavior of previous releases.
	$convrtd_subdir = 'converted-images/';  // Subdir for resampled images
	$caption_subdir = 'captions';           // Subdir for captions
	$touch_captions = TRUE;  // Create empty caption .txt files, if found missing.


	/**
	* Image Magick and GD Settings
	*
	* If you have both Image Magick and GD, Qdig uses IM except on a Win32 server.
	* To use the one that isn't the default, set the default one to FALSE.
	*/
	$convert_magick = TRUE;  // Use Image Magick, if available, to convert images.
	$convert_cmd    = '/usr/bin/convert';  // Full pathname to `convert'.
	// Example $convert_cmd for Win32 users:
	//$convert_cmd    = '"C:\\Program Files\\ImageMagick-5.5.3-Q16\\convert.exe"';
	$convert_GD     = TRUE;  // Use PHP GD, if available, to convert images.
	$convert_GD_ver = '';    // '' is auto-detect (recommended).  Else '1' or '2'.

	/**
	* Sizes to convert / display
	*
	* Enable or disable any of the alternate sizes (to save bandwidth,
	* fit a layout, etc.).  Experiment, but here are some suggestions:
	* Old Defaults: TRUE,TRUE,TRUE,TRUE,FALSE
	* Basic: FALSE,TRUE,FALSE,FALSE,TRUE
	*/
	$disp_size['0'] = TRUE;   // 'S'  | These cause resizing links
	$disp_size['1'] = FALSE;  // 'M'  | in the Control Bar and
	$disp_size['2'] = FALSE;  // 'L'  | Navigation Bar to disappear
	$disp_size['3'] = FALSE;  // 'XL' | if set to FALSE and
	$disp_size['4'] = TRUE;   // 'FS' | appear if set to TRUE.
	// If no size is specified, use this size as the default.
	$default_img_size = '0';  // '1' is medium.  Must be an enabled size.

	/**
	* Thumbnail Image Conversion Settings
	*/
	$cnvrt_thmb['size'] = 30;  // Thunbnail image height in pixels.
	                           // Sizes: 10 is tiny, 20 is small, 35 is medium,
	                           //        50 is large, 75 is jumbo
	$cnvrt_thmb['qual'] = 60;  // Thumbnail image quality.  Large thumbnails
	                           // may look better, but will have increased file
	                           // size, if you increase this a bit.
	$cnvrt_thmb['sharpen'] = '0.6x0.6';  // Level of sharpening for thumbnails.
	$cnvrt_thmb['single']  = FALSE;      // Convert thumb in a singleton directory.
	$cnvrt_thmb['mesg_on'] = FALSE;   // Produce a message when a thunbnail image
	                                 // is auto-generated.
	$cnvrt_thmb['no_prof'] = FALSE;  // Strip image profile data to reduce size.
	                                 // (May be incompatible with some servers.)
	$cnvrt_thmb['prefix']  =         // Filename prefix for thumbnail images.
	  "thm{$cnvrt_thmb['size']}_";   // Use "thm_" for externally generated thumbs.


	/**
	* Alternate-sized Image Conversion Settings
	*
	* ['prefix']  is the filename prefix for the generated file.
	* ['sharpen'] is the sharpen pramater passed to ImageMagick.
	* ['maxwid']  is the size setting.  Other dimensions are calculated.
	* ['qual']    is the compression quality level.
	* ['txt']     is the image size text used inline in a message.  (Language Setting)
	* ['label']   is the text used for a link.  (Language Setting)
	*/
	$cnvrt_alt['indiv']   = TRUE;   // Convert alternates one-at-a-time rather than
	                                // all the images in a directory at once.
	$cnvrt_alt['mesg_on'] = TRUE;   // Produce a message when an image is converted.
	$cnvrt_alt['no_prof'] = FALSE;  // Strip image profile data to reduce size.
	                                // (May be incompatible with some servers.)
	// small
	$cnvrt_size['0']['prefix']  = 'sml_';
	$cnvrt_size['0']['sharpen'] = '0.6x0.8';
	$cnvrt_size['0']['maxwid']  = 520;
	$cnvrt_size['0']['qual']    = 87;
	// medium
	$cnvrt_size['1']['prefix']  = 'med_';
	$cnvrt_size['1']['sharpen'] = '0.6x0.8';
	$cnvrt_size['1']['maxwid']  = 640;
	$cnvrt_size['1']['qual']    = 89;
	// large
	$cnvrt_size['2']['prefix']  = 'lrg_';
	$cnvrt_size['2']['sharpen'] = '0.6x0.9';
	$cnvrt_size['2']['maxwid']  = 800;
	$cnvrt_size['2']['qual']    = 90;
	// x-large
	$cnvrt_size['3']['prefix']  = 'xlg_';
	$cnvrt_size['3']['sharpen'] = '0.6x0.9';
	$cnvrt_size['3']['maxwid']  = 1024;
	$cnvrt_size['3']['qual']    = 91;
	// actual
	$cnvrt_size['4']['prefix']  = '../';


	// Language Settings --------------------------------------------------+
	// Text that appears in the output may be configured here.

	/**
	* Header
	*/
	$header['lang_code'] = 'en';
	$header['charset']   = 'iso-8859-15';

	/**
	* Directory Navigation
	*/
	$dir_nav['main_txt']        = 'Main';
	$dir_nav['choose_main_txt'] = 'Choose a gallery:';
	$dir_nav['choose_main_title_txt'] = 'Please choose a gallery.';
	$dir_nav['choose_sub_txt']  = '';
	$dir_nav['choose_sub_title_txt']  = 'Please choose a gallery.';
	$dir_nav['empty_dir_txt']   = 'Sorry, no gallery here.';
	$dir_nav['empty_dir_title_txt']   = 'Sorry, no gallery here.';
	$dir_nav['image_txt']       = 'Image';
	$dir_nav['go_to_txt']       = 'Go to';
	$dir_nav['up_level_txt']    = 'Up&nbsp;a&nbsp;level..';
	$dir_nav['up_title_txt']    = 'Go up one level';
	$dir_nav['current_txt']     = 'Current location:';
	$dir_nav['prefs_title_txt'] = 'Change your visitor preferences';
	$dir_nav['prefs_txt']       = 'Preferences';

	/**
	* Gallery Navigation Links
	*/
	$nav_lnk['prv_txt']   = '&laquo; Previous';
	$nav_lnk['prv_msg']   = 'Previous Image';
	$nav_lnk['next_txt']  = 'Next &raquo;';
	$nav_lnk['next_msg']  = 'Next Image';
	$nav_lnk['last_txt1'] = '<< Last';
	$nav_lnk['last_txt2'] = '>>|';
	$nav_lnk['last_msg']  = 'Last Image';
	$nav_lnk['frst_txt1'] = 'First >>';
	$nav_lnk['frst_txt2'] = '|<<';
	$nav_lnk['frst_msg']  = 'First Image';
	$nav_lnk['image']     = 'Image';

	/**
	* Text shown if there is no image to display
	*/
	$empty_gallery_msg   = 'Empty gallery!';

	// Text/Messages for controlView() (links view on control bar)
	$ctrl_links_mesg['links_style'] = 'Links Style:';
	$ctrl_links_mesg['thumbs_txt'] = 'Thumbs';
	$ctrl_links_mesg['names_txt']  = 'Names';
	$ctrl_links_mesg['nums_txt']   = 'Numbers';
	$ctrl_links_mesg['none_txt']   = 'None';
	$ctrl_links_mesg['thumbs_msg'] = 'Switch to Thumbnail Links';
	$ctrl_links_mesg['names_msg']  = 'Switch to Filename Links';
	$ctrl_links_mesg['nums_msg']   = 'Switch to Calendar-Style Links';
	$ctrl_links_mesg['none_msg']   = 'Disable Direct Image Links';

	/**
	* Image size title text
	*/
	$cnvrt_size['0']['label'] = 'S';
	$cnvrt_size['1']['label'] = 'M';
	$cnvrt_size['2']['label'] = 'L';
	$cnvrt_size['3']['label'] = 'XL';
	$cnvrt_size['4']['label'] = 'FS';
	$img_sz_labels['ctrl']['default_size'] = 'Default Size:';
	$img_sz_labels['ctrl']['str1'] = 'Change the default image size to ';
	$img_sz_labels['nav']['str1']  = 'See the ';
	$img_sz_labels['nav']['str1a'] = 'Return to the ';
	$cnvrt_size['0']['txt']  = 'Small';
	$cnvrt_size['1']['txt']  = 'Medium';
	$cnvrt_size['2']['txt']  = 'Large';
	$cnvrt_size['3']['txt']  = 'Extra Large';
	$cnvrt_size['4']['txt']  = 'Full Size';
	$cnvrt_size['4']['txt2'] = 'default';
	$img_sz_labels['ctrl']['str2'] = '.';
	$img_sz_labels['nav']['str2']  = ' version of this image.';

	/**
	* Admin link
	*/
	$admin['link_title']  = 'Edit caption for this image';
	$admin['link_text']   = 'Admin';
	$admin['before_link'] = '';
	$admin['after_link']  = '';

	/**
	* Image conversion messages (e.g. "Generated a new Large converted image for image.jpg")
	*/
	$cnvrt_mesgs['generated']  = 'Generated a new ';
	$cnvrt_mesgs['generating'] = 'Generating a new ';
	$cnvrt_mesgs['thumb']      = 'thumbnail';
	$cnvrt_mesgs['converted']  = ' converted';
	$cnvrt_mesgs['image_for']  = ' image for ';
	$cnvrt_mesgs['using IM']   = " using 'convert'";
	$cnvrt_mesgs['using GD']   = ' using GD';
	$cnvrt_mesgs['on-the-fly'] = ''; // was: ' (on-the-fly)'

	/**
	* Miscellaneous
	*/
	$Qlang['nav_cntr_txt']  = '/'; // Counter ("x of n")
	$Qlang['Forbidden']     = 'Forbidden';
	$Qlang['diag_messages'] = 'Diagnostic Messages';

	// Security Settings  ------------------------------------------------+
	/**
	* File creation mask.  Determines default permissions for created files, dirs.
	*
	* Examples: umask(002)  // `drwxrwxr-x' and `-rw-rw-r--' (world readable)
	*           umask(007)  // `drwxrwx---' and `-rw-rw----' (not world readable)
	*/
	umask(002);

	/**
	* Paranoia Settings
	*/
	$safe_captions    = TRUE;   // Disable HTML in Captions.  Convert special
	                            // characters (<>&"') to `HTML entities'
	$check_security   = TRUE;   // Perform a security check for world-writability.
	$ignore_dir_links = TRUE;   // Ignore gallery directories if they're symlinks.
	$ignore_img_links = TRUE;   // Ignore image files if they're symlinks.
	$pathname_maxlen  = 200;    // Max. number of characters in a pathname.
	$imgname_maxlen   = 100;    // Max. number of characters in an image filename.
	$extra_paranoia   = FALSE;  // Do extra-strict checking for '..'.
	$ignore_dotfiles  = TRUE;  // Ignore files that start with '.'.
	$ignore_dotdirs   = TRUE;  // Ignore directories that start with '.'.
	// HTML Header settings are only effective for stand-alone Qdig.
	$header['zap_frames']    = FALSE; // Break out of a frameset.
	$header['ie_imgbar_off'] = TRUE;  // Suppress IE6's image toolbar.


	// Miscellaneous Settings ---------------------------------------------+
	/**
	* Server Compatibility
	*/
	// Disable use of certain PHP functions for compatibility with some servers.
	$is_readable_disa = FALSE;  // Set to TRUE if is_readable() causes trouble.
	$file_exists_disa = FALSE;  // Set to TRUE if file_exists() causes trouble.
	$max_exec_time    = 60;     // Max. execution time in seconds
	$compat_quote     = TRUE;   // Add and extra "s to exec() command on Win32.
	                            // For Win98 this should be set to FALSE.
	$exclude_gif      = FALSE;  // Exclude GIF images.
	// HTML Header settings are only effective for stand-alone Qdig.
	$header['meta_cache'] = FALSE;  // Use a Cache-Control meta tag.  For servers
	                                // that cause repeated reloading of thumbs.
	$header['cache_sec']  = '3600'; // Number of seconds for the cache to expire.

	/**
	* Path Settings  (Override defaults.)
	*/
	$qdig_url = $url;       // Self-referring URL path.  Examples: '/photos/' or
	                      // '/photos/qdig.php' or '/~someuser/qdig/index.php'
	// The next two are the same location; as a URL and as a filesystem path.
	$url_base_path = '/new/cms/qdig/';  // Base URL path to the images (not the script)
	                      // Examples: '/photos/qdig/' or '/~someuser/qdig/'
	$fs_base_path  = '/var/www/vhosts/forseth.de/httpdocs/new/cms/qdig/';  // Filesystem path to the root dir of the gallery.
	                      // Ex.: '/home/someuser/public_html/qdig/' or '../qdig'

	/**
	* Et-cetera
	*/
	$excl_dirs[] = 'Private';         // Ignore a directory with its name
	$excl_dirs[] = 'qdig-converted';  // included here.  Do not  end these
	$excl_dirs[] = '';                // name(s) with '/'.
	$excl_imgs[] = 'qdig-bg.jpg';     // Ignore any image with its name
	$excl_imgs[] = 'favicon.png';     // included here.  Add as many of
	$excl_imgs[] = '';                // these as you wish.
	$excl_img_pattern = '_thumb';     // Don't display files containing this string.
	$excl_main   = TRUE;  // Exclude all images in the root (Main) directory.
	$extra_param = ''; //$contenidoQuery;     // Extra parameter(s) to include in URLs.
	                       // Examples: 'incl=qdig.php&' 'a=foo&b=bar&'
	$anchor = '';          // Include an intra-page anchor in URLs.  For embedded
	                       // galleries, use '#qdig' to jump down to the gallery.
	$keep_params = TRUE;  // Keep extra GET parameters in the URLs.

	/**
	* Debugging Setting
	*/
	$diag_messages = FALSE; // Produce diagnostic messages.  This will also enable
	                        // verbose PHP error reporting.

} // end function qdig_settings



/* embed Qdig within a div-tag of class "qdig" */
echo "<div class=\"qdig\">\n";

include_once('qdig.php');

echo "\n</div>\n";



/* return back to cms frontend directory */
chdir("../");


?>
Zuletzt geändert von Darth-Vader am Mo 21. Mai 2007, 09:38, insgesamt 2-mal geändert.

smeusel
Beiträge: 53
Registriert: Do 18. Mär 2004, 11:27
Kontaktdaten:

Beitrag von smeusel » Sa 19. Mai 2007, 00:23

Hi Darth-Vader !

Ich habe das Script gleich mal getestet und es genial :-)
Die Bildergalerie hat endlich auch mal optisch was auf dem Kasten ohne gleich vom Script her in eigenes CMS sein zu wollen.

Eine Sache ist mir aufgefallen und ich habe den Fehler nicht entdecken können:
Jedes mal, wenn ich ein Thumbnail anklicke, dann steht einmal mehr der "idcat" in der URL. Bei jedem Thumbnailclick eines mehr.

Schaut nach 3x klicken so aus:

Code: Alles auswählen

http://www.meuselmedia.de/cms/pokerrausch/front_content.php?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106?idcat=106&Qwd=./Beispiel&Qif=teneriffa_hotel.jpg&Qiv=thumbs&Qis=S
Woran kann das liegen?

Grüße,
Stephan

Darth-Vader
Beiträge: 661
Registriert: So 25. Jan 2004, 19:06
Wohnort: Stuttgart-Bad Cannstatt
Kontaktdaten:

Beitrag von Darth-Vader » Mo 21. Mai 2007, 09:36

Setze mal folgenden Parameter auf "FALSE":

Code: Alles auswählen

$keep_params = TRUE;

Und kopier dir mal oben die neueste Version, ich hab en bissl noch was geändert und weiss net ob ich das schon hier reinkopiert hatte... :/

smeusel
Beiträge: 53
Registriert: Do 18. Mär 2004, 11:27
Kontaktdaten:

Beitrag von smeusel » Di 22. Mai 2007, 17:49

hmmm...
ich habe den neuen code integriert und den parameter auf FALSE gesetzt.
jetzt komme ich nicht mehr auf die bilder, sondern er bleibt bei der bildgalerie-auswahl-seite hängen und die url schaut nach mehrmals anklicken jetzt so aus:

Code: Alles auswählen

http://www.meuselmedia.de/cms/pokerrausch/front_content.php?idcat=106?Qwd=./Beispiel?Qwd=./Beispiel?Qwd=./Beispiel?Qwd=./Beispiel?Qwd=./Beispiel?Qwd=./Beispiel&Qiv=thumbs&Qis=S
wenn ich den parameter wieder auf TRUE stelle, dann habe ich wieder das gleiche phänomen wie oben schon beschrieben... d.h. keine änderung...

ich komme aber auch nicht dahinter, woran das liegen kann...

wosch

Beitrag von wosch » Di 22. Mai 2007, 18:46

Installier das Script bzw. das Verzeichnis zu der Bildgallerie mal so das das Gallerieverzeichnis direkt oberhalb des Scriptverzeichnisses liegt.

Irgendwas scheint bei dir mit den Pfaden/Pfadangaben nicht zu stimmen.
Auch sehr komisch das der Text upload als Link zu Beispiel erscheint.
Dieses Verzeichnis ist aber gar nicht beteiligt (wenn ich die Pfade richtig interpretiert haben ?)
Im Quelltext ist bereits der Link zur Gallerie mit einer doppelten idcat vorhanden.
(Hast du im Originalscript noch eine Angabe die vom Modul nicht überschrieben wird?)

smeusel
Beiträge: 53
Registriert: Do 18. Mär 2004, 11:27
Kontaktdaten:

Beitrag von smeusel » Di 22. Mai 2007, 20:00

also das hier ist mein "Pfad-Modifiziertes" File....

die ordner sind wie bei Darth-Vader nur statt im verzeichnis "cms" im verzeichnis "pokerrausch".
die bilder liegen in "/meuselmedia/cms/pokerrausch/qdig/images/"

das ist der geänderte code:

Code: Alles auswählen

<?php 




/*************************************************************** 
* Modul name: Qdig Include 
* Author: Lars D. Forseth alias Darth-Vader, <lars@forseth.de> 
* Created: May 1st 2007 
* Last Modified: May 3rd 2007 
* 
* 
* Description: 
* 
* This module embeds the Open Source gallery Qdig, 
* see http://qdig.sourceforge.net/Support/EmbeddingQdigGalleries#advanced 
* 
* 
* Installation instructions: 
* 
* 1) Understand that I can't and don't give any guarantee for neither this module 
*    nor for these instructions -> It's your own risk! (TM) ;) 
* 
* 2) Install Qdig (you can find Qdig itself at http://qdig.sourceforge.net) and rename index.php into qdig.php, 
*         also don't forget to set a username and password in admin.php 
* 
* 3) Rename all occurances of the var $lang into $Qlang in qdig.php 
* 
* 4) Create a new module within Contenido and paste this code as the module ouput 
* 
* 5) Adapt the settings in the module to your needs, especially the paths. Read the comments to find out more 
*        about which settings are important to your individual needs! I placed Qdig in cms/qdig, if that works for you 
*        as well than the path settings I already made should work for you too. 
* 
* 6) Create a template for your gallery within Cotenido and include the module created under 3) 
* 
* 7) Enjoy and don't blame me if it doesn't work! ;p 
*     Feel free to ask for help in the Contenido forums though, 
*     see the following URL for details: 
*     --> http://contenido.org/forum/viewtopic.php?p=101130#101130 
* 
* 
* 
* Important settings for Qdig to work within Contenido: 
* 
* - $chroot_dir => folder where the foto albums/pictures are stored in 
* - $qdig_files => folder where qdig is supposed to store resized images, thumbnails and caption texts 
* - $extra_param => very important, pass the current idcat (stored in $contenidoQuery) to Qdig 
* - $qdig_url => URL to use for accessing Qdig, quite important at least when using the mod-rewrite version of Contenido 
* - $admin['full_url'] => URL in order of being able to request the admin script of Qdig, quite important when using the mod-rewrite version of Contenido 
* - $url_base_path => important, tells Qdig which URL to use, also quite important when using with the mod-rewrite version of Contenido 
* - $fs_base_path => important, tells Qdig where to find the albums when using with the mod-rewrite version of Contenido 
* 
***************************************************************/ 



/* jump into qdig directory */ 
chdir("qdig/"); 



/* function that overwrites the settings of Qdig */ 
function qdig_settings($version) { 

   global $sess, $idcat, 
                        $copyright, $admin, $chroot_dir, $dir_nav, $ctrl_bar, $thmb_default, 
         $thmb_enable, $thmb_onfly, $thmb_row, $txtlinks_default, $namelinks_disa, 
         $upr_nav, $caption, $img_link, $lwr_nav, $footer, $site_link_fnt_size, 
         $qdig_homelink, $sidebar_bg_clr, $sidebar_margin_top, $sidebar_height, 
         $qdig_homelink, $grayout_color, $gallery_table_bg_clr, $image_table_bg_clr, 
         $pre_gallery, $post_gallery, $qdig_files, $convrtd_subdir, $caption_subdir, 
         $touch_captions, $convert_magick, $convert_cmd, $convert_GD, $convert_GD_ver, 
         $disp_size, $default_img_size, $cnvrt_thmb, $cnvrt_alt, $cnvrt_size, $header, 
         $dir_nav, $nav_lnk, $empty_gallery_msg, $ctrl_links_mesg, $img_sz_labels, 
         $cnvrt_mesgs, $Qlang, $safe_captions, $check_security, $ignore_dir_links, 
         $ignore_img_links, $pathname_maxlen, $imgname_maxlen, $extra_paranoia, 
         $ignore_dotfiles, $ignore_dotdirs, $is_readable_disa, $file_exists_disa, 
         $max_exec_time, $compat_quote, $exclude_gif, $qdig_url, $url_base_path, 
         $fs_base_path, $excl_dirs, $excl_imgs, $excl_img_pattern, $excl_main, 
         $extra_param, $anchor, $keep_params, $diag_messages; 



   $url = $sess->url('front_content.php?idcat='.$idcat);    


    /** 
   * Copyright text (optional) 
   * 
   * If this is set, the text will appear at the bottom of your gallery. 
   * See http://www.whatiscopyright.org/ for information about copyrights. 
   */ 
   $copyright['txt'] = ''; 

   /** 
   * Admin Script 
   */ 
   $admin['script_file'] = 'admin.php';  // Location of Gallery Management Script 
   $admin['full_url']    = '/homepages/19/d50939183/htdocs/meuselmedia/cms/pokerrausch/qdig/admin.php';           // Full URL of Gallery Management Script 
                                         // in case just script_file isn't enough. 

   /** 
   * Chroot Directory 
   * 
   * Defines the topmost directory of the gallery tree.  Commented out by default. 
   * Typically used when including a gallery within a web page. 
   * See http://qdig.sourceforge.net/Support/ChrootDirectory for details. 
   */ 
   $chroot_dir = '';     // Note: You may also want to add this path to the 
   $qdig_files = 'qdig-files/';        // $qdig_files location (e.g. 'images/qdig-files/') 


   /** 
   * Directory Navigation (Contains pwd and subdirectories.) 
   */ 
   $dir_nav['enable']     = TRUE;    // Enable Directory Navigation.  If disabled, 
                                     // subdirectories will be isolated galleries. 
   $dir_nav['small']      = TRUE;   // Use small text for Dir. Navigation row. 
   $dir_nav['fname_ena']  = FALSE;   // Display the filename. 
   $dir_nav['cntr_ena']   = FALSE;    // Display the counter. 
   $dir_nav['path_delim'] = '&raquo;';  // Delimiter between path elements 
   $dir_nav['dir_is_new'] = 5 * 24 * 60 * 60; // New if less than this many seconds 
   $dir_nav['new_flag']   = '&nbsp; 
         <small style="font-size:8pt; vertical-align:top; padding-bottom:1px; text-decoration:none; 
          font-weight:normal; color:black; background-color:yellow;">&nbsp;Updated&nbsp;</small>'; 
                                     // String to display with dir name if "new" 
   $dir_nav['sort_age']   = FALSE;   // Sort directories by time-since-modified 
                                     // (most recent first) rather than by alpha. 
   $dir_nav['sort_rev']   = FALSE;   // Reverse the sort order of directories. 
   $dir_nav['icon']       = FALSE;   // Display a camera icon in directory links. 
   $dir_nav['updir_ena']  = FALSE;    // Display an up-one-level link. 
   $dir_nav['row_width']  = '520px';  // Width of the Directory Navigation row 

   /** 
   * Control Bar (Contains visitor preferences: links style and default view) 
   */ 
   $ctrl_bar['enable']   = FALSE;   // Enable control bar. 
   $dir_nav['prefs_ena'] = FALSE;  // Display a Preferences link, which toggles 
                                   // the Control Bar for a more compact gallery. 


   /** 
   * Thumbnail Image Links 
   */ 
   $thmb_default = TRUE;  // Default to thumbs view if thumbs-capable. 
   $thmb_enable  = TRUE;  // Enable thumbs view.  Safe to leave TRUE. 
   $thmb_onfly   = FALSE;  // Create thumbnails 'on the fly' in their 
                          // own request so pages load more quickly. 
   // Wrapping -- Don't wrap only one or two thumbnails. 
   $thmb_row['maxwidth'] = '520px';  // Approx. max. width of thumbnails row 
   $thmb_row['softwrap'] = 75;   // A percentage, 51 to 99 


   /** 
   * Filename and Numeral Text Image Links 
   */ 
   $txtlinks_default = 'none';  // If no text-link type is specified, default 
                                // to name, num, or none. 
   $namelinks_disa   = FALSE;   // Disable 'names' view option in the Control 
                                // Bar size chooser.  (Avoids the sidebar.) 


   /** 
   * Upper Gallery Navigation Row immediately above the image 
   * 
   * If nothing on the row is enabled, the navigation row is omitted. 
   */ 
   $upr_nav['enable']    = FALSE; 
   $upr_nav['sizer']     = FALSE;  // Show resizing links.  Overrides 'full_link'. 
   $upr_nav['full_link'] = FALSE;  // Show `Full Size' link if image is resized. 
   $upr_nav['prv_next']  = TRUE;   // Show `Previous' / `Next' links. 
   $upr_nav['wrap']      = FALSE;  // Wrap at Prev / Next at last / first image. 
   $upr_nav['frst_last'] = TRUE;   // Show ` |<< ' and ` >>| ' links. 
   $upr_nav['cntr']      = FALSE;  // Show `x of y' counter if no $dir_nav counter. 
   $upr_nav['cntr_bold'] = FALSE;  // Bold font for `x of y' message 
   $upr_nav['sml_txt']   = FALSE;  // Use small text. 
   $upr_nav['width']     = '520px';  // Width of this navRow's table 
   $upr_nav['pad_top']   = '10px';  // Padding above row 


   /** 
   * Image Display 
   */ 
   $caption['min_width'] = '300';    // Minimum width for an image caption 
   $caption['padding']   = '5px';  // Padding around caption text 
   $caption['nl2br']     = FALSE;  // Automatically insert <br /> tags in captions. 
   $caption['left_just'] = TRUE;  // Left-justify caption (otherwise centered). 
   $caption['above']     = FALSE;  // Place caption above the image, not below it. 
   // Settings for making the displayed image an active link 
   $img_link['next']    = TRUE;   // Link to the next image from the one displayed. 
   $img_link['wrap']    = FALSE;  // Link back to first image from the last one. 
   $img_link['wrap_up'] = FALSE;   // Link the last image to the directory above. 
   // Other scripts have the following, so some people must like it. 
   $img_link['full']  = TRUE;  // If the image is a resized version, link to the 
                                // full sized version.  Disables 'next' and 'wrap'. 
   $img_link['file']  = TRUE;  // Full size link goes directly to the image file. 

   /** 
   * Lower Gallery Navigation Row below the image and caption 
   * 
   * If nothing on the row is enabled, the navigation row is omitted. 
   */ 
   $lwr_nav['enable']    = TRUE; 
   $lwr_nav['sizer']     = FALSE;  // Show resizing links.  Overrides 'full_link'. 
   $lwr_nav['full_link'] = FALSE;   // Show `Full Size' link if image is resized. 
   $lwr_nav['prv_next']  = TRUE;   // Show `previous' / `next' links. 
   $lwr_nav['wrap']      = TRUE;  //  Wrap at prev / next at last / first image. 
   $lwr_nav['frst_last'] = TRUE;   // Show ` |<< ' and ` >>| ' links. 
   $lwr_nav['cntr']      = TRUE;   // Show `x of y' counter if no $dir_nav counter. 
   $lwr_nav['cntr_bold'] = FALSE;   // Bold font for `x of y' message 
   $lwr_nav['sml_txt']   = TRUE;  // Use small text for this navigation row. 
   $lwr_nav['width']     = '520px';  // Width of this navRow's table 
   $lwr_nav['pad_top']   = '20px';  // Padding above row 


   /** 
   * Gallery Footer Row 
   */ 
   $footer['pad_top']     = '20px';     // Extra space above the footer line 
   $site_link_fnt_size    = '10px';  // Font size for Site Home Link 
   $copyright['fnt_size'] = '10px';  // Font size for Copyright Message 
   $qdig_homelink['ena']  = TRUE;      // Show the Qdig Home link. 
   $qdig_homelink['fnt_size'] = '10px';  // Qdig Home link Font size 


   // Set these to '' to disable. 
   $sidebar_bg_clr         = '';  // Sidebar background 
   $sidebar_margin_top     = '';      // Margin above the sidebar 
   $sidebar_height         = '';         // '' is "auto".  example: '350px' 
   $copyright['color']     = '#999999';  // Copyright text 
   $admin['color']         = '#FFFFFF';  // Admin link text 
   $qdig_homelink['color'] = '#999999';  // Qdig Home Link text 
   $grayout_color          = '#999999';  // Grayed-out text 
   // Gallery Table and Image Table (Possibly for an embedded gallery) 
   // Use '' for default background color. 
   $gallery_table_bg_clr   = '';  // Background color of the gallery table. 
   $image_table_bg_clr     = '';  // Background color of image area. 
   // Arbitrary code can be inserted before or after the gallery table. 
   $pre_gallery            = '';  // User-defined output before gallery 
   $post_gallery           = '';  // User-defined output after gallery 


   /** 
   * Writable Directories 
   * 
   * Folders containing your original images may be read-only by the web server 
   * daemon, but the script needs write permissions to write empty caption .txt 
   * files and converted-image files (thumbnail and alternate-sized images). 
   */ 
   $qdig_files = 'qdig-files/'; // The root of the writable tree.  Setup is easy: 
                                // Create the directory.  Give it 2777 permissions 
                                // (`chmod 2777').  Visit the gallery once.  Then 
                                // change the permissions to something sane (0755). 
   //$cnvrtd_dir = 'qdig-converted';  // Name of the resampled images subdirectory. 
                                      // Uncomment this and comment out $qdig_files 
                                      // for the behavior of previous releases. 
   $convrtd_subdir = 'converted-images/';  // Subdir for resampled images 
   $caption_subdir = 'captions';           // Subdir for captions 
   $touch_captions = TRUE;  // Create empty caption .txt files, if found missing. 


   /** 
   * Image Magick and GD Settings 
   * 
   * If you have both Image Magick and GD, Qdig uses IM except on a Win32 server. 
   * To use the one that isn't the default, set the default one to FALSE. 
   */ 
   $convert_magick = TRUE;  // Use Image Magick, if available, to convert images. 
   $convert_cmd    = '/usr/bin/convert';  // Full pathname to `convert'. 
   // Example $convert_cmd for Win32 users: 
   //$convert_cmd    = '"C:\\Program Files\\ImageMagick-5.5.3-Q16\\convert.exe"'; 
   $convert_GD     = TRUE;  // Use PHP GD, if available, to convert images. 
   $convert_GD_ver = '';    // '' is auto-detect (recommended).  Else '1' or '2'. 

   /** 
   * Sizes to convert / display 
   * 
   * Enable or disable any of the alternate sizes (to save bandwidth, 
   * fit a layout, etc.).  Experiment, but here are some suggestions: 
   * Old Defaults: TRUE,TRUE,TRUE,TRUE,FALSE 
   * Basic: FALSE,TRUE,FALSE,FALSE,TRUE 
   */ 
   $disp_size['0'] = TRUE;   // 'S'  | These cause resizing links 
   $disp_size['1'] = FALSE;  // 'M'  | in the Control Bar and 
   $disp_size['2'] = FALSE;  // 'L'  | Navigation Bar to disappear 
   $disp_size['3'] = FALSE;  // 'XL' | if set to FALSE and 
   $disp_size['4'] = TRUE;   // 'FS' | appear if set to TRUE. 
   // If no size is specified, use this size as the default. 
   $default_img_size = '0';  // '1' is medium.  Must be an enabled size. 

   /** 
   * Thumbnail Image Conversion Settings 
   */ 
   $cnvrt_thmb['size'] = 30;  // Thunbnail image height in pixels. 
                              // Sizes: 10 is tiny, 20 is small, 35 is medium, 
                              //        50 is large, 75 is jumbo 
   $cnvrt_thmb['qual'] = 60;  // Thumbnail image quality.  Large thumbnails 
                              // may look better, but will have increased file 
                              // size, if you increase this a bit. 
   $cnvrt_thmb['sharpen'] = '0.6x0.6';  // Level of sharpening for thumbnails. 
   $cnvrt_thmb['single']  = FALSE;      // Convert thumb in a singleton directory. 
   $cnvrt_thmb['mesg_on'] = FALSE;   // Produce a message when a thunbnail image 
                                    // is auto-generated. 
   $cnvrt_thmb['no_prof'] = FALSE;  // Strip image profile data to reduce size. 
                                    // (May be incompatible with some servers.) 
   $cnvrt_thmb['prefix']  =         // Filename prefix for thumbnail images. 
     "thm{$cnvrt_thmb['size']}_";   // Use "thm_" for externally generated thumbs. 


   /** 
   * Alternate-sized Image Conversion Settings 
   * 
   * ['prefix']  is the filename prefix for the generated file. 
   * ['sharpen'] is the sharpen pramater passed to ImageMagick. 
   * ['maxwid']  is the size setting.  Other dimensions are calculated. 
   * ['qual']    is the compression quality level. 
   * ['txt']     is the image size text used inline in a message.  (Language Setting) 
   * ['label']   is the text used for a link.  (Language Setting) 
   */ 
   $cnvrt_alt['indiv']   = TRUE;   // Convert alternates one-at-a-time rather than 
                                   // all the images in a directory at once. 
   $cnvrt_alt['mesg_on'] = TRUE;   // Produce a message when an image is converted. 
   $cnvrt_alt['no_prof'] = FALSE;  // Strip image profile data to reduce size. 
                                   // (May be incompatible with some servers.) 
   // small 
   $cnvrt_size['0']['prefix']  = 'sml_'; 
   $cnvrt_size['0']['sharpen'] = '0.6x0.8'; 
   $cnvrt_size['0']['maxwid']  = 520; 
   $cnvrt_size['0']['qual']    = 87; 
   // medium 
   $cnvrt_size['1']['prefix']  = 'med_'; 
   $cnvrt_size['1']['sharpen'] = '0.6x0.8'; 
   $cnvrt_size['1']['maxwid']  = 640; 
   $cnvrt_size['1']['qual']    = 89; 
   // large 
   $cnvrt_size['2']['prefix']  = 'lrg_'; 
   $cnvrt_size['2']['sharpen'] = '0.6x0.9'; 
   $cnvrt_size['2']['maxwid']  = 800; 
   $cnvrt_size['2']['qual']    = 90; 
   // x-large 
   $cnvrt_size['3']['prefix']  = 'xlg_'; 
   $cnvrt_size['3']['sharpen'] = '0.6x0.9'; 
   $cnvrt_size['3']['maxwid']  = 1024; 
   $cnvrt_size['3']['qual']    = 91; 
   // actual 
   $cnvrt_size['4']['prefix']  = '../'; 


   // Language Settings --------------------------------------------------+ 
   // Text that appears in the output may be configured here. 

   /** 
   * Header 
   */ 
   $header['lang_code'] = 'en'; 
   $header['charset']   = 'iso-8859-15'; 

   /** 
   * Directory Navigation 
   */ 
   $dir_nav['main_txt']        = 'Main'; 
   $dir_nav['choose_main_txt'] = 'Choose a gallery:'; 
   $dir_nav['choose_main_title_txt'] = 'Please choose a gallery.'; 
   $dir_nav['choose_sub_txt']  = ''; 
   $dir_nav['choose_sub_title_txt']  = 'Please choose a gallery.'; 
   $dir_nav['empty_dir_txt']   = 'Sorry, no gallery here.'; 
   $dir_nav['empty_dir_title_txt']   = 'Sorry, no gallery here.'; 
   $dir_nav['image_txt']       = 'Image'; 
   $dir_nav['go_to_txt']       = 'Go to'; 
   $dir_nav['up_level_txt']    = 'Up&nbsp;a&nbsp;level..'; 
   $dir_nav['up_title_txt']    = 'Go up one level'; 
   $dir_nav['current_txt']     = 'Current location:'; 
   $dir_nav['prefs_title_txt'] = 'Change your visitor preferences'; 
   $dir_nav['prefs_txt']       = 'Preferences'; 

   /** 
   * Gallery Navigation Links 
   */ 
   $nav_lnk['prv_txt']   = '&laquo; Previous'; 
   $nav_lnk['prv_msg']   = 'Previous Image'; 
   $nav_lnk['next_txt']  = 'Next &raquo;'; 
   $nav_lnk['next_msg']  = 'Next Image'; 
   $nav_lnk['last_txt1'] = '<< Last'; 
   $nav_lnk['last_txt2'] = '>>|'; 
   $nav_lnk['last_msg']  = 'Last Image'; 
   $nav_lnk['frst_txt1'] = 'First >>'; 
   $nav_lnk['frst_txt2'] = '|<<'; 
   $nav_lnk['frst_msg']  = 'First Image'; 
   $nav_lnk['image']     = 'Image'; 

   /** 
   * Text shown if there is no image to display 
   */ 
   $empty_gallery_msg   = 'Empty gallery!'; 

   // Text/Messages for controlView() (links view on control bar) 
   $ctrl_links_mesg['links_style'] = 'Links Style:'; 
   $ctrl_links_mesg['thumbs_txt'] = 'Thumbs'; 
   $ctrl_links_mesg['names_txt']  = 'Names'; 
   $ctrl_links_mesg['nums_txt']   = 'Numbers'; 
   $ctrl_links_mesg['none_txt']   = 'None'; 
   $ctrl_links_mesg['thumbs_msg'] = 'Switch to Thumbnail Links'; 
   $ctrl_links_mesg['names_msg']  = 'Switch to Filename Links'; 
   $ctrl_links_mesg['nums_msg']   = 'Switch to Calendar-Style Links'; 
   $ctrl_links_mesg['none_msg']   = 'Disable Direct Image Links'; 

   /** 
   * Image size title text 
   */ 
   $cnvrt_size['0']['label'] = 'S'; 
   $cnvrt_size['1']['label'] = 'M'; 
   $cnvrt_size['2']['label'] = 'L'; 
   $cnvrt_size['3']['label'] = 'XL'; 
   $cnvrt_size['4']['label'] = 'FS'; 
   $img_sz_labels['ctrl']['default_size'] = 'Default Size:'; 
   $img_sz_labels['ctrl']['str1'] = 'Change the default image size to '; 
   $img_sz_labels['nav']['str1']  = 'See the '; 
   $img_sz_labels['nav']['str1a'] = 'Return to the '; 
   $cnvrt_size['0']['txt']  = 'Small'; 
   $cnvrt_size['1']['txt']  = 'Medium'; 
   $cnvrt_size['2']['txt']  = 'Large'; 
   $cnvrt_size['3']['txt']  = 'Extra Large'; 
   $cnvrt_size['4']['txt']  = 'Full Size'; 
   $cnvrt_size['4']['txt2'] = 'default'; 
   $img_sz_labels['ctrl']['str2'] = '.'; 
   $img_sz_labels['nav']['str2']  = ' version of this image.'; 

   /** 
   * Admin link 
   */ 
   $admin['link_title']  = 'Edit caption for this image'; 
   $admin['link_text']   = 'Admin'; 
   $admin['before_link'] = ''; 
   $admin['after_link']  = ''; 

   /** 
   * Image conversion messages (e.g. "Generated a new Large converted image for image.jpg") 
   */ 
   $cnvrt_mesgs['generated']  = 'Generated a new '; 
   $cnvrt_mesgs['generating'] = 'Generating a new '; 
   $cnvrt_mesgs['thumb']      = 'thumbnail'; 
   $cnvrt_mesgs['converted']  = ' converted'; 
   $cnvrt_mesgs['image_for']  = ' image for '; 
   $cnvrt_mesgs['using IM']   = " using 'convert'"; 
   $cnvrt_mesgs['using GD']   = ' using GD'; 
   $cnvrt_mesgs['on-the-fly'] = ''; // was: ' (on-the-fly)' 

   /** 
   * Miscellaneous 
   */ 
   $Qlang['nav_cntr_txt']  = '/'; // Counter ("x of n") 
   $Qlang['Forbidden']     = 'Forbidden'; 
   $Qlang['diag_messages'] = 'Diagnostic Messages'; 

   // Security Settings  ------------------------------------------------+ 
   /** 
   * File creation mask.  Determines default permissions for created files, dirs. 
   * 
   * Examples: umask(002)  // `drwxrwxr-x' and `-rw-rw-r--' (world readable) 
   *           umask(007)  // `drwxrwx---' and `-rw-rw----' (not world readable) 
   */ 
   umask(002); 

   /** 
   * Paranoia Settings 
   */ 
   $safe_captions    = TRUE;   // Disable HTML in Captions.  Convert special 
                               // characters (<>&"') to `HTML entities' 
   $check_security   = TRUE;   // Perform a security check for world-writability. 
   $ignore_dir_links = TRUE;   // Ignore gallery directories if they're symlinks. 
   $ignore_img_links = TRUE;   // Ignore image files if they're symlinks. 
   $pathname_maxlen  = 200;    // Max. number of characters in a pathname. 
   $imgname_maxlen   = 100;    // Max. number of characters in an image filename. 
   $extra_paranoia   = FALSE;  // Do extra-strict checking for '..'. 
   $ignore_dotfiles  = TRUE;  // Ignore files that start with '.'. 
   $ignore_dotdirs   = TRUE;  // Ignore directories that start with '.'. 
   // HTML Header settings are only effective for stand-alone Qdig. 
   $header['zap_frames']    = FALSE; // Break out of a frameset. 
   $header['ie_imgbar_off'] = TRUE;  // Suppress IE6's image toolbar. 


   // Miscellaneous Settings ---------------------------------------------+ 
   /** 
   * Server Compatibility 
   */ 
   // Disable use of certain PHP functions for compatibility with some servers. 
   $is_readable_disa = FALSE;  // Set to TRUE if is_readable() causes trouble. 
   $file_exists_disa = FALSE;  // Set to TRUE if file_exists() causes trouble. 
   $max_exec_time    = 60;     // Max. execution time in seconds 
   $compat_quote     = TRUE;   // Add and extra "s to exec() command on Win32. 
                               // For Win98 this should be set to FALSE. 
   $exclude_gif      = FALSE;  // Exclude GIF images. 
   // HTML Header settings are only effective for stand-alone Qdig. 
   $header['meta_cache'] = FALSE;  // Use a Cache-Control meta tag.  For servers 
                                   // that cause repeated reloading of thumbs. 
   $header['cache_sec']  = '3600'; // Number of seconds for the cache to expire. 

   /** 
   * Path Settings  (Override defaults.) 
   */ 
   $qdig_url = $url;       // Self-referring URL path.  Examples: '/photos/' or 
                         // '/photos/qdig.php' or '/~someuser/qdig/index.php' 
   // The next two are the same location; as a URL and as a filesystem path. 
   $url_base_path = 'cms/pokerrausch/qdig/images/';  // Base URL path to the images (not the script) 
                         // Examples: '/photos/qdig/' or '/~someuser/qdig/' 
   $fs_base_path  = '/homepages/19/d50939183/htdocs/meuselmedia/cms/pokerrausch/qdig/images/';  // Filesystem path to the root dir of the gallery. 
                         // Ex.: '/home/someuser/public_html/qdig/' or '../qdig' 

   /** 
   * Et-cetera 
   */ 
   $excl_dirs[] = 'Private';         // Ignore a directory with its name 
   $excl_dirs[] = 'qdig-converted';  // included here.  Do not  end these 
   $excl_dirs[] = '';                // name(s) with '/'. 
   $excl_imgs[] = 'qdig-bg.jpg';     // Ignore any image with its name 
   $excl_imgs[] = 'favicon.png';     // included here.  Add as many of 
   $excl_imgs[] = '';                // these as you wish. 
   $excl_img_pattern = '_thumb';     // Don't display files containing this string. 
   $excl_main   = TRUE;  // Exclude all images in the root (Main) directory. 
   $extra_param = ''; //$contenidoQuery;     // Extra parameter(s) to include in URLs. 
                          // Examples: 'incl=qdig.php&' 'a=foo&b=bar&' 
   $anchor = '';          // Include an intra-page anchor in URLs.  For embedded 
                          // galleries, use '#qdig' to jump down to the gallery. 
   $keep_params = TRUE;  // Keep extra GET parameters in the URLs. 

   /** 
   * Debugging Setting 
   */ 
   $diag_messages = FALSE; // Produce diagnostic messages.  This will also enable 
                           // verbose PHP error reporting. 

} // end function qdig_settings 



/* embed Qdig within a div-tag of class "qdig" */ 
echo "<div class=\"qdig\">\n"; 

include_once('qdig.php'); 

echo "\n</div>\n"; 



/* return back to cms frontend directory */ 
chdir("../"); 


?>

wosch

Beitrag von wosch » Di 22. Mai 2007, 20:50

smeusel hat geschrieben:die bilder liegen in "/meuselmedia/cms/pokerrausch/qdig/images/"
So ...

Dann müßte ich ja das Bild sehen wenn ich aufrufe:
http://www.meuselmedia.de/cms/pokerraus ... rahmen.jpg

Das Prefix sml_ wird von qdig eingesetzt.

Ich bin immer noch (oder trotzdem) der Meinung:
Schau in das Original Stand alone Script ob da nicht Angaben sind die vom Modul nicht überschrieben werden.

Ich nutze nicht das Modul von Darth-Vader, war aber begeistert vom Original Script. Und habe es (für mich als Hilfe für Bilder-URL) auf einem Contenido installiert.
Im dem Script sind so viele Einstellungen möglich, da kann man schon mal was übersehen.

smeusel
Beiträge: 53
Registriert: Do 18. Mär 2004, 11:27
Kontaktdaten:

Beitrag von smeusel » Di 22. Mai 2007, 21:58

das bild liegt hier (im unterordner "Beispiel"):

http://www.meuselmedia.de/cms/pokerraus ... rahmen.jpg

Darth-Vader
Beiträge: 661
Registriert: So 25. Jan 2004, 19:06
Wohnort: Stuttgart-Bad Cannstatt
Kontaktdaten:

Beitrag von Darth-Vader » Mi 23. Mai 2007, 14:50

ich hab das script so konfiguriert, dass es 1.) unter mod-rewrite und 2.) bei mir läuft. ich hab ja net umsonst beschrieben, dass ich keine garantie gebe und das man das anpassen muss.

was du beschreibst deutet also denk ich alles drauf hin, dass du die pfade an deine individuelle umgebung anpassen musst. da ich zur zeit diplomarbeit schreibe hab ich leider au keine zeit mir deine umgebung genau anzuschauen, aber wenn net dann bau doch einfach mal meine ordnerstruktur bei dir nach und nimm die mod-rewrite version von contenido von stese, dann sollte es ja wie bei mir gehen und dann kannste stück für stück es ändern... :roll:

sorry, dass ich dir net mehr helfen kann... :/

smeusel
Beiträge: 53
Registriert: Do 18. Mär 2004, 11:27
Kontaktdaten:

Beitrag von smeusel » Mi 23. Mai 2007, 17:14

ich werde sicherlich noch dahinter kommen woran es liegt...

die threads waren auch keine kritik an deinem script sondern nur ein versuch ggf. gemeinsam schneller auf eine lösung zu kommen...

das script ist klasse und ich werde es auch sicherlich behalten :-)

grüße,
Stephan

Darth-Vader
Beiträge: 661
Registriert: So 25. Jan 2004, 19:06
Wohnort: Stuttgart-Bad Cannstatt
Kontaktdaten:

Beitrag von Darth-Vader » Mi 23. Mai 2007, 17:19

smeusel hat geschrieben:die threads waren auch keine kritik an deinem script sondern nur ein versuch ggf. gemeinsam schneller auf eine lösung zu kommen...
hab ich auch net so verstanden, keine angst.
wollte nur erklären wieso ich dir net helfen kann (zeitmangel, kein kopf dafür im moment) und net einfach garnicht antworten! ;)

viel erfolg also, gruß lars.

smeusel
Beiträge: 53
Registriert: Do 18. Mär 2004, 11:27
Kontaktdaten:

Beitrag von smeusel » Do 24. Mai 2007, 18:34

na, wer sagt es denn... :-)

Code: Alles auswählen

/** 
   * Path Settings  (Override defaults.) 
   */ 
   # $qdig_url = $url;       // Self-referring URL path.  Examples: '/photos/' or 
                         // '/photos/qdig.php' or '/~someuser/qdig/index.php' 
   // The next two are the same location; as a URL and as a filesystem path. 
$qdig_url = $url diesen Parameter auskommentiert und schon geht es :-D
keine doppelten und dreifachen idcat's mehr...

Grüße,
Stephan

Martin S.
Beiträge: 183
Registriert: Fr 14. Jan 2005, 10:46
Kontaktdaten:

Beitrag von Martin S. » Sa 4. Aug 2007, 08:25

geniales Skript, genau das was ich gesucht habe, gibt es auch die Möglichkeit die Anzahl der Thumps zu begrenzen, so das ich vielleicht nur 7 in einer Reihe habe und keine zweite Reihe erscheint, lediglich ein Pfeil/Text/Link mit weiter, wie es oben schon für die Einzelbilder existiert.
Danke

Darth-Vader
Beiträge: 661
Registriert: So 25. Jan 2004, 19:06
Wohnort: Stuttgart-Bad Cannstatt
Kontaktdaten:

Beitrag von Darth-Vader » Sa 4. Aug 2007, 11:22

Hm, die neueste Version von Qdig (http://qdig.sourceforge.net/) scheint das zu können:

http://qdig.sourceforge.net/Settings/La ... bnailLinks (siehe ganz unten)


Da ich momentan meine Diplomarbeit schreibe und sie am 27.08. abgeben muss, hab ich leider keine Zeit das neueste Qdig release einzubauen. Im Sept. hab ich aber Urlaub und werd mir das mal anschaun... dann sollte das was du willst also nur noch eine Sache eines Parameters sein... ;)


Grüße Lars.

Martin S.
Beiträge: 183
Registriert: Fr 14. Jan 2005, 10:46
Kontaktdaten:

Beitrag von Martin S. » Sa 4. Aug 2007, 19:36

na dann viel erfolg bei der Diplomarbeit. Ich werde mir mal die neue Version zu gemüte führen.
Danke.

Gesperrt