PeopleSoft Rich Text boxes on custom tool Bars

Source: Internet
Author: User

You may have encountered the Rich-text edit box when using PT8.50 or at 8.51. The plugin allows you to format text, add colors, links, pictures, and more. Here are the following:

If there is only one field in the page, the text box will have enough space to accommodate the tools bars, but there are usually many fields in the page.

As a result, the required space for the field that represents the text box is less, and the tool entries in the text box need to be thin or scaled appropriately according to business requirements.

The simple implementation is as follows:

On the page Field property of the Long Edit box, you have the options option, tick "Enable Rich Text", and select the available configuration in the first drop-down box (they are all HTML objects).

The second drop-down box "image location URL Id" is used to specify the path to save the picture uploaded in long Edit box.

Open the system's existing HTML object "PT_RET_CFG_PTPPB" to see its contents:

<!%
FCKEditor configuration file for Pagelet Wizard HTML Data Source
-

ckeditor.config.skin= ' office2003 ';

CKEDITOR.config.toolbar =
[
[' Source ', '-', ' Maximize ', ' Preview ', ' Print ', '-', ' Cut ', ' Copy ', ' Paste ', '-', ' Undo ', ' Redo ', '-', ' Find ', ' Replace ', '-' , ' Horizontalrule ', ' Table ', ' imageupload ', ' Link ', ' Unlink ', ' Specialchar '],
[' Format ', ' Font ', ' FontSize ', '-', ' Bold ', ' Italic ', ' underline ', ' Strike '],
[' Justifyleft ', ' justifycenter ', ' justifyright ', ' justifyblock ', '-', ' numberedlist ', ' BulletedList ', ' outdent ', ' Indent ', '-', ' textcolor ', ' BGColor ']
];

You can see that each toolbar button is represented by an entry in the CKEDITOR.config.toolbar array, and now I just need the link button, so I create a new HTML object Pt_rte_cfg_csn_just_link,

It is important to note that the name of the new HTML object must start with Pt_rte_cfg_, otherwise you will not see the custom HTML objects in the Long Edit Box Properties dialog.

<!%
FCKEditor configuration file for Pagelet Wizard HTML Data Source
-

ckeditor.config.skin= ' office2003 ';

CKEDITOR.config.toolbar =
[
[' Link ', ' Unlink ']
];

Then select Pt_rte_cfg_csn_just_link in the Long Edit Box Properties dialog:

The slimming effect is as follows:

But the above text box at the bottom of the HTML tag, look very uncomfortable, and then want to modify in the previous configuration file, but the configuration file does not seem to control this east of the code, in the end where to modify it?

It turns out that when I use a custom configuration, it overrides the configuration in the system's default configuration, which is config.js.

in <ps_home>\webserv\<domain>\applications\peoplesoft\portal.war\<site>\ Config.js file found in CKEditor

(In my system, its location is: D:\PT8.51\webserv\peoplesoft\applications\peoplesoft\PORTAL.war\ps\ckeditor\config.js)

Ckeditor.editorconfig = function (config)

{

Define changes to the default configuration here. For example:

Config.autolanguage = false;

Config.defaultlanguage = ' PT-BR ';

config.skin= ' office2003 ';

config.resize_enabled = false;

Config.removeplugins = ' Elementspath ';

Config.toolbar =

[

[' Maximize ', ' Preview ', ' Print ', '-', ' Cut ', ' Copy ', ' Paste ', '-', ' Undo ', ' Redo ', '-', ' Find ', ' Replace ', '-', ' Horizontalrule ', ' Table ', ' imageupload ', ' Link ', ' Unlink ', ' Specialchar '],

[' Format ', ' Font ', ' FontSize ', '-', ' Bold ', ' Italic ', ' underline ', ' Strike '],

[' Justifyleft ', ' justifycenter ', ' justifyright ', ' justifyblock ', '-', ' numberedlist ', ' BulletedList ', ' outdent ', ' Indent ', '-', ' textcolor ', ' BGColor ']

];

You can see that the file contains the following two lines:

config.resize_enabled = false;

Config.removeplugins = ' Elementspath ';

Then add these two lines to the custom HTML object:

<!%
FCKEditor configuration file for Pagelet Wizard HTML Data Source
-

ckeditor.config.skin= ' office2003 ';
CKEDITOR.config.resize_enabled = false;
CKEDITOR.config.removePlugins = ' Elementspath ';
CKEDITOR.config.toolbar =
[
[' Link ', ' Unlink ']
];

Get the following effect:

PeopleSoft Rich Text boxes on custom tool Bars

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.