Changeset 684872
- Timestamp:
- 03/20/2013 05:43:44 PM (13 years ago)
- Location:
- child-page-navigation/trunk
- Files:
-
- 2 edited
-
child-page-navigation.php (modified) (4 diffs)
-
readme.txt (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
child-page-navigation/trunk/child-page-navigation.php
r684518 r684872 6 6 Author: ITS Alaska 7 7 Author URI: http://ITSCanFixThat.com/ 8 Version: 1.3 8 Version: 1.3.1 9 9 10 10 This program is free software: you can redistribute it and/or modify … … 33 33 function form(){ 34 34 $opts = get_option('widget_theme_navigation'); 35 36 $key = array_keys(array_flip($opts)); 37 unset($key['_multiwidget']); 38 var_dump($key); 35 39 ?> 36 <p>Title: <input name="cpn_title" id="cpn_title" type="text" <?php if(isset($opts[ 2]['title']) && $opts[2]['title'] != "") echo 'value="'.$opts[2]['title'].'"'; ?> /></p>37 <p>Sort by Sort Order? <input name="cpn_sort" id="cpn_sort" type="checkbox" <?php if(isset($opts[ 2]['sort']) && $opts[2]['sort']) echo 'checked="checked"'; ?> value="1" /></p>40 <p>Title: <input name="cpn_title" id="cpn_title" type="text" <?php if(isset($opts[$key]['title']) && $opts[$key]['title'] != "") echo 'value="'.$opts[$key]['title'].'"'; ?> /></p> 41 <p>Sort by Sort Order? <input name="cpn_sort" id="cpn_sort" type="checkbox" <?php if(isset($opts[$key]['sort']) && $opts[$key]['sort']) echo 'checked="checked"'; ?> value="1" /></p> 38 42 <?php } 39 43 … … 57 61 $opts = get_option('widget_theme_navigation'); 58 62 63 $key = array_keys($opts); 64 unset($key['_multiwidget']); 65 $key = array_pop($key); 66 59 67 $page_arr = array('child_of' => $post->ID, 'parent' => $post->ID); 60 68 61 if($opts[ 2]['sort'])69 if($opts[$key]['sort']) 62 70 $page_arr['sort_column'] = 'menu_order'; 63 71 … … 73 81 echo $args['before_widget']; 74 82 75 if(isset($opts[ 2]['title']) && $opts[2]['title'] != "")76 echo $args['before_title'].$opts[ 2]['title'].$args['after_title'];83 if(isset($opts[$key]['title']) && $opts[$key]['title'] != "") 84 echo $args['before_title'].$opts[$key]['title'].$args['after_title']; 77 85 78 86 echo "<ul>"; -
child-page-navigation/trunk/readme.txt
r684513 r684872 21 21 == Changelog == 22 22 23 = 1.3.1 = 24 * Fixed weird bug where some users couldn't update their widget 25 23 26 = 1.3 = 24 27 * Added option in widget to sort by page sort order
Note: See TracChangeset
for help on using the changeset viewer.