You are not logged in.
#1 2006-03-05 00:31:02
- Chops
- Member
- Registered: 2006-03-05
- Posts: 6
Internet Explorer
Line: 3112
Char: 3
Error: 'delta_width' is null or not an object
Code: 0
This is the javascript error given when trying to use this script in Internet Explorer 6.
It results in the textarea not havng tinyMCE applied to it, eg, the textarea just remains a text area.
However, tinyMCE works perfectly fine in firefox.
I was wondering if anyone knew how to fix this.
Thank you,
Matthew.
Offline
#2 2006-03-05 02:59:52
- Chops
- Member
- Registered: 2006-03-05
- Posts: 6
Re: Internet Explorer
Never mind, this was an error caused by a pesky ,
Offline
#3 2006-03-22 19:22:54
- crash
- Member
- Registered: 2006-03-22
- Posts: 2
Re: Internet Explorer
where was/is this ","? I've seen another post that references it.
Last edited by crash (2006-03-22 19:47:09)
Offline
#4 2006-03-22 23:18:51
- dalio
- Member
- Registered: 2006-03-22
- Posts: 3
Re: Internet Explorer
Yeah I'm really intrigued by this too - I'm getting the 'delta_width is null or not an object' error in IE...
And... in FF 1.5 it's doing nothing but putting an error in the jscript console: editorTemplate has no properties.
Now I've looked into the tiny_mce.js file and found that there is a variable declared with delta_width and editorTemplate both involved, but my knowledge just doesn't cover this stuff and I can't see any pesky , !
Can anyone help? Chops?
Offline
#5 2006-03-22 23:36:13
- Felix Riesterer
- Administrator
- From: Germany
- Registered: 2005-12-30
- Posts: 4687
- Website
Re: Internet Explorer
dalio wrote:
and I can't see any pesky , !
There is an issue with Javascript syntax not allowing you to have a comma at the end of a comma separated list of elements.
Compare:
Code:
myObject = { myProperty1: 'value1', myProperty2 : 'value2, };with:
Code:
myObject = { myProperty1: 'value1', myProperty2 : 'value2 };The first version will break the Javascript interpreter and the line with the "pesky , " (have you found it?) will break the whole script, whereas the second version will work fine. Do you get the principle behind it? There are many more cases where there can be a comma too much and you simply won't recognize it unless you check every kind of brackets and verify if the comma behind them is correct.
Greetings,
Felix Riesterer.
Offline
#6 2006-03-23 13:04:27
- dalio
- Member
- Registered: 2006-03-22
- Posts: 3
Re: Internet Explorer
Ok, so this is wierd.
The examples on the MCE site look fine, the examples on my local machine work fine.
I upload the whole folder to my server, and I start getting the 'delta_width' error.
I've got the feeling it's something to do with the upload but could someone have a look at
[EDIT] Removed link, as this is now not an issue as I'm using a different tool now[/EDIT]
Last edited by dalio (2007-10-30 00:00:02)
Offline
#7 2006-03-23 14:58:16
- Felix Riesterer
- Administrator
- From: Germany
- Registered: 2005-12-30
- Posts: 4687
- Website
Re: Internet Explorer
dalio wrote:
I upload the whole folder to my server, and I start getting the 'delta_width' error.
Well, in my FireFox(1.5) It says: "editorTemplate has no properties"... Are you sure you uploaded _everything_ and all files have read permission?
Greetings,
Felix Riesterer.
Offline
#8 2006-03-23 15:05:04
- dalio
- Member
- Registered: 2006-03-22
- Posts: 3
Re: Internet Explorer
That's the same error I get in Firefox
I'm sure I've uploaded the whole folder structure - I did a file size check too. What's funny is that the .js file can't seem to be read by a browser - it's just coming back blank:
[EDIT] Removed link, as this is now not an issue as I'm now using a different tool[/EDIT]
If I Ftp this back to my machine it looks fine.
'Totally stumped'
Last edited by dalio (2007-10-29 23:59:36)
Offline
#9 2006-03-23 15:11:42
- Felix Riesterer
- Administrator
- From: Germany
- Registered: 2005-12-30
- Posts: 4687
- Website
Re: Internet Explorer
dalio wrote:
What's funny is that the .js file can't seem to be read by a browser - it's just coming back blank:
[EDIT](former link here)[/EDIT]
I cannot confirm this. In my Firefox the above link shows a "page" with one extra-long line of "text" (JS-code).
IE6.0 doesn't display the file but offers to download it.
Opera8.53 displays the code with line-breaks on.
So this file _is_ readable by a browser.
Maybe there are other files that cannot be read correctly?
Greetings,
Felix Riesterer.
Offline
#10 2006-05-12 16:54:28
- ScoobyDooUK
- Member
- Registered: 2006-05-12
- Posts: 1
Re: Internet Explorer
Hi,
I just ran into this problem and here is how I fixed it.
Firstly, for me, it seemed that this was to do with paths.
I use virtual URL's for my site, and TinyMCE was trying to locate the theme files in the wrong place (by using the virtual path, instead of the real path).
So in my html file I did:
Code:
tinyMCE.baseURL = app_base + 'templates/administration/tinymce/jscripts/tiny_mce';
tinyMCE.init({
mode : "textareas",
theme : "simple"
});Which seemed logical (after looking at the source). This alone did not work because of this block of code:
Code:
if (!tinyMCE.baseURL) {
var elements = document.getElementsByTagName('script');
for (var i=0; i<elements.length; i++) {
if (elements[i].src && (elements[i].src.indexOf("tiny_mce.js") != -1 || elements[i].src.indexOf("tiny_mce_dev.js") != -1 || elements[i].src.indexOf("tiny_mce_src.js") != -1 || elements[i].src.indexOf("tiny_mce_gzip") != -1)) {
var src = elements[i].src;
tinyMCE.srcMode = (src.indexOf('_src') != -1 || src.indexOf('_dev') != -1) ? '_src' : '';
tinyMCE.gzipMode = src.indexOf('_gzip') != -1;
src = src.substring(0, src.lastIndexOf('/'));
if (settings.exec_mode == "src" || settings.exec_mode == "normal")
tinyMCE.srcMode = settings.exec_mode == "src" ? '_src' : '';
tinyMCE.baseURL = src;
break;
}
}
}The problem being it would not work out the srcMode if I supply my own baseURL.
I changed it to this:
Code:
var elements = document.getElementsByTagName('script');
for (var i=0; i<elements.length; i++) {
if (elements[i].src && (elements[i].src.indexOf("tiny_mce.js") != -1 || elements[i].src.indexOf("tiny_mce_dev.js") != -1 || elements[i].src.indexOf("tiny_mce_src.js") != -1 || elements[i].src.indexOf("tiny_mce_gzip") != -1)) {
var src = elements[i].src;
tinyMCE.srcMode = (src.indexOf('_src') != -1 || src.indexOf('_dev') != -1) ? '_src' : '';
tinyMCE.gzipMode = src.indexOf('_gzip') != -1;
src = src.substring(0, src.lastIndexOf('/'));
if (settings.exec_mode == "src" || settings.exec_mode == "normal")
tinyMCE.srcMode = settings.exec_mode == "src" ? '_src' : '';
if (!tinyMCE.baseURL) { tinyMCE.baseURL = src; }
break;
}
}If there is a better way to do this, without altering the TinyMCE source files, can somebody explain it to me?
Thanks,
Jamie.
Offline
#11 2008-03-18 18:52:26
- taewoo
- Member
- Registered: 2008-03-18
- Posts: 1
Re: Internet Explorer
Could be a META tag issue:
http://www.freshsupercool.com/2008/03/1 … play-in-ie
Offline
© 2003-2010