MyBB Community Forums

Full Version: Text editor and smilies dont work
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello,

the text editor and smilies of my forum do not work.
Do you have a solution for it? This might be helpful:

Headerinclude
<script type="text/javascript">
if (typeof jQuery == 'undefined') {
    document.write(unescape("%3Cscript src='http://code.jquery.com/jquery-1.7.2.min.js' type='text/javascript'%3E%3C/script%3E"));
}
</script>
<script type="text/javascript">
    var unreadAlerts = {$mybb->user['unreadAlerts']};
</script>
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/myalerts.js"></script>
{$stylesheets}
 <link rel="alternate" type="application/rss+xml" title="{$lang->latest_threads} (RSS 2.0)" href="{$mybb->settings['bburl']}/syndication.php" />
 <link rel="alternate" type="application/atom+xml" title="{$lang->latest_threads} (Atom 1.0)" href="{$mybb->settings['bburl']}/syndication.php?type=atom1.0" />
 <meta http-equiv="Content-Type" content="text/html; charset={$charset}" />
 <meta http-equiv="Content-Script-Type" content="text/javascript" />
 <script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/prototype.js?ver=1603"></script>
 <script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/general.js?ver=1603"></script>
 <script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/popup_menu.js?ver=1600"></script>

 <script type="text/javascript">
 if (typeof jQuery == 'undefined') {
 document.write(unescape("%3Cscript src='http://code.jquery.com/jquery-1.7.2.min.js' type='text/javascript'%3E%3C/script%3E"));
 }
 </script>
 <script type="text/javascript">
 jQuery(function($) { $(".close").click(function () {
 $(".avviso").fadeOut("slow");
 }); });</script>
 {$avvisospiti}

 <script type="text/javascript">
 <!--
 var cookieDomain = "{$mybb->settings['cookiedomain']}";
 var cookiePath = "{$mybb->settings['cookiepath']}";
 var cookiePrefix = "{$mybb->settings['cookieprefix']}";
 var deleteevent_confirm = "{$lang->deleteevent_confirm}";
 var removeattach_confirm = "{$lang->removeattach_confirm}";
 var loading_text = '{$lang->ajax_loading}';
 var saving_changes = '{$lang->saving_changes}';
 var use_xmlhttprequest = "{$mybb->settings['use_xmlhttprequest']}";
 var my_post_key = "{$mybb->post_code}";
 var imagepath = "{$theme['imgdir']}";
 // -->
 </script>
 {$newpmmsg}
remove second instance of jQuery code
<script type="text/javascript">
if (typeof jQuery == 'undefined') {
document.write(unescape("%3Cscript src='http://code.jquery.com/jquery-1.7.2.min.js' type='text/javascript'%3E%3C/script%3E"));
}
</script>
Done, but the editor does still not appear and the smilies are still not clickable.
Similar problem at http://community.mybb.com/thread-140113.html.
Enabling javascript at FireFox solved problem, but created another.

(2013-05-29, 05:14 PM)k1R@ Wrote: [ -> ]Done, but the editor does still not appear and the smilies are still not clickable.
jQuery is still loading twice. that needs to be avoided.
There was line which also caused the forum moderation to not work. I removed that and the forum moderation worked again. But the editor and smilies are still not on:

<script type="text/javascript">
var unreadAlerts = {$mybb->user['unreadAlerts']};
</script>
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/myalerts.js"></script>
{$stylesheets}
<link rel="alternate" type="application/rss+xml" title="{$lang->latest_threads} (RSS 2.0)" href="{$mybb->settings['bburl']}/syndication.php" />
<link rel="alternate" type="application/atom+xml" title="{$lang->latest_threads} (Atom 1.0)" href="{$mybb->settings['bburl']}/syndication.php?type=atom1.0" />
<meta http-equiv="Content-Type" content="text/html; charset={$charset}" />
<meta http-equiv="Content-Script-Type" content="text/javascript" />
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/prototype.js?ver=1603"></script>
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/general.js?ver=1603"></script>
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/popup_menu.js?ver=1600"></script>
<script type="text/javascript">jQuery.noConflict();</script>

<script type="text/javascript">
jQuery(function($) { $(".close").click(function () {
$(".avviso").fadeOut("slow");
}); });</script>
{$avvisospiti}

<script type="text/javascript">
<!--
var cookieDomain = "{$mybb->settings['cookiedomain']}";
var cookiePath = "{$mybb->settings['cookiepath']}";
var cookiePrefix = "{$mybb->settings['cookieprefix']}";
var deleteevent_confirm = "{$lang->deleteevent_confirm}";
var removeattach_confirm = "{$lang->removeattach_confirm}";
var loading_text = '{$lang->ajax_loading}';
var saving_changes = '{$lang->saving_changes}';
var use_xmlhttprequest = "{$mybb->settings['use_xmlhttprequest']}";
var my_post_key = "{$mybb->post_code}";
var imagepath = "{$theme['imgdir']}";
// -->
</script>
{$newpmmsg}
Please specify which line next time so others can use it as help too.

Anyways, try this:
{$stylesheets}
<link rel="alternate" type="application/rss+xml" title="{$lang->latest_threads} (RSS 2.0)" href="{$mybb->settings['bburl']}/syndication.php" />
<link rel="alternate" type="application/atom+xml" title="{$lang->latest_threads} (Atom 1.0)" href="{$mybb->settings['bburl']}/syndication.php?type=atom1.0" />
<meta http-equiv="Content-Type" content="text/html; charset={$charset}" />
<meta http-equiv="Content-Script-Type" content="text/javascript" />
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/prototype.js?ver=1603"></script>
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/general.js?ver=1603"></script>
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/popup_menu.js?ver=1600"></script>

<script type="text/javascript">
if (typeof jQuery == 'undefined') {
    document.write(unescape("%3Cscript src='http://code.jquery.com/jquery-latest.js' type='text/javascript'%3E%3C/script%3E"));
}
</script>
<script type="text/javascript">
var unreadAlerts = {$mybb->user['unreadAlerts']};
</script>
<script type="text/javascript" src="{$mybb->settings['bburl']}/jscripts/myalerts.js"></script>

<script type="text/javascript">
jQuery(function($) { $(".close").click(function () {
$(".avviso").fadeOut("slow");
}); });</script>
{$avvisospiti}

<script type="text/javascript">
<!--
var cookieDomain = "{$mybb->settings['cookiedomain']}";
var cookiePath = "{$mybb->settings['cookiepath']}";
var cookiePrefix = "{$mybb->settings['cookieprefix']}";
var deleteevent_confirm = "{$lang->deleteevent_confirm}";
var removeattach_confirm = "{$lang->removeattach_confirm}";
var loading_text = '{$lang->ajax_loading}';
var saving_changes = '{$lang->saving_changes}';
var use_xmlhttprequest = "{$mybb->settings['use_xmlhttprequest']}";
var my_post_key = "{$mybb->post_code}";
var imagepath = "{$theme['imgdir']}";
// -->
</script>
{$newpmmsg}

Also, I don't know url to your site, but if it's surely loading twice (you can check it with for example FireBug on the affected page), check your newthread/newreply templates for any additional jQuery load and make sure you don't use plugins which insert it into cache.