custom javascript in category description...

Phoca Gallery - image gallery extension
ando0689
Phoca Newbie
Phoca Newbie
Posts: 4
Joined: 17 May 2013, 19:56

custom javascript in category description...

Post 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!
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 49149
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: custom javascript in category description...

Post 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
If you find Phoca extensions useful, please support the project
Post Reply