wiki:0.2/FAQ

FAQ

How to create a button which sets a class to an element ?

Use the following syntax:

setClass('classname','elementname','');
  • classname is the name of the class
  • elementname is the name of the element (in uppercase). You can define here a list of elements, separated by a comma:
setClass('classname','P,DIV,TD','');
  • The third parameter is a list of conflicting classes, separated by a comma:
setClass('classname','P,DIV,TD','myclass,myotherclass');
  • The character * represents every element or class:
setClass('classname','*','');
setClass('classname','P','*');
  • The fourth parameter is optional and allows you to define compatible classes (exclusive).
setClass('class3','P','','class1,class2');