update to 1.0.1

This commit is contained in:
Vanilla Thunder 2012-12-20 00:20:31 +01:00
bovenliggende a41c6139a7
commit fb2e264928
21 gewijzigde bestanden met toevoegingen van 22394 en 22319 verwijderingen

Bestand weergeven

@ -1,36 +1,41 @@
# TinyMCE for OXID eShop CE 4.6 - 4.7
TinyMCE is a platform independent web based Javascript HTML WYSIWYG editor control released as Open Source under LGPL.
More information here :http://www.tinymce.com/
and here: https://github.com/tinymce
## INSTALLATION
### upload over ftp/ssh:
copy the content of the "copy_this" folder into the shop root directory
**if you are uploading files via ftp, switch to the binary transfer mode**
### ssh shell + git client:
navigate into the modules directory and create a "hdi" directory with a "vendormetadata.php" file inside it (can be empty yet)
clone remote git repo and switch to the "module" branch.
this commands works for debian and centos:
<pre>mkdir hdi
cd hdi/
wget https://raw.github.com/vanilla-thunder/hdi-tinymce/master/copy_this/modules/hdi/vendormetadata.php
git clone git://github.com/vanilla-thunder/hdi-tinymce.git
cd hdi-tinymce/
git checkout module
</pre>
## LICENSE AGREEMENT
HDI TinyMCE
Copyright (C) 2012 HEINER DIRECT GmbH & Co. KG
info: info@heiner-direct.com
This program is free software;
you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation;
either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, see <http://www.gnu.org/licenses/>
# TinyMCE 3.5.8 for OXID eShop CE 4.6+
TinyMCE is a platform independent web based Javascript HTML WYSIWYG editor control released as Open Source under LGPL.
More information here: http://www.tinymce.com/
and here: https://github.com/tinymce
## module version 1.0.1 from 2012-12-19
### changelog
* destroying smarty tags fixed
* tinyMCE 3.5.8 update
* module settings for relative urls and editor height added
## INSTALLATION
### upload over ftp/ssh:
copy the content of the "copy_this" folder into the shop root directory
**if you are uploading files via ftp, switch to the binary transfer mode**
### ssh shell + git client:
navigate into the modules directory and create a "hdi" directory with a "vendormetadata.php" file inside it (can be empty yet)
clone remote git repo and switch to the "module" branch.
this commands works for debian and centos:
<pre>mkdir hdi
cd hdi/
wget https://raw.github.com/vanilla-thunder/hdi-tinymce/master/copy_this/modules/hdi/vendormetadata.php
git clone git://github.com/vanilla-thunder/hdi-tinymce.git
cd hdi-tinymce/
git checkout module
</pre>
## LICENSE AGREEMENT
HDI TinyMCE
Copyright (C) 2012 HEINER DIRECT GmbH & Co. KG
info: info@heiner-direct.com
This program is free software;
you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation;
either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, see <http://www.gnu.org/licenses/>

Binair bestand niet weergegeven.

Voor

Breedte:  |  Hoogte:  |  Grootte: 6.4 KiB

Na

Breedte:  |  Hoogte:  |  Grootte: 3.9 KiB

Bestand weergeven

@ -1,83 +1,84 @@
<?php
/**
* HDI TinyMCE
* Copyright (C) 2012 HEINER DIRECT GmbH & Co. KG
* info: info@heiner-direct.com
*
* This program is free software;
* you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation;
* either version 3 of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
* You should have received a copy of the GNU General Public License along with this program; if not, see <http://www.gnu.org/licenses/>
*/
$sMetadataVersion = '1.0';
$aModule = array(
'id' => 'hdi-tinymce',
'title' => '<strong style="color:#006a8c;border: 1px solid #e30061;padding: 0 2px;background:white;">HDI</strong> <strong>TinyMCE 3.5.7</strong>',
'description' => 'backend implementation of TinyMCE Editor<br/>visit <a href="http://www.tinymce.com/" target="_blank">http://www.tinymce.com/</a> for more details',
'thumbnail' => 'hdi.png',
'version' => '3.5.7',
'author' => 'Marat Bedoev, HEINER DIRECT GmbH & Co. KG',
'email' => 'info@heiner-direct.com',
'url' => 'http://www.heiner-direct.com',
'extend' => array(
'article_main' => 'hdi/hdi-tinymce/tinymce',
'category_text' => 'hdi/hdi-tinymce/tinymce',
'content_main' => 'hdi/hdi-tinymce/tinymce',
'newsletter_main' => 'hdi/hdi-tinymce/tinymce',
'news_text' => 'hdi/hdi-tinymce/tinymce'
),
'templates' => array(
'tinymce.tpl' => 'hdi/hdi-tinymce/out/tpl/tinymce.tpl',
),
'blocks' => array(
array('template' => 'bottomnaviitem.tpl', 'block' => 'admin_bottomnaviitem', 'file' => 'admin_bottomnaviitem.tpl')
),
'settings' => array(
/* enabling tinyMCE for this classes */
array('group' => 'tinyMceMain', 'name' => 'bTinyMCE_article_main', 'type' => 'bool', 'value' => true, 'position' => 1),
array('group' => 'tinyMceMain', 'name' => 'bTinyMCE_category_text', 'type' => 'bool', 'value' => true, 'position' => 2),
array('group' => 'tinyMceMain', 'name' => 'bTinyMCE_content_main', 'type' => 'bool', 'value' => true, 'position' => 3),
array('group' => 'tinyMceMain', 'name' => 'bTinyMCE_newsletter_main', 'type' => 'bool', 'value' => true, 'position' => 4),
array('group' => 'tinyMceMain', 'name' => 'bTinyMCE_news_text', 'type' => 'bool', 'value' => true, 'position' => 5),
/* plugins */
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_autolink', 'type' => 'bool', 'value' => true, 'position' => 1),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_ists', 'type' => 'bool', 'value' => true, 'position' => 2),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_pagebreak', 'type' => 'bool', 'value' => true, 'position' => 3),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_style', 'type' => 'bool', 'value' => true, 'position' => 4),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_layer', 'type' => 'bool', 'value' => true, 'position' => 5),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_table', 'type' => 'bool', 'value' => true, 'position' => 6),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_save', 'type' => 'bool', 'value' => true, 'position' => 7),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_advhr', 'type' => 'bool', 'value' => true, 'position' => 8),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_advimage', 'type' => 'bool', 'value' => true, 'position' => 9),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_advlink', 'type' => 'bool', 'value' => true, 'position' => 10),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_emotions', 'type' => 'bool', 'value' => true, 'position' => 11),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_iespell', 'type' => 'bool', 'value' => true, 'position' => 12),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_inlinepopups', 'type' => 'bool', 'value' => true, 'position' => 13),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_insertdatetime', 'type' => 'bool', 'value' => true, 'position' => 14),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_preview', 'type' => 'bool', 'value' => true, 'position' => 15),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_media', 'type' => 'bool', 'value' => true, 'position' => 16),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_searchreplace', 'type' => 'bool', 'value' => true, 'position' => 17),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_print', 'type' => 'bool', 'value' => true, 'position' => 18),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_contextmenu', 'type' => 'bool', 'value' => true, 'position' => 19),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_paste', 'type' => 'bool', 'value' => true, 'position' => 20),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_directionality', 'type' => 'bool', 'value' => true, 'position' => 21),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_fullscreen', 'type' => 'bool', 'value' => true, 'position' => 22),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_noneditable', 'type' => 'bool', 'value' => true, 'position' => 23),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_visualchars', 'type' => 'bool', 'value' => true, 'position' => 24),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_nonbreaking', 'type' => 'bool', 'value' => true, 'position' => 25),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_xhtmlxtras', 'type' => 'bool', 'value' => true, 'position' => 26),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_template', 'type' => 'bool', 'value' => true, 'position' => 27),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_wordcount', 'type' => 'bool', 'value' => true, 'position' => 28),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_advlist', 'type' => 'bool', 'value' => true, 'position' => 29),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_autosave', 'type' => 'bool', 'value' => true, 'position' => 30),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_visualblocks', 'type' => 'bool', 'value' => true, 'position' => 31),
array('group' => 'tinyMcePlugins', 'name' => 'sTinyMCE_customplugins', 'type' => 'str', 'value' => "", 'position' => 32)
)
);
/* to do
* - implement relative_url setting into module settings
*
*/
<?php
/**
* HDI TinyMCE
* Copyright (C) 2012 HEINER DIRECT GmbH & Co. KG
* info: info@heiner-direct.com
*
* This program is free software;
* you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation;
* either version 3 of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
* You should have received a copy of the GNU General Public License along with this program; if not, see <http://www.gnu.org/licenses/>
*/
$sMetadataVersion = '1.0';
$aModule = array(
'id' => 'hdi-tinymce',
'title' => '<strong style="color:#006a8c;border: 1px solid #e30061;padding: 0 2px;background:white;">HDI</strong> <strong>TinyMCE 3.5.8</strong>',
'description' => 'backend implementation of TinyMCE Editor<br/>visit <a href="http://www.tinymce.com/" target="_blank">http://www.tinymce.com/</a> for more details',
'thumbnail' => 'hdi.png',
'version' => '1.0.1 (2012-12-19)</dd><dt>newest version</dt><dd><img src="https://raw.github.com/vanilla-thunder/hdi-tinymce/module/version.jpg" /><br/>
<a style="display: inline-block; padding: 1px 15px; background: #f0f0f0; border: 1px solid gray" href="https://github.com/vanilla-thunder/hdi-tinymce/" target="_blank">info</a> <a style="display: inline-block; padding: 1px 15px; background: #f0f0f0; border: 1px solid gray" href="https://github.com/vanilla-thunder/hdi-tinymce/archive/master.zip">download</a>',
'author' => 'Marat Bedoev, HEINER DIRECT GmbH & Co. KG',
'email' => 'info@heiner-direct.com',
'url' => 'http://www.heiner-direct.com',
'extend' => array(
'article_main' => 'hdi/hdi-tinymce/tinymce',
'category_text' => 'hdi/hdi-tinymce/tinymce',
'content_main' => 'hdi/hdi-tinymce/tinymce',
'newsletter_main' => 'hdi/hdi-tinymce/tinymce',
'news_text' => 'hdi/hdi-tinymce/tinymce'
),
'templates' => array(
'tinymce.tpl' => 'hdi/hdi-tinymce/out/tpl/tinymce.tpl',
),
'blocks' => array(
array('template' => 'bottomnaviitem.tpl', 'block' => 'admin_bottomnaviitem', 'file' => 'admin_bottomnaviitem.tpl')
),
'settings' => array(
/* enabling tinyMCE for this classes */
array('group' => 'tinyMceMain', 'name' => 'bTinyMCE_article_main', 'type' => 'bool', 'value' => true, 'position' => 1),
array('group' => 'tinyMceMain', 'name' => 'bTinyMCE_category_text', 'type' => 'bool', 'value' => true, 'position' => 2),
array('group' => 'tinyMceMain', 'name' => 'bTinyMCE_content_main', 'type' => 'bool', 'value' => true, 'position' => 3),
array('group' => 'tinyMceMain', 'name' => 'bTinyMCE_newsletter_main', 'type' => 'bool', 'value' => true, 'position' => 4),
array('group' => 'tinyMceMain', 'name' => 'bTinyMCE_news_text', 'type' => 'bool', 'value' => true, 'position' => 5),
/* TinyMCE Settings */
array('group' => 'tinyMceSettings', 'name' => 'sTinyMCE_height', 'type' => 'str', 'value' => '400', 'position' => 1),
array('group' => 'tinyMceSettings', 'name' => 'bTinyMCE_relative_urls', 'type' => 'bool', 'value' => true, 'position' => 2),
/* plugins */
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_autolink', 'type' => 'bool', 'value' => true, 'position' => 1),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_ists', 'type' => 'bool', 'value' => true, 'position' => 2),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_pagebreak', 'type' => 'bool', 'value' => true, 'position' => 3),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_style', 'type' => 'bool', 'value' => true, 'position' => 4),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_layer', 'type' => 'bool', 'value' => true, 'position' => 5),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_table', 'type' => 'bool', 'value' => true, 'position' => 6),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_save', 'type' => 'bool', 'value' => true, 'position' => 7),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_advhr', 'type' => 'bool', 'value' => true, 'position' => 8),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_advimage', 'type' => 'bool', 'value' => true, 'position' => 9),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_advlink', 'type' => 'bool', 'value' => true, 'position' => 10),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_emotions', 'type' => 'bool', 'value' => true, 'position' => 11),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_iespell', 'type' => 'bool', 'value' => true, 'position' => 12),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_inlinepopups', 'type' => 'bool', 'value' => true, 'position' => 13),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_insertdatetime', 'type' => 'bool', 'value' => true, 'position' => 14),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_preview', 'type' => 'bool', 'value' => true, 'position' => 15),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_media', 'type' => 'bool', 'value' => true, 'position' => 16),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_searchreplace', 'type' => 'bool', 'value' => true, 'position' => 17),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_print', 'type' => 'bool', 'value' => true, 'position' => 18),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_contextmenu', 'type' => 'bool', 'value' => true, 'position' => 19),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_paste', 'type' => 'bool', 'value' => true, 'position' => 20),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_directionality', 'type' => 'bool', 'value' => true, 'position' => 21),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_fullscreen', 'type' => 'bool', 'value' => true, 'position' => 22),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_noneditable', 'type' => 'bool', 'value' => true, 'position' => 23),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_visualchars', 'type' => 'bool', 'value' => true, 'position' => 24),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_nonbreaking', 'type' => 'bool', 'value' => true, 'position' => 25),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_xhtmlxtras', 'type' => 'bool', 'value' => true, 'position' => 26),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_template', 'type' => 'bool', 'value' => true, 'position' => 27),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_wordcount', 'type' => 'bool', 'value' => true, 'position' => 28),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_advlist', 'type' => 'bool', 'value' => true, 'position' => 29),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_autosave', 'type' => 'bool', 'value' => true, 'position' => 30),
array('group' => 'tinyMcePlugins', 'name' => 'bTinyMCE_visualblocks', 'type' => 'bool', 'value' => true, 'position' => 31),
array('group' => 'tinyMcePlugins', 'name' => 'sTinyMCE_customplugins', 'type' => 'str', 'value' => "", 'position' => 32)
)
);

Bestand weergeven

@ -1,58 +1,61 @@
<?php
/**
* HDI MiniBanner
* Copyright (C) 2012 HEINER DIRECT GmbH & Co. KG
* info: info@heiner-direct.com
*
* This program is free software;
* you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation;
* either version 3 of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
* You should have received a copy of the GNU General Public License along with this program; if not, see <http://www.gnu.org/licenses/>
*/
$sLangName = 'Deutsch';
$aLang = array(
'charset' => 'UTF-8',
'SHOP_MODULE_GROUP_tinyMceMain' => '<style type="text/css">.groupExp a.rc b {font-size: medium; color: #ff3600; }.groupExp dt input.txt { width: 400px !important} .groupExp dl { display: block !important; } input.confinput {position: fixed; top: 20px; right: 70px; background: #008B2D; padding: 5px 20px; color: white; border: 1px solid black; cursor:pointer; font-size: 125%; } input.confinput:hover {outline: 3px solid #ff3600;}</style>Moduleinstellungen',
'SHOP_MODULE_bTinyMCE_article_main' => 'TinyMCE für die Artikelbeschreibung benutzen',
'SHOP_MODULE_bTinyMCE_category_text' => 'TinyMCE für die Kategorienbeschreibung benutzen',
'SHOP_MODULE_bTinyMCE_content_main' => 'TinyMCE für die CMS Seiten benutzen',
'SHOP_MODULE_bTinyMCE_newsletter_main' => 'TinyMCE für die Newsletter benutzen',
'SHOP_MODULE_bTinyMCE_news_text' => 'TinyMCE für die News benutzen',
'SHOP_MODULE_GROUP_tinyMcePlugins' => 'TinyMCE Plugins</b></a>&nbsp;&nbsp;&nbsp;<a href="http://www.tinymce.com/wiki.php/Plugins" target="_blank" title="mehr Infos"><b>( ? )',
'SHOP_MODULE_bTinyMCE_autolink' => 'autolink',
'SHOP_MODULE_bTinyMCE_ists' => 'ists',
'SHOP_MODULE_bTinyMCE_pagebreak' => 'pagebreak',
'SHOP_MODULE_bTinyMCE_style' => 'style',
'SHOP_MODULE_bTinyMCE_layer' => 'layer',
'SHOP_MODULE_bTinyMCE_table' => 'table',
'SHOP_MODULE_bTinyMCE_save' => 'save',
'SHOP_MODULE_bTinyMCE_advhr' => 'advhr',
'SHOP_MODULE_bTinyMCE_advimage' => 'advimage',
'SHOP_MODULE_bTinyMCE_advlink' => 'advlink',
'SHOP_MODULE_bTinyMCE_emotions' => 'emotions',
'SHOP_MODULE_bTinyMCE_iespell' => 'iespell',
'SHOP_MODULE_bTinyMCE_inlinepopups' => 'inlinepopups',
'SHOP_MODULE_bTinyMCE_insertdatetime' => 'insertdatetime',
'SHOP_MODULE_bTinyMCE_preview' => 'preview',
'SHOP_MODULE_bTinyMCE_media' => 'media',
'SHOP_MODULE_bTinyMCE_searchreplace' => 'searchreplace',
'SHOP_MODULE_bTinyMCE_print' => 'print',
'SHOP_MODULE_bTinyMCE_contextmenu' => 'contextmenu',
'SHOP_MODULE_bTinyMCE_paste' => 'paste',
'SHOP_MODULE_bTinyMCE_directionality' => 'directionality',
'SHOP_MODULE_bTinyMCE_fullscreen' => 'fullscreen',
'SHOP_MODULE_bTinyMCE_noneditable' => 'noneditable',
'SHOP_MODULE_bTinyMCE_visualchars' => 'visualchars',
'SHOP_MODULE_bTinyMCE_nonbreaking' => 'nonbreaking',
'SHOP_MODULE_bTinyMCE_xhtmlxtras' => 'xhtmlxtras',
'SHOP_MODULE_bTinyMCE_template' => 'template',
'SHOP_MODULE_bTinyMCE_wordcount' => 'wordcount',
'SHOP_MODULE_bTinyMCE_advlist' => 'advlist',
'SHOP_MODULE_bTinyMCE_autosave' => 'autosave',
'SHOP_MODULE_bTinyMCE_visualblocks' => 'visualblocks',
'SHOP_MODULE_sTinyMCE_customplugins' => 'eigene Plugins'
<?php
/**
* HDI MiniBanner
* Copyright (C) 2012 HEINER DIRECT GmbH & Co. KG
* info: info@heiner-direct.com
*
* This program is free software;
* you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation;
* either version 3 of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
* You should have received a copy of the GNU General Public License along with this program; if not, see <http://www.gnu.org/licenses/>
*/
$sLangName = 'Deutsch';
$aLang = array(
'charset' => 'UTF-8',
'SHOP_MODULE_GROUP_tinyMceMain' => '<style type="text/css">.groupExp a.rc b {font-size: medium; color: #ff3600; }.groupExp dt input.txt { width: 200px !important} .groupExp dl { display: block !important; } input.confinput {position: fixed; top: 20px; right: 70px; background: #008B2D; padding: 5px 20px; color: white; border: 1px solid black; cursor:pointer; font-size: 125%; } input.confinput:hover {outline: 3px solid #ff3600;}</style>Moduleinstellungen',
'SHOP_MODULE_bTinyMCE_article_main' => 'TinyMCE für die Artikelbeschreibung benutzen',
'SHOP_MODULE_bTinyMCE_category_text' => 'TinyMCE für die Kategorienbeschreibung benutzen',
'SHOP_MODULE_bTinyMCE_content_main' => 'TinyMCE für die CMS Seiten benutzen',
'SHOP_MODULE_bTinyMCE_newsletter_main' => 'TinyMCE für die Newsletter benutzen',
'SHOP_MODULE_bTinyMCE_news_text' => 'TinyMCE für die News benutzen',
'SHOP_MODULE_GROUP_tinyMceSettings' => 'Editor Einxtellungen',
'SHOP_MODULE_sTinyMCE_height'=>'Höhe des Editors (eine reine Zahl ohne Einheiten)',
'SHOP_MODULE_bTinyMCE_relative_urls'=>'relative Urls verwenden',
'SHOP_MODULE_GROUP_tinyMcePlugins' => 'TinyMCE Plugins</b></a>&nbsp;&nbsp;&nbsp;<a href="http://www.tinymce.com/wiki.php/Plugins" target="_blank" title="mehr Infos"><b>( ? )',
'SHOP_MODULE_bTinyMCE_autolink' => 'autolink',
'SHOP_MODULE_bTinyMCE_ists' => 'ists',
'SHOP_MODULE_bTinyMCE_pagebreak' => 'pagebreak',
'SHOP_MODULE_bTinyMCE_style' => 'style',
'SHOP_MODULE_bTinyMCE_layer' => 'layer',
'SHOP_MODULE_bTinyMCE_table' => 'table',
'SHOP_MODULE_bTinyMCE_save' => 'save',
'SHOP_MODULE_bTinyMCE_advhr' => 'advhr',
'SHOP_MODULE_bTinyMCE_advimage' => 'advimage',
'SHOP_MODULE_bTinyMCE_advlink' => 'advlink',
'SHOP_MODULE_bTinyMCE_emotions' => 'emotions',
'SHOP_MODULE_bTinyMCE_iespell' => 'iespell',
'SHOP_MODULE_bTinyMCE_inlinepopups' => 'inlinepopups',
'SHOP_MODULE_bTinyMCE_insertdatetime' => 'insertdatetime',
'SHOP_MODULE_bTinyMCE_preview' => 'preview',
'SHOP_MODULE_bTinyMCE_media' => 'media',
'SHOP_MODULE_bTinyMCE_searchreplace' => 'searchreplace',
'SHOP_MODULE_bTinyMCE_print' => 'print',
'SHOP_MODULE_bTinyMCE_contextmenu' => 'contextmenu',
'SHOP_MODULE_bTinyMCE_paste' => 'paste',
'SHOP_MODULE_bTinyMCE_directionality' => 'directionality',
'SHOP_MODULE_bTinyMCE_fullscreen' => 'fullscreen',
'SHOP_MODULE_bTinyMCE_noneditable' => 'noneditable',
'SHOP_MODULE_bTinyMCE_visualchars' => 'visualchars',
'SHOP_MODULE_bTinyMCE_nonbreaking' => 'nonbreaking',
'SHOP_MODULE_bTinyMCE_xhtmlxtras' => 'xhtmlxtras',
'SHOP_MODULE_bTinyMCE_template' => 'template',
'SHOP_MODULE_bTinyMCE_wordcount' => 'wordcount',
'SHOP_MODULE_bTinyMCE_advlist' => 'advlist',
'SHOP_MODULE_bTinyMCE_autosave' => 'autosave',
'SHOP_MODULE_bTinyMCE_visualblocks' => 'visualblocks',
'SHOP_MODULE_sTinyMCE_customplugins' => 'eigene Plugins'
);

Bestand weergeven

@ -1,69 +1,67 @@
<!-- TinyMCE -->
<script type="text/javascript">
var tinyMCE = null;
function copyLongDescFromTinyMCE( sIdent ) {
var editor = tinyMCE.get('editor_' + sIdent);
if ( tinyMCE && editor ) {
content = editor.getContent();
if (content != null) {
// restore smarty code that has been masked by htmlentities:
/*var aSmartyParts = textVal.split( "["+"{" );
if ( aSmartyParts.length > 1 ) {
for ( var i=0; i<aSmartyParts.length; i++ ) {
aSubParts = aSmartyParts[i].split( "}"+"]" );
if ( aSubParts.length > 1 )
aSubParts[0] = aSubParts[0].replace( /&gt;/g, ">" ).replace( /&lt;/g, "<" ).replace( /&amp;/g, "&" ).replace( /&quot;/g, "\"" );
aSmartyParts[i] = aSubParts.join( "}"+"]" );
}
textVal = aSmartyParts.join( "["+"{" );
}*/
document.getElementsByName( 'editval['+ sIdent + ']' ).item(0).value = content;
return true;
}
}
return false;
}
var origCopyLongDesc = copyLongDesc;
copyLongDesc = function( sIdent ) {
if ( copyLongDescFromTinyMCE( sIdent ) ) return;
origCopyLongDesc( sIdent );
}
</script>
<script type="text/javascript" src="[{$oViewConf->getModuleUrl('hdi-tinymce','tiny_mce/tiny_mce.js') }]"></script>
<script type="text/javascript">
tinyMCE.init({
// General options
height : "400",
relative_urls : false,
remove_script_host : false,
document_base_url : '[{$oViewConf->getBaseDir()}]',
mode : "textareas",
theme : "advanced",
plugins : "[{if $cfg->getConfigParam("bTinyMCE_autolink")}]autolink,[{/if}][{if $cfg->getConfigParam("bTinyMCE_lists")}]lists,[{/if}][{if $cfg->getConfigParam("bTinyMCE_pagebreak")}]pagebreak,[{/if}][{if $cfg->getConfigParam("bTinyMCE_style")}]style,[{/if}][{if $cfg->getConfigParam("bTinyMCE_layer")}]layer,[{/if}][{if $cfg->getConfigParam("bTinyMCE_table")}]table,[{/if}][{if $cfg->getConfigParam("bTinyMCE_save")}]save,[{/if}][{if $cfg->getConfigParam("bTinyMCE_advhr")}]advhr,[{/if}][{if $cfg->getConfigParam("bTinyMCE_advimage")}]advimage,[{/if}][{if $cfg->getConfigParam("bTinyMCE_advlink")}]advlink,[{/if}][{if $cfg->getConfigParam("bTinyMCE_emotions")}]emotions,[{/if}][{if $cfg->getConfigParam("bTinyMCE_iespell")}]iespell,[{/if}][{if $cfg->getConfigParam("bTinyMCE_inlinepopups")}]inlinepopups,[{/if}][{if $cfg->getConfigParam("bTinyMCE_insertdatetime")}]insertdatetime,[{/if}][{if $cfg->getConfigParam("bTinyMCE_preview")}]preview,[{/if}][{if $cfg->getConfigParam("bTinyMCE_media")}]media,[{/if}][{if $cfg->getConfigParam("bTinyMCE_searchreplace")}]searchreplace,[{/if}][{if $cfg->getConfigParam("bTinyMCE_print")}]print,[{/if}][{if $cfg->getConfigParam("bTinyMCE_contextmenu")}]contextmenu,[{/if}][{if $cfg->getConfigParam("bTinyMCE_paste")}]paste,[{/if}][{if $cfg->getConfigParam("bTinyMCE_directionality")}]directionality,[{/if}][{if $cfg->getConfigParam("bTinyMCE_fullscreen")}]fullscreen,[{/if}][{if $cfg->getConfigParam("bTinyMCE_noneditable")}]noneditable,[{/if}][{if $cfg->getConfigParam("bTinyMCE_visualchars")}]visualchars,[{/if}][{if $cfg->getConfigParam("bTinyMCE_nonbreaking")}]nonbreaking,[{/if}][{if $cfg->getConfigParam("bTinyMCE_xhtmlxtras")}]xhtmlxtras,[{/if}][{if $cfg->getConfigParam("bTinyMCE_template")}]template,[{/if}][{if $cfg->getConfigParam("bTinyMCE_wordcount")}]wordcount,[{/if}][{if $cfg->getConfigParam("bTinyMCE_advlist")}]advlist,[{/if}][{if $cfg->getConfigParam("bTinyMCE_autosave")}]autosave,[{/if}][{if $cfg->getConfigParam("bTinyMCE_visualblocks")}]visualblocks[{/if}][{if $cfg->getConfigParam("sTinyMCE_customplugins")}][{$cfg->getConfigParam("sTinyMCE_customplugins")}][{/if}]",
// Theme options
theme_advanced_buttons1 : "newdocument,|,bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,styleselect,formatselect",
theme_advanced_buttons2 : "cut,copy,paste,pastetext,pasteword,|,search,replace,|,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,link,unlink,anchor,cleanup,help,code,|,insertdate,inserttime,preview,|,forecolor,backcolor",
theme_advanced_buttons3 : "tablecontrols,|,hr,removeformat,visualaid,|,sub,sup,|,charmap,emotions,iespell,media,advhr,|,print,|,ltr,rtl,|,fullscreen",
theme_advanced_buttons4 : "insertlayer,moveforward,movebackward,absolute,|,styleprops,|,cite,abbr,acronym,del,ins,attribs,|,visualchars,nonbreaking,template,pagebreak,restoredraft,visualblocks,|,image,insertimage,|,dDesc",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_statusbar_location : "bottom",
theme_advanced_resizing : true,
// Example content CSS (should be your site CSS)
//content_css : "modules/tinymce/style.css",
// Drop lists for link/image/media/template dialogs
//template_external_list_url : "lists/template_list.js",
//external_link_list_url : "lists/link_list.js",
//external_image_list_url : "lists/image_list.js",
//media_external_list_url : "lists/media_list.js",
});
</script>
<textarea id='editor_[{$sField}]' style='width:[{$iWidth}]; height:[{$iHeight}];'>[{$sContent}]</textarea>
[{assign var=tinyMCE value=1 }]
<!-- /TinyMCE -->
<!-- TinyMCE -->
<script type="text/javascript">
var tinyMCE = null;
function copyLongDescFromTinyMCE(sIdent) {
var editor = tinyMCE.get('editor_' + sIdent);
if (tinyMCE && editor) {
editor.show();
content = editor.getContent();
if (content !== null) {
// restore smarty code that has been masked by htmlentities:
var aSmartyParts = content.split("[" + "{");
if (aSmartyParts.length > 1) {
for (var i = 0; i < aSmartyParts.length; i++) {
aSubParts = aSmartyParts[i].split("}" + "]");
if (aSubParts.length > 1)
aSubParts[0] = aSubParts[0].replace(/&gt;/gi, ">").replace(/&lt;/gi, "<").replace(/&amp;/gi, "&").replace(/&quot;/gi, '"');
aSmartyParts[i] = aSubParts.join("}" + "]");
}
content = aSmartyParts.join("[" + "{");
}
document.getElementsByName('editval[' + sIdent + ']').item(0).value = content;
return true;
}
}
return false;
}
var origCopyLongDesc = copyLongDesc;
copyLongDesc = function(sIdent) {
if ( copyLongDescFromTinyMCE( sIdent ) ) return;
origCopyLongDesc( sIdent );
}
</script>
<script type="text/javascript" src="[{$oViewConf->getModuleUrl('hdi-tinymce','tiny_mce/tiny_mce.js') }]"></script>
<script type="text/javascript">
tinyMCE.init({
// General options
height: '[{$cfg->getConfigParam("sTinyMCE_height")}]',
relative_urls: [{if $cfg->getConfigParam("bTinyMCE_relative_urls") == 1}]true[{else}]false[{/if}],
remove_script_host: false,
document_base_url: '[{$oViewConf->getBaseDir()}]',
mode: "textareas",
theme: "advanced",
plugins: "[{if $cfg->getConfigParam("bTinyMCE_autolink")}]autolink,[{/if}][{if $cfg->getConfigParam("bTinyMCE_lists")}]lists,[{/if}][{if $cfg->getConfigParam("bTinyMCE_pagebreak")}]pagebreak,[{/if}][{if $cfg->getConfigParam("bTinyMCE_style")}]style,[{/if}][{if $cfg->getConfigParam("bTinyMCE_layer")}]layer,[{/if}][{if $cfg->getConfigParam("bTinyMCE_table")}]table,[{/if}][{if $cfg->getConfigParam("bTinyMCE_save")}]save,[{/if}][{if $cfg->getConfigParam("bTinyMCE_advhr")}]advhr,[{/if}][{if $cfg->getConfigParam("bTinyMCE_advimage")}]advimage,[{/if}][{if $cfg->getConfigParam("bTinyMCE_advlink")}]advlink,[{/if}][{if $cfg->getConfigParam("bTinyMCE_emotions")}]emotions,[{/if}][{if $cfg->getConfigParam("bTinyMCE_iespell")}]iespell,[{/if}][{if $cfg->getConfigParam("bTinyMCE_inlinepopups")}]inlinepopups,[{/if}][{if $cfg->getConfigParam("bTinyMCE_insertdatetime")}]insertdatetime,[{/if}][{if $cfg->getConfigParam("bTinyMCE_preview")}]preview,[{/if}][{if $cfg->getConfigParam("bTinyMCE_media")}]media,[{/if}][{if $cfg->getConfigParam("bTinyMCE_searchreplace")}]searchreplace,[{/if}][{if $cfg->getConfigParam("bTinyMCE_print")}]print,[{/if}][{if $cfg->getConfigParam("bTinyMCE_contextmenu")}]contextmenu,[{/if}][{if $cfg->getConfigParam("bTinyMCE_paste")}]paste,[{/if}][{if $cfg->getConfigParam("bTinyMCE_directionality")}]directionality,[{/if}][{if $cfg->getConfigParam("bTinyMCE_fullscreen")}]fullscreen,[{/if}][{if $cfg->getConfigParam("bTinyMCE_noneditable")}]noneditable,[{/if}][{if $cfg->getConfigParam("bTinyMCE_visualchars")}]visualchars,[{/if}][{if $cfg->getConfigParam("bTinyMCE_nonbreaking")}]nonbreaking,[{/if}][{if $cfg->getConfigParam("bTinyMCE_xhtmlxtras")}]xhtmlxtras,[{/if}][{if $cfg->getConfigParam("bTinyMCE_template")}]template,[{/if}][{if $cfg->getConfigParam("bTinyMCE_wordcount")}]wordcount,[{/if}][{if $cfg->getConfigParam("bTinyMCE_advlist")}]advlist,[{/if}][{if $cfg->getConfigParam("bTinyMCE_autosave")}]autosave,[{/if}][{if $cfg->getConfigParam("bTinyMCE_visualblocks")}]visualblocks[{/if}][{if $cfg->getConfigParam("sTinyMCE_customplugins")}][{$cfg->getConfigParam("sTinyMCE_customplugins")}][{/if}]",
// Theme options
theme_advanced_buttons1: "newdocument,|,bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,styleselect,formatselect",
theme_advanced_buttons2: "cut,copy,paste,pastetext,pasteword,|,search,replace,|,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,link,unlink,anchor,cleanup,help,code,|,insertdate,inserttime,preview,|,forecolor,backcolor",
theme_advanced_buttons3: "tablecontrols,|,hr,removeformat,visualaid,|,sub,sup,|,charmap,emotions,iespell,media,advhr,|,print,|,ltr,rtl,|,fullscreen",
theme_advanced_buttons4: "insertlayer,moveforward,movebackward,absolute,|,styleprops,|,cite,abbr,acronym,del,ins,attribs,|,visualchars,nonbreaking,template,pagebreak,restoredraft,visualblocks,|,image,insertimage,|,dDesc",
theme_advanced_toolbar_location: "top",
theme_advanced_toolbar_align: "left",
theme_advanced_statusbar_location: "bottom",
theme_advanced_resizing: true,
// Example content CSS (should be your site CSS)
//content_css : "modules/tinymce/style.css",
// Drop lists for link/image/media/template dialogs
//template_external_list_url : "lists/template_list.js",
//external_link_list_url : "lists/link_list.js",
//external_image_list_url : "lists/image_list.js",
//media_external_list_url : "lists/media_list.js",
});
</script>
<textarea id='editor_[{$sField}]' style='width:[{$iWidth}]; height:[{$iHeight}];'>[{$sContent}]</textarea>
[{assign var=tinyMCE value=1 }]
<!-- /TinyMCE -->

Bestand weergeven

@ -1 +1 @@
(function(){tinymce.create("tinymce.plugins.AutolinkPlugin",{init:function(a,b){var c=this;a.onKeyDown.addToTop(function(d,f){if(f.keyCode==13){return c.handleEnter(d)}});if(tinyMCE.isIE){return}a.onKeyPress.add(function(d,f){if(f.which==41){return c.handleEclipse(d)}});a.onKeyUp.add(function(d,f){if(f.keyCode==32){return c.handleSpacebar(d)}})},handleEclipse:function(a){this.parseCurrentLine(a,-1,"(",true)},handleSpacebar:function(a){this.parseCurrentLine(a,0,"",true)},handleEnter:function(a){this.parseCurrentLine(a,-1,"",false)},parseCurrentLine:function(i,d,b,g){var a,f,c,n,k,m,h,e,j;a=i.selection.getRng(true).cloneRange();if(a.startOffset<5){e=a.endContainer.previousSibling;if(e==null){if(a.endContainer.firstChild==null||a.endContainer.firstChild.nextSibling==null){return}e=a.endContainer.firstChild.nextSibling}j=e.length;a.setStart(e,j);a.setEnd(e,j);if(a.endOffset<5){return}f=a.endOffset;n=e}else{n=a.endContainer;if(n.nodeType!=3&&n.firstChild){while(n.nodeType!=3&&n.firstChild){n=n.firstChild}if(n.nodeType==3){a.setStart(n,0);a.setEnd(n,n.nodeValue.length)}}if(a.endOffset==1){f=2}else{f=a.endOffset-1-d}}c=f;do{a.setStart(n,f-2);a.setEnd(n,f-1);f-=1}while(a.toString()!=" "&&a.toString()!=""&&a.toString().charCodeAt(0)!=160&&(f-2)>=0&&a.toString()!=b);if(a.toString()==b||a.toString().charCodeAt(0)==160){a.setStart(n,f);a.setEnd(n,c);f+=1}else{if(a.startOffset==0){a.setStart(n,0);a.setEnd(n,c)}else{a.setStart(n,f);a.setEnd(n,c)}}var m=a.toString();if(m.charAt(m.length-1)=="."){a.setEnd(n,c-1)}m=a.toString();h=m.match(/^(https?:\/\/|ssh:\/\/|ftp:\/\/|file:\/|www\.|(?:mailto:)?[A-Z0-9._%+-]+@)(.+)$/i);if(h){if(h[1]=="www."){h[1]="http://www."}else{if(/@$/.test(h[1])&&!/^mailto:/.test(h[1])){h[1]="mailto:"+h[1]}}k=i.selection.getBookmark();i.selection.setRng(a);tinyMCE.execCommand("createlink",false,h[1]+h[2]);i.selection.moveToBookmark(k);i.nodeChanged();if(tinyMCE.isWebKit){i.selection.collapse(false);var l=Math.min(n.length,c+1);a.setStart(n,l);a.setEnd(n,l);i.selection.setRng(a)}}},getInfo:function(){return{longname:"Autolink",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/autolink",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("autolink",tinymce.plugins.AutolinkPlugin)})();
(function(){tinymce.create("tinymce.plugins.AutolinkPlugin",{init:function(a,b){var c=this;a.onKeyDown.addToTop(function(d,f){if(f.keyCode==13){return c.handleEnter(d)}});if(tinyMCE.isIE){return}a.onKeyPress.add(function(d,f){if(f.which==41){return c.handleEclipse(d)}});a.onKeyUp.add(function(d,f){if(f.keyCode==32){return c.handleSpacebar(d)}})},handleEclipse:function(a){this.parseCurrentLine(a,-1,"(",true)},handleSpacebar:function(a){this.parseCurrentLine(a,0,"",true)},handleEnter:function(a){this.parseCurrentLine(a,-1,"",false)},parseCurrentLine:function(i,d,b,g){var a,f,c,n,k,m,h,e,j;a=i.selection.getRng(true).cloneRange();if(a.startOffset<5){e=a.endContainer.previousSibling;if(e==null){if(a.endContainer.firstChild==null||a.endContainer.firstChild.nextSibling==null){return}e=a.endContainer.firstChild.nextSibling}j=e.length;a.setStart(e,j);a.setEnd(e,j);if(a.endOffset<5){return}f=a.endOffset;n=e}else{n=a.endContainer;if(n.nodeType!=3&&n.firstChild){while(n.nodeType!=3&&n.firstChild){n=n.firstChild}if(n.nodeType==3){a.setStart(n,0);a.setEnd(n,n.nodeValue.length)}}if(a.endOffset==1){f=2}else{f=a.endOffset-1-d}}c=f;do{a.setStart(n,f>=2?f-2:0);a.setEnd(n,f>=1?f-1:0);f-=1}while(a.toString()!=" "&&a.toString()!=""&&a.toString().charCodeAt(0)!=160&&(f-2)>=0&&a.toString()!=b);if(a.toString()==b||a.toString().charCodeAt(0)==160){a.setStart(n,f);a.setEnd(n,c);f+=1}else{if(a.startOffset==0){a.setStart(n,0);a.setEnd(n,c)}else{a.setStart(n,f);a.setEnd(n,c)}}var m=a.toString();if(m.charAt(m.length-1)=="."){a.setEnd(n,c-1)}m=a.toString();h=m.match(/^(https?:\/\/|ssh:\/\/|ftp:\/\/|file:\/|www\.|(?:mailto:)?[A-Z0-9._%+-]+@)(.+)$/i);if(h){if(h[1]=="www."){h[1]="http://www."}else{if(/@$/.test(h[1])&&!/^mailto:/.test(h[1])){h[1]="mailto:"+h[1]}}k=i.selection.getBookmark();i.selection.setRng(a);tinyMCE.execCommand("createlink",false,h[1]+h[2]);i.selection.moveToBookmark(k);i.nodeChanged();if(tinyMCE.isWebKit){i.selection.collapse(false);var l=Math.min(n.length,c+1);a.setStart(n,l);a.setEnd(n,l);i.selection.setRng(a)}}},getInfo:function(){return{longname:"Autolink",author:"Moxiecode Systems AB",authorurl:"http://tinymce.moxiecode.com",infourl:"http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/autolink",version:tinymce.majorVersion+"."+tinymce.minorVersion}}});tinymce.PluginManager.add("autolink",tinymce.plugins.AutolinkPlugin)})();

Bestand weergeven

@ -107,8 +107,8 @@
do
{
// Move the selection one character backwards.
r.setStart(endContainer, end - 2);
r.setEnd(endContainer, end - 1);
r.setStart(endContainer, end >= 2 ? end - 2 : 0);
r.setEnd(endContainer, end >= 1 ? end - 1 : 0);
end -= 1;
// Loop until one of the following is found: a blank space, &nbsp;, delimeter, (end-2) >= 0

Bestand weergeven

@ -1,4 +0,0 @@
tinyMCE.addI18n('en.autosave',{
restore_content: "Restore auto-saved content",
warning_message: "If you restore the saved content, you will lose all the content that is currently in the editor.\n\nAre you sure you want to restore the saved content?"
});

Bestand weergeven

@ -1,139 +1,139 @@
/**
* editor_plugin_src.js
*
* Copyright 2009, Moxiecode Systems AB
* Released under LGPL License.
*
* License: http://tinymce.moxiecode.com/license
* Contributing: http://tinymce.moxiecode.com/contributing
*
* This plugin will force TinyMCE to produce deprecated legacy output such as font elements, u elements, align
* attributes and so forth. There are a few cases where these old items might be needed for example in email applications or with Flash
*
* However you should NOT use this plugin if you are building some system that produces web contents such as a CMS. All these elements are
* not apart of the newer specifications for HTML and XHTML.
*/
(function(tinymce) {
// Override inline_styles setting to force TinyMCE to produce deprecated contents
tinymce.onAddEditor.addToTop(function(tinymce, editor) {
editor.settings.inline_styles = false;
});
// Create the legacy ouput plugin
tinymce.create('tinymce.plugins.LegacyOutput', {
init : function(editor) {
editor.onInit.add(function() {
var alignElements = 'p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img',
fontSizes = tinymce.explode(editor.settings.font_size_style_values),
schema = editor.schema;
// Override some internal formats to produce legacy elements and attributes
editor.formatter.register({
// Change alignment formats to use the deprecated align attribute
alignleft : {selector : alignElements, attributes : {align : 'left'}},
aligncenter : {selector : alignElements, attributes : {align : 'center'}},
alignright : {selector : alignElements, attributes : {align : 'right'}},
alignfull : {selector : alignElements, attributes : {align : 'justify'}},
/**
* editor_plugin_src.js
*
* Copyright 2009, Moxiecode Systems AB
* Released under LGPL License.
*
* License: http://tinymce.moxiecode.com/license
* Contributing: http://tinymce.moxiecode.com/contributing
*
* This plugin will force TinyMCE to produce deprecated legacy output such as font elements, u elements, align
* attributes and so forth. There are a few cases where these old items might be needed for example in email applications or with Flash
*
* However you should NOT use this plugin if you are building some system that produces web contents such as a CMS. All these elements are
* not apart of the newer specifications for HTML and XHTML.
*/
(function(tinymce) {
// Override inline_styles setting to force TinyMCE to produce deprecated contents
tinymce.onAddEditor.addToTop(function(tinymce, editor) {
editor.settings.inline_styles = false;
});
// Create the legacy ouput plugin
tinymce.create('tinymce.plugins.LegacyOutput', {
init : function(editor) {
editor.onInit.add(function() {
var alignElements = 'p,h1,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img',
fontSizes = tinymce.explode(editor.settings.font_size_style_values),
schema = editor.schema;
// Override some internal formats to produce legacy elements and attributes
editor.formatter.register({
// Change alignment formats to use the deprecated align attribute
alignleft : {selector : alignElements, attributes : {align : 'left'}},
aligncenter : {selector : alignElements, attributes : {align : 'center'}},
alignright : {selector : alignElements, attributes : {align : 'right'}},
alignfull : {selector : alignElements, attributes : {align : 'justify'}},
// Change the basic formatting elements to use deprecated element types
bold : [
{inline : 'b', remove : 'all'},
{inline : 'strong', remove : 'all'},
{inline : 'span', styles : {fontWeight : 'bold'}}
bold : [
{inline : 'b', remove : 'all'},
{inline : 'strong', remove : 'all'},
{inline : 'span', styles : {fontWeight : 'bold'}}
],
italic : [
{inline : 'i', remove : 'all'},
{inline : 'em', remove : 'all'},
{inline : 'span', styles : {fontStyle : 'italic'}}
],
underline : [
{inline : 'u', remove : 'all'},
{inline : 'span', styles : {textDecoration : 'underline'}, exact : true}
],
strikethrough : [
{inline : 'strike', remove : 'all'},
{inline : 'span', styles : {textDecoration: 'line-through'}, exact : true}
],
italic : [
{inline : 'i', remove : 'all'},
{inline : 'em', remove : 'all'},
{inline : 'span', styles : {fontStyle : 'italic'}}
],
underline : [
{inline : 'u', remove : 'all'},
{inline : 'span', styles : {textDecoration : 'underline'}, exact : true}
],
strikethrough : [
{inline : 'strike', remove : 'all'},
{inline : 'span', styles : {textDecoration: 'line-through'}, exact : true}
],
// Change font size and font family to use the deprecated font element
fontname : {inline : 'font', attributes : {face : '%value'}},
fontsize : {
inline : 'font',
attributes : {
size : function(vars) {
return tinymce.inArray(fontSizes, vars.value) + 1;
}
}
},
// Setup font elements for colors as well
forecolor : {inline : 'font', attributes : {color : '%value'}},
hilitecolor : {inline : 'font', styles : {backgroundColor : '%value'}}
});
// Check that deprecated elements are allowed if not add them
tinymce.each('b,i,u,strike'.split(','), function(name) {
schema.addValidElements(name + '[*]');
});
// Add font element if it's missing
if (!schema.getElementRule("font"))
schema.addValidElements("font[face|size|color|style]");
// Add the missing and depreacted align attribute for the serialization engine
tinymce.each(alignElements.split(','), function(name) {
var rule = schema.getElementRule(name), found;
if (rule) {
if (!rule.attributes.align) {
rule.attributes.align = {};
rule.attributesOrder.push('align');
}
}
});
// Listen for the onNodeChange event so that we can do special logic for the font size and font name drop boxes
editor.onNodeChange.add(function(editor, control_manager) {
var control, fontElm, fontName, fontSize;
// Find font element get it's name and size
fontElm = editor.dom.getParent(editor.selection.getNode(), 'font');
if (fontElm) {
fontName = fontElm.face;
fontSize = fontElm.size;
}
// Select/unselect the font name in droplist
if (control = control_manager.get('fontselect')) {
control.select(function(value) {
return value == fontName;
});
}
// Select/unselect the font size in droplist
if (control = control_manager.get('fontsizeselect')) {
control.select(function(value) {
var index = tinymce.inArray(fontSizes, value.fontSize);
return index + 1 == fontSize;
});
}
});
});
},
getInfo : function() {
return {
longname : 'LegacyOutput',
author : 'Moxiecode Systems AB',
authorurl : 'http://tinymce.moxiecode.com',
infourl : 'http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/legacyoutput',
version : tinymce.majorVersion + "." + tinymce.minorVersion
};
}
});
// Register plugin
tinymce.PluginManager.add('legacyoutput', tinymce.plugins.LegacyOutput);
})(tinymce);
// Change font size and font family to use the deprecated font element
fontname : {inline : 'font', attributes : {face : '%value'}},
fontsize : {
inline : 'font',
attributes : {
size : function(vars) {
return tinymce.inArray(fontSizes, vars.value) + 1;
}
}
},
// Setup font elements for colors as well
forecolor : {inline : 'font', attributes : {color : '%value'}},
hilitecolor : {inline : 'font', styles : {backgroundColor : '%value'}}
});
// Check that deprecated elements are allowed if not add them
tinymce.each('b,i,u,strike'.split(','), function(name) {
schema.addValidElements(name + '[*]');
});
// Add font element if it's missing
if (!schema.getElementRule("font"))
schema.addValidElements("font[face|size|color|style]");
// Add the missing and depreacted align attribute for the serialization engine
tinymce.each(alignElements.split(','), function(name) {
var rule = schema.getElementRule(name), found;
if (rule) {
if (!rule.attributes.align) {
rule.attributes.align = {};
rule.attributesOrder.push('align');
}
}
});
// Listen for the onNodeChange event so that we can do special logic for the font size and font name drop boxes
editor.onNodeChange.add(function(editor, control_manager) {
var control, fontElm, fontName, fontSize;
// Find font element get it's name and size
fontElm = editor.dom.getParent(editor.selection.getNode(), 'font');
if (fontElm) {
fontName = fontElm.face;
fontSize = fontElm.size;
}
// Select/unselect the font name in droplist
if (control = control_manager.get('fontselect')) {
control.select(function(value) {
return value == fontName;
});
}
// Select/unselect the font size in droplist
if (control = control_manager.get('fontsizeselect')) {
control.select(function(value) {
var index = tinymce.inArray(fontSizes, value.fontSize);
return index + 1 == fontSize;
});
}
});
});
},
getInfo : function() {
return {
longname : 'LegacyOutput',
author : 'Moxiecode Systems AB',
authorurl : 'http://tinymce.moxiecode.com',
infourl : 'http://wiki.moxiecode.com/index.php/TinyMCE:Plugins/legacyoutput',
version : tinymce.majorVersion + "." + tinymce.minorVersion
};
}
});
// Register plugin
tinymce.PluginManager.add('legacyoutput', tinymce.plugins.LegacyOutput);
})(tinymce);

Bestand-diff onderdrukt omdat een of meer regels te lang zijn

Bestand weergeven

@ -566,6 +566,10 @@
};
function pasteRows(rows, before) {
// If we don't have any rows in the clipboard, return immediately
if(!rows)
return;
var selectedRows = getSelectedRows(),
targetRow = selectedRows[before ? 0 : selectedRows.length - 1],
targetCellCount = targetRow.cells.length;

Bestand weergeven

@ -1,237 +1,254 @@
tinyMCEPopup.requireLangPack();
function init() {
tinyMCEPopup.resizeToInnerSize();
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
document.getElementById('bgcolor_pickcontainer').innerHTML = getColorPickerHTML('bgcolor_pick','bgcolor');
var inst = tinyMCEPopup.editor;
var dom = inst.dom;
var trElm = dom.getParent(inst.selection.getStart(), "tr");
var formObj = document.forms[0];
var st = dom.parseStyle(dom.getAttrib(trElm, "style"));
// Get table row data
var rowtype = trElm.parentNode.nodeName.toLowerCase();
var align = dom.getAttrib(trElm, 'align');
var valign = dom.getAttrib(trElm, 'valign');
var height = trimSize(getStyle(trElm, 'height', 'height'));
var className = dom.getAttrib(trElm, 'class');
var bgcolor = convertRGBToHex(getStyle(trElm, 'bgcolor', 'backgroundColor'));
var backgroundimage = getStyle(trElm, 'background', 'backgroundImage').replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
var id = dom.getAttrib(trElm, 'id');
var lang = dom.getAttrib(trElm, 'lang');
var dir = dom.getAttrib(trElm, 'dir');
selectByValue(formObj, 'rowtype', rowtype);
// Any cells selected
if (dom.select('td.mceSelected,th.mceSelected', trElm).length == 0) {
// Setup form
addClassesToList('class', 'table_row_styles');
TinyMCE_EditableSelects.init();
formObj.bgcolor.value = bgcolor;
formObj.backgroundimage.value = backgroundimage;
formObj.height.value = height;
formObj.id.value = id;
formObj.lang.value = lang;
formObj.style.value = dom.serializeStyle(st);
selectByValue(formObj, 'align', align);
selectByValue(formObj, 'valign', valign);
selectByValue(formObj, 'class', className, true, true);
selectByValue(formObj, 'dir', dir);
// Resize some elements
if (isVisible('backgroundimagebrowser'))
document.getElementById('backgroundimage').style.width = '180px';
updateColor('bgcolor_pick', 'bgcolor');
} else
tinyMCEPopup.dom.hide('action');
}
function updateAction() {
var inst = tinyMCEPopup.editor, dom = inst.dom, trElm, tableElm, formObj = document.forms[0];
var action = getSelectValue(formObj, 'action');
if (!AutoValidator.validate(formObj)) {
tinyMCEPopup.alert(AutoValidator.getErrorMessages(formObj).join('. ') + '.');
return false;
}
tinyMCEPopup.restoreSelection();
trElm = dom.getParent(inst.selection.getStart(), "tr");
tableElm = dom.getParent(inst.selection.getStart(), "table");
// Update all selected rows
if (dom.select('td.mceSelected,th.mceSelected', trElm).length > 0) {
tinymce.each(tableElm.rows, function(tr) {
var i;
for (i = 0; i < tr.cells.length; i++) {
if (dom.hasClass(tr.cells[i], 'mceSelected')) {
updateRow(tr, true);
return;
}
}
});
inst.addVisual();
inst.nodeChanged();
inst.execCommand('mceEndUndoLevel');
tinyMCEPopup.close();
return;
}
switch (action) {
case "row":
updateRow(trElm);
break;
case "all":
var rows = tableElm.getElementsByTagName("tr");
for (var i=0; i<rows.length; i++)
updateRow(rows[i], true);
break;
case "odd":
case "even":
var rows = tableElm.getElementsByTagName("tr");
for (var i=0; i<rows.length; i++) {
if ((i % 2 == 0 && action == "odd") || (i % 2 != 0 && action == "even"))
updateRow(rows[i], true, true);
}
break;
}
inst.addVisual();
inst.nodeChanged();
inst.execCommand('mceEndUndoLevel');
tinyMCEPopup.close();
}
function updateRow(tr_elm, skip_id, skip_parent) {
var inst = tinyMCEPopup.editor;
var formObj = document.forms[0];
var dom = inst.dom;
var curRowType = tr_elm.parentNode.nodeName.toLowerCase();
var rowtype = getSelectValue(formObj, 'rowtype');
var doc = inst.getDoc();
// Update row element
if (!skip_id)
dom.setAttrib(tr_elm, 'id', formObj.id.value);
dom.setAttrib(tr_elm, 'align', getSelectValue(formObj, 'align'));
dom.setAttrib(tr_elm, 'vAlign', getSelectValue(formObj, 'valign'));
dom.setAttrib(tr_elm, 'lang', formObj.lang.value);
dom.setAttrib(tr_elm, 'dir', getSelectValue(formObj, 'dir'));
dom.setAttrib(tr_elm, 'style', dom.serializeStyle(dom.parseStyle(formObj.style.value)));
dom.setAttrib(tr_elm, 'class', getSelectValue(formObj, 'class'));
// Clear deprecated attributes
dom.setAttrib(tr_elm, 'background', '');
dom.setAttrib(tr_elm, 'bgColor', '');
dom.setAttrib(tr_elm, 'height', '');
// Set styles
tr_elm.style.height = getCSSSize(formObj.height.value);
tr_elm.style.backgroundColor = formObj.bgcolor.value;
if (formObj.backgroundimage.value != "")
tr_elm.style.backgroundImage = "url('" + formObj.backgroundimage.value + "')";
else
tr_elm.style.backgroundImage = '';
// Setup new rowtype
if (curRowType != rowtype && !skip_parent) {
// first, clone the node we are working on
var newRow = tr_elm.cloneNode(1);
// next, find the parent of its new destination (creating it if necessary)
var theTable = dom.getParent(tr_elm, "table");
var dest = rowtype;
var newParent = null;
for (var i = 0; i < theTable.childNodes.length; i++) {
if (theTable.childNodes[i].nodeName.toLowerCase() == dest)
newParent = theTable.childNodes[i];
}
if (newParent == null) {
newParent = doc.createElement(dest);
if (theTable.firstChild.nodeName == 'CAPTION')
inst.dom.insertAfter(newParent, theTable.firstChild);
else
theTable.insertBefore(newParent, theTable.firstChild);
}
// append the row to the new parent
newParent.appendChild(newRow);
// remove the original
tr_elm.parentNode.removeChild(tr_elm);
// set tr_elm to the new node
tr_elm = newRow;
}
dom.setAttrib(tr_elm, 'style', dom.serializeStyle(dom.parseStyle(tr_elm.style.cssText)));
}
function changedBackgroundImage() {
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
var st = dom.parseStyle(formObj.style.value);
st['background-image'] = "url('" + formObj.backgroundimage.value + "')";
formObj.style.value = dom.serializeStyle(st);
}
function changedStyle() {
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
var st = dom.parseStyle(formObj.style.value);
if (st['background-image'])
formObj.backgroundimage.value = st['background-image'].replace(new RegExp("url\\('?([^']*)'?\\)", 'gi'), "$1");
else
formObj.backgroundimage.value = '';
if (st['height'])
formObj.height.value = trimSize(st['height']);
if (st['background-color']) {
formObj.bgcolor.value = st['background-color'];
updateColor('bgcolor_pick','bgcolor');
}
}
function changedSize() {
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
var st = dom.parseStyle(formObj.style.value);
var height = formObj.height.value;
if (height != "")
st['height'] = getCSSSize(height);
else
st['height'] = "";
formObj.style.value = dom.serializeStyle(st);
}
function changedColor() {
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
var st = dom.parseStyle(formObj.style.value);
st['background-color'] = formObj.bgcolor.value;
formObj.style.value = dom.serializeStyle(st);
}
tinyMCEPopup.onInit.add(init);
tinyMCEPopup.requireLangPack();
function init() {
tinyMCEPopup.resizeToInnerSize();
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
document.getElementById('bgcolor_pickcontainer').innerHTML = getColorPickerHTML('bgcolor_pick','bgcolor');
var inst = tinyMCEPopup.editor;
var dom = inst.dom;
var trElm = dom.getParent(inst.selection.getStart(), "tr");
var formObj = document.forms[0];
var st = dom.parseStyle(dom.getAttrib(trElm, "style"));
// Get table row data
var rowtype = trElm.parentNode.nodeName.toLowerCase();
var align = dom.getAttrib(trElm, 'align');
var valign = dom.getAttrib(trElm, 'valign');
var height = trimSize(getStyle(trElm, 'height', 'height'));
var className = dom.getAttrib(trElm, 'class');
var bgcolor = convertRGBToHex(getStyle(trElm, 'bgcolor', 'backgroundColor'));
var backgroundimage = getStyle(trElm, 'background', 'backgroundImage').replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
var id = dom.getAttrib(trElm, 'id');
var lang = dom.getAttrib(trElm, 'lang');
var dir = dom.getAttrib(trElm, 'dir');
selectByValue(formObj, 'rowtype', rowtype);
setActionforRowType(formObj, rowtype);
// Any cells selected
if (dom.select('td.mceSelected,th.mceSelected', trElm).length == 0) {
// Setup form
addClassesToList('class', 'table_row_styles');
TinyMCE_EditableSelects.init();
formObj.bgcolor.value = bgcolor;
formObj.backgroundimage.value = backgroundimage;
formObj.height.value = height;
formObj.id.value = id;
formObj.lang.value = lang;
formObj.style.value = dom.serializeStyle(st);
selectByValue(formObj, 'align', align);
selectByValue(formObj, 'valign', valign);
selectByValue(formObj, 'class', className, true, true);
selectByValue(formObj, 'dir', dir);
// Resize some elements
if (isVisible('backgroundimagebrowser'))
document.getElementById('backgroundimage').style.width = '180px';
updateColor('bgcolor_pick', 'bgcolor');
} else
tinyMCEPopup.dom.hide('action');
}
function updateAction() {
var inst = tinyMCEPopup.editor, dom = inst.dom, trElm, tableElm, formObj = document.forms[0];
var action = getSelectValue(formObj, 'action');
if (!AutoValidator.validate(formObj)) {
tinyMCEPopup.alert(AutoValidator.getErrorMessages(formObj).join('. ') + '.');
return false;
}
tinyMCEPopup.restoreSelection();
trElm = dom.getParent(inst.selection.getStart(), "tr");
tableElm = dom.getParent(inst.selection.getStart(), "table");
// Update all selected rows
if (dom.select('td.mceSelected,th.mceSelected', trElm).length > 0) {
tinymce.each(tableElm.rows, function(tr) {
var i;
for (i = 0; i < tr.cells.length; i++) {
if (dom.hasClass(tr.cells[i], 'mceSelected')) {
updateRow(tr, true);
return;
}
}
});
inst.addVisual();
inst.nodeChanged();
inst.execCommand('mceEndUndoLevel');
tinyMCEPopup.close();
return;
}
switch (action) {
case "row":
updateRow(trElm);
break;
case "all":
var rows = tableElm.getElementsByTagName("tr");
for (var i=0; i<rows.length; i++)
updateRow(rows[i], true);
break;
case "odd":
case "even":
var rows = tableElm.getElementsByTagName("tr");
for (var i=0; i<rows.length; i++) {
if ((i % 2 == 0 && action == "odd") || (i % 2 != 0 && action == "even"))
updateRow(rows[i], true, true);
}
break;
}
inst.addVisual();
inst.nodeChanged();
inst.execCommand('mceEndUndoLevel');
tinyMCEPopup.close();
}
function updateRow(tr_elm, skip_id, skip_parent) {
var inst = tinyMCEPopup.editor;
var formObj = document.forms[0];
var dom = inst.dom;
var curRowType = tr_elm.parentNode.nodeName.toLowerCase();
var rowtype = getSelectValue(formObj, 'rowtype');
var doc = inst.getDoc();
// Update row element
if (!skip_id)
dom.setAttrib(tr_elm, 'id', formObj.id.value);
dom.setAttrib(tr_elm, 'align', getSelectValue(formObj, 'align'));
dom.setAttrib(tr_elm, 'vAlign', getSelectValue(formObj, 'valign'));
dom.setAttrib(tr_elm, 'lang', formObj.lang.value);
dom.setAttrib(tr_elm, 'dir', getSelectValue(formObj, 'dir'));
dom.setAttrib(tr_elm, 'style', dom.serializeStyle(dom.parseStyle(formObj.style.value)));
dom.setAttrib(tr_elm, 'class', getSelectValue(formObj, 'class'));
// Clear deprecated attributes
dom.setAttrib(tr_elm, 'background', '');
dom.setAttrib(tr_elm, 'bgColor', '');
dom.setAttrib(tr_elm, 'height', '');
// Set styles
tr_elm.style.height = getCSSSize(formObj.height.value);
tr_elm.style.backgroundColor = formObj.bgcolor.value;
if (formObj.backgroundimage.value != "")
tr_elm.style.backgroundImage = "url('" + formObj.backgroundimage.value + "')";
else
tr_elm.style.backgroundImage = '';
// Setup new rowtype
if (curRowType != rowtype && !skip_parent) {
// first, clone the node we are working on
var newRow = tr_elm.cloneNode(1);
// next, find the parent of its new destination (creating it if necessary)
var theTable = dom.getParent(tr_elm, "table");
var dest = rowtype;
var newParent = null;
for (var i = 0; i < theTable.childNodes.length; i++) {
if (theTable.childNodes[i].nodeName.toLowerCase() == dest)
newParent = theTable.childNodes[i];
}
if (newParent == null) {
newParent = doc.createElement(dest);
if (theTable.firstChild.nodeName == 'CAPTION')
inst.dom.insertAfter(newParent, theTable.firstChild);
else
theTable.insertBefore(newParent, theTable.firstChild);
}
// append the row to the new parent
newParent.appendChild(newRow);
// remove the original
tr_elm.parentNode.removeChild(tr_elm);
// set tr_elm to the new node
tr_elm = newRow;
}
dom.setAttrib(tr_elm, 'style', dom.serializeStyle(dom.parseStyle(tr_elm.style.cssText)));
}
function changedBackgroundImage() {
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
var st = dom.parseStyle(formObj.style.value);
st['background-image'] = "url('" + formObj.backgroundimage.value + "')";
formObj.style.value = dom.serializeStyle(st);
}
function changedStyle() {
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
var st = dom.parseStyle(formObj.style.value);
if (st['background-image'])
formObj.backgroundimage.value = st['background-image'].replace(new RegExp("url\\('?([^']*)'?\\)", 'gi'), "$1");
else
formObj.backgroundimage.value = '';
if (st['height'])
formObj.height.value = trimSize(st['height']);
if (st['background-color']) {
formObj.bgcolor.value = st['background-color'];
updateColor('bgcolor_pick','bgcolor');
}
}
function changedSize() {
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
var st = dom.parseStyle(formObj.style.value);
var height = formObj.height.value;
if (height != "")
st['height'] = getCSSSize(height);
else
st['height'] = "";
formObj.style.value = dom.serializeStyle(st);
}
function changedColor() {
var formObj = document.forms[0], dom = tinyMCEPopup.editor.dom;
var st = dom.parseStyle(formObj.style.value);
st['background-color'] = formObj.bgcolor.value;
formObj.style.value = dom.serializeStyle(st);
}
function changedRowType() {
var formObj = document.forms[0];
var rowtype = getSelectValue(formObj, 'rowtype');
setActionforRowType(formObj, rowtype);
}
function setActionforRowType(formObj, rowtype) {
if (rowtype === "tbody") {
formObj.action.disabled = false;
} else {
selectByValue(formObj, 'action', "row");
formObj.action.disabled = true;
}
}
tinyMCEPopup.onInit.add(init);

Bestand weergeven

@ -1,501 +1,501 @@
tinyMCEPopup.requireLangPack();
var action, orgTableWidth, orgTableHeight, dom = tinyMCEPopup.editor.dom;
function insertTable() {
var formObj = document.forms[0];
var inst = tinyMCEPopup.editor, dom = inst.dom;
var cols = 2, rows = 2, border = 0, cellpadding = -1, cellspacing = -1, align, width, height, className, caption, frame, rules;
var html = '', capEl, elm;
var cellLimit, rowLimit, colLimit;
tinyMCEPopup.restoreSelection();
if (!AutoValidator.validate(formObj)) {
tinyMCEPopup.alert(AutoValidator.getErrorMessages(formObj).join('. ') + '.');
return false;
}
elm = dom.getParent(inst.selection.getNode(), 'table');
// Get form data
cols = formObj.elements['cols'].value;
rows = formObj.elements['rows'].value;
border = formObj.elements['border'].value != "" ? formObj.elements['border'].value : 0;
cellpadding = formObj.elements['cellpadding'].value != "" ? formObj.elements['cellpadding'].value : "";
cellspacing = formObj.elements['cellspacing'].value != "" ? formObj.elements['cellspacing'].value : "";
align = getSelectValue(formObj, "align");
frame = getSelectValue(formObj, "tframe");
rules = getSelectValue(formObj, "rules");
width = formObj.elements['width'].value;
height = formObj.elements['height'].value;
bordercolor = formObj.elements['bordercolor'].value;
bgcolor = formObj.elements['bgcolor'].value;
className = getSelectValue(formObj, "class");
id = formObj.elements['id'].value;
summary = formObj.elements['summary'].value;
style = formObj.elements['style'].value;
dir = formObj.elements['dir'].value;
lang = formObj.elements['lang'].value;
background = formObj.elements['backgroundimage'].value;
caption = formObj.elements['caption'].checked;
cellLimit = tinyMCEPopup.getParam('table_cell_limit', false);
rowLimit = tinyMCEPopup.getParam('table_row_limit', false);
colLimit = tinyMCEPopup.getParam('table_col_limit', false);
// Validate table size
if (colLimit && cols > colLimit) {
tinyMCEPopup.alert(inst.getLang('table_dlg.col_limit').replace(/\{\$cols\}/g, colLimit));
return false;
} else if (rowLimit && rows > rowLimit) {
tinyMCEPopup.alert(inst.getLang('table_dlg.row_limit').replace(/\{\$rows\}/g, rowLimit));
return false;
} else if (cellLimit && cols * rows > cellLimit) {
tinyMCEPopup.alert(inst.getLang('table_dlg.cell_limit').replace(/\{\$cells\}/g, cellLimit));
return false;
}
// Update table
if (action == "update") {
dom.setAttrib(elm, 'cellPadding', cellpadding, true);
dom.setAttrib(elm, 'cellSpacing', cellspacing, true);
if (!isCssSize(border)) {
dom.setAttrib(elm, 'border', border);
} else {
dom.setAttrib(elm, 'border', '');
}
if (border == '') {
dom.setStyle(elm, 'border-width', '');
dom.setStyle(elm, 'border', '');
dom.setAttrib(elm, 'border', '');
}
dom.setAttrib(elm, 'align', align);
dom.setAttrib(elm, 'frame', frame);
dom.setAttrib(elm, 'rules', rules);
dom.setAttrib(elm, 'class', className);
dom.setAttrib(elm, 'style', style);
dom.setAttrib(elm, 'id', id);
dom.setAttrib(elm, 'summary', summary);
dom.setAttrib(elm, 'dir', dir);
dom.setAttrib(elm, 'lang', lang);
capEl = inst.dom.select('caption', elm)[0];
if (capEl && !caption)
capEl.parentNode.removeChild(capEl);
if (!capEl && caption) {
capEl = elm.ownerDocument.createElement('caption');
if (!tinymce.isIE)
capEl.innerHTML = '<br data-mce-bogus="1"/>';
elm.insertBefore(capEl, elm.firstChild);
}
if (width && inst.settings.inline_styles) {
dom.setStyle(elm, 'width', width);
dom.setAttrib(elm, 'width', '');
} else {
dom.setAttrib(elm, 'width', width, true);
dom.setStyle(elm, 'width', '');
}
// Remove these since they are not valid XHTML
dom.setAttrib(elm, 'borderColor', '');
dom.setAttrib(elm, 'bgColor', '');
dom.setAttrib(elm, 'background', '');
if (height && inst.settings.inline_styles) {
dom.setStyle(elm, 'height', height);
dom.setAttrib(elm, 'height', '');
} else {
dom.setAttrib(elm, 'height', height, true);
dom.setStyle(elm, 'height', '');
}
if (background != '')
elm.style.backgroundImage = "url('" + background + "')";
else
elm.style.backgroundImage = '';
/* if (tinyMCEPopup.getParam("inline_styles")) {
if (width != '')
elm.style.width = getCSSSize(width);
}*/
if (bordercolor != "") {
elm.style.borderColor = bordercolor;
elm.style.borderStyle = elm.style.borderStyle == "" ? "solid" : elm.style.borderStyle;
elm.style.borderWidth = cssSize(border);
} else
elm.style.borderColor = '';
elm.style.backgroundColor = bgcolor;
elm.style.height = getCSSSize(height);
inst.addVisual();
// Fix for stange MSIE align bug
//elm.outerHTML = elm.outerHTML;
inst.nodeChanged();
inst.execCommand('mceEndUndoLevel', false, {}, {skip_undo: true});
// Repaint if dimensions changed
if (formObj.width.value != orgTableWidth || formObj.height.value != orgTableHeight)
inst.execCommand('mceRepaint');
tinyMCEPopup.close();
return true;
}
// Create new table
html += '<table';
html += makeAttrib('id', id);
if (!isCssSize(border)) {
html += makeAttrib('border', border);
}
html += makeAttrib('cellpadding', cellpadding);
html += makeAttrib('cellspacing', cellspacing);
html += makeAttrib('data-mce-new', '1');
if (width && inst.settings.inline_styles) {
if (style)
style += '; ';
// Force px
if (/^[0-9\.]+$/.test(width))
width += 'px';
style += 'width: ' + width;
} else
html += makeAttrib('width', width);
/* if (height) {
if (style)
style += '; ';
style += 'height: ' + height;
}*/
//html += makeAttrib('height', height);
//html += makeAttrib('bordercolor', bordercolor);
//html += makeAttrib('bgcolor', bgcolor);
html += makeAttrib('align', align);
html += makeAttrib('frame', frame);
html += makeAttrib('rules', rules);
html += makeAttrib('class', className);
html += makeAttrib('style', style);
html += makeAttrib('summary', summary);
html += makeAttrib('dir', dir);
html += makeAttrib('lang', lang);
html += '>';
if (caption) {
if (!tinymce.isIE)
html += '<caption><br data-mce-bogus="1"/></caption>';
else
html += '<caption></caption>';
}
for (var y=0; y<rows; y++) {
html += "<tr>";
for (var x=0; x<cols; x++) {
if (!tinymce.isIE)
html += '<td><br data-mce-bogus="1"/></td>';
else
html += '<td></td>';
}
html += "</tr>";
}
html += "</table>";
// Move table
if (inst.settings.fix_table_elements) {
var patt = '';
inst.focus();
inst.selection.setContent('<br class="_mce_marker" />');
tinymce.each('h1,h2,h3,h4,h5,h6,p'.split(','), function(n) {
if (patt)
patt += ',';
patt += n + ' ._mce_marker';
});
tinymce.each(inst.dom.select(patt), function(n) {
inst.dom.split(inst.dom.getParent(n, 'h1,h2,h3,h4,h5,h6,p'), n);
});
dom.setOuterHTML(dom.select('br._mce_marker')[0], html);
} else
inst.execCommand('mceInsertContent', false, html);
tinyMCEPopup.requireLangPack();
var action, orgTableWidth, orgTableHeight, dom = tinyMCEPopup.editor.dom;
function insertTable() {
var formObj = document.forms[0];
var inst = tinyMCEPopup.editor, dom = inst.dom;
var cols = 2, rows = 2, border = 0, cellpadding = -1, cellspacing = -1, align, width, height, className, caption, frame, rules;
var html = '', capEl, elm;
var cellLimit, rowLimit, colLimit;
tinyMCEPopup.restoreSelection();
if (!AutoValidator.validate(formObj)) {
tinyMCEPopup.alert(AutoValidator.getErrorMessages(formObj).join('. ') + '.');
return false;
}
elm = dom.getParent(inst.selection.getNode(), 'table');
// Get form data
cols = formObj.elements['cols'].value;
rows = formObj.elements['rows'].value;
border = formObj.elements['border'].value != "" ? formObj.elements['border'].value : 0;
cellpadding = formObj.elements['cellpadding'].value != "" ? formObj.elements['cellpadding'].value : "";
cellspacing = formObj.elements['cellspacing'].value != "" ? formObj.elements['cellspacing'].value : "";
align = getSelectValue(formObj, "align");
frame = getSelectValue(formObj, "tframe");
rules = getSelectValue(formObj, "rules");
width = formObj.elements['width'].value;
height = formObj.elements['height'].value;
bordercolor = formObj.elements['bordercolor'].value;
bgcolor = formObj.elements['bgcolor'].value;
className = getSelectValue(formObj, "class");
id = formObj.elements['id'].value;
summary = formObj.elements['summary'].value;
style = formObj.elements['style'].value;
dir = formObj.elements['dir'].value;
lang = formObj.elements['lang'].value;
background = formObj.elements['backgroundimage'].value;
caption = formObj.elements['caption'].checked;
cellLimit = tinyMCEPopup.getParam('table_cell_limit', false);
rowLimit = tinyMCEPopup.getParam('table_row_limit', false);
colLimit = tinyMCEPopup.getParam('table_col_limit', false);
// Validate table size
if (colLimit && cols > colLimit) {
tinyMCEPopup.alert(inst.getLang('table_dlg.col_limit').replace(/\{\$cols\}/g, colLimit));
return false;
} else if (rowLimit && rows > rowLimit) {
tinyMCEPopup.alert(inst.getLang('table_dlg.row_limit').replace(/\{\$rows\}/g, rowLimit));
return false;
} else if (cellLimit && cols * rows > cellLimit) {
tinyMCEPopup.alert(inst.getLang('table_dlg.cell_limit').replace(/\{\$cells\}/g, cellLimit));
return false;
}
// Update table
if (action == "update") {
dom.setAttrib(elm, 'cellPadding', cellpadding, true);
dom.setAttrib(elm, 'cellSpacing', cellspacing, true);
if (!isCssSize(border)) {
dom.setAttrib(elm, 'border', border);
} else {
dom.setAttrib(elm, 'border', '');
}
if (border == '') {
dom.setStyle(elm, 'border-width', '');
dom.setStyle(elm, 'border', '');
dom.setAttrib(elm, 'border', '');
}
dom.setAttrib(elm, 'align', align);
dom.setAttrib(elm, 'frame', frame);
dom.setAttrib(elm, 'rules', rules);
dom.setAttrib(elm, 'class', className);
dom.setAttrib(elm, 'style', style);
dom.setAttrib(elm, 'id', id);
dom.setAttrib(elm, 'summary', summary);
dom.setAttrib(elm, 'dir', dir);
dom.setAttrib(elm, 'lang', lang);
capEl = inst.dom.select('caption', elm)[0];
if (capEl && !caption)
capEl.parentNode.removeChild(capEl);
if (!capEl && caption) {
capEl = elm.ownerDocument.createElement('caption');
if (!tinymce.isIE)
capEl.innerHTML = '<br data-mce-bogus="1"/>';
elm.insertBefore(capEl, elm.firstChild);
}
if (width && inst.settings.inline_styles) {
dom.setStyle(elm, 'width', width);
dom.setAttrib(elm, 'width', '');
} else {
dom.setAttrib(elm, 'width', width, true);
dom.setStyle(elm, 'width', '');
}
// Remove these since they are not valid XHTML
dom.setAttrib(elm, 'borderColor', '');
dom.setAttrib(elm, 'bgColor', '');
dom.setAttrib(elm, 'background', '');
if (height && inst.settings.inline_styles) {
dom.setStyle(elm, 'height', height);
dom.setAttrib(elm, 'height', '');
} else {
dom.setAttrib(elm, 'height', height, true);
dom.setStyle(elm, 'height', '');
}
if (background != '')
elm.style.backgroundImage = "url('" + background + "')";
else
elm.style.backgroundImage = '';
/* if (tinyMCEPopup.getParam("inline_styles")) {
if (width != '')
elm.style.width = getCSSSize(width);
}*/
if (bordercolor != "") {
elm.style.borderColor = bordercolor;
elm.style.borderStyle = elm.style.borderStyle == "" ? "solid" : elm.style.borderStyle;
elm.style.borderWidth = cssSize(border);
} else
elm.style.borderColor = '';
elm.style.backgroundColor = bgcolor;
elm.style.height = getCSSSize(height);
inst.addVisual();
// Fix for stange MSIE align bug
//elm.outerHTML = elm.outerHTML;
inst.nodeChanged();
inst.execCommand('mceEndUndoLevel', false, {}, {skip_undo: true});
// Repaint if dimensions changed
if (formObj.width.value != orgTableWidth || formObj.height.value != orgTableHeight)
inst.execCommand('mceRepaint');
tinyMCEPopup.close();
return true;
}
// Create new table
html += '<table';
html += makeAttrib('id', id);
if (!isCssSize(border)) {
html += makeAttrib('border', border);
}
html += makeAttrib('cellpadding', cellpadding);
html += makeAttrib('cellspacing', cellspacing);
html += makeAttrib('data-mce-new', '1');
if (width && inst.settings.inline_styles) {
if (style)
style += '; ';
// Force px
if (/^[0-9\.]+$/.test(width))
width += 'px';
style += 'width: ' + width;
} else
html += makeAttrib('width', width);
/* if (height) {
if (style)
style += '; ';
style += 'height: ' + height;
}*/
//html += makeAttrib('height', height);
//html += makeAttrib('bordercolor', bordercolor);
//html += makeAttrib('bgcolor', bgcolor);
html += makeAttrib('align', align);
html += makeAttrib('frame', frame);
html += makeAttrib('rules', rules);
html += makeAttrib('class', className);
html += makeAttrib('style', style);
html += makeAttrib('summary', summary);
html += makeAttrib('dir', dir);
html += makeAttrib('lang', lang);
html += '>';
if (caption) {
if (!tinymce.isIE)
html += '<caption><br data-mce-bogus="1"/></caption>';
else
html += '<caption></caption>';
}
for (var y=0; y<rows; y++) {
html += "<tr>";
for (var x=0; x<cols; x++) {
if (!tinymce.isIE)
html += '<td><br data-mce-bogus="1"/></td>';
else
html += '<td></td>';
}
html += "</tr>";
}
html += "</table>";
// Move table
if (inst.settings.fix_table_elements) {
var patt = '';
inst.focus();
inst.selection.setContent('<br class="_mce_marker" />');
tinymce.each('h1,h2,h3,h4,h5,h6,p'.split(','), function(n) {
if (patt)
patt += ',';
patt += n + ' ._mce_marker';
});
tinymce.each(inst.dom.select(patt), function(n) {
inst.dom.split(inst.dom.getParent(n, 'h1,h2,h3,h4,h5,h6,p'), n);
});
dom.setOuterHTML(dom.select('br._mce_marker')[0], html);
} else
inst.execCommand('mceInsertContent', false, html);
tinymce.each(dom.select('table[data-mce-new]'), function(node) {
var tdorth = dom.select('td,th', node);
var tdorth = dom.select('td,th', node);
// Fixes a bug in IE where the caret cannot be placed after the table if the table is at the end of the document
if (tinymce.isIE && node.nextSibling == null) {
if (inst.settings.forced_root_block)
dom.insertAfter(dom.create(inst.settings.forced_root_block), node);
else
dom.insertAfter(dom.create('br', {'data-mce-bogus': '1'}), node);
// Fixes a bug in IE where the caret cannot be placed after the table if the table is at the end of the document
if (tinymce.isIE && node.nextSibling == null) {
if (inst.settings.forced_root_block)
dom.insertAfter(dom.create(inst.settings.forced_root_block), node);
else
dom.insertAfter(dom.create('br', {'data-mce-bogus': '1'}), node);
}
try {
// IE9 might fail to do this selection
inst.selection.setCursorLocation(tdorth[0], 0);
} catch (ex) {
// Ignore
}
dom.setAttrib(node, 'data-mce-new', '');
});
inst.addVisual();
inst.execCommand('mceEndUndoLevel', false, {}, {skip_undo: true});
tinyMCEPopup.close();
}
function makeAttrib(attrib, value) {
var formObj = document.forms[0];
var valueElm = formObj.elements[attrib];
if (typeof(value) == "undefined" || value == null) {
value = "";
if (valueElm)
value = valueElm.value;
}
if (value == "")
return "";
// XML encode it
value = value.replace(/&/g, '&amp;');
value = value.replace(/\"/g, '&quot;');
value = value.replace(/</g, '&lt;');
value = value.replace(/>/g, '&gt;');
return ' ' + attrib + '="' + value + '"';
}
function init() {
tinyMCEPopup.resizeToInnerSize();
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
document.getElementById('bordercolor_pickcontainer').innerHTML = getColorPickerHTML('bordercolor_pick','bordercolor');
document.getElementById('bgcolor_pickcontainer').innerHTML = getColorPickerHTML('bgcolor_pick','bgcolor');
var cols = 2, rows = 2, border = tinyMCEPopup.getParam('table_default_border', '0'), cellpadding = tinyMCEPopup.getParam('table_default_cellpadding', ''), cellspacing = tinyMCEPopup.getParam('table_default_cellspacing', '');
var align = "", width = "", height = "", bordercolor = "", bgcolor = "", className = "";
var id = "", summary = "", style = "", dir = "", lang = "", background = "", bgcolor = "", bordercolor = "", rules = "", frame = "";
var inst = tinyMCEPopup.editor, dom = inst.dom;
var formObj = document.forms[0];
var elm = dom.getParent(inst.selection.getNode(), "table");
// Hide advanced fields that isn't available in the schema
tinymce.each("summary id rules dir style frame".split(" "), function(name) {
var tr = tinyMCEPopup.dom.getParent(name, "tr") || tinyMCEPopup.dom.getParent("t" + name, "tr");
if (tr && !tinyMCEPopup.editor.schema.isValid("table", name)) {
tr.style.display = 'none';
}
});
action = tinyMCEPopup.getWindowArg('action');
if (!action)
action = elm ? "update" : "insert";
if (elm && action != "insert") {
var rowsAr = elm.rows;
var cols = 0;
for (var i=0; i<rowsAr.length; i++)
if (rowsAr[i].cells.length > cols)
cols = rowsAr[i].cells.length;
cols = cols;
rows = rowsAr.length;
st = dom.parseStyle(dom.getAttrib(elm, "style"));
border = trimSize(getStyle(elm, 'border', 'borderWidth'));
cellpadding = dom.getAttrib(elm, 'cellpadding', "");
cellspacing = dom.getAttrib(elm, 'cellspacing', "");
width = trimSize(getStyle(elm, 'width', 'width'));
height = trimSize(getStyle(elm, 'height', 'height'));
bordercolor = convertRGBToHex(getStyle(elm, 'bordercolor', 'borderLeftColor'));
bgcolor = convertRGBToHex(getStyle(elm, 'bgcolor', 'backgroundColor'));
align = dom.getAttrib(elm, 'align', align);
frame = dom.getAttrib(elm, 'frame');
rules = dom.getAttrib(elm, 'rules');
className = tinymce.trim(dom.getAttrib(elm, 'class').replace(/mceItem.+/g, ''));
id = dom.getAttrib(elm, 'id');
summary = dom.getAttrib(elm, 'summary');
style = dom.serializeStyle(st);
dir = dom.getAttrib(elm, 'dir');
lang = dom.getAttrib(elm, 'lang');
background = getStyle(elm, 'background', 'backgroundImage').replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
formObj.caption.checked = elm.getElementsByTagName('caption').length > 0;
orgTableWidth = width;
orgTableHeight = height;
action = "update";
formObj.insert.value = inst.getLang('update');
}
addClassesToList('class', "table_styles");
TinyMCE_EditableSelects.init();
// Update form
selectByValue(formObj, 'align', align);
selectByValue(formObj, 'tframe', frame);
selectByValue(formObj, 'rules', rules);
selectByValue(formObj, 'class', className, true, true);
formObj.cols.value = cols;
formObj.rows.value = rows;
formObj.border.value = border;
formObj.cellpadding.value = cellpadding;
formObj.cellspacing.value = cellspacing;
formObj.width.value = width;
formObj.height.value = height;
formObj.bordercolor.value = bordercolor;
formObj.bgcolor.value = bgcolor;
formObj.id.value = id;
formObj.summary.value = summary;
formObj.style.value = style;
formObj.dir.value = dir;
formObj.lang.value = lang;
formObj.backgroundimage.value = background;
updateColor('bordercolor_pick', 'bordercolor');
updateColor('bgcolor_pick', 'bgcolor');
// Resize some elements
if (isVisible('backgroundimagebrowser'))
document.getElementById('backgroundimage').style.width = '180px';
// Disable some fields in update mode
if (action == "update") {
formObj.cols.disabled = true;
formObj.rows.disabled = true;
}
}
function changedSize() {
var formObj = document.forms[0];
var st = dom.parseStyle(formObj.style.value);
/* var width = formObj.width.value;
if (width != "")
st['width'] = tinyMCEPopup.getParam("inline_styles") ? getCSSSize(width) : "";
else
st['width'] = "";*/
var height = formObj.height.value;
if (height != "")
st['height'] = getCSSSize(height);
else
st['height'] = "";
formObj.style.value = dom.serializeStyle(st);
}
function isCssSize(value) {
return /^[0-9.]+(%|in|cm|mm|em|ex|pt|pc|px)$/.test(value);
}
function cssSize(value, def) {
value = tinymce.trim(value || def);
if (!isCssSize(value)) {
return parseInt(value, 10) + 'px';
}
return value;
}
function changedBackgroundImage() {
var formObj = document.forms[0];
var st = dom.parseStyle(formObj.style.value);
st['background-image'] = "url('" + formObj.backgroundimage.value + "')";
formObj.style.value = dom.serializeStyle(st);
}
function changedBorder() {
var formObj = document.forms[0];
var st = dom.parseStyle(formObj.style.value);
// Update border width if the element has a color
if (formObj.border.value != "" && (isCssSize(formObj.border.value) || formObj.bordercolor.value != ""))
st['border-width'] = cssSize(formObj.border.value);
else {
if (!formObj.border.value) {
st['border'] = '';
st['border-width'] = '';
}
}
formObj.style.value = dom.serializeStyle(st);
}
function changedColor() {
var formObj = document.forms[0];
var st = dom.parseStyle(formObj.style.value);
st['background-color'] = formObj.bgcolor.value;
if (formObj.bordercolor.value != "") {
st['border-color'] = formObj.bordercolor.value;
// Add border-width if it's missing
if (!st['border-width'])
st['border-width'] = cssSize(formObj.border.value, 1);
}
formObj.style.value = dom.serializeStyle(st);
}
function changedStyle() {
var formObj = document.forms[0];
var st = dom.parseStyle(formObj.style.value);
if (st['background-image'])
formObj.backgroundimage.value = st['background-image'].replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
else
formObj.backgroundimage.value = '';
if (st['width'])
formObj.width.value = trimSize(st['width']);
if (st['height'])
formObj.height.value = trimSize(st['height']);
if (st['background-color']) {
formObj.bgcolor.value = st['background-color'];
updateColor('bgcolor_pick','bgcolor');
}
if (st['border-color']) {
formObj.bordercolor.value = st['border-color'];
updateColor('bordercolor_pick','bordercolor');
}
}
tinyMCEPopup.onInit.add(init);
try {
// IE9 might fail to do this selection
inst.selection.setCursorLocation(tdorth[0], 0);
} catch (ex) {
// Ignore
}
dom.setAttrib(node, 'data-mce-new', '');
});
inst.addVisual();
inst.execCommand('mceEndUndoLevel', false, {}, {skip_undo: true});
tinyMCEPopup.close();
}
function makeAttrib(attrib, value) {
var formObj = document.forms[0];
var valueElm = formObj.elements[attrib];
if (typeof(value) == "undefined" || value == null) {
value = "";
if (valueElm)
value = valueElm.value;
}
if (value == "")
return "";
// XML encode it
value = value.replace(/&/g, '&amp;');
value = value.replace(/\"/g, '&quot;');
value = value.replace(/</g, '&lt;');
value = value.replace(/>/g, '&gt;');
return ' ' + attrib + '="' + value + '"';
}
function init() {
tinyMCEPopup.resizeToInnerSize();
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
document.getElementById('backgroundimagebrowsercontainer').innerHTML = getBrowserHTML('backgroundimagebrowser','backgroundimage','image','table');
document.getElementById('bordercolor_pickcontainer').innerHTML = getColorPickerHTML('bordercolor_pick','bordercolor');
document.getElementById('bgcolor_pickcontainer').innerHTML = getColorPickerHTML('bgcolor_pick','bgcolor');
var cols = 2, rows = 2, border = tinyMCEPopup.getParam('table_default_border', '0'), cellpadding = tinyMCEPopup.getParam('table_default_cellpadding', ''), cellspacing = tinyMCEPopup.getParam('table_default_cellspacing', '');
var align = "", width = "", height = "", bordercolor = "", bgcolor = "", className = "";
var id = "", summary = "", style = "", dir = "", lang = "", background = "", bgcolor = "", bordercolor = "", rules = "", frame = "";
var inst = tinyMCEPopup.editor, dom = inst.dom;
var formObj = document.forms[0];
var elm = dom.getParent(inst.selection.getNode(), "table");
// Hide advanced fields that isn't available in the schema
tinymce.each("summary id rules dir style frame".split(" "), function(name) {
var tr = tinyMCEPopup.dom.getParent(name, "tr") || tinyMCEPopup.dom.getParent("t" + name, "tr");
if (tr && !tinyMCEPopup.editor.schema.isValid("table", name)) {
tr.style.display = 'none';
}
});
action = tinyMCEPopup.getWindowArg('action');
if (!action)
action = elm ? "update" : "insert";
if (elm && action != "insert") {
var rowsAr = elm.rows;
var cols = 0;
for (var i=0; i<rowsAr.length; i++)
if (rowsAr[i].cells.length > cols)
cols = rowsAr[i].cells.length;
cols = cols;
rows = rowsAr.length;
st = dom.parseStyle(dom.getAttrib(elm, "style"));
border = trimSize(getStyle(elm, 'border', 'borderWidth'));
cellpadding = dom.getAttrib(elm, 'cellpadding', "");
cellspacing = dom.getAttrib(elm, 'cellspacing', "");
width = trimSize(getStyle(elm, 'width', 'width'));
height = trimSize(getStyle(elm, 'height', 'height'));
bordercolor = convertRGBToHex(getStyle(elm, 'bordercolor', 'borderLeftColor'));
bgcolor = convertRGBToHex(getStyle(elm, 'bgcolor', 'backgroundColor'));
align = dom.getAttrib(elm, 'align', align);
frame = dom.getAttrib(elm, 'frame');
rules = dom.getAttrib(elm, 'rules');
className = tinymce.trim(dom.getAttrib(elm, 'class').replace(/mceItem.+/g, ''));
id = dom.getAttrib(elm, 'id');
summary = dom.getAttrib(elm, 'summary');
style = dom.serializeStyle(st);
dir = dom.getAttrib(elm, 'dir');
lang = dom.getAttrib(elm, 'lang');
background = getStyle(elm, 'background', 'backgroundImage').replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
formObj.caption.checked = elm.getElementsByTagName('caption').length > 0;
orgTableWidth = width;
orgTableHeight = height;
action = "update";
formObj.insert.value = inst.getLang('update');
}
addClassesToList('class', "table_styles");
TinyMCE_EditableSelects.init();
// Update form
selectByValue(formObj, 'align', align);
selectByValue(formObj, 'tframe', frame);
selectByValue(formObj, 'rules', rules);
selectByValue(formObj, 'class', className, true, true);
formObj.cols.value = cols;
formObj.rows.value = rows;
formObj.border.value = border;
formObj.cellpadding.value = cellpadding;
formObj.cellspacing.value = cellspacing;
formObj.width.value = width;
formObj.height.value = height;
formObj.bordercolor.value = bordercolor;
formObj.bgcolor.value = bgcolor;
formObj.id.value = id;
formObj.summary.value = summary;
formObj.style.value = style;
formObj.dir.value = dir;
formObj.lang.value = lang;
formObj.backgroundimage.value = background;
updateColor('bordercolor_pick', 'bordercolor');
updateColor('bgcolor_pick', 'bgcolor');
// Resize some elements
if (isVisible('backgroundimagebrowser'))
document.getElementById('backgroundimage').style.width = '180px';
// Disable some fields in update mode
if (action == "update") {
formObj.cols.disabled = true;
formObj.rows.disabled = true;
}
}
function changedSize() {
var formObj = document.forms[0];
var st = dom.parseStyle(formObj.style.value);
/* var width = formObj.width.value;
if (width != "")
st['width'] = tinyMCEPopup.getParam("inline_styles") ? getCSSSize(width) : "";
else
st['width'] = "";*/
var height = formObj.height.value;
if (height != "")
st['height'] = getCSSSize(height);
else
st['height'] = "";
formObj.style.value = dom.serializeStyle(st);
}
function isCssSize(value) {
return /^[0-9.]+(%|in|cm|mm|em|ex|pt|pc|px)$/.test(value);
}
function cssSize(value, def) {
value = tinymce.trim(value || def);
if (!isCssSize(value)) {
return parseInt(value, 10) + 'px';
}
return value;
}
function changedBackgroundImage() {
var formObj = document.forms[0];
var st = dom.parseStyle(formObj.style.value);
st['background-image'] = "url('" + formObj.backgroundimage.value + "')";
formObj.style.value = dom.serializeStyle(st);
}
function changedBorder() {
var formObj = document.forms[0];
var st = dom.parseStyle(formObj.style.value);
// Update border width if the element has a color
if (formObj.border.value != "" && (isCssSize(formObj.border.value) || formObj.bordercolor.value != ""))
st['border-width'] = cssSize(formObj.border.value);
else {
if (!formObj.border.value) {
st['border'] = '';
st['border-width'] = '';
}
}
formObj.style.value = dom.serializeStyle(st);
}
function changedColor() {
var formObj = document.forms[0];
var st = dom.parseStyle(formObj.style.value);
st['background-color'] = formObj.bgcolor.value;
if (formObj.bordercolor.value != "") {
st['border-color'] = formObj.bordercolor.value;
// Add border-width if it's missing
if (!st['border-width'])
st['border-width'] = cssSize(formObj.border.value, 1);
}
formObj.style.value = dom.serializeStyle(st);
}
function changedStyle() {
var formObj = document.forms[0];
var st = dom.parseStyle(formObj.style.value);
if (st['background-image'])
formObj.backgroundimage.value = st['background-image'].replace(new RegExp("url\\(['\"]?([^'\"]*)['\"]?\\)", 'gi'), "$1");
else
formObj.backgroundimage.value = '';
if (st['width'])
formObj.width.value = trimSize(st['width']);
if (st['height'])
formObj.height.value = trimSize(st['height']);
if (st['background-color']) {
formObj.bgcolor.value = st['background-color'];
updateColor('bgcolor_pick','bgcolor');
}
if (st['border-color']) {
formObj.bordercolor.value = st['border-color'];
updateColor('bordercolor_pick','bordercolor');
}
}
tinyMCEPopup.onInit.add(init);

Bestand weergeven

@ -1,158 +1,158 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>{#table_dlg.row_title}</title>
<script type="text/javascript" src="../../tiny_mce_popup.js"></script>
<script type="text/javascript" src="../../utils/mctabs.js"></script>
<script type="text/javascript" src="../../utils/form_utils.js"></script>
<script type="text/javascript" src="../../utils/validate.js"></script>
<script type="text/javascript" src="../../utils/editable_selects.js"></script>
<script type="text/javascript" src="js/row.js"></script>
<link href="css/row.css" rel="stylesheet" type="text/css" />
</head>
<body id="tablerow" style="display: none" role="application">
<form onsubmit="updateAction();return false;" action="#">
<div class="tabs">
<ul>
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#table_dlg.general_tab}</a></span></li>
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#table_dlg.advanced_tab}</a></span></li>
</ul>
</div>
<div class="panel_wrapper">
<div id="general_panel" class="panel current">
<fieldset>
<legend>{#table_dlg.general_props}</legend>
<table role="presentation" border="0" cellpadding="4" cellspacing="0">
<tr>
<td><label for="rowtype">{#table_dlg.rowtype}</label></td>
<td class="col2">
<select id="rowtype" name="rowtype" class="mceFocus">
<option value="thead">{#table_dlg.thead}</option>
<option value="tbody">{#table_dlg.tbody}</option>
<option value="tfoot">{#table_dlg.tfoot}</option>
</select>
</td>
</tr>
<tr>
<td><label for="align">{#table_dlg.align}</label></td>
<td class="col2">
<select id="align" name="align">
<option value="">{#not_set}</option>
<option value="center">{#table_dlg.align_middle}</option>
<option value="left">{#table_dlg.align_left}</option>
<option value="right">{#table_dlg.align_right}</option>
</select>
</td>
</tr>
<tr>
<td><label for="valign">{#table_dlg.valign}</label></td>
<td class="col2">
<select id="valign" name="valign">
<option value="">{#not_set}</option>
<option value="top">{#table_dlg.align_top}</option>
<option value="middle">{#table_dlg.align_middle}</option>
<option value="bottom">{#table_dlg.align_bottom}</option>
</select>
</td>
</tr>
<tr id="styleSelectRow">
<td><label for="class">{#class_name}</label></td>
<td class="col2">
<select id="class" name="class" class="mceEditableSelect">
<option value="" selected="selected">{#not_set}</option>
</select>
</td>
</tr>
<tr>
<td><label for="height">{#table_dlg.height}</label></td>
<td class="col2"><input name="height" type="text" id="height" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
</tr>
</table>
</fieldset>
</div>
<div id="advanced_panel" class="panel">
<fieldset>
<legend>{#table_dlg.advanced_props}</legend>
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
<tr>
<td class="column1"><label for="id">{#table_dlg.id}</label></td>
<td><input id="id" name="id" type="text" value="" style="width: 200px" /></td>
</tr>
<tr>
<td><label for="style">{#table_dlg.style}</label></td>
<td><input type="text" id="style" name="style" value="" style="width: 200px;" onchange="changedStyle();" /></td>
</tr>
<tr>
<td class="column1"><label for="dir">{#table_dlg.langdir}</label></td>
<td>
<select id="dir" name="dir" style="width: 200px">
<option value="">{#not_set}</option>
<option value="ltr">{#table_dlg.ltr}</option>
<option value="rtl">{#table_dlg.rtl}</option>
</select>
</td>
</tr>
<tr>
<td class="column1"><label for="lang">{#table_dlg.langcode}</label></td>
<td>
<input id="lang" name="lang" type="text" value="" style="width: 200px" />
</td>
</tr>
<tr>
<td class="column1"><label for="backgroundimage">{#table_dlg.bgimage}</label></td>
<td>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td><input id="backgroundimage" name="backgroundimage" type="text" value="" style="width: 200px" onchange="changedBackgroundImage();" /></td>
<td id="backgroundimagebrowsercontainer">&nbsp;</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="column1"><label for="bgcolor" id="bgcolor_label">{#table_dlg.bgcolor}</label></td>
<td>
<span role="group" aria-labelledby="bgcolor_label">
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td><input id="bgcolor" name="bgcolor" type="text" value="" size="9" onchange="updateColor('bgcolor_pick','bgcolor');changedColor();" /></td>
<td id="bgcolor_pickcontainer">&nbsp;</td>
</tr>
</table>
</span>
</td>
</tr>
</table>
</fieldset>
</div>
</div>
<div class="mceActionPanel">
<div>
<select id="action" name="action">
<option value="row">{#table_dlg.row_row}</option>
<option value="odd">{#table_dlg.row_odd}</option>
<option value="even">{#table_dlg.row_even}</option>
<option value="all">{#table_dlg.row_all}</option>
</select>
</div>
<input type="submit" id="insert" name="insert" value="{#update}" />
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
</div>
</form>
</body>
</html>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>{#table_dlg.row_title}</title>
<script type="text/javascript" src="../../tiny_mce_popup.js"></script>
<script type="text/javascript" src="../../utils/mctabs.js"></script>
<script type="text/javascript" src="../../utils/form_utils.js"></script>
<script type="text/javascript" src="../../utils/validate.js"></script>
<script type="text/javascript" src="../../utils/editable_selects.js"></script>
<script type="text/javascript" src="js/row.js"></script>
<link href="css/row.css" rel="stylesheet" type="text/css" />
</head>
<body id="tablerow" style="display: none" role="application">
<form onsubmit="updateAction();return false;" action="#">
<div class="tabs">
<ul>
<li id="general_tab" class="current" aria-controls="general_panel"><span><a href="javascript:mcTabs.displayTab('general_tab','general_panel');" onmousedown="return false;">{#table_dlg.general_tab}</a></span></li>
<li id="advanced_tab" aria-controls="advanced_panel"><span><a href="javascript:mcTabs.displayTab('advanced_tab','advanced_panel');" onmousedown="return false;">{#table_dlg.advanced_tab}</a></span></li>
</ul>
</div>
<div class="panel_wrapper">
<div id="general_panel" class="panel current">
<fieldset>
<legend>{#table_dlg.general_props}</legend>
<table role="presentation" border="0" cellpadding="4" cellspacing="0">
<tr>
<td><label for="rowtype">{#table_dlg.rowtype}</label></td>
<td class="col2">
<select id="rowtype" name="rowtype" class="mceFocus" onChange="changedRowType();">
<option value="thead">{#table_dlg.thead}</option>
<option value="tbody">{#table_dlg.tbody}</option>
<option value="tfoot">{#table_dlg.tfoot}</option>
</select>
</td>
</tr>
<tr>
<td><label for="align">{#table_dlg.align}</label></td>
<td class="col2">
<select id="align" name="align">
<option value="">{#not_set}</option>
<option value="center">{#table_dlg.align_middle}</option>
<option value="left">{#table_dlg.align_left}</option>
<option value="right">{#table_dlg.align_right}</option>
</select>
</td>
</tr>
<tr>
<td><label for="valign">{#table_dlg.valign}</label></td>
<td class="col2">
<select id="valign" name="valign">
<option value="">{#not_set}</option>
<option value="top">{#table_dlg.align_top}</option>
<option value="middle">{#table_dlg.align_middle}</option>
<option value="bottom">{#table_dlg.align_bottom}</option>
</select>
</td>
</tr>
<tr id="styleSelectRow">
<td><label for="class">{#class_name}</label></td>
<td class="col2">
<select id="class" name="class" class="mceEditableSelect">
<option value="" selected="selected">{#not_set}</option>
</select>
</td>
</tr>
<tr>
<td><label for="height">{#table_dlg.height}</label></td>
<td class="col2"><input name="height" type="text" id="height" value="" size="7" maxlength="7" onchange="changedSize();" class="size" /></td>
</tr>
</table>
</fieldset>
</div>
<div id="advanced_panel" class="panel">
<fieldset>
<legend>{#table_dlg.advanced_props}</legend>
<table role="presentation" border="0" cellpadding="0" cellspacing="4">
<tr>
<td class="column1"><label for="id">{#table_dlg.id}</label></td>
<td><input id="id" name="id" type="text" value="" style="width: 200px" /></td>
</tr>
<tr>
<td><label for="style">{#table_dlg.style}</label></td>
<td><input type="text" id="style" name="style" value="" style="width: 200px;" onchange="changedStyle();" /></td>
</tr>
<tr>
<td class="column1"><label for="dir">{#table_dlg.langdir}</label></td>
<td>
<select id="dir" name="dir" style="width: 200px">
<option value="">{#not_set}</option>
<option value="ltr">{#table_dlg.ltr}</option>
<option value="rtl">{#table_dlg.rtl}</option>
</select>
</td>
</tr>
<tr>
<td class="column1"><label for="lang">{#table_dlg.langcode}</label></td>
<td>
<input id="lang" name="lang" type="text" value="" style="width: 200px" />
</td>
</tr>
<tr>
<td class="column1"><label for="backgroundimage">{#table_dlg.bgimage}</label></td>
<td>
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td><input id="backgroundimage" name="backgroundimage" type="text" value="" style="width: 200px" onchange="changedBackgroundImage();" /></td>
<td id="backgroundimagebrowsercontainer">&nbsp;</td>
</tr>
</table>
</td>
</tr>
<tr>
<td class="column1"><label for="bgcolor" id="bgcolor_label">{#table_dlg.bgcolor}</label></td>
<td>
<span role="group" aria-labelledby="bgcolor_label">
<table role="presentation" border="0" cellpadding="0" cellspacing="0">
<tr>
<td><input id="bgcolor" name="bgcolor" type="text" value="" size="9" onchange="updateColor('bgcolor_pick','bgcolor');changedColor();" /></td>
<td id="bgcolor_pickcontainer">&nbsp;</td>
</tr>
</table>
</span>
</td>
</tr>
</table>
</fieldset>
</div>
</div>
<div class="mceActionPanel">
<div>
<select id="action" name="action">
<option value="row">{#table_dlg.row_row}</option>
<option value="odd">{#table_dlg.row_odd}</option>
<option value="even">{#table_dlg.row_even}</option>
<option value="all">{#table_dlg.row_all}</option>
</select>
</div>
<input type="submit" id="insert" name="insert" value="{#update}" />
<input type="button" id="cancel" name="cancel" value="{#cancel}" onclick="tinyMCEPopup.close();" />
</div>
</form>
</body>
</html>

Bestand-diff onderdrukt omdat een of meer regels te lang zijn

Bestand-diff onderdrukt omdat een of meer regels te lang zijn

Diff onderdrukt omdat het te groot bestand Laad Diff

Bestand weergeven

@ -1,55 +1,54 @@
<?php
/**
* HDI TinyMCE
* Copyright (C) 2012 HEINER DIRECT GmbH & Co. KG
* info: info@heiner-direct.com
*
* This program is free software;
* you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation;
* either version 3 of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
* You should have received a copy of the GNU General Public License along with this program; if not, see <http://www.gnu.org/licenses/>
*/
class tinyMCE extends tinyMCE_parent {
protected function _generateTextEditor($iWidth, $iHeight, $oObject, $sField, $sStylesheet = null) {
$myConfig = $this->getConfig();
$sConfigParam = "bTinyMCE_" . $this->getClassName();
//check if tinyMCE is active for this calss
if ($myConfig->getConfigParam($sConfigParam) === true) {
$oViewConf = $this->_aViewData["oViewConf"];
$smarty = oxUtilsView::getInstance()->getSmarty();
//$sEditor = $smarty->fetch($myConfig->getModulesDir()."hdi/hdi-tinymce/test.tpl");
if ($oObject) {
$sInitialValue = '';
if ($oObject->$sField instanceof oxField) {
$sInitialValue = $oObject->$sField->getRawValue();
} else {
$sInitialValue = $oObject->$sField->value;
}
//$oObject->$sField = new oxField(str_replace('[{$shop->currenthomedir}]', $myConfig->getCurrentShopURL(), $sInitialValue), oxField::T_RAW);
$smarty->assign( "sField", $sField);
$smarty->assign( "iWidth", (strpos($iWidth, '%') === false) ? $iWidth . 'px' : $iWidth);
$smarty->assign( "iHeight", "80%");
//$smarty->assign( "iHeight", (strpos($iHeight, '%') === false) ? $iHeight . 'px' : $iHeight);
$smarty->assign( "sContent", $this->_getEditValue($oObject, $sField));
//var_dump($myConfig->getModulesDir()."hdi/hdi-tinymce/test.tpl");
$smarty->assign( "cfg", $myConfig);
$smarty->assign( "oViewConf", $this->_aViewData["oViewConf"]);
$sEditor = $smarty->fetch("tinymce.tpl");
}
return $sEditor;
} else {
//returning default textarea or whatever
return parent::_generateTextEditor($iWidth, $iHeight, $oObject, $sField, $sStylesheet);
}
}
<?php
/**
* HDI TinyMCE
* Copyright (C) 2012 HEINER DIRECT GmbH & Co. KG
* info: info@heiner-direct.com
*
* This program is free software;
* you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation;
* either version 3 of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
* You should have received a copy of the GNU General Public License along with this program; if not, see <http://www.gnu.org/licenses/>
*/
class tinyMCE extends tinyMCE_parent {
protected function _generateTextEditor($iWidth, $iHeight, $oObject, $sField, $sStylesheet = null) {
$myConfig = $this->getConfig();
$sConfigParam = "bTinyMCE_" . $this->getClassName();
//check if tinyMCE is active for this calss
if ($myConfig->getConfigParam($sConfigParam) === true) {
$oViewConf = $this->_aViewData["oViewConf"];
$smarty = oxUtilsView::getInstance()->getSmarty();
//$sEditor = $smarty->fetch($myConfig->getModulesDir()."hdi/hdi-tinymce/test.tpl");
if ($oObject) {
$sInitialValue = '';
if ($oObject->$sField instanceof oxField) {
$sInitialValue = $oObject->$sField->getRawValue();
} else {
$sInitialValue = $oObject->$sField->value;
}
//$oObject->$sField = new oxField(str_replace('[{$shop->currenthomedir}]', $myConfig->getCurrentShopURL(), $sInitialValue), oxField::T_RAW);
$smarty->assign( "sField", $sField);
$smarty->assign( "iWidth", (strpos($iWidth, '%') === false) ? $iWidth . 'px' : $iWidth);
$smarty->assign( "iHeight", "80%");
//$smarty->assign( "iHeight", (strpos($iHeight, '%') === false) ? $iHeight . 'px' : $iHeight);
$smarty->assign( "sContent", $this->_getEditValue($oObject, $sField));
//var_dump($myConfig->getModulesDir()."hdi/hdi-tinymce/test.tpl");
$smarty->assign( "cfg", $myConfig);
$smarty->assign( "oViewConf", $this->_aViewData["oViewConf"]);
$sEditor = $smarty->fetch("tinymce.tpl");
}
return $sEditor;
} else {
//returning default textarea or whatever
return parent::_generateTextEditor($iWidth, $iHeight, $oObject, $sField, $sStylesheet);
}
}
}

Binair bestand niet weergegeven.

Na

Breedte:  |  Hoogte:  |  Grootte: 1.9 KiB