本文整理汇总了PHP中util_get_dir_image_theme函数的典型用法代码示例。如果您正苦于以下问题:PHP util_get_dir_image_theme函数的具体用法?PHP util_get_dir_image_theme怎么用?PHP util_get_dir_image_theme使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了util_get_dir_image_theme函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: getContent
function getContent()
{
$html = '';
$html .= '<script type="text/javascript">';
$html .= "\n function plugin_docman_approval_toggle(what, save) {\n if (\$(what).visible()) {\n \$(what+'_icon').src = '" . util_get_dir_image_theme() . "pointer_right.png';\n \$(what).hide();\n if (save) {\n new Ajax.Request('/plugins/docman/?action='+what+'&hide=1');\n }\n } else {\n \$(what+'_icon').src = '" . util_get_dir_image_theme() . "pointer_down.png';\n \$(what).show();\n if (save) {\n new Ajax.Request('/plugins/docman/?action='+what+'&hide=0');\n }\n }\n }\n </script>";
$html .= $this->_getReviews(true);
$html .= $this->_getReviews(false);
return $html;
}
开发者ID:pombredanne,项目名称:tuleap,代码行数:9,代码来源:Docman_Widget_MyDocman.class.php
示例2: notifiedPeople
private function notifiedPeople()
{
$html = '';
$html .= '<label for="add_mail">' . $GLOBALS['Language']->getText('plugin_git', 'add_mail_title') . '</label>';
$html .= '<textarea id="add_mail" name="add_mail" class="text"></textarea>';
$html .= '<p class="help-block">' . $GLOBALS['Language']->getText('plugin_git', 'add_mail_msg') . '</p>';
$js = "new UserAutoCompleter('add_mail', '" . util_get_dir_image_theme() . "', true);";
$GLOBALS['Response']->includeFooterJavascriptSnippet($js);
return $html;
}
开发者ID:pombredanne,项目名称:tuleap,代码行数:10,代码来源:Notification.class.php
示例3: html_image
function html_image($src, $args, $display = 1)
{
global $img_size;
$return = '<IMG src="' . util_get_dir_image_theme() . $src . '"';
$purifier = Codendi_HTMLPurifier::instance();
reset($args);
while (list($k, $v) = each($args)) {
$return .= ' ' . $purifier->purify($k) . '="' . $purifier->purify($v) . '"';
}
// ## insert a border tag if there isn't one
if (!isset($args['border']) || !$args['border']) {
$return .= " border=0";
}
// ## if no height AND no width tag, insert em both
if ((!isset($args['height']) || !$args['height']) && (!isset($args['width']) || !$args['width'])) {
/* Check to see if we've already fetched the image data */
if ($img_size) {
if ((!isset($img_size[$src]) || !$img_size[$src]) && is_file($GLOBALS['sys_urlroot'] . util_get_dir_image_theme() . $src)) {
$img_size[$src] = @getimagesize($GLOBALS['sys_urlroot'] . util_get_dir_image_theme() . $src);
}
} else {
if (is_file($GLOBALS['sys_urlroot'] . util_get_dir_image_theme() . $src)) {
$img_size[$src] = @getimagesize($GLOBALS['sys_urlroot'] . util_get_dir_image_theme() . $src);
}
}
$return .= ' width="' . $img_size[$src][0] . '" height="' . $img_size[$src][1] . '"';
}
// ## insert alt tag if there isn't one
if (!isset($args['alt']) || !$args['alt']) {
$return .= ' alt="' . $purifier->purify($src) . '"';
}
$return .= '>';
if ($display) {
print $return;
} else {
return $return;
}
}
开发者ID:uniteddiversity,项目名称:tuleap,代码行数:38,代码来源:html.php
示例4: project_admin_add_user_form
/**
* Display form elements to bind project members and an LDAP group
*
* @param array $params
*
* @return void
*/
function project_admin_add_user_form(array $params)
{
if ($this->isLDAPGroupsUsageEnabled()) {
$projectMembersManager = new LDAP_ProjectGroupManager($this->getLdap());
$ldapGroup = $projectMembersManager->getLdapGroupByGroupId($params['groupId']);
if ($ldapGroup) {
$groupName = $ldapGroup->getCommonName();
} else {
$groupName = '';
}
$html = '<hr />' . PHP_EOL;
$html .= '<form method="post" class="link-with-ldap" action="' . $this->getPluginPath() . '/admin.php?group_id=' . $params['groupId'] . '">' . PHP_EOL;
$html .= '<div class="control-group">
<label class="control-label" for="add_user">' . $GLOBALS['Language']->getText('plugin_ldap', 'project_admin_add_ugroup') . '</label>
<div class="controls">
<input type="text" value="' . $groupName . '" name="ldap_group" id="project_admin_add_ldap_group" size="60" />
</div>
</div>';
$html .= '<label class="checkbox" for="preserve_members"><input type="checkbox" id="preserve_members" name="preserve_members" checked="checked" />' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_preserve_members_option') . ' (' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_preserve_members_info') . ')</label>' . PHP_EOL;
$html .= '<br />' . PHP_EOL;
$html .= '<input type="submit" name="delete" value="' . $GLOBALS['Language']->getText('global', 'btn_delete') . '" />' . PHP_EOL;
$html .= '<input type="submit" name="check" value="' . $GLOBALS['Language']->getText('global', 'btn_update') . '" />' . PHP_EOL;
$html .= '</form>' . PHP_EOL;
$GLOBALS['Response']->includeFooterJavascriptFile($this->getPluginPath() . '/scripts/autocomplete.js');
$js = "new LdapGroupAutoCompleter('project_admin_add_ldap_group',\n '" . $this->getPluginPath() . "',\n '" . util_get_dir_image_theme() . "',\n 'project_admin_add_ldap_group',\n false);";
$GLOBALS['Response']->includeFooterJavascriptSnippet($js);
echo $html;
}
}
开发者ID:pombredanne,项目名称:tuleap,代码行数:36,代码来源:ldapPlugin.class.php
示例5: _adminPage_UpdateLinkType
function _adminPage_UpdateLinkType($group_id, $link_type_id)
{
global $HTML, $Language;
if (isset($link_type_id)) {
$db_res = db_query("SELECT link_type_id, group_id, name,\n reverse_name, description, uri_plus\n FROM plugin_projectlinks_link_type\n WHERE ((group_id = " . db_ei($group_id) . ")\n AND (link_type_id = " . db_ei($link_type_id) . "));");
if (db_numrows($db_res) != 1) {
exit_error("invalid data", "2.2");
// unexpected - no i18l
}
$row = db_fetch_array($db_res);
$def = array('name' => htmlentities($row['name']), 'reverse_name' => htmlentities($row['reverse_name']), 'description' => htmlentities($row['description']), 'uri_plus' => htmlentities($row['uri_plus']));
} else {
$def = array('name' => "", 'reverse_name' => "", 'description' => "", 'uri_plus' => '/projects/$projname/');
}
$HTML->box1_top($Language->getText('plugin_plinks', 'project_links') . " " . $this->_icon('main') . " " . $Language->getText('plugin_plinks', 'link_type_update'));
print mkAH("[" . $Language->getText('global', 'btn_cancel') . "]", $this->_adminURI() . "?group_id={$group_id}");
print "<hr>\n";
print "<table><tr><td>\n";
$HTML->box1_top("");
form_Start("");
form_HiddenParams(array("func" => 'pl_type_update', "group_id" => $group_id));
if (isset($link_type_id)) {
form_HiddenParams(array("link_type_id" => $link_type_id));
}
form_GenTextBox("name", htmlentities($Language->getText('plugin_plinks', 'dbfn_name')), $def['name'], 20);
form_Validation("name", FORM_VAL_IS_NOT_ZERO_LENGTH);
form_NewRow();
form_GenTextBox("reverse_name", htmlentities($Language->getText('plugin_plinks', 'dbfn_reverse_name')), $def['reverse_name'], 20);
form_NewRow();
form_GenTextArea("description", htmlentities($Language->getText('plugin_plinks', 'dbfn_description')), $def['description']);
/** **1 commented out for now - until we can decide how to deal with project links functionality
form_NewRow();
form_GenTextBox("uri_plus",
htmlentities($Language->getText('plugin_plinks', 'dbfn_uri_plus')),
$def['uri_plus'], 85);
form_Validation("uri_plus", FORM_VAL_IS_NOT_ZERO_LENGTH);
**/
foreach (array("uri_plus", "name", "reverse_name", "description") as $ref) {
$formRefs[$ref] = form_JS_ElementRef($ref) . ".value";
}
form_End();
$HTML->box1_bottom();
print "</td><td>\n";
$HTML->box1_top($Language->getText('plugin_plinks', 'set_to_defaults'));
print "<div style='padding: 5px; border: solid thin;\n vertical-align: middle;'>";
print $Language->getText('plugin_plinks', 'replace_form_details') . ":<p>";
form_genJSButton($Language->getText('plugin_plinks', 'def_sp_name'), "if (confirm('" . $Language->getText('plugin_plinks', 'replace_form_details') . "?')){" . $formRefs["name"] . "='" . $Language->getText('plugin_plinks', 'def_sp_name') . "';" . $formRefs["reverse_name"] . "='" . $Language->getText('plugin_plinks', 'def_sp_rname') . "';" . $formRefs["description"] . "='" . $Language->getText('plugin_plinks', 'def_sp_desc') . "';" . "}");
print "<p>";
form_genJSButton($Language->getText('plugin_plinks', 'def_rp_name'), "if (confirm('" . $Language->getText('plugin_plinks', 'replace_form_details') . "?')){" . $formRefs["name"] . "='" . $Language->getText('plugin_plinks', 'def_rp_name') . "';" . $formRefs["reverse_name"] . "='" . $Language->getText('plugin_plinks', 'def_rp_rname') . "';" . $formRefs["description"] . "='" . $Language->getText('plugin_plinks', 'def_rp_desc') . "';" . "}");
print "</div><p>";
/** **1 commented out for now - until we can decide how to deal with project links functionality
print "<div style='padding: 5px; border: solid thin;
vertical-align: middle;'>";
form_genJSButton($Language->getText('plugin_plinks', 'def_link_summary'),
$formRefs["uri_plus"]."='/projects/\$projname/';");
print "<p>";
form_genJSButton($Language->getText('plugin_plinks', 'def_link_doc'),
$formRefs["uri_plus"]."='/plugins/docman/?group_id=\$group_id';"
);
print "</div>";
**/
$HTML->box1_bottom();
print "</td></tr></table>\n";
if (isset($link_type_id)) {
// Display list of linked projects
$HTML->box1_top('Projects linked');
print $this->_admin_links_table($link_type_id);
// Admin can add new link
print '<form name="plugin_projectlinks_add_link" method="post" action="?func=pl_link_update">';
print '<input type="hidden" name="link_type_id" value="' . $link_type_id . '" />';
print '<input type="hidden" name="group_id" value="' . $group_id . '" />';
print '<input type="hidden" name="disp" value="edit_link_type" />';
print '<p><label for="plugin_projectlinks_link_project">' . $GLOBALS['Language']->getText('plugin_plinks', 'add_project') . '</label>';
print '<input type="text" name="target_group" value="' . $GLOBALS['Language']->getText('plugin_plinks', 'add_project_autocompleter') . '" size="60" id="plugin_projectlinks_link_project" /></p>';
print '<input type="submit" value="' . $GLOBALS['Language']->getText('global', 'btn_create') . '" />';
print '</form>';
$HTML->box1_bottom();
$HTML->includeFooterJavascriptSnippet("new ProjectAutoCompleter('plugin_projectlinks_link_project', '" . util_get_dir_image_theme() . "', false);");
}
$HTML->box1_bottom();
}
开发者ID:nterray,项目名称:tuleap,代码行数:81,代码来源:projectlinksPlugin.class.php
示例6: ProjectAutoCompleter
$parent = $project_manager->getParentProject($group_id);
if ($parent) {
$parent_name = $parent->getUnixName();
if ($current_user->isMember($parent->getId(), 'A')) {
$url = '?group_id=' . $parent->getID();
} else {
$url = '/projects/' . $parent->getUnixName();
}
echo '<a href="' . $url . '"> ' . $parent_name . ' </a>
<br/>
<label><input type="checkbox" name="remove_parent_project"/>' . $GLOBALS['Language']->getText('project_admin_editgroupinfo', 'remove_parent_project') . '</label>';
} else {
echo '<input type="text" name="parent_project" size ="50" id="parent_project" /><br/>';
}
echo '</p>';
$js = "new ProjectAutoCompleter('parent_project', '" . util_get_dir_image_theme() . "', false, {'allowNull' : true});";
$GLOBALS['HTML']->includeFooterJavascriptSnippet($js);
echo "<u>" . $GLOBALS['Language']->getText('project_admin_editgroupinfo', 'sub_projects') . "</u><br>";
$children = $project_manager->getChildProjects($group_id);
foreach ($children as $child) {
if ($current_user->isMember($child->getId(), 'A')) {
$url = '?group_id=' . $child->getID();
} else {
$url = '/projects/' . $child->getUnixName();
}
echo '<a href="' . $url . '">' . $child->getPublicName() . '</a> ';
}
echo '
<P><br><INPUT type="submit" name="Update" value="' . $Language->getText('global', 'btn_update') . '"></P>
</FORM>
';
开发者ID:rinodung,项目名称:tuleap,代码行数:31,代码来源:editgroupinfo.php
示例7: project_admin_bullet_user_content
private function project_admin_bullet_user_content($user_id, $action, $url = null)
{
if ($action == 'add') {
$icon = '/ic/add.png';
} else {
$icon = '/ic/cross.png';
}
if (!$url) {
$url = $_SERVER['REQUEST_URI'] . '&' . http_build_query(array('action' => 'edit_ugroup_members', 'user[' . $user_id . ']' => $action));
}
$html = '<a href="' . $url . '">';
$html .= '<img alt="' . $action . '" src="' . util_get_dir_image_theme() . $icon . '" />';
$html .= '</a>';
return $html;
}
开发者ID:pombredanne,项目名称:tuleap,代码行数:15,代码来源:Members.class.php
示例8: show_grouphistory
/**
* Nicely html-formatted output of this group's audit trail
*
* @param Integer $group_id Id of the project
* @param Integer $offset Offset used for pagination
* @param Integer $limit Number of events by page
* @param String $event Events category used to filter results
* @param String $subEventsBox Event used to filter results
* @param String $value Value used to filter results
* @param Integer $startDate Start date used to filter results
* @param Integer $endDate End date used to filter results
* @param String $by User name used to filter results
*
* @return void
*/
function show_grouphistory($group_id, $offset, $limit, $event = null, $subEventsBox = null, $value = null, $startDate = null, $endDate = null, $by = null)
{
/*
show the group_history rows that are relevant to
this group_id
*/
global $Language;
$dao = new ProjectHistoryDao(CodendiDataAccess::instance());
$history_filter = build_grouphistory_filter($event, $subEventsBox, $value, $startDate, $endDate, $by);
$history_rows = $dao->groupGetHistory($offset, $limit, $group_id, $history_filter);
if (isset($subEventsBox)) {
$subEventsString = implode(",", array_keys($subEventsBox));
$forwardSubEvents = '&event=' . $event . '&subEventsBox=' . $subEventsString;
} else {
$forwardSubEvents = '&event=' . $event;
}
$renderer = TemplateRendererFactory::build()->getRenderer(ForgeConfig::get('codendi_dir') . '/src/templates/project/');
//Event select Box
$events = array('any' => $GLOBALS["Language"]->getText('global', 'any'), 'event_permission' => $GLOBALS["Language"]->getText("project_admin_utils", "event_permission"), 'event_project' => $GLOBALS["Language"]->getText("project_admin_utils", "event_project"), 'event_user' => $GLOBALS["Language"]->getText("project_admin_utils", "event_user"), 'event_ug' => $GLOBALS["Language"]->getText("project_admin_utils", "event_ug"), 'event_others' => $GLOBALS["Language"]->getText("project_admin_utils", "event_others"));
$select = new HTML_Element_Selectbox('', 'events_box', '');
$select->setId('events_box');
$select->addMultipleOptions($events, $event);
$title_arr = array();
$title_arr[] = $Language->getText('project_admin_utils', 'event');
$title_arr[] = $Language->getText('project_admin_utils', 'val');
$title_arr[] = $Language->getText('project_admin_utils', 'date');
$title_arr[] = $Language->getText('global', 'by');
$index = 1;
$presenter = new ProjectHistoryPresenter($group_id, $select->renderValue(), $value, $startDate, $endDate, $by, $history_rows, $title_arr, $index, $offset, $limit, $forwardSubEvents);
echo $renderer->renderToString('project_history', $presenter);
$translatedEvents = convert_project_history_events(get_history_entries(), false);
if (isset($subEventsString)) {
$selectedSubEvents = explode(",", $subEventsString);
foreach ($selectedSubEvents as $element) {
$subEventsBox[] = $element;
}
}
$translatedSelectedEvents = convert_project_history_events($subEventsBox, true);
$js = "options = new Array();\n options['defaultValueActsAsHint'] = false;\n new UserAutoCompleter('by', '" . util_get_dir_image_theme() . "', true, options);\n new ProjectHistory(" . $translatedEvents . ", " . $translatedSelectedEvents . ");";
$GLOBALS['HTML']->includeFooterJavascriptFile('/scripts/codendi/ProjectHistory.js');
$GLOBALS['Response']->includeFooterJavascriptSnippet($js);
}
开发者ID:rinodung,项目名称:tuleap,代码行数:57,代码来源:project_admin_utils.php
示例9: _addMailForm
/**
* MAIL FORM
*/
protected function _addMailForm()
{
?>
<h3><?php
echo $this->getText('add_mail_title');
?>
</h3>
<form id="add_mail_form" action="/plugins/git/" method="POST">
<input type="hidden" id="action" name="action" value="add_mail" />
<input type="hidden" id="group_id" name="group_id" value="<?php
echo $this->groupId;
?>
" />
<input type="hidden" id="repo_id" name="repo_id" value="<?php
echo $this->repoId;
?>
" />
<table>
<tr>
<td class="plugin_git_first_col" ><label for="add_mail_label"><?php
echo $this->getText('add_mail');
?>
<a href="#" onclick="$('help_addMail').toggle();"> [?]</a></label></td>
<td><textarea id="add_mail" name="add_mail" class="plugin_git_add_mail"></textarea></td>
</tr>
<tr>
<td colspan="2"><input type="submit" id="add_mail_submit" name="add_mail_submit" value="<?php
echo $this->getText('add_mail_submit');
?>
"></td>
</tr>
</table>
</form>
<?php
$this->help('addMail', array('display' => 'none'));
$js = "new UserAutoCompleter('add_mail', '" . util_get_dir_image_theme() . "', true);";
$GLOBALS['Response']->includeFooterJavascriptSnippet($js);
}
开发者ID:nterray,项目名称:tuleap,代码行数:41,代码来源:GitViews.class.php
示例10: fetchCharts
protected function fetchCharts($matching_ids, User $current_user, $in_dashboard = false, $readonly = null, $store_in_session = true)
{
$html = '';
$hp = Codendi_HTMLPurifier::instance();
if (!$readonly) {
$html .= '<form name="show_rep_graphic" action="" method="POST">
<input type="hidden" name="func" VALUE="renderer" />
<input type="hidden" name="renderer" VALUE="' . $this->id . '" />';
$html .= '<p><strong>' . $GLOBALS['Language']->getText('plugin_graphontrackersv5_include_report', 'add_chart') . '</strong> ';
$url = '?' . http_build_query(array('report' => $this->report->id, 'renderer' => $this->id, 'func' => 'renderer'));
$url_add = $url . '&renderer_plugin_graphontrackersv5[add_chart]=';
foreach ($this->getChartFactory()->getChartFactories() as $factory) {
$html .= '<a href="' . $url_add . $factory['chart_type'] . '"
style="border:1px solid #ccc; margin:10px; padding:5px 10px; vertical-align:middle">';
$html .= '<img style="vertical-align:middle; " src="' . $factory['icon'] . '" /> ';
$html .= '<span style="margin-left:4px;">' . $factory['title'] . '</span>';
$html .= '</a>';
}
$html .= '</p><hr size="1" color="#f0f0f0">';
}
foreach ($this->getChartFactory()->getCharts($this) as $chart) {
$html .= '<div style="float:left; padding:10px; text-align:right;">';
if (!$in_dashboard) {
$add_to_dashboard_params = array('action' => 'widget', 'chart' => array('title' => $chart->getTitle(), 'chart_id' => $chart->getId()));
//Add to my dashboard
if ($chart->getId() > 0) {
$html .= '<a title="' . $GLOBALS['Language']->getText('plugin_graphontrackersv5_include_report', 'add_chart_dashboard') . '"
href="/widgets/updatelayout.php?' . http_build_query(array_merge(array('owner' => 'u' . UserManager::instance()->getCurrentUser()->getId(), 'name' => array('my_plugin_graphontrackersv5_chart' => array('add' => 1))), $add_to_dashboard_params)) . '">' . $GLOBALS['HTML']->getImage('ic/layout_user.png') . '</a> ';
//Add to project dashboard
if ($this->report->getTracker()->getProject()->userIsAdmin($current_user)) {
$html .= '<a title="' . $GLOBALS['Language']->getText('plugin_graphontrackersv5_include_report', 'add_chart_project_dashboard') . '"
href="/widgets/updatelayout.php?' . http_build_query(array_merge(array('owner' => 'g' . $this->report->getTracker()->getProject()->getGroupId(), 'name' => array('project_plugin_graphontrackersv5_chart' => array('add' => 1))), $add_to_dashboard_params)) . '">' . $GLOBALS['HTML']->getImage('ic/layout_project.png') . '</a> ';
}
}
if (!$readonly && $this->report->userCanUpdate($current_user)) {
//Edit chart
$html .= '<a title="' . $GLOBALS['Language']->getText('plugin_graphontrackersv5_include_report', 'tooltip_edit') . '"
href="' . $url . '&renderer_plugin_graphontrackersv5[edit_chart]=' . $chart->getId() . '">
<img src="' . util_get_dir_image_theme() . 'ic/edit.png" alt="edit" />
</a>';
//Delete chart
$html .= '<input title="' . $GLOBALS['Language']->getText('plugin_graphontrackersv5_include_report', 'tooltip_del') . '"
type="image" src="' . util_get_dir_image_theme() . 'ic/cross.png"
onclick="return confirm(' . $GLOBALS['Language']->getText('plugin_graphontrackersv5_include_report', 'confirm_del') . ');"
name="renderer_plugin_graphontrackersv5[delete_chart][' . $chart->getId() . ']" />';
}
}
//Display chart
$html .= $chart->fetch($store_in_session);
$html .= '</div>';
}
$html .= '<div style="clear:both;"></div>';
if (!$readonly) {
$html .= '</form>';
}
return $html;
}
开发者ID:nterray,项目名称:tuleap,代码行数:57,代码来源:GraphOnTrackersV5_Renderer.class.php
示例11: addUserAutocompleteOn
public function addUserAutocompleteOn($element_id, $multiple = false)
{
$jsbool = $multiple ? "true" : "false";
$js = "new UserAutoCompleter('" . $element_id . "', '" . util_get_dir_image_theme() . "', " . $jsbool . ");";
$this->includeFooterJavascriptSnippet($js);
}
开发者ID:pombredanne,项目名称:tuleap,代码行数:6,代码来源:Layout.class.php
示例12: getContent
public function getContent()
{
$content = '';
// Import very long user group may takes very long time.
ini_set('max_execution_time', 0);
$ugroupName = util_translate_name_ugroup($this->row['name']);
$ldapGroup = $this->ldap_user_group_manager->getLdapGroupByGroupId($this->ugroup->getId());
$clean_ugroupName = $this->purifier->purify($ugroupName);
$clean_ldapGroupName = $this->purifyLDAPGroupName($ldapGroup);
$btn_update = $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_btn_update');
$btn_unlink = $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_btn_unlink');
$content .= '<h2>' . $GLOBALS['Language']->getText('project_admin_editugroup', 'ug_admin', $clean_ugroupName) . '</h2>';
if ($ldapGroup !== null) {
$content .= '<p>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_ugroup_linked', array($clean_ugroupName, $clean_ldapGroupName)) . '</p>';
}
$content .= '<p>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_you_can') . '</p>';
$content .= '<ul>';
if ($ldapGroup !== null) {
$content .= '<li>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_resync') . '</li>';
$content .= '<li>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_remove') . '</li>';
}
$content .= '<li>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_link') . '</li>';
$content .= '</ul>';
$content .= '<p>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_synchro') . '</p>';
$content .= '<ul>';
$content .= '<li>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_synchro_del', $GLOBALS['sys_name']) . '</li>';
$content .= '<li>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_synchro_add', $GLOBALS['sys_name']) . '</li>';
$content .= '</ul>';
$content .= '<form name="plugin_ldap_edit_ugroup" method="post" action="">';
$content .= '<input type="hidden" name="ugroup_id" value="' . $this->ugroup->getId() . '" />';
$content .= '<input type="hidden" name="action" value="edit_directory" />';
$content .= '<p>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_bind_with_group') . ' <input type="text" name="bind_with_group" id="group_add" value="' . $clean_ldapGroupName . '" size="60" /></p>';
$preservingChecked = '';
if ($this->ldap_user_group_manager->isMembersPreserving($this->ugroup->getId()) || $this->bindOption === LDAP_GroupManager::PRESERVE_MEMBERS_OPTION) {
$preservingChecked = 'checked';
}
$content .= '<p>';
$content .= '<label class="checkbox" for="preserve_members"><input type="checkbox" id="preserve_members" name="preserve_members" ' . $preservingChecked . '/>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_preserve_members_option') . ' (' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_preserve_members_info') . ')</label></p>';
$synchroChecked = '';
if ($this->ldap_user_group_manager->isSynchronizedUgroup($this->ugroup->getId()) || $this->synchro === LDAP_GroupManager::AUTO_SYNCHRONIZATION) {
$synchroChecked = 'checked';
}
$content .= '<p>';
$content .= '<label class="checkbox" for="synchronize"><input type="checkbox" id="synchronize" name="synchronize" ' . $synchroChecked . '/>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_synchronize_option') . ' (' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_synchronize_info') . ')</label></p>';
$content .= '<input type="submit" name="submit" value="' . $btn_update . '" />';
if ($ldapGroup !== null) {
$content .= ' ';
$content .= '<input type="submit" name="submit" value="' . $btn_unlink . '" />';
}
$GLOBALS['Response']->includeFooterJavascriptFile($this->pluginPath . '/scripts/autocomplete.js');
$js = "new LdapGroupAutoCompleter('group_add',\n '" . $this->pluginPath . "',\n '" . util_get_dir_image_theme() . "',\n 'group_add',\n false);";
$GLOBALS['Response']->includeFooterJavascriptSnippet($js);
$content .= '</form>';
return $content;
}
开发者ID:pombredanne,项目名称:tuleap,代码行数:55,代码来源:EditDirectoryGroup.class.php
示例13: UserAutoCompleter
*/
echo '
<FORM ACTION="?" METHOD="POST" class="add-user">
<INPUT TYPE="hidden" NAME="func" VALUE="adduser">
<INPUT TYPE="HIDDEN" NAME="group_id" VALUE="' . $group_id . '">
<div class="control-group">
<label class="control-label" for="add_user">' . $Language->getText('project_admin_index', 'login_name') . '</label>
<div class="input-append">
<INPUT TYPE="TEXT" NAME="form_unix_name" VALUE="" id="add_user">
<INPUT TYPE="SUBMIT" NAME="SUBMIT" VALUE="' . $Language->getText('project_admin_index', 'add_user') . '" class="btn">
</div>
</div>
';
// JS code for autocompletion on "add_user" field defined on top.
$js = "new UserAutoCompleter('add_user',\n '" . util_get_dir_image_theme() . "',\n false);";
$GLOBALS['Response']->includeFooterJavascriptSnippet($js);
echo ' </FORM>
';
$em->processEvent('project_admin_add_user_form', array('groupId' => $group_id));
echo '
<HR NoShade SIZE="1">
<div align="center">
<A href="/project/admin/userimport.php?group_id=' . $group_id . '">' . $Language->getText('project_admin_index', 'import_user') . '</A>
</div>
<HR NoShade SIZE="1">
<div align="center">
<A href="/project/admin/userperms.php?group_id=' . $group_id . '">' . $Language->getText('project_admin_index', 'edit_member_perm') . '</A>
</div>
</TD></TR>';
开发者ID:pombredanne,项目名称:tuleap,代码行数:31,代码来源:index.php
示例14: addListeningUser
/**
* Add a user to the list of peoples that are monitoring a given item.
*
* @param Integer $itemId Id of the document
*
* @return String
*/
function addListeningUser($itemId)
{
$content = '<tr><td colspan="2"><hr width="100%" size="1" NoShade></td></tr>';
$content .= '<tr><form name="add_monitoring" method="POST" action="">';
$content .= '<input type="hidden" name="action" value="add_monitoring">';
$content .= '<input type="hidden" name="item_id" value="' . $itemId . '">';
$content .= '<table>';
$content .= '<tr><td><b>' . $GLOBALS['Language']->getText('plugin_docman', 'notifications_add_user_title') . '</b></td></tr>';
$content .= '<tr><td><textarea name="listeners_to_add" value="" id="listeners_to_add" rows="2" cols="50"></textarea></td></tr>';
//checkbox to enable cascade monitoring
$content .= '<tr><td>';
$content .= '<label class="checkbox" for="plugin_docman_monitor_add_user_cascade">';
$content .= '<input type="checkbox" name="monitor_cascade" value="1" id="plugin_docman_monitor_add_user_cascade" />' . $GLOBALS['Language']->getText('plugin_docman', 'notifications_add_user_cascade');
$content .= '</label></td></tr></table>';
//autocompletion on "add_user" field.
$autocomplete = "new UserAutoCompleter('listeners_to_add','" . util_get_dir_image_theme() . "',true);";
$GLOBALS['Response']->includeFooterJavascriptSnippet($autocomplete);
$content .= '<input type="submit" name="submit" value="' . $GLOBALS['Language']->getText('plugin_docman', 'notifications_add_user') . '"></td></form></tr>';
return $content;
}
开发者ID:rinodung,项目名称:tuleap,代码行数:27,代码来源:Docman_View_ItemDetailsSectionNotifications.class.php
示例15: LdapGroupAutoCompleter
echo '<p>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_synchro') . '</p>';
echo '<ul>';
echo '<li>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_synchro_del', $GLOBALS['sys_name']) . '</li>';
echo '<li>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_synchro_add', $GLOBALS['sys_name']) . '</li>';
echo '</ul>';
echo '<form name="plugin_ldap_edit_ugroup" method="post" action="">';
echo '<input type="hidden" name="ugroup_id" value="' . $ugroupId . '" />';
echo '<input type="hidden" name="func" value="' . $func . '" />';
echo '<p>' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_bind_with_group') . ' <input type="text" name="bind_with_group" id="group_add" value="' . $clean_ldapGroupName . '" size="60" /></p>';
$preservingChecked = '';
if ($ldapUserGroupManager->isMembersPreserving($ugroupId)) {
$preservingChecked = 'checked';
}
echo '<p><input type="checkbox" id="preserve_members" name="preserve_members" ' . $preservingChecked . '/>';
echo '<label for="preserve_members">' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_preserve_members_option') . ' (' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_preserve_members_info') . ')</label></p>';
$synchroChecked = '';
if ($ldapUserGroupManager->isSynchronizedUgroup($ugroupId)) {
$synchroChecked = 'checked';
}
echo '<p><input type="checkbox" id="synchronize" name="synchronize" ' . $synchroChecked . '/>';
echo '<label for="synchronize">' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_synchronize_option') . ' (' . $GLOBALS['Language']->getText('plugin_ldap', 'ugroup_edit_group_synchronize_info') . ')</label></p>';
echo '<input type="submit" name="submit" value="' . $btn_update . '" />';
if ($ldapGroup !== null) {
echo ' ';
echo '<input type="submit" name="submit" value="' . $btn_unlink . '" />';
}
$GLOBALS['Response']->includeFooterJavascriptFile($pluginPath . '/scripts/autocomplete.js');
$js = "new LdapGroupAutoCompleter('group_add',\n '" . $pluginPath . "',\n '" . util_get_dir_image_theme() . "',\n 'group_add',\n false);";
$GLOBALS['Response']->includeFooterJavascriptSnippet($js);
echo '</form>';
project_admin_footer(array());
开发者ID:nterray,项目名称:tuleap,代码行数:31,代码来源:ugroup_edit.php
示例16: _getImportForm
function _getImportForm()
{
$GLOBALS['HTML']->includeFooterJavascriptSnippet("new ProjectAutoCompleter('import_search_report_from_group', '" . util_get_dir_image_theme() . "', false);");
$html = '';
$html .= '<form name="docman_report_import" method="post" action="?">';
$html .= '<input type="hidden" name="group_id" value="' . $this->groupId . '">';
$html .= '<input type="hidden" name="action" value="report_import">';
$html .= '<table border="0">';
// Select project
$html .= '<tr>';
$html .= '<td valign="top">' . $GLOBALS['Language']->getText('plugin_docman', 'report_settings_import_sel_prj') . '</td>';
// Group id selector
$html .= '<td>';
$html .= '<input type="text" id="import_search_report_from_group" name="import_search_report_from_group" size="60" value="';
$html .= $GLOBALS['Language']->getText('plugin_docman', 'report_settings_import_sel_prj_hint');
$html .= '" />';
$html .= '</td>';
$html .= '</tr>';
// Select report
$html .= '<tr>';
$html .= '<td valign="top">' . $GLOBALS['Language']->getText('plugin_docman', 'report_settings_import_sel_rpt') . '(' . $GLOBALS['Language']->getText('plugin_docman', 'report_settings_import_sel_rpt_id') . ')' . '</td>';
$html .= '<td>';
$html .= '<input type="text" name="import_report_id" value="" />';
$html .= '</td>';
$html .= '</tr>';
$html .= '</table>';
// Submit
$html .= '<input type="submit" name="submit" value="' . $GLOBALS['Language']->getText('global', 'btn_create') . '">';
$html .= '</form>';
return $html;
}
开发者ID:pombredanne,项目名称:tuleap,代码行数:31,代码来源:Docman_View_ReportSettings.class.php
示例17: displayForm
/**
* Display form to fill a request
*
* @param Array $params params of the hook
*
* @return Void
*/
function displayForm($params = null)
{
$um = UserManager::instance();
$user = $um->getCurrentUser();
$ignoreLabs = $this->getController()->getPlugin()-
|
请发表评论