For a 'quick & dirty' method while debug mode is turned on and logged in as an admin to the ACP, go into...How do you add codes to the drop down?
<script src="{$javaScriptSource}/digitalpoint/syntax_highlighter.js?_v={$xenOptions.jsVersion}"></script>
$1
<option value="code=CFM">ColdFusion</option>
<option value="code=JavaScript">JavaScript</option>
<option value="code=CSS">CSS</option>
ErrorException: preg_replace_callback() [<a href='function.preg-replace-callback'>function.preg-replace-callback</a>]: Unknown modifier '.' - library/DigitalPointSyntaxHighlighter/geshi.php:3456
It adds JavaScript and CSS to the drop-down by default... pretty sure if you added hundreds of languages to the drop-down (most of which people have never heard of), it's going to make them use it less, not more.The digitalpoint addon is nice, but it doesn't add the languages to the drop down list. Members have to do this manually which means it rarely gets used.
It's the normal code pop up from the editor button for it.
There are no options.
You would want to edit the normal xenforo editor_dialog_code template.I found code thing, just forgot to come back and say.
How can I add/remove the code tags in the drop down menu? I would like to remove html, css, and add a few others, c#, java and C++ ;]
Can you explain more.You would want to edit the normal xenforo editor_dialog_code template.
<dl class="ctrlUnit">
<dt>{xen:phrase language}:</dt>
<dd><select name="redactor_code_type" id="redactor_code_type" class="textCtrl">
<option value="code">{xen:phrase general_code}</option>
<option value="php">PHP</option>
<option value="html">HTML</option>
<option value="python">Python</option>
<option value="c++">C++</option>
<option value="c#">C#</option>
</select></dd>
</dl>
<dl class="ctrlUnit">
<dt>{xen:phrase code}:</dt>
<dd><textarea name="redactor_code_code" id="redactor_code_code" class="textCtrl" style="height: 100px; resize: none"></textarea></dd>
</dl>
<dl class="ctrlUnit submitUnit">
<dt></dt>
<dd>
<input type="button" name="upload" class="redactor_modal_btn button primary" id="redactor_insert_code_btn" value="{xen:phrase insert}" />
<a href="javascript:void(null);" class="redactor_modal_btn redactor_btn_modal_close button">{xen:phrase cancel}</a>
</dd>
</dd>
Finally retried the update, and it occurs when people use bogus languages, eg:This update broke it:
Code:ErrorException: Undefined index: LANG_NAME - library/DigitalPointSyntaxHighlighter/geshi.php:651 Generated By: Squawkers13, Today at 9:53 AM Stack Trace #0 /srv/spigot-forums/library/DigitalPointSyntaxHighlighter/geshi.php(651): XenForo_Application::handlePhpError(8, 'Undefined index...', '/srv/spigot-for...', 651, Array) #1 /srv/spigot-forums/library/DigitalPointSyntaxHighlighter/BbCode/Formatter/Base.php(92): GeSHi->get_language_name() #2 [internal function]: DigitalPointSyntaxHighlighter_BbCode_Formatter_Base->renderTagCode(Array, Array, Object(DigitalPointSyntaxHighlighter_BbCode_Formatter_Base)) #3 /srv/spigot-forums/library/XenForo/BbCode/Formatter/Base.php(664): call_user_func(Array, Array, Array, Object(DigitalPointSyntaxHighlighter_BbCode_Formatter_Base)) #4 /srv/spigot-forums/library/XenForo/BbCode/Formatter/Base.php(575): XenForo_BbCode_Formatter_Base->renderValidTag(Array, Array, Array) #5 /srv/spigot-forums/library/XenForo/BbCode/Formatter/Base.php(488): XenForo_BbCode_Formatter_Base->renderTag(Array, Array, 0) #6 /srv/spigot-forums/library/XenForo/BbCode/Formatter/Base.php(469): XenForo_BbCode_Formatter_Base->renderTreeElement(Array, Array, 0) #7 /srv/spigot-forums/library/XenForo/BbCode/Formatter/Base.php(449): XenForo_BbCode_Formatter_Base->renderSubTree(Array, Array) #8 /srv/spigot-forums/library/XenForo/BbCode/Parser.php(505): XenForo_BbCode_Formatter_Base->renderTree(Array, Array) #9 /srv/spigot-forums/library/XenForo/BbCode/TextWrapper.php(117): XenForo_BbCode_Parser->render('The [I]spigot.y...', Array) #10 /srv/spigot-forums/library/EWRcarta/ViewPublic/PageView.php(28): XenForo_BbCode_TextWrapper->__toString() #11 /srv/spigot-forums/library/XenForo/ViewRenderer/Abstract.php(227): EWRcarta_ViewPublic_PageView->renderHtml() #12 /srv/spigot-forums/library/XenForo/ViewRenderer/HtmlPublic.php(67): XenForo_ViewRenderer_Abstract->renderViewObject('EWRcarta_ViewPu...', 'Html', Array, 'EWRcarta_PageVi...') #13 /srv/spigot-forums/library/XenForo/FrontController.php(582): XenForo_ViewRenderer_HtmlPublic->renderView('EWRcarta_ViewPu...', Array, 'EWRcarta_PageVi...', NULL) #14 /srv/spigot-forums/library/XenForo/FrontController.php(158): XenForo_FrontController->renderView(Object(XenForo_ControllerResponse_View), Object(XenForo_ViewRenderer_HtmlPublic), Array) #15 /srv/spigot-forums/index.php(13): XenForo_FrontController->run() #16 {main} Request State array(3) { ["url"] => string(91) "http://www.spigotmc.org/wiki/spigot-configuration-spigot-yml/?redirect=spigot-configuration" ["_GET"] => array(2) { ["/wiki/spigot-configuration-spigot-yml/"] => string(0) "" ["redirect"] => string(20) "spigot-configuration" } ["_POST"] => array(0) { } }
java -jar BuildTools.jar --rev 1.8
{
"name": "acme/blog",
"type": "phpbb3-extension",
"description": "This will add an AI with mind reading capabilities to your board who will post your thoughts to a blog",
"homepage": "http://yourdomain.com/",
"version": "1.0.0",
"time": "2012-02-15",
"license": "GPLv2",
"authors": [
{
"name": "Unknown Bliss",
"email": "ub@yourdomain.com",
"homepage": "http://yourdomain.com"
},
{
"name": "imkingdavid",
"email": "ikd@yourdomain.com",
"homepage": "http://yourdomain.com"
}
},
"require": {
"php": ">=5.4",
"phpbb": ">=3.1.0"
},
"extra": {
"display-name": "phpBB Blog Extension",
"author-notes": "This extension requires PHP 10.4 RC2 and only works with MySQL 20.4 because AI and Mindreading is not supported in earlier versions. Donate via head transfer to address MCJFIDEO29495"
}
}
We use essential cookies to make this site work, and optional cookies to enhance your experience.