This site has been archived and you can no longer log in or post new messages. For up-to-date community resources please visit

eZ Community » Forums » Developer » Editing...

Editing ezpublish/design/standard/templates/content/datatype/edit/eztext.tpl wont change anything

Editing ezpublish/design/standard/templates/content/datatype/edit/eztext.tpl wont change anything

Sunday 06 April 2003 8:03:57 pm - 5 replies

I was trying to integrate htmlarea into ezpublish (if OE were working in Mozilla, I could see myself paying the 150 bucks but surely not for an IE only solution) and lazy as I am, I figured I could just as well modify the Text type for this.

So I went and tried changing ezpublish/design/standard/templates/content/datatype/edit/eztext.tpl
but whatever I do, it won't end up on the page (not even something along the lines of adding AAAAAAAAA to the file).

From all I can tell, caching is deactivated so I really can't figure it out.

(If anyone already has integrated HTMLArea 3, I'd like to hear about that, of course blunk.gif Emoticon

Monday 07 April 2003 9:52:35 am

happy.gif Emoticon


Monday 07 April 2003 3:10:37 pm

That's not really what I'm after.

Basically, I'm fine with saving the data in a text field but I want to change the edit template to support HTMLArea.

Basically, I just need to find a way to add a onLoad call to the body tag and some script tags to the header (so the scripts are already loaded when the onLoad call happens).

Modified on Monday 07 April 2003 3:47:37 pm by Gabriel Ambuehl

Monday 07 April 2003 4:47:53 pm

That would go into the general page layout, that is in


More info on this at


Tuesday 08 April 2003 1:37:45 am

I already had come to that solution but it kinda sucks for one reason: you'll end up with ALL textareas being HTML editors, even with such where it doesn't make much sense (descriptions of objects for one).

Now HTMLArea can actually just turn some textareas to editors (by using the name attribute of those) but just how am I supposed to know this before the page is assembled?

It would actually work with onFocus events on the textareas in question but it's not exactly an elegant solution either. Whomever decided that only body may have onLoad evets should be shot blunk.gif Emoticon.

Ah well, maybe I can figure it out. I'll post it, rest assured (works better with IE than with Mozilla at the moment but the script is alpha so...).

Tuesday 08 April 2003 3:25:06 pm

You can attach onload events with just scripting.

window.onload = someFunctionPointer;

If you need multiple events, then you'll need the DOM methods attachEvent and addEventListener, neither of which work in Opera 6 or less and IE5-Mac.

if ( window.attachEvent )
window.attachEvent( "onload", functionPointer );
else if ( window.addEventListener )
window.addEventListener( "load", functionPointer, false );

Of course, for any function-pointer resource you can substitute-in an anonymous function.

Also, the onload event handler applies not only to <body>, but also to <applet>, <embed>, <frame>, <frameset>, <img>, <link>, and <script>


You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from