Ignore:
Timestamp:
Jun 9, 2014, 7:11:17 PM (10 years ago)
Author:
mistic100
Message:

update for 2.7

File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/skeleton/trunk/include/public_events.inc.php

    r26137 r28650  
    1212  {
    1313    $page['section'] = 'skeleton';
    14    
     14
    1515    // section_title is for breadcrumb, title is for page <title>
    1616    $page['section_title'] = '<a href="'.get_absolute_root_url().'">'.l10n('Home').'</a>'.$conf['level_separator'].'<a href="'.SKELETON_PUBLIC.'">'.l10n('Skeleton').'</a>';
    1717    $page['title'] = l10n('Skeleton');
    18    
     18
    1919    $page['body_id'] = 'theSkeletonPage';
    2020    $page['is_external'] = true; // inform Piwigo that you are on a new page
     
    2929  global $page, $template;
    3030
    31   if ( isset($page['section']) and $page['section']=='skeleton' )
     31  if (isset($page['section']) and $page['section']=='skeleton')
    3232  {
    3333    include(SKELETON_PATH . 'include/skeleton_page.inc.php');
     
    4141{
    4242  global $template;
    43  
     43
    4444  $template->assign('SKELETON_PATH', SKELETON_PATH);
    4545  $template->set_filename('skeleton_button', realpath(SKELETON_PATH.'template/my_button.tpl'));
    4646  $button = $template->parse('skeleton_button', true);
    47  
     47
    4848  if (script_basename()=='index')
    4949  {
    50     $template->add_index_button($button, EVENT_HANDLER_PRIORITY_NEUTRAL);
     50    $template->add_index_button($button, BUTTONS_RANK_NEUTRAL);
    5151  }
    5252  else
    5353  {
    54     $template->add_picture_button($button, EVENT_HANDLER_PRIORITY_NEUTRAL);
     54    $template->add_picture_button($button, BUTTONS_RANK_NEUTRAL);
    5555  }
    5656}
     
    6262{
    6363  global $template;
    64  
     64
    6565  $template->set_prefilter('picture', 'skeleton_picture_prefilter');
    6666}
     
    6969{
    7070  $search = '{if $display_info.author and isset($INFO_AUTHOR)}';
    71   $replace = '<div id="Skeleton" class="imageInfo">
    72                 <dt>{\'Skeleton\'|@translate}</dt>
    73                 <dd style="color:orange;">{\'Piwigo rocks\'|@translate}</dd>
    74         </div>
    75 '.$search;
     71  $replace = '
     72<div id="Skeleton" class="imageInfo">
     73  <dt>{\'Skeleton\'|@translate}</dt>
     74  <dd style="color:orange;">{\'Piwigo rocks\'|@translate}</dd>
     75</div>
     76';
    7677
    77   return str_replace($search, $replace, $content);
     78  return str_replace($search, $replace.$search, $content);
    7879}
Note: See TracChangeset for help on using the changeset viewer.