mstdmstd
(Mstdmstd)
1
Hello,
Using Yii::app()->clientScript->registerScriptFile( and Yii::app()->assetManager->publish
I published ‘tinymce.min.js’ file to include tinymce editor into my project, but it raised many errors as all related tinymce js-files are not found.
Viewing source file I see the line
<script type="text/javascript" src="/tybapp/assets/f1c9e5f1/tinymce.min.js"></script>
But subdirectory assets/f1c9e5f1/ has only 1 file tinymce.min.js and no other tinymce files and this raise the errros.
How to fix it ?
alirz23
(Alirz23)
2
you gotta do it explicitly since otherfiles are not in the same dir as tinymce, OR you can use the ext
http://www.yiiframework.com/extension/tinymce/
mstdmstd
(Mstdmstd)
3
Thanks, This extension is good, but I install it on the form
<?php $this->widget('application.extensions.tinymce.ETinyMce', array('name'=>'content')); ?>
and with this extension when I click on "Update" button with code:
onclick="javascript:CmsitemFuncs.onSubmit(1);"
and function defined
CmsitemFuncs.prototype.onSubmit = function (IsReopen) {
var theForm = $("#form_cmsitem_edit");
$("#is_reopen").val(IsReopen)
theForm.submit();
}
I see error in JS console
TypeError: k.type.toUpperCase is not a function
and it shows at packed jquery-1.11.1.min.js file.
So submit of form is not working with this extension.
If this extension is commented out then submitting works ok.
I comments for this extension I see block "Jquery Conflict" - seems somebody else had similar error, but I did not find the decision.
I tried to googlle, but I did not find how to fix it ?
alirz23
(Alirz23)
4
do you include jquery? if you do remove your jquery reference let the ext take care of that