For running HTML Editor , these fuctions must be called ::
print_textarea(1,8, 50, "", "", "intro", "", $courseid=0);
use_html_editor("intro");
into= the name of field;
If you want to call these fuction use_html_editor("intro"); in the *.php file ,you must call without any prarameter. like this : use_html_editor();
because when *.php file wants to render HTML page the editor had problem and can not show its body.
Pay attention that you can have as many as HTML Editors you want to have and in this file (*.php), and the number of print_textarea(1,8, 50, "", "", "intro", "", $courseid=0); fuction explan the number of your HTML Editor in your page, but just for one time in the end of that section you must call this fuction (use_html_editor()); .
And if you want to call it in *.html, you must call it with parameter. like: use_html_editor("intro");
I solved my problem from this way. And I hope for you................
Shirin Shirvani
Solution about HTML editor, for who has problem to show its body
by Shirin Shirvani -
Number of replies: 6
In reply to Shirin Shirvani
Re: Solution about HTML editor, for who has problem to show its body
by Martin Dougiamas -
Thanks, Shirin!
I think you've hit upon the solution to this hard-to-spot bug.
I'll get this fix implemented today in all branches of Moodle CVS.
I think you've hit upon the solution to this hard-to-spot bug.
I'll get this fix implemented today in all branches of Moodle CVS.
In reply to Martin Dougiamas
Re: Solution about HTML editor, for who has problem to show its body
by Martin Dougiamas -
Actually, I'm now able to make this bug happen with IE6 (I wasn't able to before) but this idea does NOT fix the problem, unfortunately.
I'm working on it so we can have a 1.3.1.
I'm working on it so we can have a 1.3.1.
In reply to Martin Dougiamas
Re: Solution about HTML editor, for who has problem to show its body
by Janne Mikkonen -
If you're able to make the bug happen (I can't) then could you try give default height and width values in HTMLArea.prototype.generate object?
Somewhere in here:
// size the IFRAME according to user's prefs or initial textarea
var height = (this.config.height == "auto" ? (this._ta_size.h + "px") : this.config.height);
height = parseInt(height)
var width = (this.config.width == "auto" ? (this._ta_size.w + "px") : this.config.width);
width = parseInt(width);
And see what happens?
In reply to Martin Dougiamas
Re: Solution about HTML editor, for who has problem to show its body
by Shirin Shirvani -
Hi, Martin
I solved my problem with this way. and the browser which I test it is IE6
shirin
I solved my problem with this way. and the browser which I test it is IE6
shirin
In reply to Shirin Shirvani
Re: Solution about HTML editor, for who has problem to show its body
by Martin Dougiamas -
I actually implemented it but without success ... the good news is that I found something else that caused it (a particular order of HTML tags).
Can you also please try Moodle 1.3.1? It should have a permanent fix for this problem now.
Can you also please try Moodle 1.3.1? It should have a permanent fix for this problem now.
In reply to Shirin Shirvani
Re: Solution about HTML editor, for who has problem to show its body
by vijesh g -
Thank you very much for the help.I was struggling to create an editor in my php code using moodle code.I found your comment very useful.Keep in touch
Regards
Vijesh
Regards
Vijesh