PRODUCT) && $GLOBALS['_VERSION']->PRODUCT == 'Joomla!') { $GALLERY_EMBEDDED_INSIDE = 'joomla'; $GALLERY_EMBEDDED_INSIDE_TYPE = 'joomla'; } } elseif (isset($GLOBALS['phpbb_root_path'])) { $GALLERY_EMBEDDED_INSIDE='phpBB2'; $GALLERY_EMBEDDED_INSIDE_TYPE = 'phpBB2'; } elseif ($postnuke) { $GALLERY_EMBEDDED_INSIDE='nuke'; $GALLERY_EMBEDDED_INSIDE_TYPE = 'postnuke'; } elseif ($GLOBALS['user_prefix'] == "nukea") { $GALLERY_EMBEDDED_INSIDE='nuke'; $GALLERY_EMBEDDED_INSIDE_TYPE = 'nsnnuke'; } elseif (defined('CPG_NUKE')) { $GALLERY_EMBEDDED_INSIDE='nuke'; $GALLERY_EMBEDDED_INSIDE_TYPE='cpgnuke'; } else { $GALLERY_EMBEDDED_INSIDE='nuke'; $GALLERY_EMBEDDED_INSIDE_TYPE = 'phpnuke'; } if (empty($include)) { $include = "albums.php"; } /* * As a security precaution, only allow one of the following files to be included. * If you want Gallery to allow you to include other files (such as the random photo block) * then you need to add the name of the file including any relevant path components to this * array. */ $safe_to_include = array( "add_comment.php", "add_photos.php", "add_photos_frame.php", "admin-page.php", "administer_startpage.php", "album_permissions.php", "albums.php", "block-random.php", "captionator.php", "copy_photo.php", "create_user.php", "delete_album.php", "delete_photo.php", "delete_user.php", "do_command.php", "download.php", "ecard_form.php", "edit_appearance.php", "edit_caption.php", "edit_field.php", "edit_thumb.php", "edit_watermark.php", "extra_fields.php", "gallery_remote.php", "gallery_remote2.php", "help/imagemap.php", "help/metadataOnUpload.php", "highlight_photo.php", "imagemap.php", "lib/colorpicker.php", "login.php", "manage_users.php", "modify_user.php", "move_album.php", "move_photo.php", "multi_create_user.php", "photo_owner.php", "poll_properties.php", "poll_results.php", "progress_uploading.php", "publish_xp.php", "publish_xp_docs.php", "rearrange.php", "register.php", "rename_album.php", "reset_votes.php", "resize_photo.php", "rotate_photo.php", "rss.php", "save_photos.php", "search.php", "slideshow.php", "slideshow_high.php", "slideshow_low.php", "sort_album.php", "stats-wizard.php", "stamp_preview.php", "stats.php", "tools/find_orphans.php", "tools/despam-comments.php", "tools/validate_albums.php", "upgrade_album.php", "upgrade_users.php", "user_preferences.php", "view_album.php", "view_comments.php", "view_photo.php", "view_photo_properties.php", "watermark_album.php", ); if (!in_array($include, $safe_to_include)) { $include = htmlentities($include); print sprintf(_("Security error! The file you tried to include is not on the approved file list. To include this file you must edit %s's index.php and add %s to the \$safe_to_include array"), 'Gallery', $include); exit; } include(dirname(__FILE__) . "/$include"); } else { include("albums.php"); } ?>