You are here: javascript » smf error when using the kani theme in 2 0
SMF Error when using the kani theme in 2.0
- Written By
- PHPin24
- Submitted At
- 2010-02-17 17:15:24
- Num Views
- 1833
- Category
- Javascript
|
While in SMF and trying to post the WYSIWYG editor doesn't show up and I see this Javascript error. I am not exactly sure why it is doing this but I think it might have something to do with the kani theme that I am using. Below is the error I am getting... Error: this.opt.sUniqueId.php_htmlspecialchars is not a function Source File: http://www.phpin24.co.za/Themes/default/scripts/editor.js Line: 1521 I am not using the default theme but I still shows up as loading the editor from the default theme? Assuming that the editor always stays in the default theme and loads from there unless you actually specify or create a new scripts folder on your server within the "kani theme" (in my case) folder. By PHPin24 @ 2010-02-17 17:15:24
|
|
Ok so I have found the problem. In the kani theme used in the previous release of SMF, it had a link to a file called script.js in the default theme. In the older version of SMF this link was located in /Themes/default/script.js in the version 2.0 of SMF it is located in /Themes/default/scripts/script.js So to fix this all you need to do is add the extra directory "scripts" to the link in your index.template.php file. [size=14pt]SOLUTION:[/size] STEP 1: Go to your folder containing your forum. Find the folders: Themes/kani_119/index.template.php If you are using a different theme than kani and experience the same problem go to Themes/your_theme_name_here/index.template.php STEP 2: Find the line containing something like: <script language="JavaScript" type="text/javascript" src="', $settings['default_theme_url'], '/script.js?fin11"></script> Change it to: <script language="JavaScript" type="text/javascript" src="', $settings['default_theme_url'], '/scripts/script.js?fin11"></script> In my theme index file (index.template.php) it was located on line 71. STEP 3: Save the file index.template.php and refresh your web browser. Your WYSIWYG should now show. STEP 4: Only if all the WYSIWYG icons aren't showing If you find that some of the icons in the WYSIWYG editor don't show correctly then it is a simple case of copying them from Themes/default/images/bbc/ to Themes/kani_119/images/bbc Or if you are using a different template and experiencing the same issue then just copy the images from Themes/default/images/bbc/ to Themes/your_theme_name_here/images/bbc You can either copy all or in my case I just needed 3 files: 1. toggle.gif 2. unformat.gif 3. orderlist.gif Hope this helps someone else having the same issue By PHPin24 @ 2010-02-17 18:13:03
|
