Sorry John-Marc!
I have 2 classes for each id. One with a border and one without. Each id has different styles assigned. When I used the code I originally asked for, the class removes the border on the id's but I lose the default styles.
In my css:
HTML Code:
.companyname {
font-size: 14px;
font-weight: bold;
font-style:normal;
height:18px;
vertical-align:bottom;
}
.companyname_border {
font-size: 14px;
font-weight: bold;
font-style:normal;
height:18px;
vertical-align:bottom;
border:2px dotted #0CF;
}
.sloganS {
font-size: 11px;
font-style: italic;
font-weight: bold;
}
.sloganS_border {
font-size: 11px;
font-style: italic;
font-weight: bold;
border:2px dotted #0CF;
}
In my php code: PHP Code:
<?php
...
else {
$optn2 = '#FF0000';
$fontsize = '14px';
$optn53 = 'The Company Name';
$optn54 = 'Verdana';
print "<span class=\"companyname\" id=\"companyName\" onMouseup=\"this.className='companyname_border'; applyClass('sloganS,cell','sloganS'); \" style=\"font-family:$optn54; font-size:$fontsize; color:$optn2;\">$optn53</span>";
}
...
?>
When the span is clicked on the designer preview for companyName, I need the .companyname_border class applied and the classes without borders applied to the remaining 9 ids on the designer preview (sloganS, cellS, etc.).
If the span for sloganS is clicked, I need the sloganS_border applied, and the classes with no borders applied to the remaining ids...like for the companyName id, the class .companyname.
Better?