<[include file="common/group_list.tpl"]>
<div id="contents">
<[include file="common/group_menu.tpl"]>
  <br />
  <div id="site-info">
    <h3><img src="<[$TEMPLATE_DIR]>/img/icon_large/ninki.jpg" align="absmiddle" style="margin-right:8px;">リンク元ランキング</h3>
    <br />
    <fieldset style="width:500px;padding-left:30px;">
    <legend>ランキング期間を指定して下さい。</legend>
    <table width="100%" border="0">
      <tr>
        <td>
        <form method="post" action="./index.php?mode=53&group_code=<[$current_group.group_code]>">
          ランキング期間:
          <select name="period" onchange="submit();">
            <option value="30"<[if $period == "30"]> selected<[/if]>>30日間</option>
            <option value="60"<[if $period == "60"]> selected<[/if]>>60日間</option>
            <option value="90"<[if $period == "90"]> selected<[/if]>>90日間</option>
          </select>
        </form>
        </td>
      </tr>
    </table>
    </fieldset>
    <table id="view-table" cellpadding="2" cellspacing="0" width="100%">
      <tr>
        <th nowrap>順位</th>
        <th>リンク元URL</th>
        <th nowrap>リクエスト数</th>
      </tr>
    <[foreach from=$refer_array key=url item=refer name=refer]>
      <tr class="<[cycle values="odd,even"]>">
        <td class="ac_date" nowrap><[if $smarty.foreach.refer.iteration < 4]><img src="<[$TEMPLATE_DIR]>/img/icon/s_crown.gif">&nbsp;<[/if]><[$smarty.foreach.refer.iteration]>位</td>
        <td class="ac_graph"><div style="word-break:break-all;overflow:hidden;"><[if $url != ""]><a href="<[$url]>" target="_blank"><[$url]></a><[else]>リンク元なし（お気に入り等）<[/if]></div></td>
        <td class="ac_count" nowrap><[$refer|number_format]></td>
      </tr>
    <[foreachelse]>
      <tr class="odd">
        <td colspan="3">ログデータがありません。</td>
      </tr>
    <[/foreach]>
    </table>
  </div>
</div>