Page 1 of 3 123 LastLast
Results 1 to 10 of 23

Thread: [3.x]Ext.ux.form.HtmlEditor.Picture

  1. #1
    Sencha User
    Join Date
    May 2008
    Location
    Earth Aisa
    Posts
    19

    Default [3.x]Ext.ux.form.HtmlEditor.Picture

    Ext.form.HtmlEditor not support Upload image.

    HTML Code:
     <script type="text/javascript" src="js/Ext.ux.form.HtmlEditor.Picture.js"></script>
     <link rel="stylesheet" type="text/css" href="js/Ext.ux.form.HtmlEditor.Picture.css" />
    Code:
    Ext.QuickTips.init();
       new Ext.form.HtmlEditor({
            renderTo: Ext.getBody(),
            width: 600,
            height: 300,
        plugins: [
         new Ext.ux.form.HtmlEditor.Divider(),
                       new Ext.ux.form.HtmlEditor.Picture({
                         uploadUrl:'php/up-img.php',
                         downloadUrl:'php/get-images.php',
                        flashUrl:'js/swfupload.swf'
                       })
              ]
       });

    demo:http://plugins.extgui.cn/htmleditor_...ture/index.php

    demo.jpg

    upload.jpg

    htmleditor_plugins_picture.zip

  2. #2
    Sencha Premium User wemerson.januario's Avatar
    Join Date
    Nov 2008
    Location
    Goiânia - GO, Brazil
    Posts
    905

    Default good

    Nice work. I'm gonna test.

  3. #3

    Default

    Example files online and downloads do not work

  4. #4
    Sencha User
    Join Date
    May 2008
    Location
    Earth Aisa
    Posts
    19

    Default

    Quote Originally Posted by Fabyo View Post
    Example files online and downloads do not work
    fixed, please try again.

    cn_en.zip

  5. #5

    Default

    Thank you for your dedication, but still not working.



    Error calling method on NPObject!
    var swfobject=function(){var E="undefine...}});Ext.grid.GroupingView.GROUP_ID=1000;ext-all.js (linha 11)

    e is undefined
    window.undefined=window.undefined;Ext={v...)}window.attachEvent("onunload",a)}})();ext-base.js (linha 7)

    Ext.ux.form.HtmlEditor.Divider is not a constructor
    new Ext.ux.form.HtmlEditor.Divider(),\r\n

  6. #6
    Sencha User
    Join Date
    Mar 2007
    Location
    Baltimore, MD
    Posts
    1,501

    Default

    "Ext.ux.form.HtmlEditor.Divider is not a constructor"

    The Divider is part of the HtmlEditor Plugins UX, so you will need to include that as well.

  7. #7

    Default

    index.php included:

    <script type="text/javascript" src="js/ext-base.js"></script>
    <script type="text/javascript" src="js/ext-all.js"></script>
    <script type="text/javascript" src="js/Ext.ux.HtmlEditor.Plugins.js"></script>
    <script type="text/javascript" src="js/ext-lang-pt_BR.js"></script>
    <script type="text/javascript" src="js/Ext.ux.form.HtmlEditor.Picture.js"></script>
    <link rel="stylesheet" type="text/css" href="css/Ext.ux.form.HtmlEditor.Picture.css" />
    <script type="text/javascript" src="js/swfupload.js"></script>
    error:

    Code:
    Error calling method on NPObject!
    var swfobject=function(){var E="undefine...}});Ext.grid.GroupingView.GROUP_ID=1000;ext-all.js (linha 11)
    
    e is undefined
    window.undefined=window.undefined;Ext={v...)}window.attachEvent("onunload",a)}})();ext-base.js (linha 7)
    
    Ext.ux.form.HtmlEditor.Picture is not a constructor
                                    flashUrl:'js/swfupload.swf'\r\n

  8. #8
    Sencha User
    Join Date
    May 2008
    Location
    Earth Aisa
    Posts
    19

    Default

    if you have the last version of the Ext3.
    remove the code
    Code:
    Ext.override(Ext.form.HtmlEditor, {
     insertAtCursor : function(text){
         if(!this.activated){
             return;
         }
         if(Ext.isIE){
             this.win.focus();
             var r = this.doc.selection.createRange();
             if(r){
                 r.collapse(true);
                 r.pasteHTML(text);
                 this.syncValue();
                 this.deferFocus();
             }
         }else if(Ext.isGecko || Ext.isOpera || Ext.isWebKit){
             this.win.focus();
             this.execCmd('InsertHTML', text);
             this.deferFocus();
         }
     }
    });
    if you are already include the HtmlEditor Plugins UX please remvoe the code.

    Code:
    Ext.ux.form.HtmlEditor.Divider = Ext.extend(Ext.util.Observable, {
        // private
        init: function(cmp){
            this.cmp = cmp;
            this.cmp.on('render', this.onRender, this);
        },
        // private
        onRender: function(){
            this.cmp.getToolbar().addButton([new Ext.Toolbar.Separator()]);
        }
    });
    the online demo is work's in ie 6.0 8.0 google chrome.

    the online demo was disabled the upload. some bad guy's.upload sex picture.

  9. #9

    Default

    thanks

    I got to work in firefox, only that the "upload" button when you do not run anything, or show error in the firebug

  10. #10
    Ext JS Premium Member
    Join Date
    Jan 2008
    Location
    Espaa
    Posts
    215

    Default

    Is there a way to disable the button until the user clicks in the editable area? Just like the behavior of the standard buttons of the toolbar

Page 1 of 3 123 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •