Give me button code

neel - April 11, 2008 - 06:19
Project:BUEditor
Version:5.x-1.1
Component:Code
Category:support request
Priority:normal
Assigned:Unassigned
Status:active
Description

Hello,

I want button code for font color and background color for text.

Please help me.

#1

zincica - May 11, 2008 - 09:06

for backgroun color:
js:
var form = [
{name: 'style', title: 'background color', type: 'select', options: {'': '', 'background-color:red;': 'red', 'background-color:green;': 'green', 'background-color:blue;': 'blue', 'background-color:black;': 'black'}},
];
eDefTagDialog('font', form, 'Background color', 'Ok');

for font color:

js:
var form = [
{name: 'color', title: 'Font color', type: 'select', options: {'': '', red: 'red', blue: 'blue', green: 'green'}},
];
eDefTagDialog('font', form, 'Fon color', 'Ok');

#2

Hipfox - May 11, 2008 - 20:29

But the font element is not supported in XHTML 1.0 Strict DTD. Use styles (instead of the tag) to define the font face, font size, and font color of text.

js:
var form = [
{name: 'style', title: 'Font color', type: 'select', options: {'': '', 'color:red;': 'red', 'color:blue;': 'blue', 'color:green;': 'green'}},
];
eDefTagDialog('span', form, 'Font color', 'Ok');

 
 

Drupal is a registered trademark of Dries Buytaert.