本文整理汇总了PHP中makefileopts函数的典型用法代码示例。如果您正苦于以下问题:PHP makefileopts函数的具体用法?PHP makefileopts怎么用?PHP makefileopts使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了makefileopts函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: display_html
function display_html($formname, $textarea, $html = TRUE, $colors = FALSE, $images = FALSE, $folder = "")
{
global $locale;
$res = "";
if ($html) {
$res .= "<div class='btn-group m-b-10'>\n";
$res .= "<button type='button' value='b' class='btn btn-sm btn-default button' style='font-weight:bold;' onclick=\"addText('" . $textarea . "', '<strong>', '</strong>', '" . $formname . "');\">b</button>\n";
$res .= "<button type='button' value='i' class='btn btn-sm btn-default button' style='font-style:italic;' onclick=\"addText('" . $textarea . "', '<i>', '</i>', '" . $formname . "');\">i</button>\n";
$res .= "<button type='button' value='u' class='btn btn-sm btn-default button' style='text-decoration:underline;' onclick=\"addText('" . $textarea . "', '<u>', '</u>', '" . $formname . "');\">u</button>\n";
$res .= "<button type='button' value='link' class='btn btn-sm btn-default button' onclick=\"addText('" . $textarea . "', '<a href=\\'', '\\' target=\\'_blank\\'>Link</a>', '" . $formname . "');\">link</button>\n";
$res .= "<button type='button' value='img' class='btn btn-sm btn-default button' onclick=\"addText('" . $textarea . "', '<img src=\\'" . str_replace("../", "", $folder) . "', '\\' style=\\'margin:5px\\' alt=\\'\\' align=\\'left\\' />', '" . $formname . "');\">img</button>\n";
$res .= "<button type='button' value='center' class='btn btn-sm btn-default button' onclick=\"addText('" . $textarea . "', '<center>', '</center>', '" . $formname . "');\">center</button>\n";
$res .= "<button type='button' value='small' class='btn btn-sm btn-default button' onclick=\"addText('" . $textarea . "', '<span class=\\'small\\'>', '</span>', '" . $formname . "');\">small</button>\n";
$res .= "<button type='button' value='small2' class='btn btn-sm btn-default button' onclick=\"addText('" . $textarea . "', '<span class=\\'small2\\'>', '</span>', '" . $formname . "');\">small2</button>\n";
$res .= "<button type='button' value='alt' class='btn btn-sm btn-default button' onclick=\"addText('" . $textarea . "', '<span class=\\'alt\\'>', '</span>', '" . $formname . "');\">alt</button>\n";
$res .= "</div>\n";
}
if ($colors) {
$color_array = array('maroon' => $locale['html402'], 'red' => $locale['html403'], 'orange' => $locale['html404'], 'brown' => $locale['html405'], 'yellow' => $locale['html406'], 'green' => $locale['html407'], 'lime' => $locale['html408'], 'olive' => $locale['html409'], 'cyan' => $locale['html410'], 'blue' => $locale['html411'], 'navy' => $locale['html412'], 'purple' => $locale['html413'], 'violet' => $locale['html414'], 'black' => $locale['html415'], 'gray' => $locale['html416'], 'silver' => $locale['html417'], 'white' => $locale['html418']);
$placeholder = $locale['html400'];
$res .= form_select('', "setcolor-{$formname}", "setcolor-{$formname}", $color_array, '', array('placeholder' => $placeholder, 'class' => 'pull-left m-r-10', 'allowclear' => 1));
add_to_jquery("\r\n function color(item) {\r\n if(!item.id) {return item.text;}\r\n var color = item.text;\r\n return '<table><tr><td><label style=\\'display: inline-block; width: 18px; height:18px; margin:3px; margin-right:5px; padding: 0px 8px; background:'+item.text+'\\'></label>'+item.text+'</td></tr></table>';\r\n }\r\n \$('#setcolor-{$formname}').select2({\r\n formatSelection: color,\r\n escapeMarkup: function(m) { return m; },\r\n formatResult: color,\r\n placeholder:'{$placeholder}',\r\n allowClear:true,\r\n });\r\n \$('#setcolor-{$formname}').on('change', function(e){\r\n addText('" . $textarea . "', '<span style=\\'color:' + this.options[this.selectedIndex].value + '\\'>', '</span>', '" . $formname . "');this.selectedIndex=0;\r\n \$(this).select2({\r\n formatSelection: color,\r\n escapeMarkup: function(m) { return m; },\r\n formatResult: color,\r\n placeholder:'{$placeholder}',\r\n allowClear:true}).val('');\r\n });\r\n ");
}
if ($images && $folder) {
$image_files = makefilelist($folder, ".|..|index.php", TRUE);
$image_list = makefileopts($image_files);
$res .= "<select name='insertimage' class='form-control textbox' style='margin-top:5px' onchange=\"insertText('" . $textarea . "', '<img src=\\'" . str_replace("../", "", $folder) . "' + this.options[this.selectedIndex].value + '\\' alt=\\'\\' style=\\'margin:5px\\' align=\\'left\\' />', '" . $formname . "');this.selectedIndex=0;\">\n";
$res .= "<option value=''>" . $locale['html401'] . "</option>\n" . $image_list . "</select>\n";
}
return $res;
}
示例2: display_html
function display_html($formname, $textarea, $html = true, $colors = false, $images = false, $folder = "")
{
global $locale, $settings;
// Pimped: $settings added
$res = "";
if ($html) {
$res .= "<input type='button' value='b' class='button' style='font-weight:bold;width:25px' onclick=\"addText('" . $textarea . "', '<strong>', '</strong>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='i' class='button' style='font-style:italic;width:25px' onclick=\"addText('" . $textarea . "', '<i>', '</i>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='u' class='button' style='text-decoration:underline;width:25px' onclick=\"addText('" . $textarea . "', '<u>', '</u>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='link' class='button' style='width:35px' onclick=\"addText('" . $textarea . "', '<a href=\\'', '\\' target=\\'_blank\\'>Link</a>', '" . $formname . "');\" />\n";
if ($settings['enable_lightbox'] == "1") {
$res .= "<input type='button' value='img' class='button' style='width:35px' onclick=\"addText('" . $textarea . "', '<a class=\\'fancybox\\' href=\\'" . str_replace("../", "", $folder) . "\\'><img src=\\'" . str_replace("../", "", $folder) . "', '\\' style=\\'margin:5px\\' width=\\'300\\' height=\\'200\\' align=\\'left\\' rel=\\'group\\' /></a>', '" . $formname . "');\" />\n";
// Pimped
} else {
$res .= "<input type='button' value='img' class='button' style='width:35px' onclick=\"addText('" . $textarea . "', '<img src=\\'" . str_replace("../", "", $folder) . "', '\\' style=\\'margin:5px\\' align=\\'left\\' />', '" . $formname . "');\" />\n";
}
$res .= "<input type='button' value='center' class='button' style='width:45px' onclick=\"addText('" . $textarea . "', '<center>', '</center>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='small' class='button' style='width:40px' onclick=\"addText('" . $textarea . "', '<span class=\\'small\\'>', '</span>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='small2' class='button' style='width:45px' onclick=\"addText('" . $textarea . "', '<span class=\\'small2\\'>', '</span>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='alt' class='button' style='width:25px' onclick=\"addText('" . $textarea . "', '<span class=\\'alt\\'>', '</span>', '" . $formname . "');\" />\n";
}
if ($html && ($colors || $images)) {
$res .= "<br />\n";
}
if ($colors) {
$res .= "<select name='setcolor' class='textbox' style='margin-top:5px' onchange=\"addText('" . $textarea . "', '<span style=\\'color:' + this.options[this.selectedIndex].value + '\\'>', '</span>', '" . $formname . "');this.selectedIndex=0;\">\n";
$res .= "<option value=''>" . $locale['html400'] . "</option>\n";
$res .= "<option value='maroon' style='color:maroon'>Maroon</option>\n";
$res .= "<option value='red' style='color:red'>Red</option>\n";
$res .= "<option value='orange' style='color:orange'>Orange</option>\n";
$res .= "<option value='brown' style='color:brown'>Brown</option>\n";
$res .= "<option value='yellow' style='color:yellow'>Yellow</option>\n";
$res .= "<option value='green' style='color:green'>Green</option>\n";
$res .= "<option value='lime' style='color:lime'>Lime</option>\n";
$res .= "<option value='olive' style='color:olive'>Olive</option>\n";
$res .= "<option value='cyan' style='color:cyan'>Cyan</option>\n";
$res .= "<option value='blue' style='color:blue'>Blue</option>\n";
$res .= "<option value='navy' style='color:navy'>Navy Blue</option>\n";
$res .= "<option value='purple' style='color:purple'>Purple</option>\n";
$res .= "<option value='violet' style='color:violet'>Violet</option>\n";
$res .= "<option value='black' style='color:black'>Black</option>\n";
$res .= "<option value='gray' style='color:gray'>Gray</option>\n";
$res .= "<option value='silver' style='color:silver'>Silver</option>\n";
$res .= "<option value='white' style='color:white'>White</option>\n";
$res .= "</select>\n";
}
if ($images && $folder) {
$image_files = makefilelist($folder, ".|..|index.php", true);
$image_list = makefileopts($image_files);
$res .= "<select name='insertimage' class='textbox' style='margin-top:5px' onchange=\"insertText('" . $textarea . "', '<img src=\\'" . str_replace("../", "", $folder) . "' + this.options[this.selectedIndex].value + '\\' style=\\'margin:5px\\' align=\\'left\\' />', '" . $formname . "');this.selectedIndex=0;\">\n";
$res .= "<option value=''>" . $locale['html401'] . "</option>\n" . $image_list . "</select>\n";
}
return $res;
}
示例3: display_html
function display_html($formname, $textarea, $html = true, $colors = false, $images = false, $folder = "")
{
global $locale;
$res = "";
if ($html) {
$res .= "<input type='button' value='b' class='button' style='font-weight:bold;' onclick=\"addText('" . $textarea . "', '<strong>', '</strong>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='i' class='button' style='font-style:italic;' onclick=\"addText('" . $textarea . "', '<i>', '</i>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='u' class='button' style='text-decoration:underline;' onclick=\"addText('" . $textarea . "', '<u>', '</u>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='link' class='button' onclick=\"addText('" . $textarea . "', '<a href=\\'', '\\' target=\\'_blank\\'>Link</a>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='img' class='button' onclick=\"addText('" . $textarea . "', '<img src=\\'" . str_replace("../", "", $folder) . "', '\\' style=\\'margin:5px\\' alt=\\'\\' align=\\'left\\' />', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='center' class='button' onclick=\"addText('" . $textarea . "', '<center>', '</center>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='small' class='button' onclick=\"addText('" . $textarea . "', '<span class=\\'small\\'>', '</span>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='small2' class='button' onclick=\"addText('" . $textarea . "', '<span class=\\'small2\\'>', '</span>', '" . $formname . "');\" />\n";
$res .= "<input type='button' value='alt' class='button' onclick=\"addText('" . $textarea . "', '<span class=\\'alt\\'>', '</span>', '" . $formname . "');\" />\n";
}
if ($html && ($colors || $images)) {
$res .= "<br />\n";
}
if ($colors) {
$res .= "<select name='setcolor' class='textbox' style='margin-top:5px' onchange=\"addText('" . $textarea . "', '<span style=\\'color:' + this.options[this.selectedIndex].value + '\\'>', '</span>', '" . $formname . "');this.selectedIndex=0;\">\n";
$res .= "<option value=''>" . $locale['html400'] . "</option>\n";
$res .= "<option value='maroon' style='color:maroon'>" . $locale['html402'] . "</option>\n";
$res .= "<option value='red' style='color:red'>" . $locale['html403'] . "</option>\n";
$res .= "<option value='orange' style='color:orange'>" . $locale['html404'] . "</option>\n";
$res .= "<option value='brown' style='color:brown'>" . $locale['html405'] . "</option>\n";
$res .= "<option value='yellow' style='color:yellow'>" . $locale['html406'] . "</option>\n";
$res .= "<option value='green' style='color:green'>" . $locale['html407'] . "</option>\n";
$res .= "<option value='lime' style='color:lime'>" . $locale['html408'] . "</option>\n";
$res .= "<option value='olive' style='color:olive'>" . $locale['html409'] . "</option>\n";
$res .= "<option value='cyan' style='color:cyan'>" . $locale['html410'] . "</option>\n";
$res .= "<option value='blue' style='color:blue'>" . $locale['html411'] . "</option>\n";
$res .= "<option value='navy' style='color:navy'>" . $locale['html412'] . "</option>\n";
$res .= "<option value='purple' style='color:purple'>" . $locale['html413'] . "</option>\n";
$res .= "<option value='violet' style='color:violet'>" . $locale['html414'] . "</option>\n";
$res .= "<option value='black' style='color:black'>" . $locale['html415'] . "</option>\n";
$res .= "<option value='gray' style='color:gray'>" . $locale['html416'] . "</option>\n";
$res .= "<option value='silver' style='color:silver'>" . $locale['html417'] . "</option>\n";
$res .= "<option value='white' style='color:white'>" . $locale['html418'] . "</option>\n";
$res .= "</select>\n";
}
if ($images && $folder) {
$image_files = makefilelist($folder, ".|..|index.php", true);
$image_list = makefileopts($image_files);
$res .= "<select name='insertimage' class='textbox' style='margin-top:5px' onchange=\"insertText('" . $textarea . "', '<img src=\\'" . str_replace("../", "", $folder) . "' + this.options[this.selectedIndex].value + '\\' alt=\\'\\' style=\\'margin:5px\\' align=\\'left\\' />', '" . $formname . "');this.selectedIndex=0;\">\n";
$res .= "<option value=''>" . $locale['html401'] . "</option>\n" . $image_list . "</select>\n";
}
return $res;
}
示例4: makefileopts
echo "</select></td>\n";
echo "</tr>\n<tr>\n";
echo "<td width='50%' class='tbl'>" . $locale['417'] . "</td>\n";
echo "<td width='50%' class='tbl'><select name='localeset' class='textbox'>\n";
echo makefileopts($locale_files, $settings2['locale']) . "\n";
echo "</select></td>\n";
echo "</tr>\n<tr>\n";
echo "<td width='50%' class='tbl'>" . $locale['418'];
if ($userdata['user_theme'] == "Default") {
if ($settings2['theme'] != str_replace(THEMES, "", substr(THEME, 0, strlen(THEME) - 1))) {
echo "<div class='admin-message'>" . $locale['global_302'] . "</div>\n";
}
}
echo "</td>\n";
echo "<td width='50%' class='tbl'><select name='theme' class='textbox'>\n";
echo makefileopts($theme_files, $settings2['theme']) . "\n";
echo "</select></td>\n";
echo "</tr>\n<tr>\n";
echo "<td width='50%' class='tbl'>" . $locale['419'] . "</td>\n";
echo "<td width='50%' class='tbl'><select name='default_search' class='textbox'>\n[DEFAULT_SEARCH]</select></td>\n";
echo "</tr>\n<tr>\n";
echo "<td valign='top' width='50%' class='tbl'>" . $locale['420'] . "<br /><span class='small2'>" . $locale['424'] . "</span></td>\n";
echo "<td width='50%' class='tbl'><textarea name='exclude_left' cols='50' rows='5' class='textbox' style='width:230px;'>" . $settings2['exclude_left'] . "</textarea></td>\n";
echo "</tr>\n<tr>\n";
echo "<td valign='top' width='50%' class='tbl'>" . $locale['421'] . "<br /><span class='small2'>" . $locale['424'] . "</span></td>\n";
echo "<td width='50%' class='tbl'><textarea name='exclude_upper' cols='50' rows='5' class='textbox' style='width:230px;'>" . $settings2['exclude_upper'] . "</textarea></td>\n";
echo "</tr>\n<tr>\n";
echo "<td valign='top' width='50%' class='tbl'>" . $locale['422'] . "<br /><span class='small2'>" . $locale['424'] . "</span></td>\n";
echo "<td width='50%' class='tbl'><textarea name='exclude_lower' cols='50' rows='5' class='textbox' style='width:230px;'>" . $settings2['exclude_lower'] . "</textarea></td>\n";
echo "</tr>\n<tr>\n";
echo "<td valign='top' width='50%' class='tbl'>" . $locale['423'] . "<br /><span class='small2'>" . $locale['424'] . "</span></td>\n";
示例5: _t
<td width="120px"><?php
echo _t("Template");
?>
:</td>
<td><select name="template"><?php
echo makefileopts($templates, $spref->template);
?>
</select></td>
</tr>
<tr>
<td width="120px"><?php
echo _t("Startpage");
?>
:</td>
<td><select name="startapp"><?php
echo makefileopts($apps, $wpref->startapp);
?>
</select></td>
</tr>
<tr>
<td width="120px"><?php
echo _t("Default language");
?>
:</td>
<td><select name="language"><?php
echo getLanguages($wpref->language);
?>
</select></td>
</tr>
<tr>
<td><?php
示例6: openform
echo "</table></form>\n";
} else {
echo "<div class='admin-message'>\n";
//echo "<form action='".$formaction."' method='post'>\n";
echo openform('why_no_formname', 'why_no_formname', 'post', $formaction, array('downtime' => 0));
echo "<span style='color:red;font-weight:bold;'>" . sprintf($locale['502'], $upload_dir) . "</span><br />" . $locale['503'] . "<br />";
echo form_button($locale['504'], 'refresh2', 'refresh2', $locale['504'], array('class' => 'btn-primary btn-block'));
//echo "<input type='submit' class='button' value='".$locale['504']."' />";
echo "</form>\n";
echo "</div>\n";
}
echo "</div>";
echo "<div class='tbl2' id='show_multiform' style='font-weight:bold;cursor:pointer;margin-bottom:2px;'>" . $locale['495'] . "</div>";
echo "<div id='multi_upload' class='image_upload' style='padding:15px 0;'>";
$multi_files = makefilelist($upload_dir, ".|..|index.php", TRUE, "files", "php|js");
$multi_opts = makefileopts($multi_files);
if ($can_upload == TRUE) {
//echo "<form name='multiform' method='post' action='".."' enctype='multipart/form-data'>\n";
echo openform('multiform', 'multiform', 'post', FUSION_SELF . $aidlink . "&album_id=" . $_GET['album_id'], array('downtime' => 0, 'enctype' => 1));
echo "<table class='table table-responsive tbl-border center' cellpadding='2' cellspacing='0'>\n";
echo $multi_opts != "" ? "<tr>\n<td class='tbl1' colspan='2' style='text-align:center;'>" . $locale['496'] . "</td>\n</tr>\n" : "";
echo "<tr>\n<td class='tbl1' colspan='2' style='text-align:left;'>";
echo sprintf($locale['505'], $upload_dir) . "<br />";
echo sprintf($locale['506'], $album_title) . "<br />";
echo $locale['507'] . "<br />";
echo "</td>\n</tr>\n";
if ($multi_opts != "") {
echo "<tr>\n<td class='tbl1' style='text-align:right;vertical-align:top;width:20%;'>" . $locale['508'] . "</td>\n";
echo "<td class='tbl1'>";
echo "<select size='10' multiple name='multi_image[]' class='textbox' style='width:90%;'>" . $multi_opts . "</select>";
echo "</td>\n</tr>\n";
示例7: makefilelist
echo "</tr>\n<tr>\n";
echo "<td colspan='2' style='height:10px;background-color:#f6a504;'></td>\n";
echo "</tr>\n</table>\n";
echo "<br /><br />\n";
echo "<form name='setupform' method='post' action='setup.php'>\n";
echo "<table align='center' cellpadding='0' cellspacing='1' width='450' class='tbl-border'>\n<tr>\n";
echo "<td class='tbl2'><strong>";
if (isset($_POST['step']) && preg_match("/^[2-6]\$/", $_POST['step'])) {
echo $locale['00' . $_POST['step']];
} else {
echo $locale['001'];
}
echo "</strong></td>\n</tr>\n<tr>\n<td class='tbl1' style='text-align:center'>\n";
if (!isset($_POST['step']) || $_POST['step'] == "" || $_POST['step'] == "1") {
$locale_files = makefilelist("locale/", ".svn|.|..", true, "folders");
$locale_list = makefileopts($locale_files);
echo $locale['010'] . "<br /><br />";
echo "<select name='localeset' class='textbox' style='margin-top:5px'>\n";
echo $locale_list . "</select><br /><br />\n";
echo $locale['011'] . "\n";
echo "</td>\n</tr>\n<tr>\n<td class='tbl2' style='text-align:center'>\n";
echo "<input type='hidden' name='step' value='2' />\n";
echo "<input type='submit' name='next' value='" . $locale['007'] . "' class='button' />\n";
}
if (isset($_POST['step']) && $_POST['step'] == "2") {
if (!file_exists("config.php")) {
if (file_exists("_config.php") && function_exists("rename")) {
@rename("_config.php", "config.php");
} else {
$handle = fopen("config.php", "w");
fclose($handle);
示例8: makefileopts
echo "<input type='text' name='forum_name' value='" . $forum_name . "' class='textbox' style='width:285px;' /></td>\n";
echo "</tr>\n<tr>\n";
echo "<td colspan='2' class='tbl'>" . $locale['521'] . "<br />\n";
echo "<input type='text' name='forum_description' value='" . $forum_description . "' class='textbox' style='width:285px;' /></td>\n";
echo "</tr>\n<tr>\n";
echo "<td class='tbl'>" . $locale['522'] . "<br />\n";
echo "<select name='forum_cat' class='textbox' style='width:225px;'>\n" . $cat_opts . "</select></td>\n";
echo "<td width='55' class='tbl'>";
if (!isset($_GET['action']) || $_GET['action'] != "edit") {
echo $locale['523'] . "<br />\n<input type='text' name='forum_order' value='" . $forum_order . "' class='textbox' style='width:45px;' />";
echo "</td>\n</tr>\n";
} else {
echo "</td></tr>\n";
}
if (isset($_GET['action']) && $_GET['action'] == "edit") {
$forumIconImages = makefileopts(makefilelist(INFUSIONS . "fusionboard4/images/forum_icons/", ".|..|index.php"), $forum_icon);
echo "<tr><td colspan='2' class='tbl'>" . $locale['fb100'] . "<br />\n";
echo "<select name='forum_icon' class='textbox' style='width:285px;' />\n";
echo "<option value=''>---</option>\n{$forumIconImages}\n";
echo "</td>\n";
echo "</tr>\n<tr>\n";
}
function renderChildren($parent, $level = 1)
{
global $forum_parent;
$children = "";
$p_res = dbquery("select * from " . DB_PREFIX . "forums f\n\t\t\t\t\tleft join " . DB_PREFIX . "fb_forums f2 on f2.forum_id=f.forum_id\n\t\t\t\t\twhere f2.forum_parent='{$parent}'");
while ($p_data = dbarray($p_res)) {
$children .= "<option value='" . $p_data['forum_id'] . "'" . ($p_data['forum_id'] == $forum_parent ? " SELECTED" : "") . ">";
for ($i = $level; $i--; $i > 0) {
$children .= "--";
示例9: closesetup
echo "</div>\n";
echo "<!--button -->\n";
echo "<div class='text-right'>\n";
echo "<button type='submit' name='next' value='{$locale}' class='btn btn-primary' /><i class='entypo right-dir'></i> {$locale}</button>\n";
echo "</div>\n";
}
function closesetup()
{
echo "</form>\n";
echo "</aside>\n";
echo "</body>\n</html>\n";
}
opensetup();
// Step 1
if (!isset($_POST['step']) || $_POST['step'] == "" || $_POST['step'] == "1") {
$locale_list = makefileopts($locale_files, $_POST['localeset']);
echo $locale['010'] . "<br /><br />";
echo "<select name='localeset' class='input-sm form-control' style='margin-top:5px'>\n";
echo $locale_list . "</select><br /><br />\n";
echo $locale['011'] . "\n";
echo "</td>\n</tr>\n<tr>\n<td class='tbl2' style='text-align:center'>\n";
echo "<input type='hidden' name='step' value='2' />\n";
renderButton();
}
// Step 2
if (isset($_POST['step']) && $_POST['step'] == "2") {
if (!file_exists("config.php")) {
if (file_exists("_config.php") && function_exists("rename")) {
@rename("_config.php", "config.php");
} else {
$handle = fopen("config.php", "w");
示例10: dbarray
}
$data = dbarray($result);
$type_name = stripslash($data['type_name']);
$type_icon = $data['type_icon'];
$action = FUSION_SELF . $aidlink . "§ion=ratings&update=" . $_GET['edit'];
$panel = $locale['fb852'];
$button = $locale['fb854'];
} else {
$type_name = "";
$type_icon = "";
$action = FUSION_SELF . $aidlink . "§ion=ratings";
$panel = $locale['fb851'];
$button = $locale['fb853'];
}
opentable($panel);
$iconOpts = makefileopts(makefilelist(INFUSIONS . "fusionboard4/images/forum_icons/", ".|..|index.php|Thumbs.db"), $type_icon);
echo "<form action='{$action}' name='ratingForm' method='post'>\n\t\t<table width='300' cellspacing='1' cellpadding='0' class='tbl-border center'>\n\t\t<tr>\n\t\t\t<td class='tbl1'>" . $locale['fb855'] . "</td>\n\t\t\t<td class='tbl2'><input type='text' name='type_name' class='textbox' value='{$type_name}'></td>\n\t\t</tr>\n\t\t<tr>\n\t\t\t<td class='tbl1'>" . $locale['fb856'] . "</td>\n\t\t\t<td class='tbl2'><select name='type_icon' class='textbox'>\n\t\t\t{$iconOpts}\n\t\t\t</select></td>\n\t\t</tr>\n\t\t<tr>\n\t\t\t<td class='tbl1' colspan='2' style='text-align:center;'>\n\t\t\t<input type='submit' name='goRating' value='{$button}' class='button'>\n\t\t\t</td>\n\t\t</tr>\n\t\t</table>\n\t\t</form>\n";
closetable();
tablebreak();
opentable($locale['fb860']);
$result = dbquery("select * from " . DB_PREFIX . "fb_rate_type");
if (dbrows($result)) {
echo "<table width='300' cellspacing='1' cellpadding='0' class='tbl-border center'>\n\t\t\t<tr>\n\t\t\t\t<td class='tbl2' style='font-weight:bold;'>" . $locale['fb855'] . "</td>\n\t\t\t\t<td class='tbl2' style='font-weight:bold;'>" . $locale['fb856'] . "</td>\n\t\t\t\t<td class='tbl2' style='font-weight:bold;'>" . $locale['fb857'] . "</td>\n\t\t\t</tr>\n";
while ($data = dbarray($result)) {
echo "<tr>\n\t\t\t\t\t<td class='tbl1'>" . stripslash($data['type_name']) . "</td>\n\t\t\t\t\t<td class='tbl1'><img src='" . INFUSIONS . "fusionboard4/images/forum_icons/" . $data['type_icon'] . "' alt=''></td>\n\t\t\t\t\t<td class='tbl1'><a href='" . FUSION_SELF . $aidlink . "&section=ratings&edit=" . $data['type_id'] . "'>" . $locale['fb858'] . "</a> :: \n\t\t\t\t\t<a href='" . FUSION_SELF . $aidlink . "&section=ratings&del=" . $data['type_id'] . "' onclick=\"return confirm('" . $locale['fb869'] . "');\">" . $locale['fb859'] . "</a></td>\n\t\t\t\t</tr>\n";
}
echo "</table>\n";
} else {
echo "<div align='center'>" . $locale['fb861'] . "</div>\n";
}
closetable();
示例11: makefilelist
echo "<option value='" . $vote1_user_id[$i] . "'>" . $vote1_user_name[$i] . "</option>\n";
}
echo "</select>\n";
echo "<select multiple='multiple' size='10' name='votelist2' id='votelist2' class='textbox' style='width:140px' onchange=\"addvoteUser('votelist1','votelist2');\">\n";
if (isset($vote2_user_id) && is_array($vote2_user_id)) {
for ($i = 0; $i < count($vote2_user_id); $i++) {
echo "<option value='" . $vote2_user_id[$i] . "'>" . $vote2_user_name[$i] . "</option>\n";
}
}
echo "<input type='hidden' name='forum_vote' />\n";
echo "</div>";
// Forum Cat Images
if ($settings['forum_cat_icons'] == "1") {
$forum_cat_image = $forum_cat_image != "" ? $forum_cat_image : "default.png";
$image_files = makefilelist(IMAGES_FC, ".|..|index.php", true);
$image_list = makefileopts($image_files, $forum_cat_image);
echo "<div class='forum_admin'>";
echo "<strong>" . $locale['535'] . "</strong><br />\n";
echo "<select name='forum_image' class='textbox' style='width:200px;' onchange=\"PreviewForumCat();\" id='forumcat_image'>\n" . $image_list . "</select>";
echo "<br /><br /><strong>" . $locale['536'] . "</strong><br /><br />";
echo "<img src='" . ($forum_cat_image ? IMAGES_FC . $forum_cat_image : IMAGES_FC . "default.png") . "' alt='ForumCat' style='border:none' id='forumcat_preview' />";
echo "</div>";
echo "<script type='text/javascript'>\n";
echo "function PreviewForumCat() {\n";
echo "\tvar selectForumCat = document.getElementById('forumcat_image');\n";
echo "\tvar imageForumCat = document.getElementById('forumcat_preview');\n";
echo "\tvar optionValue = selectForumCat.options[selectForumCat.selectedIndex].value;\n";
echo "\tif (optionValue!='') {\n";
echo "\t\timageForumCat.src = '" . IMAGES_FC . "' + optionValue;\n";
echo "\t} else {\n";
echo "\t\timageForumCat.src = '" . IMAGES_FC . "default.png';\n";
示例12: _t
</script>
<form method="post">
<table>
<tr><td><?php
echo _t("Name");
?>
</td><td><input type="text" name="name" value=""></td></tr>
<tr><td><?php
echo _t("Id");
?>
</td><td><input type="text" name="id" value=""></td></tr>
<tr><td><?php
echo _t("Flag");
?>
</td><td><img src = "" id = "flag_image"><select id = "flag" name = "flag"><?php
echo makefileopts($flags);
?>
</select></td></tr>
<tr><td><input type="submit" name="save" value="<?php
echo _t("Save");
?>
"></td></tr>
</table>
</form>
<?php
if (isset($_POST['save'])) {
try {
if (empty($_POST['name']) || empty($_POST['id']) || empty($_POST['flag'])) {
throw new Exception("missing data");
}
示例13: foreach
}
$addon_type_list = "";
foreach ($addon_types as $k => $addon_type) {
$addon_type_list .= "<option value='" . $k . "'" . ($addon_modtype == $k ? " selected" : "") . ">" . $addon_type . "</option>\n";
}
$months = explode("|", $locale['months']);
$month_list = "";
for ($i = 1; $i < count($months); $i++) {
$month_list .= "<option value='" . $i . "'" . ($i == $addon_date_m ? " selected" : "") . ">" . $months[$i] . "</option>\n";
}
$day_list = "";
for ($i = 1; $i < 32; $i++) {
$day_list .= "<option value='" . $i . "'" . ($i == $addon_date_d ? " selected" : "") . ">" . $i . "</option>\n";
}
$dld_list = makefilelist($addon_upload_dir, ".|..|index.php", true);
$addon_download_list = $addon_download ? makefileopts($dld_list, $addon_download) : "";
$addon_status_list = "";
foreach ($addon_status as $k => $addon_status_name) {
$addon_status_list .= "<option value='" . $k . "'" . ($addon_status_value == $k ? " selected='selected'" : "") . ">" . $addon_status_name . "</option>\n";
}
opentable(isset($_GER['action']) && $_GET['action'] == "edit" ? $locale['addondb426'] : $locale['addondb425']);
echo "<form name='add_mod' method='post' action='" . FUSION_SELF . $aidlink . "' enctype='multipart/form-data'>\n";
echo "<input type='hidden' name='action' value='" . (isset($_GET['action']) ? $_GET['action'] : "") . "'>\n";
echo "<input type='hidden' name='addon_id' value='" . (isset($_GET['addon_id']) ? $_GET['addon_id'] : "") . "'>\n";
echo "<table align='center' cellpadding='0' cellspacing='0' class='body'>\n";
echo "" . (isset($error) ? "<tr><td class='tbl1 error' align='center' colspan='3'>" . $error . "</td></tr>" : "") . "\n";
echo "<tr>\n";
echo "<td class='tbl1' nowrap>" . $locale['addondb402'] . ":</td>\n";
echo "<td class='tbl1' nowrap><span class='error'>*</span></td>\n";
echo "<td class='tbl1'><input type='text' class='textbox' name='addon_name' value='" . $addon_name . "' style='width:300px;'></td>\n";
echo "</tr>\n<tr>\n";
示例14: log_admin_action
}
log_admin_action("admin-4", "admin_settings_language_save");
redirect(FUSION_SELF . $aidlink . "&error=" . $error);
}
$settings2 = array();
$result = dbquery("SELECT settings_name, settings_value FROM " . DB_SETTINGS);
while ($data = dbarray($result)) {
$settings2[$data['settings_name']] = $data['settings_value'];
}
$locale_files = makefilelist(LOCALE, ".|..", true, "folders");
opentable($locale['lang100']);
echo "<form name='settingsform' method='post' action='" . FUSION_SELF . $aidlink . "'>\n";
echo "<table cellpadding='0' cellspacing='0' width='500' class='center'>\n<tr>\n";
echo "<td width='50%' class='tbl'>" . $locale['lang101'] . "</td>\n";
echo "<td width='50%' class='tbl'><select name='localeset' class='textbox'>\n";
echo makefileopts($locale_files, $settings2['locale']) . "\n";
echo "</select></td>\n";
echo "</tr>\n<tr>\n";
echo "<td width='50%' class='tbl'>" . $locale['lang102'] . "</td>\n";
echo "<td width='50%' class='tbl'><select name='multilanguage' class='textbox'>\n";
echo "<option value='1'" . ($settings2['locale_multi'] == "1" ? " selected='selected'" : "") . ">" . $locale['518'] . "</option>\n";
echo "<option value='0'" . ($settings2['locale_multi'] == "0" ? " selected='selected'" : "") . ">" . $locale['519'] . "</option>\n";
echo "</select></td>\n";
echo "</tr>\n<tr>\n";
echo "<td width='50%' class='tbl'>" . $locale['lang107'] . "</td>\n";
echo "<td width='50%' class='tbl'><select name='multilanguage_forum' class='textbox'>\n";
echo "<option value='1'" . ($settings2['locale_multi_forum'] == "1" ? " selected='selected'" : "") . ">" . $locale['518'] . "</option>\n";
echo "<option value='0'" . ($settings2['locale_multi_forum'] == "0" ? " selected='selected'" : "") . ">" . $locale['519'] . "</option>\n";
echo "</select></td>\n";
echo "</tr>\n<tr>\n";
echo "<td width='50%' class='tbl'>" . $locale['lang108'] . "</td>\n";
示例15: author
+--------------------------------------------------------+
| This program is released as free software under the
| Affero GPL license. You can redistribute it and/or
| modify it under the terms of this license which you
| can read by viewing the included agpl.txt or online
| at www.gnu.org/licenses/agpl.html. Removal of this
| copyright header is strictly prohibited without
| written permission from the original author(s).
+--------------------------------------------------------*/
if (!checkRights("I")) {
header("Location:../../../index.php");
exit;
}
define("CAT_DIR", INFUSIONS . "varcade/categoryimg/");
$cat_files = makefilelist(CAT_DIR, ".|..|index.php", true);
$cat_list = makefileopts($cat_files);
if (isset($stats_id_cat) && !isNum($stats_id_cat)) {
fallback("index.php");
}
if (isset($step) && $step == "delete") {
$result = dbquery("DELETE FROM " . $db_prefix . "varcade_cats WHERE cid='{$stats_id_cat}'");
}
if (isset($_POST['save_cat'])) {
$title = stripinput($_POST['title']);
$cid = stripinput($_POST['cid']);
$access = stripinput($_POST['access']);
$cat_image = stripinput($_POST['cat_image']);
if (isset($step) && $step == "edit") {
$result = dbquery("UPDATE " . $db_prefix . "varcade_cats SET title='{$title}', access='{$access}',image='{$cat_image}' WHERE cid ='{$stats_id_cat}'");
} else {
$result = dbquery("INSERT INTO " . $db_prefix . "varcade_cats (cid, title,image,access) VALUES('', '{$title}','{$cat_image}', '{$access}')");