diff options
Diffstat (limited to 'phpBB/adm/style')
-rw-r--r-- | phpBB/adm/style/acp_ext_delete_data.html | 2 | ||||
-rw-r--r-- | phpBB/adm/style/acp_groups.html | 7 | ||||
-rw-r--r-- | phpBB/adm/style/acp_inactive.html | 2 | ||||
-rw-r--r-- | phpBB/adm/style/acp_modules.html | 2 | ||||
-rw-r--r-- | phpBB/adm/style/acp_prune_users.html | 4 | ||||
-rw-r--r-- | phpBB/adm/style/acp_users_prefs.html | 5 | ||||
-rw-r--r-- | phpBB/adm/style/acp_users_signature.html | 64 | ||||
-rw-r--r-- | phpBB/adm/style/admin.css | 30 | ||||
-rw-r--r-- | phpBB/adm/style/admin.js | 3 | ||||
-rw-r--r-- | phpBB/adm/style/colour_swatch.html | 82 | ||||
-rw-r--r-- | phpBB/adm/style/editor.js | 336 | ||||
-rw-r--r-- | phpBB/adm/style/overall_footer.html | 2 | ||||
-rw-r--r-- | phpBB/adm/style/overall_header.html | 5 |
13 files changed, 71 insertions, 473 deletions
diff --git a/phpBB/adm/style/acp_ext_delete_data.html b/phpBB/adm/style/acp_ext_delete_data.html index bbac22055f..5b38d9b8d0 100644 --- a/phpBB/adm/style/acp_ext_delete_data.html +++ b/phpBB/adm/style/acp_ext_delete_data.html @@ -21,7 +21,7 @@ <form id="acp_extensions" method="post" action="{U_PURGE}"> <fieldset class="submit-buttons"> <legend>{L_EXTENSION_DELETE_DATA}</legend> - <input class="button1" type="submit" name="purge" value="{L_EXTENSION_DELETE_DATA}" /> + <input class="button1" type="submit" name="delete_data" value="{L_EXTENSION_DELETE_DATA}" /> <input class="button2" type="submit" name="cancel" value="{L_CANCEL}" /> </fieldset> </form> diff --git a/phpBB/adm/style/acp_groups.html b/phpBB/adm/style/acp_groups.html index a77010b636..925d24f3a3 100644 --- a/phpBB/adm/style/acp_groups.html +++ b/phpBB/adm/style/acp_groups.html @@ -92,7 +92,12 @@ </dl> <dl> <dt><label for="group_colour">{L_GROUP_COLOR}{L_COLON}</label><br /><span>{L_GROUP_COLOR_EXPLAIN}</span></dt> - <dd><input name="group_colour" type="text" id="group_colour" value="{GROUP_COLOUR}" size="6" maxlength="6" /><!-- IF GROUP_COLOUR --> <span style="background-color: #{GROUP_COLOUR}"> </span><!-- ENDIF --> <span>[ <a href="{U_SWATCH}" onclick="popup(this.href, 636, 150, '_swatch'); return false">{L_COLOUR_SWATCH}</a> ]</span></dd> + <dd> + <input name="group_colour" type="text" id="group_colour" value="{GROUP_COLOUR}" size="6" maxlength="6" /> + <!-- IF GROUP_COLOUR --> <span style="background-color: #{GROUP_COLOUR}"> </span><!-- ENDIF --> <span> + [ <a href="#" id="color_palette_toggle">{L_COLOUR_SWATCH}</a> ]</span> + <div id="color_palette_placeholder" style="display: none;" data-orientation="h" data-height="12" data-width="15" data-target="#group_colour"></div> + </dd> </dl> <dl> <dt><label for="group_rank">{L_GROUP_RANK}{L_COLON}</label></dt> diff --git a/phpBB/adm/style/acp_inactive.html b/phpBB/adm/style/acp_inactive.html index 0302007861..1c42c93f76 100644 --- a/phpBB/adm/style/acp_inactive.html +++ b/phpBB/adm/style/acp_inactive.html @@ -53,7 +53,7 @@ </table> <fieldset class="display-options"> - {L_DISPLAY_LOG}{L_COLON} {S_LIMIT_DAYS} {L_SORT_BY}{L_COLON} {S_SORT_KEY} {S_SORT_DIR}<!-- IF .pagination --> Users per page{L_COLON} <input class="inputbox autowidth" type="number" name="users_per_page" id="users_per_page" size="3" value="{USERS_PER_PAGE}" /><!-- ENDIF --> + {L_DISPLAY_LOG}{L_COLON} {S_LIMIT_DAYS} {L_SORT_BY}{L_COLON} {S_SORT_KEY} {S_SORT_DIR}<!-- IF .pagination --> {L_USERS_PER_PAGE}{L_COLON} <input class="inputbox autowidth" type="number" name="users_per_page" id="users_per_page" size="3" value="{USERS_PER_PAGE}" /><!-- ENDIF --> <input class="button2" type="submit" value="{L_GO}" name="sort" /> </fieldset> diff --git a/phpBB/adm/style/acp_modules.html b/phpBB/adm/style/acp_modules.html index 8870c815af..5024a950b9 100644 --- a/phpBB/adm/style/acp_modules.html +++ b/phpBB/adm/style/acp_modules.html @@ -151,7 +151,7 @@ <td style="width: 15%; white-space: nowrap; text-align: center; vertical-align: middle;"> <!-- IF modules.MODULE_ENABLED --><a href="{modules.U_DISABLE}">{L_DISABLE}</a><!-- ELSE --><a href="{modules.U_ENABLE}">{L_ENABLE}</a><!-- ENDIF --> </td> <td class="actions"> <span class="up-disabled" style="display:none;">{ICON_MOVE_UP_DISABLED}</span> - <span class="up"><a href="{modules.U_MOVE_DOWN}">{ICON_MOVE_DOWN}</a></span> + <span class="up"><a href="{modules.U_MOVE_UP}">{ICON_MOVE_UP}</a></span> <span class="down-disabled" style="display:none;">{ICON_MOVE_DOWN_DISABLED}</span> <span class="down"><a href="{modules.U_MOVE_DOWN}">{ICON_MOVE_DOWN}</a></span> <a href="{modules.U_EDIT}">{ICON_EDIT}</a> diff --git a/phpBB/adm/style/acp_prune_users.html b/phpBB/adm/style/acp_prune_users.html index 1257f3fb3d..2bbb03a834 100644 --- a/phpBB/adm/style/acp_prune_users.html +++ b/phpBB/adm/style/acp_prune_users.html @@ -39,11 +39,11 @@ </dl> <dl> <dt><label for="posts_on_queue">{L_POSTS_ON_QUEUE}{L_COLON}</label></dt> - <dd><select name="queue_select">{S_COUNT_OPTIONS}</select> <input type="number" id="posts_on_queue" name="posts_on_queue" /></select> + <dd><select name="queue_select">{S_COUNT_OPTIONS}</select> <input type="number" id="posts_on_queue" name="posts_on_queue" /></dd> </dl> <!-- IF S_GROUP_LIST --> <dl> - <dt><label for="group_id">{L_GROUP}{L_COLON}</label><br /><span>{L_PRUNE_USERS_GROUP_EXPLAIN}</dt> + <dt><label for="group_id">{L_GROUP}{L_COLON}</label><br /><span>{L_PRUNE_USERS_GROUP_EXPLAIN}</span></dt> <dd><select name="group_id">{S_GROUP_LIST}</select></dd> </dl> <!-- ENDIF --> diff --git a/phpBB/adm/style/acp_users_prefs.html b/phpBB/adm/style/acp_users_prefs.html index f1b9e28a66..1092b25b04 100644 --- a/phpBB/adm/style/acp_users_prefs.html +++ b/phpBB/adm/style/acp_users_prefs.html @@ -40,11 +40,6 @@ <label><input type="radio" class="radio" name="notifypm" value="0"<!-- IF not NOTIFY_PM --> id="notifypm" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd> </dl> <dl> - <dt><label for="popuppm">{L_POPUP_ON_PM}{L_COLON}</label></dt> - <dd><label><input type="radio" class="radio" name="popuppm" value="1"<!-- IF POPUP_PM --> id="popuppm" checked="checked"<!-- ENDIF --> /> {L_YES}</label> - <label><input type="radio" class="radio" name="popuppm" value="0"<!-- IF not POPUP_PM --> id="popuppm" checked="checked"<!-- ENDIF --> /> {L_NO}</label></dd> - </dl> - <dl> <dt><label for="lang">{L_BOARD_LANGUAGE}{L_COLON}</label></dt> <dd><select id="lang" name="lang">{S_LANG_OPTIONS}</select></dd> </dl> diff --git a/phpBB/adm/style/acp_users_signature.html b/phpBB/adm/style/acp_users_signature.html index 2b4964803e..0a04c411d2 100644 --- a/phpBB/adm/style/acp_users_signature.html +++ b/phpBB/adm/style/acp_users_signature.html @@ -3,6 +3,8 @@ var form_name = 'user_signature'; var text_name = 'signature'; + var load_draft = false; + var upload = false; // Define the bbCode tags var bbcode = new Array(); @@ -20,11 +22,11 @@ o: '{LA_BBCODE_O_HELP}', p: '{LA_BBCODE_P_HELP}', w: '{LA_BBCODE_W_HELP}', + a: '{LA_BBCODE_A_HELP}', s: '{LA_BBCODE_S_HELP}', f: '{LA_BBCODE_F_HELP}', y: '{LA_BBCODE_Y_HELP}', - d: '{LA_BBCODE_D_HELP}', - tip: '{L_STYLES_TIP}' + d: '{LA_BBCODE_D_HELP}' <!-- BEGIN custom_tags --> ,cb_{custom_tags.BBCODE_ID}{L_COLON} '{custom_tags.A_BBCODE_HELPLINE}' <!-- END custom_tags --> @@ -32,7 +34,7 @@ // ]]> </script> -<script type="text/javascript" src="{T_TEMPLATE_PATH}/editor.js"></script> +<!-- INCLUDEJS {T_ASSETS_PATH}/javascript/editor.js --> <form id="user_signature" method="post" action="{U_ACTION}"> @@ -48,52 +50,46 @@ <p>{L_SIGNATURE_EXPLAIN}</p> <div id="format-buttons"> - <input type="button" class="button2" accesskey="b" name="addbbcode0" value=" B " style="font-weight:bold; width: 30px;" onclick="bbstyle(0)" onmouseover="helpline('b')" onmouseout="helpline('tip')" /> - <input type="button" class="button2" accesskey="i" name="addbbcode2" value=" i " style="font-style:italic; width: 30px;" onclick="bbstyle(2)" onmouseover="helpline('i')" onmouseout="helpline('tip')" /> - <input type="button" class="button2" accesskey="u" name="addbbcode4" value=" u " style="text-decoration: underline; width: 30px;" onclick="bbstyle(4)" onmouseover="helpline('u')" onmouseout="helpline('tip')" /> - <input type="button" class="button2" accesskey="q" name="addbbcode6" value="Quote" style="width: 50px" onclick="bbstyle(6)" onmouseover="helpline('q')" onmouseout="helpline('tip')" /> - <input type="button" class="button2" accesskey="c" name="addbbcode8" value="Code" style="width: 40px" onclick="bbstyle(8)" onmouseover="helpline('c')" onmouseout="helpline('tip')" /> - <input type="button" class="button2" accesskey="l" name="addbbcode10" value="List" style="width: 40px" onclick="bbstyle(10)" onmouseover="helpline('l')" onmouseout="helpline('tip')" /> - <input type="button" class="button2" accesskey="o" name="addbbcode12" value="List=" style="width: 40px" onclick="bbstyle(12)" onmouseover="helpline('o')" onmouseout="helpline('tip')" /> - <input type="button" class="button2" accesskey="y" name="addlistitem" value="[*]" style="width: 40px" onclick="bbstyle(-1)" onmouseover="helpline('y')" onmouseout="helpline('tip')" /> + <input type="button" class="button2" accesskey="b" name="addbbcode0" value=" B " style="font-weight:bold; width: 30px" onclick="bbstyle(0)" title="{L_BBCODE_B_HELP}" /> + <input type="button" class="button2" accesskey="i" name="addbbcode2" value=" i " style="font-style:italic; width: 30px" onclick="bbstyle(2)" title="{L_BBCODE_I_HELP}" /> + <input type="button" class="button2" accesskey="u" name="addbbcode4" value=" u " style="text-decoration: underline; width: 30px" onclick="bbstyle(4)" title="{L_BBCODE_U_HELP}" /> + <!-- IF S_BBCODE_QUOTE --> + <input type="button" class="button2" accesskey="q" name="addbbcode6" value="Quote" style="width: 50px" onclick="bbstyle(6)" title="{L_BBCODE_Q_HELP}" /> + <!-- ENDIF --> + <input type="button" class="button2" accesskey="c" name="addbbcode8" value="Code" style="width: 40px" onclick="bbstyle(8)" title="{L_BBCODE_C_HELP}" /> + <input type="button" class="button2" accesskey="l" name="addbbcode10" value="List" style="width: 40px" onclick="bbstyle(10)" title="{L_BBCODE_L_HELP}" /> + <input type="button" class="button2" accesskey="o" name="addbbcode12" value="List=" style="width: 40px" onclick="bbstyle(12)" title="{L_BBCODE_O_HELP}" /> + <input type="button" class="button2" accesskey="y" name="addlistitem" value="[*]" style="width: 40px" onclick="bbstyle(-1)" title="{L_BBCODE_LISTITEM_HELP}" /> <!-- IF S_BBCODE_IMG --> - <input type="button" class="button2" accesskey="p" name="addbbcode14" value="Img" style="width: 40px" onclick="bbstyle(14)" onmouseover="helpline('p')" onmouseout="helpline('tip')" /> + <input type="button" class="button2" accesskey="p" name="addbbcode14" value="Img" style="width: 40px" onclick="bbstyle(14)" title="{L_BBCODE_P_HELP}" /> <!-- ENDIF --> <!-- IF S_LINKS_ALLOWED --> - <input type="button" class="button2" accesskey="w" name="addbbcode16" value="URL" style="text-decoration: underline; width: 40px" onclick="bbstyle(16)" onmouseover="helpline('w')" onmouseout="helpline('tip')" /> + <input type="button" class="button2" accesskey="w" name="addbbcode16" value="URL" style="text-decoration: underline; width: 40px" onclick="bbstyle(16)" title="{L_BBCODE_W_HELP}" /> <!-- ENDIF --> <!-- IF S_BBCODE_FLASH --> - <input type="button" class="button2" accesskey="d" name="addbbcode18" value="Flash" onclick="bbstyle(18)" onmouseover="helpline('d')" onmouseout="helpline('tip')" /> + <input type="button" class="button2" accesskey="d" name="addbbcode18" value="Flash" onclick="bbstyle(18)" title="{L_BBCODE_D_HELP}" /> <!-- ENDIF --> - - {L_FONT_SIZE}{L_COLON} <select name="addbbcode20" onchange="bbfontstyle('[size=' + this.form.addbbcode20.options[this.form.addbbcode20.selectedIndex].value + ']', '[/size]');this.form.addbbcode20.selectedIndex = 2;" title="{L_FONT_SIZE}" onmouseover="helpline('f')" onmouseout="helpline('tip')"> + <select name="addbbcode20" onchange="bbfontstyle('[size=' + this.form.addbbcode20.options[this.form.addbbcode20.selectedIndex].value + ']', '[/size]');this.form.addbbcode20.selectedIndex = 2;" title="{L_BBCODE_F_HELP}"> <option value="50">{L_FONT_TINY}</option> <option value="85">{L_FONT_SMALL}</option> <option value="100" selected="selected">{L_FONT_NORMAL}</option> - <option value="150">{L_FONT_LARGE}</option> - <option value="200">{L_FONT_HUGE}</option> + <!-- IF not MAX_FONT_SIZE or MAX_FONT_SIZE >= 150 --> + <option value="150">{L_FONT_LARGE}</option> + <!-- IF not MAX_FONT_SIZE or MAX_FONT_SIZE >= 200 --> + <option value="200">{L_FONT_HUGE}</option> + <!-- ENDIF --> + <!-- ENDIF --> </select> - <!-- IF .custom_tags --> - <br /><br /> <!-- BEGIN custom_tags --> - <input type="button" class="button2" name="addbbcode{custom_tags.BBCODE_ID}" value="{custom_tags.BBCODE_TAG}" onclick="bbstyle({custom_tags.BBCODE_ID})"<!-- IF custom_tags.BBCODE_HELPLINE !== '' --> onmouseover="helpline('cb_{custom_tags.BBCODE_ID}')" onmouseout="helpline('tip')"<!-- ENDIF --> /> + <input type="button" class="button2" name="addbbcode{custom_tags.BBCODE_ID}" value="{custom_tags.BBCODE_TAG}" onclick="bbstyle({custom_tags.BBCODE_ID})" title="{custom_tags.BBCODE_HELPLINE}" /> <!-- END custom_tags --> - <!-- ENDIF --> - </div> - <p><input type="text" class="text full" style="border: 0; background: none;" name="helpbox" value="{L_STYLES_TIP}" /></p> - <dl> - <dt style="width: 90px;"> - <script type="text/javascript"> - // <![CDATA[ - colorPalette('v', 12, 10); - // ]]> - </script> + <dt style="width: 90px;" id="color_palette_placeholder" data-orientation="v" data-height="12" data-width="15" data-bbcode="true"> </dt> - <dd style="margin-{S_CONTENT_FLOW_BEGIN}{L_COLON} 90px;"><textarea name="signature" rows="10" cols="60" style="width: 95%;" onselect="storeCaret(this);" onclick="storeCaret(this);" onkeyup="storeCaret(this);" onfocus="initInsertions();" data-bbcode="true">{SIGNATURE}</textarea></dd> - <dd style="margin-{S_CONTENT_FLOW_BEGIN}{L_COLON} 90px; margin-top: 5px;"> + <dd style="margin-{S_CONTENT_FLOW_BEGIN}: 90px;"><textarea name="signature" rows="10" cols="60" style="width: 95%;" onselect="storeCaret(this);" onclick="storeCaret(this);" onkeyup="storeCaret(this);" onfocus="initInsertions();" data-bbcode="true">{SIGNATURE}</textarea></dd> + <dd style="margin-{S_CONTENT_FLOW_BEGIN}: 90px; margin-top: 5px;"> <!-- IF S_BBCODE_ALLOWED --> <label><input type="checkbox" class="radio" name="disable_bbcode"{S_BBCODE_CHECKED} /> {L_DISABLE_BBCODE}</label> <!-- ENDIF --> @@ -104,7 +100,7 @@ <label><input type="checkbox" class="radio" name="disable_magic_url"{S_MAGIC_URL_CHECKED} /> {L_DISABLE_MAGIC_URL}</label> <!-- ENDIF --> </dd> - <dd style="margin-{S_CONTENT_FLOW_BEGIN}{L_COLON} 90px; margin-top: 10px;"><strong>{L_OPTIONS}{L_COLON} </strong>{BBCODE_STATUS} :: {IMG_STATUS} :: {FLASH_STATUS} :: {URL_STATUS} :: {SMILIES_STATUS}</dd> + <dd style="margin-{S_CONTENT_FLOW_BEGIN}: 90px; margin-top: 10px;"><strong>{L_OPTIONS}{L_COLON} </strong>{BBCODE_STATUS} :: {IMG_STATUS} :: {FLASH_STATUS} :: {URL_STATUS} :: {SMILIES_STATUS}</dd> </dl> </fieldset> diff --git a/phpBB/adm/style/admin.css b/phpBB/adm/style/admin.css index eae4f42641..c4f1caf722 100644 --- a/phpBB/adm/style/admin.css +++ b/phpBB/adm/style/admin.css @@ -381,6 +381,14 @@ li { color: #BC2A4D; } +#tabs a:hover { + background-position: 0 -69px; +} + +#tabs a:hover span { + background-position: 100% -69px; +} + #tabs .activetab a { background-position: 0 0; border-bottom: 1px solid #DCDEE2; @@ -392,14 +400,6 @@ li { color: #23649F; } -#tabs a:hover { - background-position: 0 -69px; -} - -#tabs a:hover span { - background-position: 100% -69px; -} - #tabs .activetab a:hover span { color: #115098; } @@ -737,6 +737,15 @@ td { border-spacing: 1px; } +dt#color_palette_placeholder table { + margin-right: 5px; + width: 80px; +} + +#color_palette_placeholder td { + padding: 0; +} + table.type2 { border: none; background: none; @@ -1578,6 +1587,8 @@ input.button1:focus, input.button2:focus, input.button3:focus { #darkenwrapper { display: none; + position: relative; + z-index: 44; } #darken { @@ -2354,11 +2365,14 @@ fieldset.permissions .padding { .dropdown .dropdown-contents { z-index: 2; overflow: hidden; + overflow-y: auto; background: #fff; border: 1px solid #b9b9b9; border-radius: 5px; padding: 5px; position: relative; + min-width: 40px; + max-height: 200px; box-shadow: 1px 3px 5px rgba(0, 0, 0, 0.2); -webkit-box-sizing: border-box; -moz-box-sizing: border-box; diff --git a/phpBB/adm/style/admin.js b/phpBB/adm/style/admin.js index e9f0f1e512..dd46124f97 100644 --- a/phpBB/adm/style/admin.js +++ b/phpBB/adm/style/admin.js @@ -133,6 +133,9 @@ function parse_document(container) column += colspan; }); }); + + // Remove <dfn> in disabled extensions list + $this.find('tr.ext_disabled > .empty:nth-child(2) + .empty').siblings(':first-child').children('dfn').remove(); }); /** diff --git a/phpBB/adm/style/colour_swatch.html b/phpBB/adm/style/colour_swatch.html deleted file mode 100644 index e692a8bd91..0000000000 --- a/phpBB/adm/style/colour_swatch.html +++ /dev/null @@ -1,82 +0,0 @@ -<!DOCTYPE html> -<html dir="{S_CONTENT_DIRECTION}" lang="{S_USER_LANG}"> -<head> -<meta charset="utf-8"> -<title>{L_COLOUR_SWATCH}</title> - -<style type="text/css"> -/* <![CDATA[ */ - body { - background-color: #404040; - color: #fff; - } - - table { - border-collapse: separate; - border-spacing: 0; - border: 0; - } - - td { - border: solid 1px #333; - padding: 1px; - } - - .over { - border-color: white; - } - - .out { - border-color: #333333; - } - - img { - border: 0; - } -/* ]]> */ -</style> -</head> - -<body> - -<script type="text/javascript"> -// <![CDATA[ - var r = 0, g = 0, b = 0; - - var numberList = new Array(6); - numberList[0] = '00'; - numberList[1] = '33'; - numberList[2] = '66'; - numberList[3] = '99'; - numberList[4] = 'CC'; - numberList[5] = 'FF'; - - document.writeln('<table>'); - - for (r = 0; r < 6; r++) - { - document.writeln('<tr>'); - - for (g = 0; g < 6; g++) - { - for (b = 0; b < 6; b++) - { - color = String(numberList[r]) + String(numberList[g]) + String(numberList[b]); - document.write('<td style="background-color: #' + color + ';" onmouseover="this.className=\'over\'" onmouseout="this.className=\'out\'">'); - document.write('<a href="#" onclick="cell(\'' + color + '\'); return false;"><img src="{T_IMAGES_PATH}spacer.gif" width="13" height="10" alt="#' + color + '" title="#' + color + '" \/><\/a>'); - document.writeln('<\/td>'); - } - } - document.writeln('<\/tr>'); - } - document.writeln('<\/table>'); - - function cell(color) - { - opener.document.forms["{OPENER}"].{NAME}.value = color; - } -// ]]> -</script> - -</body> -</html> diff --git a/phpBB/adm/style/editor.js b/phpBB/adm/style/editor.js deleted file mode 100644 index 9938ff5d0b..0000000000 --- a/phpBB/adm/style/editor.js +++ /dev/null @@ -1,336 +0,0 @@ -/** -* bbCode control by subBlue design [ www.subBlue.com ] -* Includes unixsafe colour palette selector by SHS` -*/ - -// Startup variables -var imageTag = false; -var theSelection = false; - -// Check for Browser & Platform for PC & IE specific bits -// More details from: http://www.mozilla.org/docs/web-developer/sniffer/browser_type.html -var clientPC = navigator.userAgent.toLowerCase(); // Get client info -var clientVer = parseInt(navigator.appVersion, 10); // Get browser version - -var is_ie = ((clientPC.indexOf('msie') !== -1) && (clientPC.indexOf('opera') === -1)); -var is_win = ((clientPC.indexOf('win') !== -1) || (clientPC.indexOf('16bit') !== -1)); -var baseHeight; - -/** -* Shows the help messages in the helpline window -*/ -function helpline(help) { - document.forms[form_name].helpbox.value = help_line[help]; -} - -/** -* Fix a bug involving the TextRange object. From -* http://www.frostjedi.com/terra/scripts/demo/caretBug.html -*/ -function initInsertions() { - var doc; - - if (document.forms[form_name]) { - doc = document; - } else { - doc = opener.document; - } - - var textarea = doc.forms[form_name].elements[text_name]; - - if (is_ie && typeof(baseHeight) !== 'number') { - textarea.focus(); - baseHeight = doc.selection.createRange().duplicate().boundingHeight; - - if (!document.forms[form_name]) { - document.body.focus(); - } - } -} - -/** -* bbstyle -*/ -function bbstyle(bbnumber) { - if (bbnumber !== -1) { - bbfontstyle(bbtags[bbnumber], bbtags[bbnumber+1]); - } else { - insert_text('[*]'); - document.forms[form_name].elements[text_name].focus(); - } -} - -/** -* Apply bbcodes -*/ -function bbfontstyle(bbopen, bbclose) { - theSelection = false; - - var textarea = document.forms[form_name].elements[text_name]; - - textarea.focus(); - - if ((clientVer >= 4) && is_ie && is_win) { - // Get text selection - theSelection = document.selection.createRange().text; - - if (theSelection) { - // Add tags around selection - document.selection.createRange().text = bbopen + theSelection + bbclose; - document.forms[form_name].elements[text_name].focus(); - theSelection = ''; - return; - } - } else if (document.forms[form_name].elements[text_name].selectionEnd - && (document.forms[form_name].elements[text_name].selectionEnd - document.forms[form_name].elements[text_name].selectionStart > 0)) { - mozWrap(document.forms[form_name].elements[text_name], bbopen, bbclose); - document.forms[form_name].elements[text_name].focus(); - theSelection = ''; - return; - } - - //The new position for the cursor after adding the bbcode - var caret_pos = getCaretPosition(textarea).start; - var new_pos = caret_pos + bbopen.length; - - // Open tag - insert_text(bbopen + bbclose); - - // Center the cursor when we don't have a selection - // Gecko and proper browsers - if (!isNaN(textarea.selectionStart)) { - textarea.selectionStart = new_pos; - textarea.selectionEnd = new_pos; - } - // IE - else if (document.selection) { - var range = textarea.createTextRange(); - range.move("character", new_pos); - range.select(); - storeCaret(textarea); - } - - textarea.focus(); - return; -} - -/** -* Insert text at position -*/ -function insert_text(text, spaces, popup) { - var textarea; - - if (!popup) { - textarea = document.forms[form_name].elements[text_name]; - } else { - textarea = opener.document.forms[form_name].elements[text_name]; - } - - if (spaces) { - text = ' ' + text + ' '; - } - - if (!isNaN(textarea.selectionStart)) { - var sel_start = textarea.selectionStart; - var sel_end = textarea.selectionEnd; - - mozWrap(textarea, text, ''); - textarea.selectionStart = sel_start + text.length; - textarea.selectionEnd = sel_end + text.length; - } else if (textarea.createTextRange && textarea.caretPos) { - if (baseHeight !== textarea.caretPos.boundingHeight) { - textarea.focus(); - storeCaret(textarea); - } - - var caret_pos = textarea.caretPos; - caret_pos.text = caret_pos.text.charAt(caret_pos.text.length - 1) === ' ' ? caret_pos.text + text + ' ' : caret_pos.text + text; - } else { - textarea.value = textarea.value + text; - } - - if (!popup) { - textarea.focus(); - } -} - -/** -* Add inline attachment at position -*/ -function attach_inline(index, filename) { - insert_text('[attachment=' + index + ']' + filename + '[/attachment]'); - document.forms[form_name].elements[text_name].focus(); -} - -/** -* Add quote text to message -*/ -function addquote(post_id, username) -{ - var message_name = 'message_' + post_id; - var theSelection = ''; - var divarea = false; - - if (document.all) { - divarea = document.all[message_name]; - } else { - divarea = document.getElementById(message_name); - } - - // Get text selection - not only the post content :( - if (window.getSelection) { - theSelection = window.getSelection().toString(); - } else if (document.getSelection) { - theSelection = document.getSelection(); - } else if (document.selection) { - theSelection = document.selection.createRange().text; - } - - if (theSelection === '' || typeof theSelection === 'undefined' || theSelection === null) { - if (divarea.innerHTML) { - theSelection = divarea.innerHTML.replace(/<br>/ig, '\n'); - theSelection = theSelection.replace(/<br\/>/ig, '\n'); - theSelection = theSelection.replace(/<\;/ig, '<'); - theSelection = theSelection.replace(/>\;/ig, '>'); - theSelection = theSelection.replace(/&\;/ig, '&'); - theSelection = theSelection.replace(/ \;/ig, ' '); - } else if (document.all) { - theSelection = divarea.innerText; - } else if (divarea.textContent) { - theSelection = divarea.textContent; - } else if (divarea.firstChild.nodeValue) { - theSelection = divarea.firstChild.nodeValue; - } - } - - if (theSelection) { - insert_text('[quote="' + username + '"]' + theSelection + '[/quote]'); - } - - return; -} - -/** -* From http://www.massless.org/mozedit/ -*/ -function mozWrap(txtarea, open, close) { - var selLength = (typeof(txtarea.textLength) === 'undefined') ? txtarea.value.length : txtarea.textLength; - var selStart = txtarea.selectionStart; - var selEnd = txtarea.selectionEnd; - var scrollTop = txtarea.scrollTop; - - if (selEnd === 1 || selEnd === 2) { - selEnd = selLength; - } - - var s1 = (txtarea.value).substring(0,selStart); - var s2 = (txtarea.value).substring(selStart, selEnd); - var s3 = (txtarea.value).substring(selEnd, selLength); - - txtarea.value = s1 + open + s2 + close + s3; - txtarea.selectionStart = selStart + open.length; - txtarea.selectionEnd = selEnd + open.length; - txtarea.focus(); - txtarea.scrollTop = scrollTop; - - return; -} - -/** -* Insert at Caret position. Code from -* http://www.faqts.com/knowledge_base/view.phtml/aid/1052/fid/130 -*/ -function storeCaret(textEl) { - if (textEl.createTextRange) { - textEl.caretPos = document.selection.createRange().duplicate(); - } -} - -/** -* Color pallette -*/ -function colorPalette(dir, width, height) { - var r = 0, g = 0, b = 0; - var numberList = new Array(6); - var color = ''; - - numberList[0] = '00'; - numberList[1] = '40'; - numberList[2] = '80'; - numberList[3] = 'BF'; - numberList[4] = 'FF'; - - document.writeln('<table class="type2">'); - - for (r = 0; r < 5; r++) { - if (dir === 'h') { - document.writeln('<tr>'); - } - - for (g = 0; g < 5; g++) { - if (dir === 'v') { - document.writeln('<tr>'); - } - - for (b = 0; b < 5; b++) { - color = String(numberList[r]) + String(numberList[g]) + String(numberList[b]); - document.write('<td bgcolor="#' + color + '" style="width: ' + width + 'px; height: ' + height + 'px;">'); - document.write('<a href="#" onclick="bbfontstyle(\'[color=#' + color + ']\', \'[/color]\'); return false;"><img src="images/spacer.gif" width="' + width + '" height="' + height + '" alt="#' + color + '" title="#' + color + '" /></a>'); - document.writeln('</td>'); - } - - if (dir === 'v') { - document.writeln('</tr>'); - } - } - - if (dir === 'h') { - document.writeln('</tr>'); - } - } - document.writeln('</table>'); -} - -/** -* Caret Position object -*/ -function caretPosition() { - var start = null; - var end = null; -} - -/** -* Get the caret position in an textarea -*/ -function getCaretPosition(txtarea) { - var caretPos = new caretPosition(); - - // simple Gecko/Opera way - if (txtarea.selectionStart || txtarea.selectionStart === 0) { - caretPos.start = txtarea.selectionStart; - caretPos.end = txtarea.selectionEnd; - } - // dirty and slow IE way - else if (document.selection) { - // get current selection - var range = document.selection.createRange(); - - // a new selection of the whole textarea - var range_all = document.body.createTextRange(); - range_all.moveToElementText(txtarea); - - // calculate selection start point by moving beginning of range_all to beginning of range - var sel_start; - for (sel_start = 0; range_all.compareEndPoints('StartToStart', range) < 0; sel_start++) { - range_all.moveStart('character', 1); - } - - txtarea.sel_start = sel_start; - - // we ignore the end value for IE, this is already dirty enough and we don't need it - caretPos.start = txtarea.sel_start; - caretPos.end = txtarea.sel_start; - } - - return caretPos; -} diff --git a/phpBB/adm/style/overall_footer.html b/phpBB/adm/style/overall_footer.html index 72af9d3388..8810414fc2 100644 --- a/phpBB/adm/style/overall_footer.html +++ b/phpBB/adm/style/overall_footer.html @@ -36,9 +36,9 @@ <script type="text/javascript" src="{T_ASSETS_PATH}/javascript/core.js?assets_version={T_ASSETS_VERSION}"></script> <!-- INCLUDEJS ajax.js --> <!-- INCLUDEJS admin.js --> -{$SCRIPTS} <!-- EVENT acp_overall_footer_after --> +{$SCRIPTS} </body> </html> diff --git a/phpBB/adm/style/overall_header.html b/phpBB/adm/style/overall_header.html index 455446f8e3..04f818f95a 100644 --- a/phpBB/adm/style/overall_header.html +++ b/phpBB/adm/style/overall_header.html @@ -103,7 +103,11 @@ function popup(url, width, height, name) // ]]> </script> + <!-- EVENT acp_overall_header_head_append --> + +{$STYLESHEETS} + </head> <body class="{S_CONTENT_DIRECTION} nojs"> @@ -153,7 +157,6 @@ function popup(url, width, height, name) </ul> </div> <!-- ENDIF --> - </ul> </div> <div id="main"> |