Changeset 157

Show
Ignore:
Timestamp:
12/16/06 03:19:06 (14 years ago)
Author:
exi
Message:

Added option to show a link to the pod killmail instead of a pod picture on the battle summary.
Battle summaries will now be sorted by shippoints, shipname, pilotname.
Added option to disable mailposting without having to change the password.
Fixed a typo on the standingslist.

Location:
dev
Files:
6 modified

Legend:

Unmodified
Added
Removed
  • dev/common/admin.php

    r154 r157  
    3535    $config->checkCheckbox('adapt_items'); 
    3636    $config->checkCheckbox('show_standing'); 
     37    $config->checkCheckbox('bs_podlink'); 
     38    $config->checkCheckbox('post_forbid'); 
    3739 
    3840    if ($config->checkCheckbox('comments')) 
     
    164166} 
    165167$html .= "></td></tr>"; 
     168$html .= "<tr><td width=120><b>Display a link instead of POD on Battlesummary:</b></td><td><input type=checkbox name=bs_podlink id=bs_podlink"; 
     169if ($config->getConfig('bs_podlink')) 
     170{ 
     171    $html .= " checked=\"checked\""; 
     172} 
     173$html .= "></td></tr>"; 
    166174// $html .= "<tr><td width=120><b>Display least active:</b></td><td><input type=checkbox name=least_active id=least_active"; 
    167175// if ( $config->getLeastActive() ) 
     
    177185$html .= "<tr><td width=120><b>Mailhost:</b></td><td><input type=text name=post_mailhost id=post_mailhost size=20 maxlength=80 value=\"".$config->getConfig('mail_host')."\"></td></tr>"; 
    178186$html .= "<tr><td width=120><b>Disallow any killmails before:</b></td><td>".dateSelector($config->getConfig('filter_apply'), $config->getConfig('filter_date'))."</td></tr>"; 
     187$html .= "<tr><td width=120><b>Forbid posting</b></td><td><input type=checkbox name=post_forbid id=post_forbid"; 
     188if ($config->getConfig('post_forbid')) 
     189{ 
     190    $html .= " checked=\"checked\""; 
     191} 
     192$html .= "> (Checking this option disables mailposting)</td></tr>"; 
    179193$html .= "<tr><td width=120><b>Enable auto-addition of unknown Items:</b></td><td><input type=checkbox name=adapt_items id=adapt_items"; 
    180194if ($config->getConfig('adapt_items')) 
  • dev/common/kill_related.php

    r155 r157  
    169169    { 
    170170        global $pods; 
    171         $pods[] = $kill->getVictimID(); 
     171        $pods[$kill->getID()] = $kill->getVictimID(); 
    172172 
    173173        // return when we've added him already 
     
    203203        return -1; 
    204204    } 
     205    // sort after points, shipname, pilotname 
    205206    elseif ($a['scl'] == $b['scl']) 
    206207    { 
    207         if ($a['ship'] > $b['ship']) 
     208        if ($a['ship'] == $b['ship']) 
     209        { 
     210            if ($a['name'] > $b['name']) 
     211            { 
     212                return 1; 
     213            } 
     214            return -1; 
     215        } 
     216        elseif ($a['ship'] > $b['ship']) 
    208217        { 
    209218            return 1; 
     
    232241    global $pods; 
    233242 
    234     if (in_array((string)$pilot, $pods)) 
    235     { 
     243    if ($result = array_search((string)$pilot, $pods)) 
     244    { 
     245        global $smarty; 
     246 
     247        $smarty->assign('pod_kll_id', $result); 
    236248        return true; 
    237249    } 
  • dev/common/post.php

    r92 r157  
    103103    } 
    104104} 
    105 else 
     105elseif (!$config->getConfig('post_forbid')) 
    106106{ 
    107107    $html .= "Paste the killmail from your EVEMail inbox into the box below. Make sure you post the <b>ENTIRE</b> mail.<br>Posting fake or otherwise edited mails is not allowed. All posts are logged."; 
     
    117117    $html .= "</form>"; 
    118118} 
     119else 
     120{ 
     121    $html .= 'Posting killmails is disabled<br/>'; 
     122} 
    119123 
    120124$page->setContent($html); 
  • dev/common/post_igb.php

    r59 r157  
    7777    } 
    7878} 
    79 else 
     79elseif (!$config->getConfig('post_forbid')) 
    8080{ 
    8181    $html .= "Paste the killmail from your EVEMail inbox into the box below. Make sure you post the <b>ENTIRE</b> mail.<br>Posting fake or otherwise edited mails is not allowed. All posts are logged."; 
     
    8888    $html .= "</form>"; 
    8989} 
     90else 
     91{ 
     92    $html .= 'Posting killmails is disabled<br/>'; 
     93} 
    9094 
    9195$html .= "</body></html>"; 
  • dev/templates/battle_overview.tpl

    r154 r157  
    2121      </td> 
    2222{if podded($pilot) and $i.ship != 'Capsule'} 
     23{if $config->getConfig('bs_podlink')} 
     24      <td class="kb-table-cell"> 
     25        <b>{$i.name}&nbsp;<a href="?a=kill_detail&amp;kll_id={$pod_kll_id}">[Pod]</a></b><br/>{$i.ship} 
     26      </td> 
     27{else} 
    2328      <td class="kb-table-cell" style="background-image: url({$podpic}); background-repeat: no-repeat; background-position: right;"> 
    2429        <b>{$i.name}</b><br/>{$i.ship} 
    2530      </td> 
     31{/if} 
    2632{else} 
    2733      <td class="kb-table-cell"><b><a href="?a=pilot_detail&amp;plt_id={$pilot}">{$i.name}</a></b><br/>{$i.ship}</td> 
     
    5056      </td> 
    5157{if podded($pilot) and $i.ship != 'Capsule'} 
     58{if $config->getConfig('bs_podlink')} 
     59      <td class="kb-table-cell"> 
     60        <b>{$i.name}</b>&nbsp;<a href="?a=kill_detail&amp;kll_id={$pod_kll_id}">[Pod]</a><br/>{$i.ship} 
     61      </td> 
     62{else} 
    5263      <td class="kb-table-cell" style="background-image: url({$podpic}); background-repeat: no-repeat; background-position: right;"> 
    5364        <b>{$i.name}</b><br/>{$i.ship} 
    5465      </td> 
     66{/if} 
    5567{else} 
    5668      <td class="kb-table-cell"><b><a href="?a=pilot_detail&amp;plt_id={$pilot}">{$i.name}</a></b><br/>{$i.ship}</td> 
  • dev/templates/standings.tpl

    r149 r157  
    1010{else} 
    1111    <td width="32" height="34" valign="top" align="right" style="background-image: url(?a=corpportrait&size=32&id={$standings[opt].list[idx].id});"><img src="img/sta_{$standings[opt].list[idx].icon}.png"/></td> 
    12     <td><b><a href="?a=corp_detail&all_id={$standings[opt].list[idx].id}">{$standings[opt].list[idx].text}</a></b>{$standings[opt].list[idx].descr}</td> 
     12    <td><b><a href="?a=corp_detail&crp_id={$standings[opt].list[idx].id}">{$standings[opt].list[idx].text}</a></b>{$standings[opt].list[idx].descr}</td> 
    1313{/if} 
    1414    <td align="right">{$standings[opt].list[idx].value}</td>