Dotclear


Ignore:
Timestamp:
05/13/10 20:19:47 (13 years ago)
Author:
JcDenis
Message:

pollsFactory 1.2:

  • Fixed results order on image (thanks Kompozitor)
  • Fixed minor bug
Location:
plugins/pollsFactory/inc
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • plugins/pollsFactory/inc/class.pollsfactory.chart.php

    r2139 r2240  
    182182               } 
    183183          } 
    184           # Lopp through options 
     184          # Loop through options 
    185185          $selections_params['option_type'] = 'pollsselection'; 
    186186          $selections_params['post_id'] = $poll_id; 
     
    191191               $key = (integer) $selections->option_id; 
    192192               # Set bars with no responses 
    193                $opt[$key] = $selections->option_title; 
    194193               if (!isset($chd[$key])) { 
    195194                    $chd[$key] = 0; 
    196195               } 
    197196               # Bar title 
    198                $chxl[$key] = $selections->option_title; 
    199           } 
     197               $chxl[$key] = html::escapeHTML($selections->option_title); 
     198          } 
     199          # Sort every tables to preserve title/responses 
     200          ksort($chd);ksort($chxl); 
     201          array_multisort($chd,$chxl); 
     202          krsort($chd);ksort($chxl); 
     203 
    200204          # go go go 
    201205          $data = array(); 
  • plugins/pollsFactory/inc/index.content.php

    r2139 r2240  
    500500     ); 
    501501} 
    502 echo '</div>'.dcPage::helpBlock('pollsFactory').$footer.'</body></html>'; 
     502echo '</div>'; 
     503dcPage::helpBlock('pollsFactory'); 
     504echo $footer.'</body></html>'; 
    503505 
    504506function addpollForm($section,$title,$poll_id,$query_id,$selection_id,$submit,$action,$content,$tabindex=2,$accesskey='',$sidebar=false) 
  • plugins/pollsFactory/inc/index.poll.php

    r2140 r2240  
    3838$can_delete = false; 
    3939 
    40 $post_headlink = '<link rel="%s" title="%s" href="post.php?id=%s" />'; 
     40$post_headlink = '<link rel="%s" title="%s" href="'.$p_url.'&amp;tab=poll&amp;id=%s" />'; 
    4141$post_link = '<a href="'.$p_url.'&amp;tab=poll&amp;id=%s" title="%s">%s</a>'; 
    4242 
  • plugins/pollsFactory/inc/index.setting.php

    r2139 r2240  
    147147form::hidden(array('action'),'savesetting').' 
    148148</p></div> 
    149 </form> 
    150 '.dcPage::helpBlock('pollsFactory').$footer.'</body></html>'; 
     149</form>'; 
     150dcPage::helpBlock('pollsFactory'); 
     151echo $footer.'</body></html>'; 
    151152?> 
Note: See TracChangeset for help on using the changeset viewer.

Sites map