Replacing editor in news publishing program

Last post 10-03-2007, 10:44 PM by Capper. 12 replies.
Sort Posts: Previous Next
  •  09-30-2007, 8:21 AM 33916

    Replacing editor in news publishing program

    I'm currently using Vivvo news publishing program, which has a horrible editor (An older version of TinyMCE) and would like to replace it with Cute Editor.......having  no experience editing these types of files, or installing scripts.....how hard is it, and can I get help?

    Also, Vivvo is releasing a new version within a couple weeks, but I would again want to replace their editor with Cute Editor.

  •  10-01-2007, 9:08 AM 33924 in reply to 33916

    Re: Replacing editor in news publishing program

    Capper,
     
    TinyMCE is pure JavaScript Editor. It's very easy to replace it with Cute Editor.
     
    Deployment instruction is here:
     
     
    Basically if your textarea ID/name is "Editor1", you need to create an editor instance and set its ID to Editor1.
     

    <?php
             $editor=new CuteEditor();
             $editor->ID="Editor1";
             $editor->Text="Type here";
             $editor->FilesPath="CuteEditor_Files";
             $editor->Draw();
             $editor=null;

             //use $_POST["Editor1"]to catch the data
    ?>
     
    Also importan issue is: Your server must be running version 5.x to use Cute Editor.
     
    Web Server Requirements
    • Operating System: Linux, Unix, Windows

    • Web Server: Apache Web Server, IIS

    • Scripting Language: PHP 5.0 or above

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  10-02-2007, 2:01 PM 33959 in reply to 33924

    Re: Replacing editor in news publishing program

    K, our server is running PHP V5.0.......here is the problem, we're using Vivvo (their editor sucks)....

    I saw the instructions, and understand that I need to delete all reference java scripts for their editor, but how do I replace it in the files with Cute Editor?


    I put the Cute Editor folder in the /public/_html/admin folder of the CMS I'm using (same directory as the TinyMCE folder)?

    after creating the PHP file:
    <?php
             $editor=new CuteEditor();
             $editor->ID="Editor1";
             $editor->Text="Type here";
             $editor->FilesPath="public_html/admin/CuteEditor_Files";
             $editor->Draw();
             $editor=null; 

             //use $_POST["Editor1"]to catch the data
    ?>


    I put that in the same directory (/public_html/admin/Editor1.php)


    This part stumped me........


    "Once you've created a CuteEditor class object, you call functions against that object.

    Note 1: You can retrieve the CuteEditor contents using the $_POST array. The name of the variable in the $_POST array will be CuteEditor ID. For example if your Cute Editor class ID is "Editor1", the variable would be $_POST["Editor1"].

    Note 1: If you want to deploy the CuteEditor Client file to a different location, you will have to make sure that you set your editor FilesPath property correctly. The control expects to find the all the files and images in the files directory specified by the control FilesPath property."

    Can you explain this in maybe a little simpler terms?

  •  10-02-2007, 4:26 PM 33962 in reply to 33959

    Re: Replacing editor in news publishing program

    Anyone???

    2 minutes after I purchase the program, I start a chat to ask a few questions, it connects.......any theres no one there.....i log out and back in, and it says the messenger is offline........I see Adam online, but he's nor responding to PMs, emails, or the thread.........can we maybe get a little better installation instructions?
  •  10-02-2007, 8:56 PM 33965 in reply to 33959

    Re: Replacing editor in news publishing program

    Capper:
    K, our server is running PHP V5.0.......here is the problem, we're using Vivvo (their editor sucks)....

    I saw the instructions, and understand that I need to delete all reference java scripts for their editor, but how do I replace it in the files with Cute Editor?


    I put the Cute Editor folder in the /public/_html/admin folder of the CMS I'm using (same directory as the TinyMCE folder)?

    after creating the PHP file:
    <?php
             $editor=new CuteEditor();
             $editor->ID="Editor1";
             $editor->Text="Type here";
             $editor->FilesPath="public_html/admin/CuteEditor_Files";
             $editor->Draw();
             $editor=null; 

             //use $_POST["Editor1"]to catch the data
    ?>


    I put that in the same directory (/public_html/admin/Editor1.php)


    This part stumped me........


    "Once you've created a CuteEditor class object, you call functions against that object.

    Note 1: You can retrieve the CuteEditor contents using the $_POST array. The name of the variable in the $_POST array will be CuteEditor ID. For example if your Cute Editor class ID is "Editor1", the variable would be $_POST["Editor1"].

    Note 1: If you want to deploy the CuteEditor Client file to a different location, you will have to make sure that you set your editor FilesPath property correctly. The control expects to find the all the files and images in the files directory specified by the control FilesPath property."

    Can you explain this in maybe a little simpler terms?

     
    Capper,
     
    Are you able to run Cute Editor in your system sucessfully?
     
    If so, all you need to do is making sure your Cute Editor ID is same as existing ID of your textarea.
     
    For example:
     
    If you have the following code:
     
    <textarea id="elm2" name="elm2" rows="15" cols="32">
     
    </textarea>
     
    And you want to replace it with Cute Editor, You need to do:
     
    <?php
             $editor=new CuteEditor();
             $editor->ID="elm2";
             $editor->Text="Type here";
             $editor->FilesPath="public_html/admin/CuteEditor_Files";
             $editor->Draw();
             $editor=null; 

             //use $_POST["Editor1"]to catch the data
    ?>
     
     
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  10-03-2007, 12:15 AM 33967 in reply to 33965

    Re: Replacing editor in news publishing program

    Did you look at what I posted? The instructions say 5 minutes to add the editor, and I've been working on it almost 12 hours without any success. Above are the two files they list as needing to be edited, along with a link to their forums. They say to remove the JS and add your own editor....thats about it.
    where am i going to find the text area ID?

     

    Myself and two other people have looked at it, and cannot figure it out at all. I have the files uploaded, both the Editor files into the /admin/ directory (where they have tinymce), and the php file i created....same directory, named "Editor1".....They won't help or even give suggestions, and I'm trying to get a guide done so more people aren't stuck.....i need some help here


    http://www.vivvo.net/forums/showthread.php?t=325

    i've tried to start a small tutorial to make it easier, but not understanding at all how they do things, i can't get it installed or working correctly..... here is what I have done

    1. Always save copies of any files you plan on editing, or which might be changed or otherwise overwritten by any changes you make to your Vivvo installation. This way, if you make a mistake, you can simply replace the edited file with the original. a good way of replacing files with the same name within a folder is to simply rename the original (I simply add a old_in front of the file name).

    2. Different folks use different applications for editing files, some use Notepad (which is fine, make sure you turn off wordwrap), some use Dreamweaver (expensive), others use the built in browser that comes with most FTP programs (I use Coffee cup FTP, and it has a nice built in browser/editor). Experiment with different editors, and find the one you are most comfortable with. Any time you edit or create a file, make sure you save the file with the same name (everything is case sensitive), and don't forget the extensions (some applications save files with a .txt extension or a doc. extension).

    Now that we have that out of the way, we can move on to removing the default editor (TinyMCE) and replacing it with the editor of your choice.

    The first file to edit is /public_html/admin/templates/article_add_tiny.tpl. With this file, you'll simply remove the Java Script for the default editor

    Code:
    <script language="javascript" type="text/javascript" src="tinymce/jscripts/tiny_mce/tiny_mce.js"></script>
    <script language="javascript" type="text/javascript">
    tinyMCE.init({
    mode : "textareas",
    theme : "advanced",
    plugins : "table,save,advhr,advimage,advlink,iespell,insertd atetime,preview,zoom,flash,searchreplace,print,con textmenu,ibrowser,paste",
    theme_advanced_buttons1_add_before : "save,separator",
    theme_advanced_buttons1_add : "fontselect,fontsizeselect",
    theme_advanced_buttons2_add : "separator,insertdate,inserttime,preview,zoom,separator,forecolor,backcolor",
    theme_advanced_buttons2_add_before: "cut,copy,paste,separator,search,replace,separator",
    theme_advanced_buttons3_add_before : "tablecontrols,separator",
    theme_advanced_buttons3_add : "iespell,flash,advhr,separator,print,ibrowser,past etext,pasteword,selectall",
    theme_advanced_toolbar_location : "top",
    theme_advanced_toolbar_align : "left",
    theme_advanced_path_location : "bottom",
    plugin_insertdate_dateFormat : "%Y-%m-%d",
    plugin_insertdate_timeFormat : "%H:%M:%S",
    extended_valid_elements : "a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name],hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]",
    external_link_list_url : "example_data/example_link_list.js",
    external_image_list_url : "example_data/example_image_list.js",
    flash_external_list_url : "example_data/example_flash_list.js"
    });
    </script>
    Save the file to your server.

    Next up is the /public_html/admin/templates/edit_tiny.tpl file. Remove the Java Script for the default editor from here also:

    Code:
    <script language="javascript" type="text/javascript" src="tinymce/jscripts/tiny_mce/tiny_mce.js"></script>
    <script language="javascript" type="text/javascript">
    tinyMCE.init({
    mode : "textareas",
    theme : "advanced",
    plugins : "table,save,advhr,advimage,advlink,iespell,insertd atetime,preview,zoom,flash,searchreplace,print,con textmenu,ibrowser,paste",
    theme_advanced_buttons1_add_before : "save,separator",
    theme_advanced_buttons1_add : "fontselect,fontsizeselect",
    theme_advanced_buttons2_add : "separator,insertdate,inserttime,preview,zoom,separator,forecolor,backcolor",
    theme_advanced_buttons2_add_before: "cut,copy,paste,separator,search,replace,separator",
    theme_advanced_buttons3_add_before : "tablecontrols,separator",
    theme_advanced_buttons3_add : "iespell,flash,advhr,separator,print,ibrowser,past etext,pasteword,selectall",
    theme_advanced_toolbar_location : "top",
    theme_advanced_toolbar_align : "left",
    theme_advanced_path_location : "bottom",
    plugin_insertdate_dateFormat : "%Y-%m-%d",
    plugin_insertdate_timeFormat : "%H:%M:%S",
    extended_valid_elements : "a[name|href|target|title|onclick],img[class|src|border=0|alt|title|hspace|vspace|width|height|align|onmouseover|onmouseout|name],hr[class|width|size|noshade],font[face|size|color|style],span[class|align|style]",
    external_link_list_url : "example_data/example_link_list.js",
    external_image_list_url : "example_data/example_image_list.js",
    flash_external_list_url : "example_data/example_flash_list.js"
    });
    </script>
    Again, save the file to your server.

    Now, the default editor has been removed from your Admin Panel (If you look, you'll notice the buttons are gone, and any text in the box is in an html view).

    From here, you can integrate your own editor into Vivvo.......

    Here's where I'm currently stuck...............
    (Maybe some explanation from Vivvo staff on what this next step does).

    public_html/admin/include.php. you need to change the editor name here (the "tiny" in this example)
    Code:
    $wysiwyg_editor = "tiny";   //  "spaw", "tiny"
    To whatever editor you plan on using. save the file to your server.


    http://phphtmledit.com/document/scr/...Deployment.htm


    Since I'm using Cute Editor, I uploaded the Cute Editor folder into the /public/_html/admin folder of Vivvo (the same directory as the TinyMCE folder)

    after creating the PHP file:
    Code:
    <?php
    $editor=new CuteEditor();
    $editor->ID="Editor1";
    $editor->Text="Type here";
    $editor->FilesPath="public_html/admin/CuteEditor_Files";
    $editor->Draw();
    $editor=null;

    //use $_POST["Editor1"]to catch the data
    ?>
    I put this file (Editor1.php) in the same directory (/public_html/admin/Editor1.php)

    This part stumped me........



    "Once you've created a CuteEditor class object, you call functions against that object.

    You can retrieve the CuteEditor contents using the $_POST array. The name of the variable in the $_POST array will be CuteEditor ID. For example if your Cute Editor class ID is "Editor1", the variable would be $_POST["Editor1"].

  •  10-03-2007, 12:37 PM 33979 in reply to 33967

    Re: Replacing editor in news publishing program

    It should be very simple.
     
    Send that PHP file to me. Adam@CuteSoft.net.
     
    You need to follow the logic below if you want to do it yourself.
     
    1. Find the exisitng Textarea ID
     
    2. Delete the current editor code.
     
    3. Create a new instance based on the Textarea ID.
     
    That's it.
     
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  10-03-2007, 1:41 PM 33983 in reply to 33979

    Re: Replacing editor in news publishing program

    This is the last word from Vivvo

    "The way I see this, CuteEditor uses PHP integration code, and TinyMCE uses JS integration code. Therefore those two cannot simply be swapped, by replacing TinyMCE code inside article_add and edit templates. If, by any chance, CuteEditor used JS integration, this would be much easier.

    I'm afraid I can't help much more at this point, for this requires digging in CuteEditor's documentation and changing Vivvo to use PHP integration for wysiwyg instead of JS."
    __________________
    Vivvo CMS Dev. Team

    The instructions make this out to be an extremely simple to install app.....but my fears have been realized when trying to replace an embedded editor, and not having a lot of scripting experience. Myself and two of my staff, and three Vivvo people have tried working on this, and cannot get it to work at all. I'd very much like to get this sorted and use Cute Editor.

    thanks for all your time and help Adam, we'll get this sorted and I'll get this guide finished.
  •  10-03-2007, 7:26 PM 33992 in reply to 33983

    Re: Replacing editor in news publishing program

    Capper,
     
    Done. I've finished the add article and edit article part. Please test it. I will post the detailed intruction showing how to integrate.

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  10-03-2007, 7:44 PM 33994 in reply to 33992

    How to change default editor of Vivvo to Cute Editor?

    How to change default editor of Vivvo to Cute Editor?

     
    Step 1: Open admin/include.php file and in the bottom of this file,  set

    $wysiwyg_editor = "cute";
     
    Step 2: Create a new file, name it to article_add_cute.tpl. Copy the content of article_add_tiny.tpl into it.  Then delete tinyMCE javascript code.
     
    Step 3. Open admin/article_add.php file, find the following code:
     
     if (!isset($wysiwyg_editor) or $wysiwyg_editor=="spaw")
        include('spaw/spaw_control.class.php');
     
    to:
     
    if (!isset($wysiwyg_editor) or $wysiwyg_editor=="cute")
        include_once("CuteEditor_Files/include_CuteEditor.php");

     
    Find the following code:
     

     $sw = new SPAW_Wysiwyg('body' ,"",
                           'en', 'full', 'default', '550px' , '350px');
                    $body_editor = $sw->getHtml();
                    $filename=$root . $admin_directory . "/templates/article_add_spaw.tpl";

    Change it to:
     
                     
                  $editor=new CuteEditor();
                  $editor->ID="body";
                  $editor->Text="{$body}";
                  $editor->FilesPath="CuteEditor_Files";              
                  $body_editor = $editor->GetString();
                  $editor=null;
                  $filename=$root . $admin_directory . "/templates/article_add_cute.tpl";

    Step 4. Open admin/edit.php file, modify the code as step 3.
     

     
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  10-03-2007, 8:01 PM 33996 in reply to 33994

    Re: How to change default editor of Vivvo to Cute Editor?

    thanks Adam, so far so good....I need to make the editor a little bigger, but I'm ectstatic right now.......thank you again so much for all your help


  •  10-03-2007, 8:12 PM 33997 in reply to 33996

    Re: How to change default editor of Vivvo to Cute Editor?

    Spoke too soon.......

    1. When you edit an existing article, and click submit, it creates a new article instead of editing the current one.....
    ***Solved*** We made a mistake in the code- instead of linking to article_add_cute.tpl it should have been edit_cute.tpl

    2. There are several icons missing. when you right click in the editor to insert, cut, or paste, etc.....several of the buttons are missing.

    As to the images, I've uploaded all the images several times, but for some reason none of them are showing up.
  •  10-03-2007, 10:44 PM 34002 in reply to 33997

    Re: How to change default editor of Vivvo to Cute Editor?

    I'd like to point out that not only is the cute Editor a phenomenal product......but the support here is fantastic as well. I've been working on my CMS all week long, 20+ hours a day and through all the little issues and trying to perfect everything, Adam has been simply awesome, giving suggestions and solving problems....going well above and beyond what I typically see from companies.
View as RSS news feed in XML