• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP html_build_list_table_top函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中html_build_list_table_top函数的典型用法代码示例。如果您正苦于以下问题:PHP html_build_list_table_top函数的具体用法?PHP html_build_list_table_top怎么用?PHP html_build_list_table_top使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了html_build_list_table_top函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: display_docs

function display_docs($style, $group_id)
{
    global $sys_datefmt;
    $query = "select * " . "from doc_data as d1, doc_groups as d2 " . "where d1.stateid = '" . $style . "' " . "and d2.group_id = '" . $group_id . "' " . "and d1.doc_group = d2.doc_group";
    $result = db_query($query);
    if (db_numrows($result) < 1) {
        $query = "select name " . "from doc_states " . "where stateid = " . $style . "";
        $result = db_query($query);
        $row = db_fetch_array($result);
        echo 'No ' . $row['name'] . ' docs available <p>';
    } else {
        $title_arr = array();
        $title_arr[] = 'Document ID';
        $title_arr[] = 'Name';
        $title_arr[] = 'Type';
        $title_arr[] = 'Filename';
        $title_arr[] = 'Create Date';
        $title_arr[] = 'Update Date';
        echo html_build_list_table_top($title_arr);
        $i = 0;
        while ($row = db_fetch_array($result)) {
            print "<tr bgcolor=\"" . html_get_alt_row_color($i) . "\">" . "<td>" . $row['docid'] . "</td>" . "<td><a href=\"index.php?docid=" . $row['docid'] . "&mode=docedit&group_id=" . $group_id . "\">" . $row['title'] . "</a></td>" . "<td>" . $row['type'] . "</td>" . "<td>" . $row['filename'] . "</td>" . "<td>" . date($sys_datefmt, $row['createdate']) . "</td>" . "<td>" . date($sys_datefmt, $row['updatedate']) . "</td>" . "</tr>";
            $i++;
        }
        echo '</table>';
    }
    //end else
}
开发者ID:BackupTheBerlios,项目名称:berlios,代码行数:28,代码来源:doc_utils.php


示例2: all

 function all(&$request)
 {
     $html = '';
     $servers = $this->server_factory->getAllServers();
     if (count($servers)) {
         $title_arr = array($GLOBALS['Language']->getText('admin_servers', 'all_name'), $GLOBALS['Language']->getText('admin_servers', 'all_description'), 'HTTP', 'HTTPS', $GLOBALS['Language']->getText('admin_servers', 'all_is_master'), '');
         $html .= html_build_list_table_top($title_arr);
         $row_num = 0;
         foreach ($servers as $key => $nop) {
             $html .= '<tr class="' . util_get_alt_row_color($row_num++) . '">';
             $html .= '<td><a title="' . $GLOBALS['Language']->getText('admin_servers', 'all_edit', array(htmlentities($servers[$key]->getName(), ENT_QUOTES, 'UTF-8'))) . '" href="/admin/servers/edit/' . $servers[$key]->getId() . '">' . $servers[$key]->getId() . '. ' . $servers[$key]->getName() . '</a></td>';
             $html .= '<td>' . $servers[$key]->getDescription() . '</td>';
             $html .= '<td>' . $servers[$key]->getHttp() . '</td>';
             $html .= '<td>' . $servers[$key]->getHttps() . '</td>';
             $html .= '<td style="text-align:center">' . ($servers[$key]->isMaster() ? $GLOBALS['Language']->getText('admin_servers', 'all_master') : '-') . '</td>';
             $html .= '<td>';
             if (!$servers[$key]->isMaster()) {
                 $html .= '<a title="' . $GLOBALS['Language']->getText('admin_servers', 'all_delete', array(htmlentities($servers[$key]->getName(), ENT_QUOTES, 'UTF-8'))) . '" href="/admin/servers/delete/' . $servers[$key]->getId() . '">' . $GLOBALS['Response']->getImage('ic/trash.png', array('alt' => 'Delete server')) . '</a>';
             } else {
                 $html .= '-';
             }
             $html .= '</td>';
             $html .= '</tr>';
         }
         $html .= '</table>';
     } else {
         $html .= '<p>No servers</p>';
     }
     $html .= '<p><a href="/admin/servers/add">' . $GLOBALS['Language']->getText('admin_servers', 'all_add') . '</a> ';
     if (count($servers)) {
         $html .= '| <a href="/admin/servers/master">' . $GLOBALS['Language']->getText('admin_servers', 'all_choose') . '</a>';
     }
     $html .= '</p>';
     return $html;
 }
开发者ID:nterray,项目名称:tuleap,代码行数:35,代码来源:index.php


示例3: showParseResults

 /**
  * create the html output to visualize what has been parsed
  * @param $users: array containing all the users (User Object) that are in the import file
  */
 function showParseResults($parsed_users)
 {
     global $Language;
     echo $Language->getText('project_admin_userimport', 'ready') . "<br><br>\n";
     //Display table containing the list of users to be imported
     $title_arr = array($Language->getText('project_admin_userimport', 'username'), $Language->getText('project_admin_userimport', 'mail_addr'));
     echo html_build_list_table_top($title_arr);
     $i = 0;
     foreach ($parsed_users as $current_user) {
         echo '<TR class="' . util_get_alt_row_color($i++) . '">' . "\n";
         echo '<TD>' . $current_user->getName() . '</TD>' . "\n";
         echo '<TD>' . $current_user->getEmail() . '</TD></TR>' . "\n";
     }
     echo "</TABLE>\n";
     // Add 'import'  button to confirm import
     echo '<FORM NAME="acceptimportdata" action="?" method="POST" enctype="multipart/form-data">
         <p align="left"><INPUT TYPE="SUBMIT" NAME="submit" VALUE="' . $Language->getText('project_admin_userimport', 'import') . '"></p>
         <INPUT TYPE="HIDDEN" NAME="group_id" VALUE="' . $this->group_id . '">
         <INPUT TYPE="HIDDEN" NAME="func" VALUE="import">
         <INPUT TYPE="HIDDEN" NAME="mode" VALUE="import">';
     foreach ($parsed_users as $current_user) {
         echo '<INPUT TYPE="HIDDEN" NAME="parsed_users[]" VALUE="' . $current_user->getId() . '">';
     }
     echo '</FORM><A href="/project/admin/userimport.php?group_id=' . $this->group_id . '"> [' . $Language->getText('global', 'back') . ']</A>';
 }
开发者ID:pombredanne,项目名称:tuleap,代码行数:29,代码来源:UserImportHtml.class.php


示例4: getTable

 function getTable($params)
 {
     $this->defaultUrl = $params['default_url'];
     $content = '';
     $content .= html_build_list_table_top(array($GLOBALS['Language']->getText('plugin_docman', 'view_documenttable_title'), $GLOBALS['Language']->getText('plugin_docman', 'view_documenttable_location'), $GLOBALS['Language']->getText('plugin_docman', 'admin_lock_infos_who'), $GLOBALS['Language']->getText('plugin_docman', 'admin_lock_infos_when')));
     // Get list of all locked documents in the project.
     $dPM = Docman_PermissionsManager::instance($params['group_id']);
     $lockInfos = $dPM->getLockFactory()->getProjectLockInfos($params['group_id']);
     $uH = UserHelper::instance();
     $hp = Codendi_HTMLPurifier::instance();
     require_once dirname(__FILE__) . '/../Docman_ItemFactory.class.php';
     $dIF = new Docman_ItemFactory($params['group_id']);
     $altRowClass = 0;
     foreach ($lockInfos as $row) {
         $trclass = html_get_alt_row_color($altRowClass++);
         $item = $dIF->getItemFromDb($row['item_id']);
         $parent = $dIF->getItemFromDb($item->getParentId());
         $content .= '<tr class="' . $trclass . '">';
         $content .= '<td>' . '<a href="/plugins/docman/?group_id=' . $params['group_id'] . '&action=details&id=' . $item->getId() . '">' . $item->getTitle() . '</a></td>';
         $content .= '<td>';
         if ($dIF->isRoot($parent)) {
             $content .= '</td>';
         } else {
             $content .= '<a href="' . $this->defaultUrl . '&action=show&id=' . $parent->getId() . '">' . $parent->getTitle() . '</a></td>';
         }
         $content .= '<td>' . $hp->purify($uH->getDisplayNameFromUserId($row['user_id'])) . '</td>';
         $content .= '<td>' . format_date($GLOBALS['Language']->getText('system', 'datefmt'), $row['lock_date']) . '</td>';
         $content .= '</tr>';
     }
     $content .= '</table>';
     return $content;
 }
开发者ID:pombredanne,项目名称:tuleap,代码行数:32,代码来源:Docman_View_Admin_LockInfos.class.php


示例5: getContent

 function getContent()
 {
     $content = '';
     $uh = UserHelper::instance();
     if (is_a($this->item, 'Docman_File')) {
         $content .= '<h3>' . $GLOBALS['Language']->getText('plugin_docman', 'details_history_versions') . '</h3>';
         $version_factory =& new Docman_VersionFactory();
         $approvalFactory =& Docman_ApprovalTableFactory::getFromItem($this->item);
         if ($versions = $version_factory->getAllVersionForItem($this->item)) {
             if (count($versions)) {
                 $titles = array();
                 $titles[] = $GLOBALS['Language']->getText('plugin_docman', 'details_history_versions_version');
                 $titles[] = $GLOBALS['Language']->getText('plugin_docman', 'details_history_versions_date');
                 $titles[] = $GLOBALS['Language']->getText('plugin_docman', 'details_history_versions_author');
                 $titles[] = $GLOBALS['Language']->getText('plugin_docman', 'details_history_versions_label');
                 $titles[] = $GLOBALS['Language']->getText('plugin_docman', 'details_history_versions_changelog');
                 $titles[] = $GLOBALS['Language']->getText('plugin_docman', 'details_history_versions_approval');
                 $titles[] = $GLOBALS['Language']->getText('plugin_docman', 'details_history_versions_delete_version');
                 $content .= html_build_list_table_top($titles, false, false, false);
                 $odd_even = array('boxitem', 'boxitemalt');
                 $i = 0;
                 foreach ($versions as $key => $nop) {
                     $download = Docman_View_View::buildUrl($this->url, array('action' => 'show', 'id' => $this->item->getId(), 'version_number' => $versions[$key]->getNumber()));
                     $delete = Docman_View_View::buildUrl($this->url, array('action' => 'confirmDelete', 'id' => $this->item->getId(), 'version' => $versions[$key]->getNumber()));
                     $user = $versions[$key]->getAuthorId() ? $uh->getDisplayNameFromUserId($versions[$key]->getAuthorId()) : $GLOBALS['Language']->getText('plugin_docman', 'details_history_anonymous');
                     $content .= '<tr class="' . $odd_even[$i++ % count($odd_even)] . '">';
                     $content .= '<td align="center"><a href="' . $download . '">' . $versions[$key]->getNumber() . '</a></td>';
                     $content .= '<td>' . html_time_ago($versions[$key]->getDate()) . '</td>';
                     $content .= '<td>' . $this->hp->purify($user) . '</td>';
                     $content .= '<td>' . $this->hp->purify($versions[$key]->getLabel()) . '</td>';
                     $content .= '<td>' . $this->hp->purify($versions[$key]->getChangelog(), CODENDI_PURIFIER_LIGHT) . '</td>';
                     $table = $approvalFactory->getTableFromVersion($versions[$key]);
                     if ($table != null) {
                         $appTable = Docman_View_View::buildUrl($this->url, array('action' => 'details', 'section' => 'approval', 'id' => $this->item->getId(), 'version' => $versions[$key]->getNumber()));
                         $content .= '<td align="center"><a href="' . $appTable . '">' . ($titles[] = $GLOBALS['Language']->getText('plugin_docman', 'details_history_versions_approval_show') . '</a></td>');
                     } else {
                         $content .= '<td></td>';
                     }
                     $content .= '<td align="center"><a href="' . $delete . '"><img src="' . util_get_image_theme("ic/trash.png") . '" height="16" width="16" border="0"></a></td>';
                     $content .= '</tr>';
                 }
                 $content .= '</table>';
             } else {
                 $content .= '<div>' . $GLOBALS['Language']->getText('plugin_docman', 'details_history_versions_no') . '</div>';
             }
         } else {
             $content .= '<div>' . $GLOBALS['Language']->getText('plugin_docman', 'details_history_versions_error') . '</div>';
         }
     }
     if ($this->logger) {
         $content .= $this->logger->fetchLogsForItem($this->item->getId(), $this->display_access_logs);
     }
     return $content;
 }
开发者ID:nterray,项目名称:tuleap,代码行数:54,代码来源:Docman_View_ItemDetailsSectionHistory.class.php


示例6: getTableHeader

 private function getTableHeader()
 {
     $title = array();
     $title[] = $GLOBALS['Language']->getText('plugin_statistics', 'project_name');
     $title[] = $GLOBALS['Language']->getText('plugin_statistics', 'current_size');
     $title[] = $GLOBALS['Language']->getText('plugin_statistics', 'quota');
     $title[] = $GLOBALS['Language']->getText('plugin_statistics', 'exceeding_size');
     $title[] = $GLOBALS['Language']->getText('plugin_statistics', 'warn_administrators');
     $table_header = html_build_list_table_top($title);
     return $table_header;
 }
开发者ID:pombredanne,项目名称:tuleap,代码行数:11,代码来源:ProjectsOverQuotaTableHeaderPresenter.class.php


示例7: getContent

 function getContent()
 {
     $html = '';
     $dwItemFactory = $this->getDocmanWatermarkItemFactory();
     $watermarkingIsDisabled = $dwItemFactory->isWatermarkingDisabled($this->item->getId());
     // Status
     if ($watermarkingIsDisabled) {
         $status = '<strong>' . $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_watermarking_disabled') . '</strong>';
     } else {
         $status = $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_watermarking_enabled');
     }
     $html .= '<p>' . $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_watermarking_status', array($status)) . '</p>';
     // About section
     $html .= '<h2>' . $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_about_title') . '</h2>';
     $html .= '<p>' . $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_disclamer_pdf') . '</p>';
     // Disable/enable section
     $user = $this->getUserManager()->getCurrentUser();
     $dPm = $this->getDocman_PermissionsManager($this->item->getGroupId());
     if ($dPm->userCanManage($user, $this->item->getId())) {
         $html .= '<h2>' . $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_toggle_title') . '</h2>';
         $html .= '<p>' . $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_watermarking_desc') . '</p>';
         $html .= '<p>' . $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_watermarking_clicktoproceed') . '</p>';
         $html .= '<form method="post" action="' . $this->url . '&item_id=' . $this->item->getId() . '&action=docmanwatermark_toggle_item">';
         if ($watermarkingIsDisabled) {
             $html .= '<input type="submit" name="enable_watermarking" value="' . $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_watermarking_enableit') . '" />';
         } else {
             $html .= '<input type="submit" name="disable_watermarking" value="' . $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_watermarking_disableit') . '" />';
         }
         $html .= '</form>';
     }
     // History
     $html .= '<h2>' . $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_history_title') . '</h2>';
     $dwLog = $this->getDocmanWatermark_Log();
     $dar = $dwLog->getLog($this->item);
     if ($dar && $dar->rowCount() > 0) {
         $uh = UserHelper::instance();
         $hp = Codendi_HTMLPurifier::instance();
         $titles = array($GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_history_when'), $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_history_who'), $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_history_what'));
         $html .= html_build_list_table_top($titles, false, false, false);
         $altColor = 0;
         foreach ($dar as $logEntry) {
             $html .= '<tr class="' . html_get_alt_row_color($altColor++) . '">';
             $html .= '<td>' . util_timestamp_to_userdateformat($logEntry['time']) . '</td>';
             $html .= '<td>' . $hp->purify($uh->getDisplayNameFromUserId($logEntry['who'])) . '</td>';
             $html .= '<td>' . ($logEntry['watermarked'] == 0 ? $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_history_desactivate') : $GLOBALS['Language']->getText('plugin_docmanwatermark', 'details_history_activate')) . '</td>';
             $html .= '</tr>';
         }
         $html .= '</table>';
     }
     return $html;
 }
开发者ID:pombredanne,项目名称:tuleap,代码行数:51,代码来源:DocmanWatermark_View_ItemDetailsSectionWatermarking.class.php


示例8: snippet_show_package_snippets

function snippet_show_package_snippets($version)
{
    global $Language;
    $version = (int) $version;
    //show the latest version
    $sql = "SELECT snippet.snippet_id, snippet_package_item.snippet_version_id, snippet_version.version,snippet.name,user.user_name, snippet_version.filesize " . "FROM snippet,snippet_version,snippet_package_item,user " . "WHERE snippet.snippet_id=snippet_version.snippet_id " . "AND user.user_id=snippet_version.submitted_by " . "AND snippet_version.snippet_version_id=snippet_package_item.snippet_version_id " . "AND snippet_package_item.snippet_package_version_id='" . db_ei($version) . "'";
    $result = db_query($sql);
    $rows = db_numrows($result);
    echo '
	<P>
	<H3>' . $Language->getText('snippet_add_snippet_to_package', 's_in_p') . '</H3>
	<P>';
    $title_arr = array();
    $title_arr[] = $Language->getText('snippet_utils', 'version_id');
    $title_arr[] = $Language->getText('snippet_details', 's_version');
    $title_arr[] = $Language->getText('snippet_browse', 'title');
    $title_arr[] = $Language->getText('snippet_details', 'author');
    echo html_build_list_table_top($title_arr, $links_arr);
    if (!$result || $rows < 1) {
        echo db_error();
        echo '
			<TR><TD COLSPAN="4"><H3>' . $Language->getText('snippet_add_snippet_to_package', 'no_s_in_p') . '</H3></TD></TR>';
    } else {
        //get the newest version, so we can display it's code
        $newest_version = db_result($result, 0, 'snippet_version_id');
        for ($i = 0; $i < $rows; $i++) {
            echo '
			<TR class="' . util_get_alt_row_color($i) . '">
                            <TD><A HREF="/snippet/detail.php?type=snippet&id=' . db_result($result, $i, 'snippet_id') . '"><b><center>' . db_result($result, $i, 'snippet_version_id') . '</center></b></A></TD>
                            <TD>';
            echo '<A HREF="/snippet/download.php?type=snippet&id=' . db_result($result, $i, 'snippet_version_id') . '"><b><center>' . db_result($result, $i, 'version') . '</b></A>';
            // For uploaded files, the user can choose between view or display the code snippet
            if (db_result($result, $i, 'filesize') != 0) {
                // View link : the file is forced to be displayed as a text
                echo '&nbsp;<a href="/snippet/download.php?mode=view&type=snippet&id=' . db_result($result, $i, 'snippet_version_id') . '">';
                echo '<img src="' . util_get_image_theme("ic/view.png") . '" border="0" alt="' . $Language->getText('snippet_details', 'view') . '" title="' . $Language->getText('snippet_details', 'view') . '"></a>';
                // Download link : the file is forced to be downloaded
                echo '&nbsp;<a href="/snippet/download.php?mode=download&type=snippet&id=' . db_result($result, $i, 'snippet_version_id') . '">';
                echo '<img src="' . util_get_image_theme("ic/download.png") . '" border="0" alt="' . $Language->getText('snippet_details', 'download') . '" title="' . $Language->getText('snippet_details', 'download') . '"></a>';
            }
            $user = UserManager::instance()->getUserByUserName(db_result($result, $i, 'user_name'));
            echo '</center></TD>
                             <TD>' . db_result($result, $i, 'name') . '</TD><TD>' . UserHelper::instance()->getLinkOnUser($user) . '</TD></TR>';
        }
    }
    echo '</TABLE>';
}
开发者ID:pombredanne,项目名称:tuleap,代码行数:47,代码来源:snippet_utils.php


示例9: getMetadataTable

 /**
  * List the available metadata
  */
 function getMetadataTable($mdIter, $groupId, $defaultUrl)
 {
     $content = '';
     $mdFactory = new Docman_MetadataFactory($groupId);
     $content .= '<h3>' . $GLOBALS['Language']->getText('plugin_docman', 'admin_metadata_list_title') . '</h3>' . "\n";
     $content .= $GLOBALS['Language']->getText('plugin_docman', 'admin_metadata_instructions') . "\n";
     $content .= html_build_list_table_top(array($GLOBALS['Language']->getText('plugin_docman', 'admin_metadata_list_name'), $GLOBALS['Language']->getText('plugin_docman', 'admin_metadata_list_descr'), $GLOBALS['Language']->getText('plugin_docman', 'admin_metadata_list_status'), $GLOBALS['Language']->getText('plugin_docman', 'admin_metadata_list_delete')));
     $altRowClass = 0;
     $mdIter->rewind();
     while ($mdIter->valid()) {
         $md =& $mdIter->current();
         $canDelete = false;
         if ($mdFactory->isRealMetadata($md->getLabel())) {
             $canDelete = true;
         }
         $trclass = html_get_alt_row_color($altRowClass++);
         $content .= '<tr class="' . $trclass . '">';
         $nameUrl = $this->buildUrl($defaultUrl, array('action' => 'admin_md_details', 'md' => $md->getLabel()));
         $nameHref = '<a href="' . $nameUrl . '">' . $this->hp->purify($md->getName()) . '</a>';
         $content .= '<td>' . $nameHref . '</td>';
         $content .= '<td>' . $this->hp->purify($md->getDescription()) . '</td>';
         $content .= '<td>';
         if ($md->isRequired()) {
             $content .= "-";
         } else {
             if ($md->isUsed()) {
                 $content .= "Used";
             } else {
                 $content .= "Unused";
             }
         }
         $content .= '</td>';
         $trash = '-';
         if ($canDelete) {
             $link = $this->buildUrl($defaultUrl, array('action' => 'admin_delete_metadata', 'md' => $md->getLabel()));
             $warn = $GLOBALS['Language']->getText('plugin_docman', 'admin_metadata_list_delete_warn', $this->hp->purify($md->getName()));
             $alt = $GLOBALS['Language']->getText('plugin_docman', 'admin_metadata_list_delete_alt', $this->hp->purify($md->getName()));
             $trash = html_trash_link($link, $warn, $alt);
         }
         $content .= '<td>' . $trash . '</td>';
         $content .= '</tr>' . "\n";
         $mdIter->next();
     }
     $content .= '</table>' . "\n";
     return $content;
 }
开发者ID:pombredanne,项目名称:tuleap,代码行数:49,代码来源:Docman_View_Admin_Metadata.class.php


示例10: ShowResultsGroupSurveys

function ShowResultsGroupSurveys($result)
{
    global $group_id, $Language;
    $survey =& SurveySingleton::instance();
    $rows = db_numrows($result);
    $cols = db_numfields($result);
    $title_arr = array();
    $title_arr[] = $Language->getText('survey_index', 's_id');
    $title_arr[] = $Language->getText('survey_index', 's_tit');
    echo html_build_list_table_top($title_arr);
    for ($j = 0; $j < $rows; $j++) {
        echo "<tr class=\"" . html_get_alt_row_color($j) . "\">\n";
        echo "<TD><A HREF=\"survey.php?group_id={$group_id}&survey_id=" . db_result($result, $j, "survey_id") . "\">" . db_result($result, $j, "survey_id") . "</TD>";
        printf("<TD>%s</TD>\n", $survey->getSurveyTitle(db_result($result, $j, 'survey_title')));
        echo "</tr>";
    }
    echo "</table>";
    //</TD></TR></TABLE>");
}
开发者ID:nterray,项目名称:tuleap,代码行数:19,代码来源:index.php


示例11: getReferencesTable

function getReferencesTable($groupId)
{
    $html = '';
    $html .= '<h3>' . $GLOBALS['Language']->getText('project_showdetails', 'references') . '</h3>';
    $title_arr[] = $GLOBALS['Language']->getText('project_reference', 'r_keyword');
    $title_arr[] = $GLOBALS['Language']->getText('project_reference', 'r_desc');
    $title_arr[] = $GLOBALS['Language']->getText('project_reference', 'r_link');
    $html .= html_build_list_table_top($title_arr, false, false, true);
    $referenceManager =& ReferenceManager::instance();
    $references =& $referenceManager->getReferencesByGroupId($groupId);
    // References are sorted by scope first
    $row_num = 0;
    foreach ($references as $ref) {
        $html .= getReferenceRow($ref, $row_num);
        $row_num++;
    }
    $html .= '</table>';
    return $html;
}
开发者ID:nterray,项目名称:tuleap,代码行数:19,代码来源:showdetails.php


示例12: getTable

 function getTable($params)
 {
     $html = '';
     // Get root
     $itemFactory = new Docman_ItemFactory($params['group_id']);
     $rootItem = $itemFactory->getRoot($params['group_id']);
     $nbItemsFound = 0;
     $itemIterator =& $itemFactory->getItemList($rootItem->getId(), $nbItemsFound, array('user' => $params['user'], 'ignore_collapse' => true, 'obsolete_only' => true));
     $table = html_build_list_table_top(array('Title', 'Obsolete date'));
     $altRowClass = 0;
     $itemIterator->rewind();
     while ($itemIterator->valid()) {
         $item =& $itemIterator->current();
         $type = $itemFactory->getItemTypeForItem($item);
         if ($type != PLUGIN_DOCMAN_ITEM_TYPE_FOLDER) {
             $trclass = html_get_alt_row_color($altRowClass++);
             $table .= "<tr class=\"" . $trclass . "\">\n";
             // Name
             $docmanIcons =& $this->_getDocmanIcons($params);
             $icon_src = $docmanIcons->getIconForItem($item, $params);
             $icon = '<img src="' . $icon_src . '" class="docman_item_icon" />';
             $table .= "<td>";
             $table .= '<span style="white-space: nowrap;">';
             $table .= $icon;
             $url = $this->buildActionUrl($params, array('action' => 'details', 'id' => $item->getId()), false, true);
             $table .= '<a href="' . $url . '">';
             $table .= htmlentities($item->getTitle(), ENT_QUOTES, 'UTF-8');
             $table .= '</a>';
             $table .= '</span>';
             $table .= "</td>\n";
             // Obsolete date
             $table .= "<td>";
             $table .= format_date("Y-m-j", $item->getObsolescenceDate());
             $table .= "</td>\n";
             $table .= "</tr>\n";
         }
         $itemIterator->next();
     }
     $table .= "</table>\n";
     $html = $table;
     return $html;
 }
开发者ID:pombredanne,项目名称:tuleap,代码行数:42,代码来源:Docman_View_Admin_Obsolete.class.php


示例13: ShowResultComments

 function ShowResultComments($result)
 {
     global $survey_id;
     $rows = db_numrows($result);
     $cols = db_numfields($result);
     echo "<h3>{$rows} Found</h3>";
     $title_arr = array();
     $title_arr[] = 'User ID';
     $title_arr[] = 'Response';
     echo html_build_list_table_top($title_arr);
     for ($j = 0; $j < $rows; $j++) {
         echo "<tr BGCOLOR=\"" . html_get_alt_row_color($j) . "\">\n";
         for ($i = 0; $i < $cols; $i++) {
             printf("<TD>%s</TD>\n", db_result($result, $j, $i));
         }
         echo "</tr>";
     }
     echo "</table>";
     //</TD></TR></TABLE>";
 }
开发者ID:BackupTheBerlios,项目名称:berlios,代码行数:20,代码来源:show_results_comments.php


示例14: ShowResultsGroupSurveys

 function ShowResultsGroupSurveys($result)
 {
     global $group_id;
     $rows = db_numrows($result);
     $cols = db_numfields($result);
     $title_arr = array();
     $title_arr[] = 'Survey ID';
     $title_arr[] = 'Survey Title';
     echo html_build_list_table_top($title_arr);
     for ($j = 0; $j < $rows; $j++) {
         echo "<tr BGCOLOR=\"" . html_get_alt_row_color($j) . "\">\n";
         echo "<TD><A HREF=\"survey.php?group_id={$group_id}&survey_id=" . db_result($result, $j, "survey_id") . "\">" . sprintf("%06d", db_result($result, $j, "survey_id")) . "</A></TD>";
         for ($i = 1; $i < $cols; $i++) {
             printf("<TD WIDTH=\"99%%\">%s</TD>\n", db_result($result, $j, $i));
         }
         echo "</tr>";
     }
     echo "</table>";
     //</TD></TR></TABLE>");
 }
开发者ID:BackupTheBerlios,项目名称:berlios,代码行数:20,代码来源:index.php


示例15: showAvailableReports

 function showAvailableReports()
 {
     $hp = Codendi_HTMLPurifier::instance();
     $g = $GLOBALS['ath']->getGroup();
     $group_id = $g->getID();
     $atid = $GLOBALS['ath']->getID();
     $reports = $this->grf->getReports_ids();
     echo '<H2>' . $GLOBALS['Language']->getText('plugin_graphontrackers_include_report', 'tracker') . ' \'<a href="/tracker/admin/?group_id=' . $group_id . '&atid=' . $atid . '">' . $hp->purify($GLOBALS['ath']->getName()) . '</a>\'' . $GLOBALS['Language']->getText('plugin_graphontrackers_include_report', 'report_admin') . '</H2>';
     if ($reports) {
         // Loop through the list of all graphic reports
         $title_arr = array();
         $title_arr[] = $GLOBALS['Language']->getText('plugin_graphontrackers_include_report', 'report_name');
         $title_arr[] = $GLOBALS['Language']->getText('plugin_graphontrackers_include_report', 'desc');
         $title_arr[] = $GLOBALS['Language']->getText('plugin_graphontrackers_include_report', 'scope');
         $title_arr[] = $GLOBALS['Language']->getText('plugin_graphontrackers_include_report', 'delete');
         echo '<p>' . $GLOBALS['Language']->getText('plugin_graphontrackers_include_report', 'mod');
         echo html_build_list_table_top($title_arr);
         for ($i = 0; $i < count($reports); $i++) {
             $r = new GraphOnTrackers_Report($reports[$i]);
             echo '<TR class="' . util_get_alt_row_color($i) . '"><TD>';
             if ($r->getScope() == 'S' || !$GLOBALS['ath']->userIsAdmin() && $r->getScope() == 'P') {
                 echo $hp->purify($r->getName());
             } else {
                 echo '<A HREF="/tracker/admin/?func=reportgraphic&group_id=' . $group_id . '&report_graphic_id=' . $r->getId() . '&atid=' . $GLOBALS['ath']->getID() . '">' . $hp->purify($r->getName()) . '</A>';
             }
             echo "</td>" . "\n<td>" . $hp->purify($r->getDescription(), CODENDI_PURIFIER_BASIC) . '</td>' . "\n<td align=\"center\">" . $hp->purify($r->getScopeLabel($r->getScope())) . '</td>' . "\n<td align=\"center\">";
             if ($r->getScope() == 'S' || !$GLOBALS['ath']->userIsAdmin() && $r->getScope() == 'P') {
                 echo '-';
             } else {
                 $delete_report_text = $GLOBALS['Language']->getText('plugin_graphontrackers_include_report', 'delete_report', $r->getName());
                 $delete_report_text_js = $hp->purify($delete_report_text, CODENDI_PURIFIER_JS_QUOTE);
                 echo '<A HREF="/tracker/admin/?func=reportgraphic' . '&report_graphic_id=' . $r->getId() . '&group_id=' . $group_id . '&atid=' . $atid . '&delete_report_graphic=1"' . '" onClick="return confirm(\'' . $delete_report_text_js . '\')">' . '<img src="' . util_get_image_theme("ic/trash.png") . '" border="0"></A>';
             }
             echo '</td></tr>';
         }
         echo '</TABLE>';
     } else {
         echo '<p><h3>' . $GLOBALS['Language']->getText('plugin_graphontrackers_include_report', 'no_rep_def') . '</h3>';
     }
     echo '<P> ' . $GLOBALS['Language']->getText('plugin_graphontrackers_include_report', 'create_report', array('/tracker/admin/?func=reportgraphic&group_id=' . $group_id . '&atid=' . $atid . '&new_report_graphic=1'));
 }
开发者ID:pombredanne,项目名称:tuleap,代码行数:41,代码来源:GraphicEngineHtml.class.php


示例16: fetch

 function fetch($id, $params)
 {
     $html = '';
     if ($params['user_can_manage']) {
         $titles = array();
         $titles[] = $GLOBALS['Language']->getText('plugin_docman', 'details_permissions_ugroups');
         $titles[] = $GLOBALS['Language']->getText('plugin_docman', 'details_permissions_perms');
         $html .= html_build_list_table_top($titles, false, false, false);
         $odd_even = array('boxitem', 'boxitemalt');
         $i = 0;
         $ugroups = permission_get_ugroups_permissions($params['group_id'], $id, array('PLUGIN_DOCMAN_READ', 'PLUGIN_DOCMAN_WRITE', 'PLUGIN_DOCMAN_MANAGE'), false);
         ksort($ugroups);
         foreach ($ugroups as $ugroup) {
             $html .= '<tr class="' . $odd_even[$i++ % count($odd_even)] . '">';
             $html .= '<td>' . $ugroup['ugroup']['name'] . '</td>';
             $html .= '<td style="text-align:center;"><select name="permissions[' . $ugroup['ugroup']['id'] . ']">';
             $html .= '<option value="100">-</option>';
             $perms = array('PLUGIN_DOCMAN_READ', 'PLUGIN_DOCMAN_WRITE', 'PLUGIN_DOCMAN_MANAGE');
             $i = 1;
             foreach ($perms as $perm) {
                 if (isset($params['force_permissions'][$ugroup['ugroup']['id']])) {
                     $selected = $params['force_permissions'][$ugroup['ugroup']['id']] == $i ? 'selected="selected"' : '';
                 } else {
                     $selected = isset($ugroup['permissions'][$perm]) ? 'selected="selected"' : '';
                 }
                 $html .= '<option value="' . $i++ . '" ' . $selected . '>' . permission_get_name($perm) . '</option>';
             }
             $html .= '</select></td>';
             $html .= '</tr>';
         }
         $html .= '</table>';
     } else {
         $html .= $GLOBALS['Language']->getText('plugin_docman', 'new_same_perms_as_parent');
         // Will be created with the same permissions than its parent.
         $html .= $GLOBALS['Language']->getText('plugin_docman', 'new_need_to_be_manager');
         // <br />You need Manage permission to define permissions.
     }
     return $html;
 }
开发者ID:pombredanne,项目名称:tuleap,代码行数:39,代码来源:Docman_View_PermissionsForItem.class.php


示例17: displayListeningUsers

 /**
  * Show list of people monitoring the document directly or indirectly by monitoring one of the parents and its subitems
  *
  * @param Integer $itemId Id of the document
  *
  * @return String
  */
 function displayListeningUsers($itemId)
 {
     $dpm = Docman_PermissionsManager::instance($this->item->getGroupId());
     $userHelper = new UserHelper();
     $um = UserManager::instance();
     $content = '';
     if ($dpm->userCanManage($um->getCurrentUser(), $itemId)) {
         $listeners = $this->notificationsManager->getListeningUsers($this->item);
         if (!empty($listeners)) {
             $content .= '<fieldset><legend>' . $GLOBALS['Language']->getText('plugin_docman', 'details_listeners') . '</legend>';
             $content .= '<form name="remove_monitoring" method="POST" action="">';
             $content .= '<input type="hidden" name="action" value="remove_monitoring" />';
             $content .= '<table><tr><td>';
             $content .= html_build_list_table_top(array($GLOBALS['Language']->getText('people_viewprofile', 'user_name'), $GLOBALS['Language']->getText('plugin_docman', 'details_notifications_monitored_doc'), $GLOBALS['Language']->getText('docman_doc_utils', 'delete_ask')), false, false, false);
             $rowBgColor = 0;
             $hp = Codendi_HTMLPurifier::instance();
             foreach ($listeners as $userId => $item) {
                 $content .= '<tr class="' . html_get_alt_row_color(++$rowBgColor) . '">';
                 $user = $um->getUserById($userId);
                 $content .= '<td>' . $userHelper->getDisplayName($user->getName(), $user->getRealName()) . '</td>';
                 $content .= '<td>' . $item->getTitle() . '</td><td>';
                 if ($this->item == $item) {
                     $content .= '<input type="checkbox" value="' . $userId . '" name="listeners_to_delete[]">';
                 } else {
                     $content .= '<input type="checkbox" value="' . $userId . '" name="listeners_to_delete[]" disabled="disabled">';
                 }
                 $content .= '</td></tr>';
             }
             // TODO : ask user if he wants or not to notify the users he remove
             // TODO : We may ask him also if his name will appear as the guilty one or not
             $content .= '<td colspan="2"><input type="submit" value="' . $GLOBALS['Language']->getText('plugin_docman', 'action_delete') . '"></td></tr>';
             $content .= '</tbody></table></form>';
             $content .= '</td><td><div class="docman_help">' . $GLOBALS['Language']->getText('plugin_docman', 'details_notifications_help') . '</div></td></tr>';
         }
         $content .= $this->addListeningUser($itemId);
         $content .= '</table></fieldset>';
     }
     return $content;
 }
开发者ID:rinodung,项目名称:tuleap,代码行数:46,代码来源:Docman_View_ItemDetailsSectionNotifications.class.php


示例18: ShowResultsEditQuestion


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP html_build_select_box函数代码示例发布时间:2022-05-15
下一篇:
PHP html_btn函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap