本文整理匯總了PHP中Goteo\Library\Text::filters方法的典型用法代碼示例。如果您正苦於以下問題:PHP Text::filters方法的具體用法?PHP Text::filters怎麽用?PHP Text::filters使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類Goteo\Library\Text
的用法示例。
在下文中一共展示了Text::filters方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: isset
*
* You should have received a copy of the GNU Affero General Public License
* along with Goteo. If not, see <http://www.gnu.org/licenses/agpl.txt>.
*
*/
use Goteo\Library\Text;
$bodyClass = 'admin';
// paginacion
require_once 'library/pagination/pagination.php';
// no cache para textos
define('GOTEO_ADMIN_NOCACHE', true);
$filter = $this['filter'];
$data = Text::getAll($this['filters'], $_SESSION['translator_lang']);
$pagedResults = new \Paginated($data, 20, isset($_GET['page']) ? $_GET['page'] : 1);
// valores de filtro
$idfilters = Text::filters();
$groups = Text::groups();
// metemos el todos
\array_unshift($idfilters, 'Todos los textos');
\array_unshift($groups, 'Todas las agrupaciones');
$filters = array('idfilter' => array('label' => 'Filtrar por tipo:', 'type' => 'select', 'options' => $idfilters, 'value' => $this['filters']['idfilter']), 'group' => array('label' => 'Filtrar por agrupación:', 'type' => 'select', 'options' => $groups, 'value' => $this['filters']['group']), 'text' => array('label' => 'Buscar texto:', 'type' => 'input', 'options' => null, 'value' => $this['filters']['text']));
?>
<!-- Filtro -->
<?php
if (!empty($filters)) {
?>
<div class="widget board">
<form id="filter-form" action="/translate/texts/list/<?php
echo $filter;
?>
" method="get">