⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 admin.blocklist.html.php

📁 joomla的系统插件,用于用户的管理,可以开发或阻塞用户
💻 PHP
字号:
<?php/*** @package Blocklist* @copyright (C) 2006 Websmurf* @author Websmurf* * --------------------------------------------------------------------------------* All rights reserved.  Blocklist is a component for Joomla and Mambo. * You can use it to block certain ipadresses or ipblocks** This program is free software; you can redistribute it and/or* modify it under the terms of the Creative Commons - Attribution-NoDerivs 2.5 * license as published by the Creative Commons Organisation* http://creativecommons.org/licenses/by-nd/2.5/.** This program is distributed in the hope that it will be useful,* but WITHOUT ANY WARRANTY; without even the implied warranty of* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  * --------------------------------------------------------------------------------**/// ensure this file is being included by a parent filedefined( '_VALID_MOS' ) or die( 'Direct Access to this location is not allowed.' );class HTML_blocklist {    function showBlocklist($rows){    global $option;    ?>    <script type="text/javascript">    <!--        function submitbutton(pressbutton){      if(pressbutton == 'new'){        add();        return;      }            submitform(pressbutton);    }        function add(){      var tbody = document.getElementById('blocklist');      var row = document.createElement("tr");      var id = parseInt(document.adminForm.count.value);      row.setAttribute('id', 'row' + id );            var td1 = document.createElement("td");      td1.innerHTML = id + 1;      row.appendChild(td1);            var td2 = document.createElement("td");      td2.innerHTML = '<input type="text" name="block_ip[]" value="" class="inputbox" />';      row.appendChild(td2);            var td3 = document.createElement("td");      td3.innerHTML = '<input type="text" name="reason[]" size="50" value="" class="inputbox" />';      row.appendChild(td3);            var td4 = document.createElement("td");      td4.innerHTML = '<a href="javascript:remove('+ id + ');"><img src="images/publish_x.png" border="0" alt="Remove entry" /></a>';      row.appendChild(td4);            tbody.appendChild(row);      document.adminForm.count.value = id + 1;    }        function remove(id){      var row = document.getElementById('row' + id);      row.parentNode.removeChild(row);    }        //-->    </script>    <form name="adminForm" method="post" action="index2.php">    <table class="adminheading">		<tr>			<th class="edit">Manage blocklist</th>	  </tr>	  </table>	  	  <table class="adminlist" id="blocklist">		<tr>			<th width="5">#</th>			<th width="200" class="title">IP/IP range/hostname</th>			<th class="title">Reason</th>			<th class="title">&nbsp;</th>    </tr>    <?php    for($i=0,$n=count($rows);$i<$n;$i++){      $row = $rows[$i];      ?>      <tr id="row<?php echo $i; ?>">        <td><?php echo $i + 1; ?></td>        <td><input type="text" name="block_ip[]" value="<?php echo $row[0]; ?>" class="inputbox" /></td>        <td><input type="text" name="reason[]" value="<?php echo $row[1]; ?>" size="50" class="inputbox" /></td>        <td><a href="javascript:remove(<?php echo $i; ?>);"><img src="images/publish_x.png" border="0" alt="Remove entry" /></a></td>      </tr>      <?php    }    ?>    </table>    <input type="hidden" name="count" value="<?php echo count($rows); ?>" />    <input type="hidden" name="option" value="<?php echo $option; ?>" />	  <input type="hidden" name="act" value="blocklist" />	  <input type="hidden" name="task" value="" />	  <input type="hidden" name="hidemainmenu" value="0" />	  </form>    <?php  }    /**   * Show current configuration   *   */  function showConfiguration(){    global $bl_config, $option;    ?>    <form name="adminForm" method="post" action="index2.php">    <table class="adminheading">		<tr>			<th class="cpanel" rowspan="2" nowrap>Blocklist configuration</th>	  </tr>	  </table>    <table cellpadding="4" cellspacing="0" border="0" width="100%" class="adminform">    <tr>      <td>Define the block page</td>	  </tr>	  <tr>	    <td><textarea name="bl_config[pagecontent]" class="inputbox" rows="15" cols="50"><?php echo $bl_config['pagecontent']; ?></textarea></td>	  </tr>	  </table>	  <input type="hidden" name="option" value="<?php echo $option; ?>" />	  <input type="hidden" name="act" value="config" />	  <input type="hidden" name="task" value="" />	  <input type="hidden" name="hidemainmenu" value="0" />	  </form>    <?php  }}?>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -