Changeset 360971
- Timestamp:
- 03/16/2011 10:16:53 PM (15 years ago)
- Location:
- wp-photocontest/trunk
- Files:
-
- 4 edited
-
lib/wp-photocontest.class.php (modified) (2 diffs)
-
readme.txt (modified) (2 diffs)
-
viewimg.php (modified) (3 diffs)
-
wp-photocontest.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
wp-photocontest/trunk/lib/wp-photocontest.class.php
r358725 r360971 283 283 $page_data = $this->get_page_data($contest_id, $post_id, $p, $n_photo_x_page,'recent'); 284 284 $page_menu = $this->get_top_menu(get_option('siteurl'),$post_id); 285 $scrolling = $this->get_page_scrolling($post_id, $number_of_photos, $p, $number_of_pages,'recent' );285 $scrolling = $this->get_page_scrolling($post_id, $number_of_photos, $p, $number_of_pages,'recent','refresh'); 286 286 287 287 $content_title = "Recently added"; … … 412 412 $base_url = '?page=wp-photocontest/photocontest-manager.php&mode=view_contest&contest_id='.$post_id.'&order='.$order; 413 413 } 414 elseif ($base_url == 'refresh') 415 { 416 $base_url = 'wp-content/plugins/wp-photocontest/view.php?post_id='.$post_id.'&order='.$order; 417 } 414 418 else 415 419 { -
wp-photocontest/trunk/readme.txt
r358725 r360971 5 5 Requires at least: 2.7 6 6 Tested up to: 3.0.1 7 Stable tag: 1.5. 57 Stable tag: 1.5.6 8 8 9 9 This plugin automatically turns a WordPress-page into a photo contest. … … 188 188 189 189 == Changelog == 190 = 1.5.6 - 16.03.2011 = 191 * (added) Added a previous and next entry link when viewing a entry 192 * (fixed) The pagination on the homepage / post links gave a 404-error. 193 190 194 = 1.5.5 - 11.03.2011 = 191 195 * (added) The upload and intro text now can have the tags br, h1, h2 and h3 with classes -
wp-photocontest/trunk/viewimg.php
r358725 r360971 242 242 $image_details = (array) $wpdb->get_row( $wpdb->prepare("SELECT contest_id, wp_uid, img_id, img_path, img_name, img_title, img_comment, sum_votes, img_view_count, insert_time, wp_email FROM ".$wpdb->prefix."photocontest WHERE img_id = %d", $img_id)); 243 243 244 ############################## 245 ### Get the next/prev btns ### 246 ############################## 247 $next_id = NULL; 248 $prev_id = NULL; 249 $prev_details = (array) $wpdb->get_row( $wpdb->prepare("SELECT contest_id,img_id FROM ".$wpdb->prefix."photocontest WHERE contest_id = %d AND visibile = 1 AND img_id < %d ORDER BY img_id DESC LIMIT 1", $contest_id, $img_id)); 250 if ($prev_details['img_id'] > 0) 251 { 252 $prev_id = $prev_details['img_id']; 253 } 254 $next_details = (array) $wpdb->get_row( $wpdb->prepare("SELECT contest_id,img_id FROM ".$wpdb->prefix."photocontest WHERE contest_id = %d AND visibile = 1 AND img_id > %d ORDER BY img_id DESC LIMIT 1", $contest_id, $img_id)); 255 if ($next_details['img_id'] > 0) 256 { 257 $next_id = $next_details['img_id']; 258 } 244 259 // today is?? 245 260 $today = date('Y-m-d'); … … 574 589 { 575 590 ?> 591 <br clear="all"> 592 <?php 593 if ($prev_id) 594 { 595 ?> 596 <div id="prev_btn" style="float:left;font-size:11px;font-weight:normal !important"><a href="<?php echo get_option("siteurl");?>/wp-content/plugins/wp-photocontest/viewimg.php?post_id=<?php echo $post_id;?>&img_id=<?php echo $prev_id;?>">« <?php _e('Previous entry', 'wp-photocontest');?></a></div> 597 <?php 598 } 599 if ($next_id) 600 { 601 ?> 602 <div id="next_btn" style="float:right;font-size:11px;font-weight:normal !important"><a href="<?php echo get_option("siteurl");?>/wp-content/plugins/wp-photocontest/viewimg.php?post_id=<?php echo $post_id;?>&img_id=<?php echo $next_id;?>"><?php _e('Next entry', 'wp-photocontest');?> »</a></div> 603 <?php 604 } 605 ?> 606 <br clear="all"> 576 607 <div id="vote"> 577 608 <div class="wp-photocontest_detailslist"> … … 797 828 </div> 798 829 </div> 830 <br clear="all"> 831 <?php 832 if ($prev_id) 833 { 834 ?> 835 <div id="prev_btn" style="float:left;font-size:11px;font-weight:normal !important"><a href="<?php echo get_option("siteurl");?>/wp-content/plugins/wp-photocontest/viewimg.php?post_id=<?php echo $post_id;?>&img_id=<?php echo $prev_id;?>">« <?php _e('Previous entry', 'wp-photocontest');?></a></div> 836 <?php 837 } 838 if ($next_id) 839 { 840 ?> 841 <div id="next_btn" style="float:right;font-size:11px;font-weight:normal !important"><a href="<?php echo get_option("siteurl");?>/wp-content/plugins/wp-photocontest/viewimg.php?post_id=<?php echo $post_id;?>&img_id=<?php echo $next_id;?>"><?php _e('Next entry', 'wp-photocontest');?> »</a></div> 842 <?php 843 } 844 ?> 845 <br clear="all"> 799 846 <?php 800 847 } -
wp-photocontest/trunk/wp-photocontest.php
r358734 r360971 4 4 Plugin URI: http://www.vanderstad.nl/wordpress/plugins/wp-photocontest 5 5 Description: Adds a photo contest to your post or page. Note: Only apply auto-upgrade when you don't care about losing your contests!! (and if you do: Backup you tables, 'CONTEST_FOLDER'- and 'skins'-directories!) 6 Version: 1.5. 56 Version: 1.5.6 7 7 Author: Frank van der Stad 8 8 Author URI: http://www.vanderstad.nl/wordpress/
Note: See TracChangeset
for help on using the changeset viewer.