Changeset 568
- Timestamp:
- 07/25/08 08:31:16 (2 years ago)
- Location:
- trunk
- Files:
-
- 3 added
- 36 edited
-
plog-admin/css/admin.css (modified) (3 diffs)
-
plog-admin/plog-admin-functions.php (modified) (2 diffs)
-
plog-admin/plog-feedback.php (modified) (2 diffs)
-
plog-admin/plog-manage.php (modified) (8 diffs)
-
plog-admin/plog-themes.php (modified) (2 diffs)
-
plog-content/themes/air/404.php (added)
-
plog-content/themes/air/album.php (modified) (1 diff)
-
plog-content/themes/air/collection.php (modified) (1 diff)
-
plog-content/themes/air/collections.php (modified) (1 diff)
-
plog-content/themes/air/gallery.css (modified) (1 diff)
-
plog-content/themes/air/header.php (modified) (1 diff)
-
plog-content/themes/air/picture.php (modified) (1 diff)
-
plog-content/themes/air/search.php (modified) (1 diff)
-
plog-content/themes/air/slideshow.php (modified) (1 diff)
-
plog-content/themes/default/404.php (added)
-
plog-content/themes/default/album.php (modified) (1 diff)
-
plog-content/themes/default/collection.php (modified) (1 diff)
-
plog-content/themes/default/collections.php (modified) (1 diff)
-
plog-content/themes/default/gallery.css (modified) (2 diffs)
-
plog-content/themes/default/header.php (modified) (2 diffs)
-
plog-content/themes/default/picture.php (modified) (1 diff)
-
plog-content/themes/default/search.php (modified) (1 diff)
-
plog-content/themes/default/slideshow.php (modified) (1 diff)
-
plog-content/themes/lucid/404.php (added)
-
plog-content/themes/lucid/album.php (modified) (1 diff)
-
plog-content/themes/lucid/collection.php (modified) (1 diff)
-
plog-content/themes/lucid/collections.php (modified) (1 diff)
-
plog-content/themes/lucid/gallery.css (modified) (1 diff)
-
plog-content/themes/lucid/header.php (modified) (1 diff)
-
plog-content/themes/lucid/picture.php (modified) (1 diff)
-
plog-content/themes/lucid/search.php (modified) (1 diff)
-
plog-content/themes/lucid/slideshow.php (modified) (1 diff)
-
plog-download.php (modified) (2 diffs)
-
plog-globals.php (modified) (1 diff)
-
plog-includes/plog-functions.php (modified) (20 diffs)
-
plog-print.php (modified) (1 diff)
-
plog-rss.php (modified) (2 diffs)
-
plog-xml.php (modified) (1 diff)
-
plogger.php (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/plog-admin/css/admin.css
r555 r568 11 11 12 12 #theme-table td { 13 padding: 15px;14 } 15 16 #theme-table tr.header t d{13 padding: 8px; 14 } 15 16 #theme-table tr.header th { 17 17 padding: 8px; 18 18 } … … 305 305 border-top: 2px solid #ccc; 306 306 border-bottom: 2px solid #ccc; 307 width: 100%;307 width: 98%; 308 308 } 309 309 … … 404 404 405 405 #contentList #breadcrumb_links { 406 font-size: 1. 1em;407 padding: 5px 3px 5px 0;406 font-size: 1.0em; 407 padding: 3px; 408 408 } 409 409 410 410 #contentList .pagination { 411 font-size: 1.3em; 412 padding: 5px 3px 5px 0; 413 font-weight: bold; 411 font-size: 1.0em; 412 margin-right: 5px; 413 padding: 3px; 414 font-weight: bold; 415 text-align: right; 416 } 417 418 #contentList label, select, option { 419 font-weight: normal; 420 } 421 422 #contentList .entries-page { 423 text-align: right; 424 } 425 426 #contentList .entries-page label, select { 427 display: block inline; 428 margin-bottom: auto; 429 } 430 431 #contentList .move-del-manage input, select { 432 display: block inline; 433 margin-bottom: auto; 414 434 } 415 435 -
trunk/plog-admin/plog-admin-functions.php
r561 r568 1001 1001 } 1002 1002 1003 // 1003 // 1004 1004 function configure_htaccess_fullpic($allow = false) { 1005 1005 $cfg = ""; … … 1072 1072 $cfg .= "RewriteEngine on\n"; 1073 1073 $cfg .= "RewriteBase ".$rewritebase."\n"; 1074 $cfg .= "RewriteCond %{REQUEST_URI} !(\.|/\$)\n";1074 $cfg .= "RewriteCond %{REQUEST_URI} !(\.|/\$)\n"; 1075 1075 $cfg .= "RewriteRule ^.*\$ http://".parse_url($config['gallery_url'], PHP_URL_HOST)."%{REQUEST_URI}/ [R=301,L]\n"; 1076 /*$cfg .= "RewriteCond %{HTTP_HOST} !^www [NC]\n";1076 /*$cfg .= "RewriteCond %{HTTP_HOST} !^www [NC]\n"; 1077 1077 $cfg .= "RewriteRule ^(.*)\$ ".$config['gallery_url']."\$1 [R=301,L]\n";*/ 1078 1078 $cfg .= "RewriteCond %{REQUEST_FILENAME} -d [OR]\n"; -
trunk/plog-admin/plog-feedback.php
r563 r568 14 14 15 15 $possible_values = array("5"=>5, "10"=>10, "20"=>20, "50"=>50); 16 $output = plog_tr('Entries per page') . '17 <select onchange="'.$java.'" name="entries_per_page">';16 $output = "\n\t\t\t\t\t" . '<label accesskey="e" for="entries_on_page">' .plog_tr('<em>E</em>ntries per page') . '</label> 17 <select class="entries-page" onchange="'.$java.'" name="entries_per_page" style="width: 60px;">'; 18 18 foreach ($possible_values as $key => $value) 19 19 if ($_SESSION['entries_per_page'] == $key) … … 283 283 } 284 284 285 $output .= "\n\ n\t\t" . '</form>'. "\n";285 $output .= "\n\t\t" . '</form>'. "\n"; 286 286 287 287 display($output, "feedback"); -
trunk/plog-admin/plog-manage.php
r563 r568 11 11 function generate_pagination_view_menu() { 12 12 13 $java = 'document.location.href = \''.$_SERVER["PHP_SELF"].'?level='.$_REQUEST["level"]. 14 '&id='.$_REQUEST["id"].'&entries_per_page=\'+this.options[this.selectedIndex].value'; 13 $java = 'document.location.href = \''.$_SERVER["PHP_SELF"].'?level='.$_REQUEST["level"].'&id='.$_REQUEST["id"].'&entries_per_page=\'+this.options[this.selectedIndex].value'; 15 14 16 15 $possible_values = array("5"=>5, "10"=>10, "20"=>20, "50"=>50); 17 $output= '<label accesskey="e" for="entries_on_page"><em>E</em>ntries per page</label>18 <select onchange="'.$java.'" name="entries_per_page">';16 $output= "\n\t\t\t" . '<label accesskey="e" for="entries_on_page">' .plog_tr('<em>E</em>ntries per page') . '</label> 17 <select class="entries-page" onchange="'.$java.'" name="entries_per_page" style="width: 60px;">'; 19 18 foreach ($possible_values as $key => $value) 20 19 if ($_SESSION['entries_per_page'] == $key) 21 $output .= " <option value=\"$value\" selected>$key</option>";20 $output .= "\n\t\t\t\t<option value=\"$value\" selected=\"selected\">$key</option>"; 22 21 else 23 $output .= " <option value=\"$value\">$key</option>";24 $output.= '</select>';22 $output .= "\n\t\t\t\t<option value=\"$value\">$key</option>"; 23 $output.= "\n\t\t\t</select>"; 25 24 return $output; 26 25 } … … 29 28 if ($level == "albums") $parent = "collections"; 30 29 if ($level == "pictures") $parent = "albums"; 31 $output = "\n\t\t " . '<input class="submit" type="submit" name="move_checked" value="' . plog_tr("Move Checked To") . '" />';30 $output = "\n\t\t\t" . '<input class="submit" type="submit" name="move_checked" value="' . plog_tr("Move Checked To") . '" />'; 32 31 33 32 if ($level == "pictures") { … … 35 34 $output .= generate_albums_menu($albums); 36 35 } else { 37 $output .= "\n\t\t\t " . '<selectid="group_id" name="group_id">';36 $output .= "\n\t\t\t\t" . '<select class="move-del-manage" id="group_id" name="group_id">'; 38 37 $collections = get_collections(); 39 38 foreach($collections as $collection) { 40 $output .= "\n\t\t\t\t " . '<option value="'.$collection["id"].'">'.SmartStripSlashes($collection["name"]);39 $output .= "\n\t\t\t\t\t" . '<option value="'.$collection["id"].'">'.SmartStripSlashes($collection["name"]); 41 40 $output .= '</option>'; 42 41 } 43 $output .= "\n\t\t\t " . '</select>';42 $output .= "\n\t\t\t\t" . '</select>'; 44 43 } 45 44 … … 54 53 if (isset($_REQUEST["albums_menu"]) && isset($_REQUEST["new_album_name"])){ 55 54 if ($albums_menu == $album_id || $new_album_name == $album['album_name']){ 56 $selected = " selected ";55 $selected = " selected=\"selected\""; 57 56 } 58 57 } … … 125 124 $output = "\n\t" . '<h1>' . plog_tr('Manage Content') . '</h1>' . "\n"; 126 125 127 /* if ($level == "collections") { // display some high level statistics on the main page.128 $output .= '<p class="highlight">You have a total of <strong>'. count_pictures().'</strong> images within <strong>'.count_albums() .'</strong> album(s). Users have posted <strong>'. count_comments().'</strong> comment(s) to your gallery</p>'; } */126 /*if ($level == "collections") { // display some high level statistics on the main page. 127 $output .= "\n\t" . '<p class="highlight">You have a total of <strong>'. count_pictures().'</strong> images within <strong>'.count_albums() .'</strong> album(s). Users have posted <strong>'. count_comments().'</strong> comment(s) to your gallery</p>' . "\n"; } */ 129 128 130 129 global $config; … … 329 328 $totalRows = mysql_result($totalRowsResult,'num_items'); 330 329 331 $pagination_menu = "\n\t\t" . '<div class="pagination">'.generate_pagination("admin", "manage", $plog_page, $totalRows, $_SESSION['entries_per_page'], array("level" => $level, "id" => $id, "entries_per_page" => $_SESSION['entries_per_page'])).'</div>'; 330 $pagination_menu = "\n\t\t" . '<div class="entries-page">'.generate_pagination_view_menu().'</div> 331 <div class="pagination">'.generate_pagination("admin", "manage", $plog_page, $totalRows, $_SESSION['entries_per_page'], array("level" => $level, "id" => $id, "entries_per_page" => $_SESSION['entries_per_page'])).' 332 </div>'; 332 333 333 334 $output .= "\n\t\t" . '<form id="contentList" action="'.$_SERVER["PHP_SELF"].'" method="get">'; … … 336 337 337 338 if (empty($level) || $level == "collections") { 338 $output .= generate_breadcrumb_admin("").$pagination_menu;339 $output .= $pagination_menu.generate_breadcrumb_admin(""); 339 340 $output .= plog_collection_manager($first_item,$_SESSION['entries_per_page']); 340 341 } 341 342 342 343 if ($level == "albums") { 343 $output .= generate_breadcrumb_admin("albums", $id).$pagination_menu;344 $output .= $pagination_menu.generate_breadcrumb_admin("albums", $id); 344 345 $output .= plog_album_manager($id,$first_item,$_SESSION['entries_per_page']); 345 346 }; 346 347 347 348 if ($level == "pictures") { 348 $output .= generate_breadcrumb_admin("pictures", $id).$pagination_menu;349 $output .= $pagination_menu.generate_breadcrumb_admin("pictures", $id); 349 350 $output .= plog_picture_manager($id,$first_item,$_SESSION['entries_per_page']); 350 351 … … 352 353 353 354 if ($level == "comments") { 354 $output .= generate_breadcrumb_admin("comments", $id).$pagination_menu;355 $output .= $pagination_menu.generate_breadcrumb_admin("comments", $id); 355 356 $output .= plog_comment_manager($id,$first_item,$_SESSION['entries_per_page']); 356 357 }; 357 358 358 359 $output .= "\n\t\t" . '<div><a href="#" onclick="checkAll(document.getElementById(\'contentList\')); return false; ">' . plog_tr('Invert Checkbox Selection') . '</a></div> 359 '.$pagination_menu.' 360 <div><input type="hidden" name="level" value="'.$level.'" /> 361 <input type="hidden" name="id" value="'.$id.'" /> 362 <input type="hidden" name="action" value="1" /> 363 <input class="submit" type="submit" name="delete_checked" onclick="return confirm(\'' . plog_tr('Are you sure you want to delete selected items?') . '\');" value="' . plog_tr('Delete Checked') . '" />'; 360 <div class="pagination">'.generate_pagination("admin", "manage", $plog_page, $totalRows, $_SESSION['entries_per_page'], array("level" => $level, "id" => $id, "entries_per_page" => $_SESSION['entries_per_page'])).'</div> 361 <div class="move-del-manage"> 362 <input type="hidden" name="level" value="'.$level.'" /> 363 <input type="hidden" name="id" value="'.$id.'" /> 364 <input type="hidden" name="action" value="1" /> 365 <input class="submit" type="submit" name="delete_checked" onclick="return confirm(\'' . plog_tr('Are you sure you want to delete selected items?') . '\');" value="' . plog_tr('Delete Checked') . '" />'; 364 366 if (!empty($level) && $level != "collections" && $level != "comments"){ 365 367 $output .= generate_move_menu($level); -
trunk/plog-admin/plog-themes.php
r567 r568 58 58 59 59 // Output table header 60 $output .= "\n\n\t\t" . '<table id="theme-table" cellpadding=" 5" width="100%">60 $output .= "\n\n\t\t" . '<table id="theme-table" cellpadding="1" width="100%"> 61 61 <tr class="header"> 62 62 <th class="table-header-left"> </th> … … 98 98 99 99 $output .= "\t\t\t\t<td>"; 100 100 101 101 if ($preview_thumb) 102 $output .= "<div class=\"img-shadow\"><a rel=\"lightbox\" href=\"$preview_thumb_large\"><img src=\"$preview_thumb\"/></a></div>"; 103 104 $output .= "</td><td><strong>$theme_name</strong><br /> Version $version</td> 102 $output .= "<div class=\"img-shadow\"><a rel=\"lightbox\" href=\"$preview_thumb_large\"><img src=\"$preview_thumb\" alt=\"$theme_name\" /></a></div>"; 103 104 $output .= "</td> 105 <td><strong>$theme_name</strong><br /> Version $version</td> 105 106 <td>$description</td> 106 107 <td><a href=\"$url\">$author</a></td>\n"; -
trunk/plog-content/themes/air/album.php
r557 r568 22 22 </ul><!-- /slides --> 23 23 <?php else : ?> 24 <p id="no-pictures-msg"><?php echo plog_tr('There are no pictures in this album')?>.</p> 24 <div id="error-404"> 25 <h2><?php echo plog_tr('404 - Not Found')?></h2> 26 <p><?php echo plog_tr('We are sorry, but the image that you requested does not exist. You might try using the <strong>Search</strong> feature to locate the image you are looking for.')?></p> 27 </div> 25 28 <?php endif; ?> 26 29 -
trunk/plog-content/themes/air/collection.php
r557 r568 24 24 25 25 <?php else : ?> 26 <p id="no-pictures-msg"><?php echo plog_tr('No albums yet')?>.</p> 26 <div id="error-404"> 27 <h2><?php echo plog_tr('404 - Not Found')?></h2> 28 <p><?php echo plog_tr('We are sorry, but the collection that you requested does not exist.')?></p> 29 </div> 27 30 <?php endif; ?> 28 31 </div><!-- /thumbnail-container --> -
trunk/plog-content/themes/air/collections.php
r557 r568 23 23 24 24 <?php else : ?> 25 <p id="no-pictures-msg"><?php echo plog_tr('No collections yet')?>.</p> 25 <div id="error-404"> 26 <h2><?php echo plog_tr('404 - Not Found')?></h2> 27 <p><?php echo plog_tr('We are sorry, but the collection that you requested does not exist.')?></p> 28 </div> 26 29 <?php endif; ?> 27 30 </div><!-- /thumbnail-container --> -
trunk/plog-content/themes/air/gallery.css
r557 r568 135 135 font-size: 1.4em; 136 136 text-align: center; 137 } 138 139 #error-404 { 140 /* error-404 controls the "not found" message received when going to a non-existent URL */ 141 margin: 50px; 142 text-align: justify; 137 143 } 138 144 -
trunk/plog-content/themes/air/header.php
r557 r568 1 <?php plogger_init(); ?>2 1 <div id="wrapper"> 3 2 -
trunk/plog-content/themes/air/picture.php
r557 r568 45 45 <?php endwhile; ?> 46 46 <?php else : ?> 47 <p id="no-pictures-msg"><?php echo plog_tr('No such image')?>.</p> 47 <div id="error-404"> 48 <h2><?php echo plog_tr('404 - Not Found')?></h2> 49 <p><?php echo plog_tr('We are sorry, but the image that you requested does not exist. You might try using the <strong>Search</strong> feature to locate the image you are looking for.')?></p> 50 </div> 48 51 <?php endif; ?> 49 52 </div><!-- /big-picture-container --> -
trunk/plog-content/themes/air/search.php
r557 r568 22 22 </ul><!-- /slides --> 23 23 <?php else : ?> 24 <p id="no-pictures-msg"><?php echo plog_tr('There are no pictures that match this search')?>.</p> 24 <div id="error-404"> 25 <h2><?php echo plog_tr('Search Results')?></h2> 26 <p><?php echo plog_tr('We are sorry, but there are no pictures that matched your search.')?></p> 27 </div> 25 28 <?php endif; ?> 26 29 -
trunk/plog-content/themes/air/slideshow.php
r561 r568 25 25 <?php echo generate_slideshow_interface(); ?> 26 26 <?php else : ?> 27 <p id="no-pictures-msg"><?php echo plog_tr('There are no pictures to show')?>.</p> 27 <div id="error-404"> 28 <h2><?php echo plog_tr('404 - Not Found')?></h2> 29 <p><?php echo plog_tr('We are sorry, but there are no images in this album to create a slideshow with.')?></p> 30 </div> 28 31 29 32 <?php endif; ?> -
trunk/plog-content/themes/default/album.php
r557 r568 29 29 </ul><!-- /slides --> 30 30 <?php else : ?> 31 <p id="no-pictures-msg"><?php echo plog_tr('There are no pictures in this album')?>.</p> 31 <div id="error-404"> 32 <h2><?php echo plog_tr('404 - Not Found')?></h2> 33 <p><?php echo plog_tr('We are sorry, but the image that you requested does not exist. You might try using the <strong>Search</strong> feature to locate the image you are looking for.')?></p> 34 </div> 32 35 33 36 <?php endif; ?> -
trunk/plog-content/themes/default/collection.php
r557 r568 23 23 </ul><!-- /slides --> 24 24 <?php else : ?> 25 <p id="no-pictures-msg"><?php echo plog_tr('No albums yet')?>.</p> 25 <div id="error-404"> 26 <h2><?php echo plog_tr('404 - Not Found')?></h2> 27 <p><?php echo plog_tr('We are sorry, but the collection that you requested does not exist.')?></p> 28 </div> 26 29 27 30 <?php endif; ?> -
trunk/plog-content/themes/default/collections.php
r557 r568 22 22 </ul><!-- /slides --> 23 23 <?php else : ?> 24 <p id="no-pictures-msg"><?php echo plog_tr('No collections yet')?>.</p> 24 <div id="error-404"> 25 <h2><?php echo plog_tr('404 - Not Found')?></h2> 26 <p><?php echo plog_tr('We are sorry, but the collection that you requested does not exist.')?></p> 27 </div> 25 28 26 29 <?php endif; ?> -
trunk/plog-content/themes/default/gallery.css
r557 r568 252 252 } 253 253 254 #error-404 { 255 margin: 50px 75px; 256 text-align: justify; 257 } 258 254 259 /* Form Structure/Elements */ 255 260 256 261 #jump_menu { 257 float: right;262 text-align: right; 258 263 } 259 264 … … 264 269 265 270 #search_box { 266 margin-left: 5px; 267 float: right; 271 text-align: right; 268 272 } 269 273 -
trunk/plog-content/themes/default/header.php
r557 r568 1 <?php plogger_init(); ?>2 1 <!--Output highest level container division--> 3 2 <div id="wrapper"> … … 7 6 <td id="jump-search-container"> 8 7 <?php echo generate_jump_menu(); ?> 9 <br /> <br />8 <br /> 10 9 <?php echo generate_search_box(); ?> 11 10 </td> -
trunk/plog-content/themes/default/picture.php
r557 r568 49 49 <?php endwhile; ?> 50 50 <?php else : ?> 51 <p id="no-pictures-msg"><?php echo plog_tr('No such image')?>.</p> 51 <div id="error-404"> 52 <h2><?php echo plog_tr('404 - Not Found')?></h2> 53 <p><?php echo plog_tr('We are sorry, but the image that you requested does not exist. You might try using the <strong>Search</strong> feature to locate the image you are looking for.')?></p> 54 </div> 52 55 <?php endif; ?> 53 56 </div><!-- /inner_wrapper --> -
trunk/plog-content/themes/default/search.php
r557 r568 26 26 </ul><!-- /slides --> 27 27 <?php else : ?> 28 <p id="no-pictures-msg"><?php echo plog_tr('There are no pictures that matched your search')?>.</p> 29 28 <div id="error-404"> 29 <h2><?php echo plog_tr('Search Results')?></h2> 30 <p><?php echo plog_tr('We are sorry, but there are no pictures that matched your search.')?></p> 31 </div> 30 32 <?php endif; ?> 31 33 </div><!-- /thumbnail container --> -
trunk/plog-content/themes/default/slideshow.php
r561 r568 33 33 <?php echo generate_slideshow_interface(); ?> 34 34 <?php else : ?> 35 <p id="no-pictures-msg"><?php echo plog_tr('There are no pictures to show')?>.</p> 35 <div id="error-404"> 36 <h2><?php echo plog_tr('404 - Not Found')?></h2> 37 <p><?php echo plog_tr('We are sorry, but there are no images in this album to create a slideshow with.')?></p> 38 </div> 36 39 37 40 <?php endif; ?> -
trunk/plog-content/themes/lucid/album.php
r557 r568 27 27 </ul><!-- /slides --> 28 28 <?php else : ?> 29 <p id="no-pictures-msg"><?php echo plog_tr('There are no pictures in this album')?>.</p> 29 <div id="error-404"> 30 <h2><?php echo plog_tr('404 - Not Found')?></h2> 31 <p><?php echo plog_tr('We are sorry, but the image that you requested does not exist. You might try using the <strong>Search</strong> feature to locate the image you are looking for.')?></p> 32 </div> 30 33 31 34 <?php endif; ?> -
trunk/plog-content/themes/lucid/collection.php
r557 r568 24 24 </div><!-- /collections --> 25 25 <?php else : ?> 26 <p id="no-pictures-msg"><?php echo plog_tr('No albums yet')?>.</p> 26 <div id="error-404"> 27 <h2><?php echo plog_tr('404 - Not Found')?></h2> 28 <p><?php echo plog_tr('We are sorry, but the collection that you requested does not exist.')?></p> 29 </div> 27 30 <?php endif; ?> 28 31 </div><!-- /thumbnail container --> -
trunk/plog-content/themes/lucid/collections.php
r557 r568 23 23 </div><!-- /collections --> 24 24 <?php else : ?> 25 <p id="no-pictures-msg"><?php echo plog_tr('No collections yet')?>.</p> 25 <div id="error-404"> 26 <h2><?php echo plog_tr('404 - Not Found')?></h2> 27 <p><?php echo plog_tr('We are sorry, but the collection that you requested does not exist.')?></p> 28 </div> 26 29 <?php endif; ?> 27 30 </div><!-- /thumbnail container --> -
trunk/plog-content/themes/lucid/gallery.css
r557 r568 106 106 text-align: center; 107 107 padding: 15px 0; 108 } 109 110 #error-404 { 111 margin: 50px; 112 text-align: justify; 108 113 } 109 114 -
trunk/plog-content/themes/lucid/header.php
r557 r568 1 <?php plogger_init(); ?>2 1 <!--Output highest level container division--> 3 2 <div id="wrapper"> -
trunk/plog-content/themes/lucid/picture.php
r557 r568 36 36 <?php endwhile; ?> 37 37 <?php else : ?> 38 <p id="no-pictures-msg"><?php echo plog_tr('No such image')?>.</p> 38 <div id="error-404"> 39 <h2><?php echo plog_tr('404 - Not Found')?></h2> 40 <p><?php echo plog_tr('We are sorry, but the image that you requested does not exist. You might try using the <strong>Search</strong> feature to locate the image you are looking for.')?></p> 41 </div> 39 42 <?php endif; ?> 40 43 </div><!-- /inner_wrapper --> -
trunk/plog-content/themes/lucid/search.php
r557 r568 26 26 </ul><!-- /slides --> 27 27 <?php else : ?> 28 <p id="no-pictures-msg"><?php echo plog_tr('There are no pictures that matched your search')?>.</p> 28 <div id="error-404"> 29 <h2><?php echo plog_tr('Search Results')?></h2> 30 <p><?php echo plog_tr('We are sorry, but there are no pictures that matched your search.')?></p> 31 </div> 29 32 30 33 <?php endif; ?> -
trunk/plog-content/themes/lucid/slideshow.php
r561 r568 33 33 <?php echo generate_slideshow_interface(); ?> 34 34 <?php else : ?> 35 <div id="no-pictures-msg">No pictures to show.</div> 35 <div id="error-404"> 36 <h2><?php echo plog_tr('404 - Not Found')?></h2> 37 <p><?php echo plog_tr('We are sorry, but there are no images in this album to create a slideshow with.')?></p> 38 </div> 36 39 <?php endif; ?> 37 40 -
trunk/plog-download.php
r550 r568 102 102 $this -> ctrl_dir[] = $cdrec; 103 103 104 105 } 106 104 } 107 105 108 106 function add_file($data, $name) … … 283 281 } 284 282 285 286 283 // $zipfile -> add_dir($dir . $newdir); 287 284 -
trunk/plog-globals.php
r566 r568 60 60 } 61 61 62 63 62 ?> -
trunk/plog-includes/plog-functions.php
r567 r568 69 69 } 70 70 71 // Does this ever happen? Picture level + slideshow adds 'Slideshow' to breadcrumbs only72 //if ($GLOBALS['plogger_mode'] == "slideshow") $breadcrumbs .= $sep . '<strong>' . plog_tr('Slideshow') ;71 // Does this ever happen? Picture level + slideshow adds 'Slideshow' to breadcrumbs only 72 //if ($GLOBALS['plogger_mode'] == "slideshow") $breadcrumbs .= $sep . '<strong>' . plog_tr('Slideshow') . '</strong>'; 73 73 74 74 break; … … 86 86 } 87 87 break; 88 case '404': 89 $breadcrumbs = $collections_link . $sep . '<strong>'.plog_tr("404 Error - Not Found").'</strong>'; 90 break; 88 91 default: 89 92 $breadcrumbs = $collections_name; … … 132 135 if ($GLOBALS['plogger_mode'] == "slideshow") $breadcrumbs .= ' » ' . plog_tr('Slideshow'); 133 136 137 break; 138 case '404': 139 $breadcrumbs = ' ' . plog_tr('404 Error - Not Found'); 134 140 break; 135 141 default: … … 1039 1045 $result = run_query($sql); 1040 1046 1041 // No such collection, fall back to main page1047 // no such collection 1042 1048 if (mysql_num_rows($result) == 0){ 1043 return $rv; 1049 // check if it's an RSS feed 1050 if ($names['collection'] == "feed") { 1051 return array("level" => "collections", "id" => 0); 1052 // else throw a 404 error 1053 } else { 1054 return array("level" => "404"); 1055 } 1044 1056 } 1045 1057 … … 1062 1074 $result = run_query($sql); 1063 1075 1064 // no such album , fall back to collection1076 // no such album 1065 1077 if (mysql_num_rows($result) == 0){ 1066 return $rv; 1078 // check if it's an RSS feed 1079 if ($names['album'] == "feed") { 1080 return array("level" => "collection", "id" => $collection['id']); 1081 // else throw a 404 error 1082 } else { 1083 return array("level" => "404"); 1084 } 1067 1085 } 1068 1086 … … 1117 1135 } 1118 1136 1119 // no such picture , fall back to album1137 // no such picture 1120 1138 if (!$picture) { 1121 return $rv; 1139 // check if it's an RSS feed 1140 if ($names['picture'] == "feed") { 1141 return array("level" => "album", "id" => $album['id']); 1142 // else throw a 404 error 1143 } else { 1144 return array("level" => "404"); 1145 } 1122 1146 } 1123 1147 … … 1465 1489 1466 1490 if (!$row) { 1491 $GLOBALS['plogger_level'] = "404"; 1467 1492 return false; 1468 1493 } … … 1574 1599 case 'collection': 1575 1600 $sql .= " WHERE `p`.`parent_collection` = ".$value; 1576 break;1601 break; 1577 1602 case 'album': 1578 1603 $sql .= " WHERE `p`.`parent_album` = ".$value; 1579 break;1604 break; 1580 1605 case 'id': 1581 1606 $sql .= " WHERE `p`.`id` = ".$value; 1582 break;1607 break; 1583 1608 case 'latest': 1584 break;1609 break; 1585 1610 default: 1586 return 0;1611 return 0; 1587 1612 } 1588 1613 … … 1653 1678 UNIX_TIMESTAMP(`date_submitted`) AS `unix_date_submitted`, 1654 1679 UNIX_TIMESTAMP(`EXIF_date_taken`) AS `unix_exif_date_taken` " . $sql); 1655 1680 if (!mysql_num_rows($result)){ 1681 $GLOBALS['plogger_level'] = "404"; 1682 return false; 1683 } 1656 1684 $GLOBALS["available_pictures"] = mysql_num_rows($result); 1657 1685 $GLOBALS["picture_counter"] = 0; … … 1799 1827 $cond $ordering LIMIT $from,$lim"; 1800 1828 $result = run_query($sql); 1801 1829 if (!mysql_num_rows($result)){ 1830 $GLOBALS['plogger_level'] = "404"; 1831 return false; 1832 } 1802 1833 $GLOBALS["available_collections"] = mysql_num_rows($result); 1803 1834 $GLOBALS["collection_counter"] = 0; … … 1845 1876 1846 1877 $result = run_query($sql); 1878 if (!mysql_num_rows($result)){ 1879 $GLOBALS['plogger_level'] = "404"; 1880 return false; 1881 } 1847 1882 $GLOBALS["available_albums"] = mysql_num_rows($result); 1848 1883 $GLOBALS["album_counter"] = 0; … … 1872 1907 global $config; 1873 1908 1874 if ($GLOBALS['plogger_level'] != "picture" && $GLOBALS['plogger_mode'] != "slideshow" && $ config["allow_dl"]) {1909 if ($GLOBALS['plogger_level'] != "picture" && $GLOBALS['plogger_mode'] != "slideshow" && $GLOBALS['plogger_level'] !="404" && $config["allow_dl"]) { 1875 1910 return '<input id="download_selected_button" class="submit" type="submit" name="download_selected" value="' . plog_tr('Download Selected') . '" />'; 1876 1911 } … … 1880 1915 global $config; 1881 1916 1882 if ($GLOBALS['plogger_level'] != "picture" && $GLOBALS['plogger_mode'] != "slideshow" && $ config["allow_dl"]) {1917 if ($GLOBALS['plogger_level'] != "picture" && $GLOBALS['plogger_mode'] != "slideshow" && $GLOBALS['plogger_level'] !="404" && $config["allow_dl"]) { 1883 1918 return "\n\t" . '<form action="'.$config['gallery_url'].'plog-download.php" method="post"> 1884 1919 <p><input type="hidden" name="dl_type" value="'.$GLOBALS['plogger_level'].'" /></p>' . "\n"; … … 1890 1925 global $config; 1891 1926 1892 if ($GLOBALS['plogger_level'] != "picture" && $GLOBALS['plogger_mode'] != "slideshow" && $ config["allow_dl"]) {1927 if ($GLOBALS['plogger_level'] != "picture" && $GLOBALS['plogger_mode'] != "slideshow" && $GLOBALS['plogger_level'] !="404" && $config["allow_dl"]) { 1893 1928 return "\n\t" . '</form><!-- /download form -->' . "\n"; 1894 1929 } … … 1937 1972 global $config; 1938 1973 1939 if ($GLOBALS['plogger_mode'] != "slideshow" && $GLOBALS['plogger_level'] != "picture" ) {1974 if ($GLOBALS['plogger_mode'] != "slideshow" && $GLOBALS['plogger_level'] != "picture" && $GLOBALS['plogger_level'] != "404") { 1940 1975 $rss_link = ""; 1941 1976 // change the tooltip message to reflect the nature of the RSS aggregate link. … … 1959 1994 $id = $GLOBALS["plogger_id"]; 1960 1995 $ss_tag = ""; 1961 if ($GLOBALS['plogger_mode'] != "slideshow" ) {1996 if ($GLOBALS['plogger_mode'] != "slideshow" && $GLOBALS['plogger_level'] != "404") { 1962 1997 if ($GLOBALS['plogger_level'] == "album") { 1963 1998 $ss_url = generate_url('album',$GLOBALS['plogger_id'],array('mode' => 'slideshow')); … … 1985 2020 global $config; 1986 2021 1987 if ($GLOBALS['plogger_mode'] != 'slideshow' ) {2022 if ($GLOBALS['plogger_mode'] != 'slideshow' && $GLOBALS['plogger_level'] != '404') { 1988 2023 $page = isset($_GET['plog_page']) ? intval($_GET['plog_page']) : 1; 1989 2024 $level = $GLOBALS['plogger_level']; … … 2059 2094 /*** The following functions can only be used inside the Picture loop ***/ 2060 2095 function plogger_has_pictures() { 2061 return $GLOBALS["picture_counter"] < $GLOBALS["available_pictures"]; 2096 if (isset($GLOBALS['picture_counter']) && isset($GLOBALS['available_pictures'])) { 2097 return $GLOBALS['picture_counter'] < $GLOBALS['available_pictures']; 2098 } 2099 return false; 2062 2100 } 2063 2101 … … 2376 2414 2377 2415 function plogger_has_collections() { 2378 return $GLOBALS["collection_counter"] < $GLOBALS["available_collections"]; 2416 if (isset($GLOBALS['collection_counter']) && isset($GLOBALS['available_collections'])) { 2417 return $GLOBALS['collection_counter'] < $GLOBALS['available_collections']; 2418 } 2419 return false; 2379 2420 } 2380 2421 … … 2442 2483 2443 2484 function plogger_has_albums() { 2444 return $GLOBALS["album_counter"] < $GLOBALS["available_albums"]; 2485 if (isset($GLOBALS['album_counter']) && isset($GLOBALS['available_albums'])) { 2486 return $GLOBALS['album_counter'] < $GLOBALS['available_albums']; 2487 } 2488 return false; 2445 2489 } 2446 2490 -
trunk/plog-print.php
r550 r568 11 11 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 12 12 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> 13 14 13 <html xml:lang="<?php echo $language ?>" lang="<?php echo $language ?>" xmlns="http://www.w3.org/1999/xhtml"> 15 16 14 <head> 17 <title><?php echo get_head_title() ?></title>15 <title><?php echo get_head_title() ?></title> 18 16 </head> 19 17 20 <body onload="window.print();"> 21 <div><img src="<?php echo $picture['url']; ?>" alt="<?php echo $picture['caption']; ?>" /></div> 22 </body> 18 <body onload="window.print();"> 23 19 20 <div><img src="<?php echo $picture['url']; ?>" alt="<?php echo $picture['caption']; ?>" /></div> 21 22 </body> 24 23 </html> -
trunk/plog-rss.php
r550 r568 81 81 //$pagelink = $config["address"] . plogger_get_picture_url(); 82 82 // XXX: Below won't look nice with mod_rewrite, but plogger_get_picture_url 83 // returns wrong filename, needs to be fixed 84 $pagelink = $config[ "gallery_url"] . "?level=picture&id=" . plogger_get_picture_id();83 // returns wrong filename, needs to be fixed - still needs to be fixed as this does not always work as wanted either 84 $pagelink = $config['gallery_url'] . "?level=picture&id=" . plogger_get_picture_id(); 85 85 86 86 if ($caption == "" || $caption == " ") $caption = plog_tr("New Image (no caption)"); … … 124 124 // there is no meaningful RSS feed for images 125 125 if (is_array($resolved_path) && isset($resolved_path['level']) && $resolved_path['level'] != "picture") { 126 $level = $resolved_path['level'];127 $id = $resolved_path['id'];126 $level = (isset($resolved_path['level'])) ? $resolved_path['level'] : "collections"; 127 $id = (isset($resolved_path['id'])) ? $resolved_path['id'] : 0; 128 128 } 129 129 } -
trunk/plog-xml.php
r550 r568 31 31 unset($config["admin_email"]); 32 32 unset($config["basedir"]); 33 34 33 35 34 foreach ($config as $var => $val){ -
trunk/plogger.php
r563 r568 78 78 if (count($active['albums']) == 1) { 79 79 $config['truncate_breadcrumb'] = 'album'; 80 if ($GLOBALS['plogger_level']!="picture" ) {80 if ($GLOBALS['plogger_level']!="picture" && $GLOBALS['plogger_level']!="404") { 81 81 if ($GLOBALS['plogger_level']!="search") { 82 82 $GLOBALS['plogger_level'] = "album"; … … 87 87 } else if (count($active['collections']) == 1) { 88 88 $config['truncate_breadcrumb'] = 'collection'; 89 if ($GLOBALS['plogger_level']!="album" && $GLOBALS['plogger_level']!='picture' ) {89 if ($GLOBALS['plogger_level']!="album" && $GLOBALS['plogger_level']!='picture' && $GLOBALS['plogger_level']!="404") { 90 90 if ($GLOBALS['plogger_level']!="search") { 91 91 $GLOBALS['plogger_level'] = "collection"; … … 97 97 } 98 98 99 $allowed_levels = array('collections','collection','album','picture','search' );99 $allowed_levels = array('collections','collection','album','picture','search','404'); 100 100 if (!in_array($GLOBALS['plogger_level'],$allowed_levels)) { 101 101 $GLOBALS['plogger_level'] = 'collections'; … … 106 106 define('THEME_DIR', PLOGGER_DIR.'plog-content/themes/'.$config['theme_dir']); 107 107 define('THEME_URL', $config['theme_url']); 108 109 // initialize plogger 110 plogger_init(); 111 112 // throw 404 headers if a 404 error has occurred 113 if ($GLOBALS['plogger_level'] == "404" && !headers_sent()) { 114 header( "Status: 404 Not Found" ); 115 header($_SERVER['SERVER_PROTOCOL']." 404 Not Found"); 116 } 108 117 109 118 function the_plogger_gallery_head() { … … 124 133 if ($GLOBALS['plogger_level'] == "picture"){ 125 134 $use_file = 'picture.php'; 126 } 127 elseif ($GLOBALS['plogger_level'] == "search"){ 135 } elseif ($GLOBALS['plogger_level'] == "search"){ 128 136 if ($GLOBALS['plogger_mode'] == "slideshow") { 129 137 $use_file = 'slideshow.php'; … … 131 139 $use_file = 'search.php'; 132 140 } 133 } 134 elseif ($GLOBALS['plogger_level'] == "album") { 141 } elseif ($GLOBALS['plogger_level'] == "album") { 135 142 // Album level display mode (display all pictures within album) 136 143 if ($GLOBALS['plogger_mode'] == "slideshow") { … … 139 146 $use_file = 'album.php'; 140 147 } 141 } 142 else if ($GLOBALS['plogger_level'] == "collection") { 148 } else if ($GLOBALS['plogger_level'] == "collection") { 143 149 $use_file = 'collection.php'; 150 } else if ($GLOBALS['plogger_level'] == "404") { 151 $use_file = '404.php'; 144 152 } 145 153
Note: See TracChangeset
for help on using the changeset viewer.
