Changeset 586 for trunk

Show
Ignore:
Timestamp:
09/18/08 19:32:25 (3 months ago)
Author:
kimparsell
Message:

+ Themes:

+ Changed style element names to remove underscore (_) and replace with a hyphen (-).
+ Added theme_functions.php to each theme to provide a centralized location for new functionality in themes.
+ Added gallery stats to the footer in the default and Lucid themes.
+ Miscellaneous cleanup.

+ Added code to include page numbers in title tags for SEO purposes per this thread:

http://www.plogger.org/forum/discussion/2096/seo-titletag-for-pages-in-album/#Item_5

+ Update Exifer1_7/makers/panasonic.php to latest version.
+ Added code to display flash data for images.
+ Added code to extract ISO data from images and display it.

Location:
trunk
Files:
3 added
48 modified

Legend:

Unmodified
Added
Removed
  • trunk/plog-admin/_upgrade.php

    r585 r586  
    5454        fwrite($fh,"<?php\n"); 
    5555        fwrite($fh,$cfg_file); 
    56         fwrite($fh,"?>\n"); 
     56        fwrite($fh,"?>"); 
    5757        fclose($fh); 
    5858 
     
    226226 
    227227// selectable thumbnails 
    228 maybe_add_column(TABLE_PREFIX.'albums','thumbnail_id',"int(11) NOT NULL DEFAULT 0"); 
    229 maybe_add_column(TABLE_PREFIX.'collections','thumbnail_id',"int(11) NOT NULL DEFAULT 0"); 
     228maybe_add_column(TABLE_PREFIX.'albums','thumbnail_id',"int(11) NOT NULL default 0"); 
     229maybe_add_column(TABLE_PREFIX.'collections','thumbnail_id',"int(11) NOT NULL default 0"); 
    230230 
    231231// 
     
    238238 
    239239maybe_add_column(TABLE_PREFIX.'pictures','description',"text"); 
     240maybe_add_column(TABLE_PREFIX.'pictures','EXIF_iso',"varchar(64) NOT NULL default"); 
    240241 
    241242// user definable theme directory 
  • trunk/plog-admin/css/login.css

    r585 r586  
    4343        padding: 0.25em; 
    4444        margin-left: 0; 
    45         width: 70px; 
     45        width: auto; 
    4646} 
    4747 
  • trunk/plog-admin/includes/install-functions.php

    r561 r586  
    198198        `EXIF_flash` varchar(64) NOT NULL default '', 
    199199        `EXIF_aperture` varchar(64) NOT NULL default '', 
     200        `EXIF_iso` varchar(64) NOT NULL default '', 
    200201        `allow_comments` int(11) NOT NULL default '1', 
    201202        PRIMARY KEY  (id), 
  • trunk/plog-admin/plog-admin-functions.php

    r585 r586  
    148148        $exif["flash"] = (isset($exif_raw["SubIFD"]["Flash"])) ? $exif_raw["SubIFD"]["Flash"] : ''; 
    149149        $exif["aperture"] = (isset($exif_raw["SubIFD"]["FNumber"])) ? $exif_raw["SubIFD"]["FNumber"] : ''; 
     150        $exif["iso"] = (isset($exif_raw["SubIFD"]["ISOSpeedRatings"])) ? $exif_raw["SubIFD"]["ISOSpeedRatings"] : ''; 
    150151 
    151152        $picture_path = $create_path . "/" . $final_filename; 
     
    164165                `EXIF_flash`, 
    165166                `EXIF_aperture`, 
     167                `EXIF_iso`, 
    166168                `caption`, 
    167169                `description`) 
     
    179181                        '".mysql_real_escape_string($exif["flash"])."', 
    180182                        '".mysql_real_escape_string($exif["aperture"])."', 
     183                        '".mysql_real_escape_string($exif["iso"])."', 
    181184                        '".mysql_real_escape_string($caption)."', 
    182185                        '".mysql_real_escape_string($desc)."')"; 
     
    13831386                        $output .= "\n\t\t\t\t<td><p id=\"picture-description-" . plogger_get_picture_id() ."\">" . plogger_get_picture_description() . "</p></td>"; 
    13841387                        $allow_comments = (1 == plogger_picture_allows_comments()) ? plog_tr("Yes") : plog_tr("No"); 
    1385                         $output .= "\n\t\t\t\t<td>" . $allow_comments . "</td>"; 
     1388                        $output .= "\n\t\t\t\t<td style=\"text-align: center;\">" . $allow_comments . "</td>"; 
    13861389                        $output .= "\n\t\t\t\t" . '<td style="text-align: center;"><a href="?action=edit-picture&amp;id=' . $id; 
    13871390                        if (isset($_GET["entries_per_page"])) $output .= '&amp;entries_per_page=' . intval($_GET["entries_per_page"]); 
  • trunk/plog-admin/plog-manage.php

    r585 r586  
    200200                                <label accesskey="c" for="caption">' . plog_tr('<em>C</em>aption') . ':</label><br /> 
    201201                                <input size="80" name="caption" id="caption" value="'.htmlspecialchars(SmartStripSlashes($photo['caption'])).'" /><br /> 
    202                                 <label>' . plog_tr('Description') . ':</label><br /> 
     202                                <label for="description">' . plog_tr('Description') . ':</label><br /> 
    203203                                <textarea name="description" id="description" cols="60" rows="5">'.htmlspecialchars(SmartStripSlashes($photo['description'])).'</textarea><br /> 
    204204                                <label for="allow_comments" accesskey="w">' . plog_tr('Allo<em>w</em> Comments') . '?</label> <input type="checkbox" id="allow_comments" name="allow_comments" value="1"'." $state /><br /><br />"; 
     
    239239                        break; 
    240240                case "update-collection": 
    241                         // update the collection infomration 
     241                        // update the collection information 
    242242                        if (!isset($_REQUEST['cancel'])) { 
    243243                                $action_result = update_collection($_POST['pid'], $_POST['name'], $_POST['description'], $_POST['thumbnail_id']); 
  • trunk/plog-admin/plog-options.php

    r570 r586  
    178178                                <table class="option-table"> 
    179179                                        <tr class="alt"> 
    180                                                 <td class="left"><label for="feed_language">' . plog_tr('Language:') . '</label> <a href="http://www.w3.org/TR/REC-html40/struct/dirlang.html#langcodes">' . plog_tr('(language codes)') . '</a></td> 
     180                                                <td class="left"><label for="feed_language">' . plog_tr('RSS Language:') . '</label> <a href="http://www.w3.org/TR/REC-html40/struct/dirlang.html#langcodes">' . plog_tr('(language codes)') . '</a></td> 
    181181                                                <td class="right"><input size="40" type="text" id="feed_language" name="feed_language" value="'.$config['feed_language'].'" /></td> 
    182182                                        </tr> 
  • trunk/plog-content/themes/air/404.php

    r568 r586  
    11<?php plogger_get_header(); ?> 
    22 
    3                 <div id="thumbnail_container"> 
     3                <div id="thumbnail-container"> 
    44 
    55                        <div id="error-404"> 
    66                                <h2><?php echo plog_tr('404 - Not Found')?></h2> 
    77                                <p><?php echo plog_tr('We are sorry, but the page that you are looking for does not exist. You might try using the <strong>Search</strong> feature to locate the image or album you are looking for.')?></p> 
    8                         </div> 
     8                        </div><!-- /error-404 --> 
    99 
    10                 </div><!-- /thumbnail container --> 
     10                </div><!-- /thumbnail-container --> 
    1111 
    1212<?php plogger_get_footer(); ?> 
  • trunk/plog-content/themes/air/album.php

    r572 r586  
    2020                        </li><!-- /thumbnail --> 
    2121<?php endwhile; ?> 
    22                 </ul><!-- /slides --> 
     22                </ul><!-- /slides clearfix --> 
    2323<?php else : ?> 
    2424                <div id="no-pictures-msg"> 
    2525                        <h2><?php echo plog_tr('No Images') ?></h2> 
    2626                        <p><?php echo plog_tr('Sorry, but there are no images in this album yet.') ?></p> 
    27                 </div> 
     27                </div><!-- /no-pictures-msg --> 
    2828<?php endif; ?> 
    2929 
    30         </div><!-- /thumbnail container --> 
     30        </div><!-- /thumbnail-container clearfix --> 
    3131<?php plogger_get_footer(); ?> 
  • trunk/plog-content/themes/air/collection.php

    r572 r586  
    2727                        <h2><?php echo plog_tr('No Albums') ?></h2> 
    2828                        <p><?php echo plog_tr('Sorry, but there are no images or albums in this collection yet.') ?></p> 
    29                 </div> 
     29                </div><!-- /no-pictures-msg --> 
    3030<?php endif; ?> 
    31         </div><!-- /thumbnail-container --> 
     31        </div><!-- /thumbnail-container clearfix --> 
    3232<?php plogger_get_footer(); ?> 
  • trunk/plog-content/themes/air/collections.php

    r572 r586  
    2222                </div><!-- /collections --> 
    2323 
    24         <?php else : ?> 
     24<?php else : ?> 
    2525                <div id="no-pictures-msg"> 
    2626                        <h2><?php echo plog_tr('No Images') ?></h2> 
    2727                        <p><?php echo plog_tr('Sorry, but there are no images in this gallery yet.') ?></p> 
    28                 </div> 
    29         <?php endif; ?> 
    30 </div><!-- /thumbnail-container --> 
     28                </div><!-- /no-pictures-msg --> 
     29<?php endif; ?> 
     30        </div><!-- /thumbnail-container clearfix --> 
    3131<?php plogger_get_footer(); ?> 
  • trunk/plog-content/themes/air/comments.php

    r573 r586  
    33                        <h2 class="comment-heading"><?php echo plog_tr('Comments'); ?>:</h2> 
    44 
    5 <? if (plogger_picture_has_comments()) { ?> 
     5<?php if (plogger_picture_has_comments()) { ?> 
    66                                <ol class="comments"> 
    7 <? $counter = 0; 
     7<?php $counter = 0; 
    88                while(plogger_picture_has_comments()) { 
    99                        plogger_load_comment(); 
     
    1111                        $author = plogger_get_comment_author(); 
    1212                        // this code alternates the background color every other comment 
    13                         $comment_class = ($counter % 2) ? "comment_alt" : "comment"; 
     13                        $comment_class = ($counter % 2) ? "comment-alt" : "comment"; 
    1414?> 
    1515                                        <li class="<?php echo $comment_class; ?>"> 
    1616                                                <p><?php echo plogger_get_comment_text(); ?></p> 
    1717                                                <cite><?php echo plog_tr('Comment by'); ?> <?php echo (trim($url) != '') ? "<a href=\"$url\" rel=\"nofollow\">$author</a>" : "$author"; ?> - <?php echo plog_tr('posted on'); ?> <?php echo plogger_get_comment_date(); ?></cite> 
    18                                         </li> 
     18                                        </li><!-- /comment comment-alt --> 
    1919<?php $counter++; 
    2020                } ?> 
    21                                 </ol> 
     21                                </ol><!-- /comments --> 
    2222<?php } else { ?> 
    2323                                <p><?php echo plog_tr('No comments yet'); ?></p> 
     
    5555                                        </p> 
    5656                                        <p class="comment-input-button"><input class="submit" name="submit" type="submit" tabindex="5" value="<?php echo plog_tr('Post Comment'); ?>" /></p> 
    57                                 </form> 
     57                                </form><!-- /commentform --> 
    5858 
    5959<?php } else { ?> 
  • trunk/plog-content/themes/air/dynamics.js

    r585 r586  
    3131        httpRequest.send(null); 
    3232 
    33         document.getElementById('exif_data').style.display = 'none'; 
     33        document.getElementById('exif-data').style.display = 'none'; 
    3434        document.getElementById('hide_details').style.display = 'none';      // We have to switch visible tag 
    3535        document.getElementById('show_details').style.display = 'inline';    // due to translations 
     
    5252        httpRequest.send(null); 
    5353 
    54         document.getElementById('exif_data').style.display = ''; 
     54        document.getElementById('exif-data').style.display = ''; 
    5555        document.getElementById('hide_details').style.display = 'inline';    // We have to switch visible tag 
    5656        document.getElementById('show_details').style.display = 'none';      // due to translations 
  • trunk/plog-content/themes/air/footer.php

    r557 r586  
    2424<?php } ?> 
    2525                <?php echo plogger_link_back(); ?> 
    26                 <div class="credit"><a href="http://www.ardamis.com/"><?php echo plog_tr('Design by')?> ardamis.com</a></div> 
     26                <div class="credit"><a href="http://www.ardamis.com/"><?php echo plog_tr('Design by')?> ardamis.com</a></div><!-- /credit --> 
    2727 
    28         </div><!-- /footer --> 
     28        </div><!-- /footer clearfix --> 
    2929<?php echo plogger_download_selected_form_end(); ?> 
    3030 
    31 </div><!-- /wrapper --> 
     31</div><!-- /plog-wrapper --> 
  • trunk/plog-content/themes/air/gallery.css

    r572 r586  
    3333} 
    3434 
    35 #wrapper { 
     35#plog-wrapper { 
    3636        /* #wrapper contains the entire content of the page; this is where one would center the page content, and give it a definite width, this is also where one would put borders around the content of the page */  
    3737        margin: 0 auto 0; 
     
    101101} 
    102102 
    103 #breadcrumb_links { 
     103#breadcrumb-links { 
    104104        /* #breadcrumb_links controls the breadcrumbs text that isn't a link */ 
    105105        float: left; 
     
    108108} 
    109109 
    110 #breadcrumb_links a { 
     110#breadcrumb-links a { 
    111111        /* #breadcrumb_links a controls the breadcrumbs text that is a link */ 
    112112        color: #fff; 
     
    114114} 
    115115 
    116 #breadcrumb_links a:hover, #slideshow a:hover { 
     116#breadcrumb-links a:hover, #slideshow a:hover { 
    117117        /* #breadcrumb_links a:hover, #slideshow a:hover a controls hover behavior of the breadcrumbs text that is a link */ 
    118118        color: #fff; 
     
    362362} 
    363363 
    364 /* exif stuff is for the 'camera details' table */ 
    365  
    366 #exif_toggle { 
     364/* Exif stuff is for the 'camera details' table */ 
     365 
     366#exif-toggle { 
    367367        margin: 0 0 20px 0; 
    368368        padding: 0; 
     
    372372} 
    373373 
    374 #exif_table { 
    375 } 
    376  
    377 #exif_data { 
     374#exif-table { 
     375} 
     376 
     377#exif-data { 
    378378        margin: 0 auto 0; 
    379379        text-align: left; 
    380380} 
    381381 
    382 #exif_data td { 
    383         padding: 0 20px; 
     382#exif-data td.exif-label { 
     383        text-align: right; 
     384        padding-right: 10px; 
     385        width: 50%; 
     386} 
     387 
     388#exif-data td.exif-info { 
     389        text-align: left; 
     390        padding-right: 10px; 
     391        width: 50%; 
    384392} 
    385393 
     
    432440} 
    433441 
    434 .comment, .comment_alt { 
     442.comment, .comment-alt { 
    435443        /* .comment, .comment_alt control those elements that all comments have in common */ 
    436444        border-top: 1px solid #dfded6; 
     
    440448} 
    441449 
    442 .comment_alt { 
     450.comment-alt { 
    443451        /* .comment_alt controls those elements that every other comment has in common, eg: a different colored background */ 
    444452        background: #effbfb; 
     
    534542} 
    535543 
    536 .page_link { 
     544.page-link { 
    537545        /* .page_link controls the page numbers (link and non-link) */ 
    538546        padding-left: 1px; 
  • trunk/plog-content/themes/air/header.php

    r572 r586  
    1 <div id="wrapper"> 
     1<?php include('theme_functions.php'); ?> 
     2<!--Output highest level container division--> 
     3<div id="plog-wrapper"> 
    24 
    35        <div id="header"> 
     
    1315<?php echo plogger_print_button(); ?> 
    1416 
    15                         </div> 
     17                        </div><!-- /slideshow --> 
    1618                        <?php echo generate_breadcrumb("Home", " | "); ?> 
    1719 
  • trunk/plog-content/themes/air/picture.php

    r572 r586  
    2929 
    3030                <p id="picture-description"><?php echo plogger_get_picture_description(); ?></p> 
    31                 <div id="exif_toggle"><?php echo $detail_link; ?></div> 
     31                <div id="exif-toggle"><?php echo $detail_link; ?></div> 
    3232                <div id="exif-toggle-container"> 
    3333<?php echo generate_exif_table(plogger_get_picture_id()); ?> 
     
    4848                        <h2><?php echo plog_tr('Not Found') ?></h2> 
    4949                        <p><?php echo plog_tr('Sorry, but the image that you requested does not exist.') ?></p> 
    50                 </div> 
     50                </div><!-- /no-pictures-msg --> 
    5151        <?php endif; ?> 
    5252        </div><!-- /big-picture-container --> 
  • trunk/plog-content/themes/air/search.php

    r572 r586  
    1717                                <a href="<?php echo plogger_get_picture_url(); ?>"><img id="thumb-<?php echo plogger_get_picture_id(); ?>" class="photos" src="<?php echo plogger_get_picture_thumb(); ?>" width="<?php echo $thumb_width; ?>px" height="<?php echo $thumb_height; ?>px" title="<?php echo $picture_caption; ?>" alt="<?php echo $picture_caption; ?>" /></a> 
    1818                                <div class="checkbox"><?php echo plogger_download_checkbox(plogger_get_picture_id()); ?></div> 
    19                                 <p style="width:<?php echo $thumb_width; ?>px;"><?php echo $picture_caption; ?></p> 
     19                                <p style="width: <?php echo $thumb_width; ?>px;"><?php echo $picture_caption; ?></p> 
    2020                        </li><!-- /thumbnail --> 
    2121<?php endwhile; ?> 
    22                 </ul><!-- /slides --> 
     22                </ul><!-- /slides clearfix --> 
    2323<?php else : ?> 
    2424                <div id="no-pictures-msg"> 
    2525                        <h2><?php echo plog_tr('Search Results') ?></h2> 
    2626                        <p><?php echo plog_tr('Sorry, but there are no images that matched your search terms.') ?></p> 
    27                 </div> 
     27                </div><!-- /no-pictures-msg --> 
    2828<?php endif; ?> 
    2929 
    30         </div><!-- /thumbnail-container --> 
     30        </div><!-- /thumbnail-container clearfix --> 
    3131<?php plogger_get_footer(); ?> 
  • trunk/plog-content/themes/air/slideshow.php

    r585 r586  
    4646                        <h2><?php echo plog_tr('No Images') ?></h2> 
    4747                        <p><?php echo plog_tr('Sorry, but there are no images in this album to create a slideshow with.') ?></p> 
    48                 </div> 
     48                </div><!-- /no-pictures-msg --> 
    4949<?php endif; ?> 
    5050 
  • trunk/plog-content/themes/default/404.php

    r568 r586  
    11<?php plogger_get_header(); ?> 
    22 
    3                 <div id="thumbnail_container"> 
     3                <div id="thumbnail-container"> 
    44 
    55                        <div id="error-404"> 
    66                                <h2><?php echo plog_tr('404 - Not Found')?></h2> 
    77                                <p><?php echo plog_tr('We are sorry, but the page that you are looking for does not exist. You might try using the <strong>Search</strong> feature to locate the image or album you are looking for.')?></p> 
    8                         </div> 
     8                        </div><!-- /error-404 --> 
    99 
    10                 </div><!-- /thumbnail container --> 
     10                </div><!-- /thumbnail-container --> 
    1111 
    1212<?php plogger_get_footer(); ?> 
  • trunk/plog-content/themes/default/album.php

    r572 r586  
    11<?php plogger_get_header(); ?> 
    22 
    3                 <div id="thumbnail_container"> 
     3                <div id="thumbnail-container"> 
    44 
    55<?php if (plogger_has_pictures()) : ?> 
     
    3232                                <h2><?php echo plog_tr('No Images') ?></h2> 
    3333                                <p><?php echo plog_tr('Sorry, but there are no images in this album yet.') ?></p> 
    34