本文整理汇总了PHP中Projects::languages方法的典型用法代码示例。如果您正苦于以下问题:PHP Projects::languages方法的具体用法?PHP Projects::languages怎么用?PHP Projects::languages使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Projects
的用法示例。
在下文中一共展示了Projects::languages方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: project_index
/**
* Output the Project Index interface.
*
* @since 1.0.0
*
* @global string $plugin_page The slug of the current admin page.
*/
protected static function project_index()
{
global $plugin_page;
$projects = new Projects();
$projects->scan();
?>
<div class="tablenav top">
<div class="alignleft actions">
<label for="filter_by_type" class="screen-reader-text"><?php
_e('Filter by type', 'pomo-editor');
?>
</label>
<select id="filter_by_type" class="pomoeditor-filter">
<option value=""><?php
_e('All types', 'pomo-editor');
?>
</option>
<?php
foreach ($projects->types() as $type => $label) {
?>
<option value="<?php
echo $type;
?>
"><?php
echo $label;
?>
</option>
<?php
}
?>
</select>
<label for="filter_by_package" class="screen-reader-text"><?php
_e('Filter by package', 'pomo-editor');
?>
</label>
<select id="filter_by_package" class="pomoeditor-filter">
<option value=""><?php
_e('All packages', 'pomo-editor');
?>
</option>
<?php
foreach ($projects->packages() as $package => $label) {
?>
<option value="<?php
echo $package;
?>
"><?php
echo $label;
?>
</option>
<?php
}
?>
</select>
<label for="filter_by_language" class="screen-reader-text"><?php
_e('Filter by type', 'pomo-editor');
?>
</label>
<select id="filter_by_language" class="pomoeditor-filter">
<option value=""><?php
_e('All languages', 'pomo-editor');
?>
</option>
<?php
foreach ($projects->languages() as $language => $label) {
?>
<option value="<?php
echo $language;
?>
"><?php
echo $label;
?>
</option>
<?php
}
?>
</select>
<label>
<input type="checkbox" id="filter_modded_only" class="pomoeditor-filter" />
<?php
_e('Show Edited Files Only', 'pomo-editor');
?>
</label>
</div>
</div>
<table id="pomoeditor_projects" class="wp-list-table widefat fixed striped">
<thead>
<tr>
<th class="manage-column column-pmeproject-file"><?php
_e('File', 'pomo-editor');
?>
</th>
//.........这里部分代码省略.........