Page 1 of 1

custom javascript in category description...

Posted: 17 May 2013, 20:03
by ando0689
Good day,
I want some javascript code to be executed when user enters into the gallery.
But in category description section when I write the <script> tag it is being removed after I save :( .
I turned off the Editor and switch off all filters for superuser, so in articles I have <script>, but in the description of phoca category I cannot :x

Can anyone help me with this?
Thanks in advance!

Re: custom javascript in category description...

Posted: 24 May 2013, 12:33
by Jan
Hi, writing javascript to descriptions or content in Joomla! is managed by Joomla! rights and Editor rights (Try to see settings of editor) and see XML of description field, e.g. here:
administrator\components\com_phocagallery\models\forms\phocagalleryc.xml

Code: Select all

<field name="description" type="editor" buttons="true" hide="pagebreak,readmore" class="inputbox" label="COM_PHOCAGALLERY_FIELD_DESCRIPTION_LABEL" filter="safehtml" description="COM_PHOCAGALLERY_FIELD_DESCRIPTION_DESC" />
remove the filter tag or change it to "raw" (but if you change it, you then need to check the editor and Joomla! settings)

Jan