We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 25551 ☆ A M B ☆
    • 1,231 Posts
    @David

    Which path would you be referring too? Sorry...

    I have noticed one thing which is interesting. If you manually type in the url of a image on the site and tab to the next line, the image appears in the browser preview box.

    I have blanked out the url as it’s work in progress!

    That’s me signed in as a webuser in another browser so there is some sort of access... just not able to view in the popup window.

    The popup browser must be looking in the wrong area.
      Ross Sivills - MD AugmentBLU Edinburgh, Scotland UK
      AugmentBLU - MODX Partner

      BLUcart - MODX Revolution E-Commerce & Shopping Cart
      • 6726
      • 7,075 Posts
      Thus the idea that it’s a path issue, not a problem with permission...

      In Tools > Configuration > Friendly URLs, do you have FURLs enabled ?
      If so, what’s your configuration for aliases ?

      Is [tt]Use friendly alias path[/tt] set to Yes or No

      And if it’s set to Yes have you read and taken the note into account

      NOTE: When setting this option to ’Yes’ (turning on alias paths), reference items (such as images, css, javascripts, etc) using the absolute path: e.g., ’/assets/images’ as oppose to ’assets/images’. By doing so you will prevent the browser (or web server) from appending the relative path to the alias path.

      Another lead to follow, in Tools > Configuration > Interface & Features what is your setting for [tt]Rewrite browser paths?[/tt] Yes or No ?

      Again did you read the accompanying note :

      If this is set to ’No’, MODx will write file browser resource src’s (images, files, flash, etc.) as absolute URLs. Relative URLs are helpful should you wish to move your MODx install, e.g., from a staging site to a production site. If you have no idea what this means, it’s best just to leave it set to ’Yes’.

        .: COO - Commerce Guys - Community Driven Innovation :.


        MODx est l'outil id
        • 25551 ☆ A M B ☆
        • 1,231 Posts
        I turned Furls off as it was causing some problems with FDM and it was easier to turn them off as I’m going through the testing stages.

        Rewrite browser paths are set to yes

        What is the best setup for Furls and the rewrite options?

        Thanks for your help so far!

        Ross
          Ross Sivills - MD AugmentBLU Edinburgh, Scotland UK
          AugmentBLU - MODX Partner

          BLUcart - MODX Revolution E-Commerce & Shopping Cart
          • 12983
          • 108 Posts
          I have FURLs activated, with simple paths off, and FDM works well: I don’t remember any special action to have it working.

          I write this contribute but I’m unsure it will be of any help to anyone.

          I don’t know why, but in order to make things work well in my local environment and on the remote server without any modifications, I need to include in the <head> section of my templates the following snippet:

          [!include_base_href_on_local!]
          


          ...which is:

          <?php
          $html = '';
          
          if ($_SERVER['SERVER_NAME'] == 'localhost'){
          	$html = $html ."<base href=\"[(site_url)]\" />\n";
          }
          
          return $html;
          ?>
          


          Then, when I have to specify a path, I use e.g. something like this:

          [(base_url)][~84~]
          


          Again, I don’t know if this is helpful.
          Btw, FDM works with FURLs activated.
            • 25551 ☆ A M B ☆
            • 1,231 Posts
            I have just thought... i’m using the &script=`tinymceload` call in my FDM call.

            The chunk that the script is called from is this.

            <script language="javascript" type="text/javascript" src="[(base_url)]assets/plugins/tinymce309/jscripts/tiny_mce/tiny_mce.js"></script>
            <script language="javascript" type="text/javascript" src="[(base_url)]assets/plugins/tinymce309/xconfig.js"></script>
            <script language="javascript" type="text/javascript">
            	tinyMCE.init({
            		  theme : "advanced",
            		  mode : "exact",
            		  width : "100%",
            		  height : "400",
            		  relative_urls : true,
            		  document_base_url : "/",
            		  remove_script_host : true,
            		  language : "en",
            		  elements : "tvcontent",
            		  valid_elements : tinymce_valid_elements,
            		  extended_valid_elements : tinymce_extended_valid_elements,
            		  invalid_elements : tinymce_invalid_elements,
            		  entity_encoding : "named",
            		  cleanup: true,
            		  apply_source_formatting : true,
            		  remove_linebreaks : false,
            		  convert_fonts_to_spans : "true",
            		  file_browser_callback : "myFileBrowser",
            		  external_link_list_url : "/assets/plugins/tinymce309/tinymce.linklist.php",
            		  theme_advanced_blockformats : "p,h1,h2,h3,h4,h5,h6,div,blockquote,code,pre,address",
            		  plugins : "style,advimage,advlink,searchreplace,print,contextmenu,paste,fullscreen,nonbreaking,xhtmlxtras,visualchars,media",
            		  theme_advanced_buttons0 : "",
            		  theme_advanced_buttons1 : "undo,redo,selectall,separator,pastetext,pasteword,separator,search,replace,separator,nonbreaking,hr,charmap,separator,image,link,unlink,anchor,media,separator,cleanup,removeformat,separator,fullscreen,print,code,help",
            		  theme_advanced_buttons2 : "bold,italic,underline,strikethrough,sub,sup,separator,bullist,numlist,outdent,indent,separator,justifyleft,justifycenter,justifyright,justifyfull,separator,styleselect,formatselect,separator,styleprops",
            		  theme_advanced_buttons3 : "",
            		  theme_advanced_buttons4 : "",
            		  theme_advanced_toolbar_location : "top",
            		  theme_advanced_toolbar_align : "left",
            		  theme_advanced_path_location : "bottom",
            		  theme_advanced_disable : "",
            		  theme_advanced_resizing : false,
            		  theme_advanced_resize_horizontal : false,
            		  plugin_insertdate_dateFormat : "%Y-%m-%d",
            		  plugin_insertdate_timeFormat : "%H:%M:%S",
            		  button_tile_map : false 
            
            	});
            	function myFileBrowser (field_name, url, type, win) {		
            		var cmsURL = '/assets/plugins/tinymce309/mcpuk/browser.php?Connector=/assets/plugins/tinymce309/mcpuk/connectors/php/connector.php&ServerPath=/&editor=tinymce3&editorpath=/assets/plugins/tinymce309';    // script URL - use an absolute path!
            		switch (type) {
            			case "image":
            				type = 'images';
            				break;
            			case "media":
            				break;
            			case "flash": 
            				break;
            			case "file":
            				type = 'files';
            				break;
            			default:
            				return false;
            		}
            		if (cmsURL.indexOf("?") < 0) {
            		    //add the type as the only query parameter
            		    cmsURL = cmsURL + "?type=" + type;
            		}
            		else {
            		    //add the type as an additional query parameter
            		    // (PHP session ID is now included if there is one at all)
            		    cmsURL = cmsURL + "&type=" + type;
            		}
            		
            		tinyMCE.activeEditor.windowManager.open({
            		    file : cmsURL,
            		    width : screen.width * 0.7,  // Your dimensions may differ - toy around with them!
            		    height : screen.height * 0.7,
            		    resizable : "yes",
            		    inline : "yes",  // This parameter only has an effect if you use the inlinepopups plugin!
            		    close_previous : "no"
            		}, {
            		    window : win,
            		    input : field_name
            		});
            		return false;
            	}
            </script>


            I got this from an earlier post in this thread. Tinymce is loading just the browser is showing only a media folder but i have no idea where this media folder is. Still can’t write to it. I went back to tinymce212 and it worked fine apart from the fact it won’t work in IE due to a javascript error and opera won’t allow the tinymce box to be clickable. Those are some of the bug the updates were to solve. The edit box is clickable in all.

            If I manually put the URL in the popup box and apply it, the information is incomplete which means I have to update to the latest version of 3.10 from the Tinymce site which nearly solves the issue of the code.

            I have Furls on now.
            Suffix : .html
            use friendly aliases : yes
            use friendly alias path : no
            Allow duplicate alias : no
            Auto generate alias : yes

            Interface & features
            Enable resource browser : yes
            web users? : yes
            rewrite browser path : yes
            resource path : /home/sites/err-clan.com/public_html/assets/
            resource url : http://mysite/assets/
            uploadable media types : mp3,wav,au,wmv,avi,mpg,mpeg,swf,fla

            I really don’t know if these settings are correct but i’m sure they are as I have tried every combination I can think of.


            I really don’t know if anyone follows what the problem I’m having.... Which version of tinymce are you guys using, can you use it as a webuser, can you user the browse buttons and access the media, can you insert images, flash and quicktime elements?

            I’ve tried no less than 5 versions of tinymce over the past 12 solid hours and only the 212 version worked but it doesn’t work in any browser but FF. LOL!!! I swear I’m cracking up with this. I’ve made a great FDM managed template and with permissions only to the webuser who signed up. It’s only tinymce webuser end that is scuppering my idea.

            I was hoping to write up a complete tutorial on exactly what i’ve done once I get it working as I think what I’ve done will be really cool for others to use. Dimmy has helped with most of the coding side of course but I’d like to share exactly what I’ve done so far as long as I can get this final part done.

            Soda, your snippet is excellent.
              Ross Sivills - MD AugmentBLU Edinburgh, Scotland UK
              AugmentBLU - MODX Partner

              BLUcart - MODX Revolution E-Commerce & Shopping Cart
              • 12983
              • 108 Posts
              I can just say that I let some web users write in a tinymce212 (included with MODx) field with FDM (-> eForm) and tinyMCE works in IE7, Firefox 2, and Opera 9.27. Hope it’ll work also in Firefox 3 and Opera 8, still not tested there.
              But, for project reasons, I’ve not included/tested the possibility for them to include images or whatever, they essentially can just write text and eventually bold or stroke it, or insert links and bullet/numbered lists. So the case is a little different.
              But, as far as a simple tinymce212 textarea is concerned (really, I also use two instances of them in the same form), I can say it should work. I can’t rememer if I have done any modification in tinymce212 files, but I remember that often I’ve seen it working in Opera and Firefox, and not in IE7. Can’t remember how I solved the issue.
              On top of my head, I remember there was an error in the italian language file (a missing ; or something like that). And also, beware: often it’s the character encoding that makes these strange behaviours. But it’s rather a mess. You can do it, as I have done it. But yeah, it’s a mess!
              But please remember: with a eventually *slighty* modified tinymce212, friendly urls on, IE7, FF, Opera, there are great chances you can make it work, as I have already done it.
                • 36624
                • 535 Posts
                im really interested in your solution rossco.

                i have a solution with FDM and Tinymce212 with images and files upload working on frontend on three sites now, but users are Manager User’s because with webusers i never get it !
                  CTRL+SHIFT+U - Clear Cache
                  CTRL+SHIFT+H - Hiding Heft Panel
                  CTRL+SHIFT+N - Fast Create Resource
                  CTRL+ALT+P - Preview Recource (in edit resorce window)
                  CTRL+ALT+S - Save
                  • 34017
                  • 898 Posts
                  rossco have you thought about using a simpler wysiywyg like
                  - http://markitup.jaysalvat.com/home/
                  - http://projects.bundleweb.com.ar/jWYSIWYG/

                  That might be a little easier. and if you need file manager functionality, you could add that on seperately.
                    Chuck the Trukk
                    ProWebscape.com :: Nashville-WebDesign.com
                    - - - - - - - -
                    What are TV's? Here's some info below.
                    http://modxcms.com/forums/index.php/topic,21081.msg159009.html#msg1590091
                    http://modxcms.com/forums/index.php/topic,14957.msg97008.html#msg97008
                    • 25551 ☆ A M B ☆
                    • 1,231 Posts
                    Thanks for the replies folks.

                    @Prospace, would these editors work writing to a TV? I have the form that fills fields in TVs and was wondering how these 3rd party editors would come in to play. Tinymce was exactly what I was after but I just can’t get it working how it should.

                    @insert_nick I don’t suppose you could check to see if you are able to use the flash and media player options in your install? I tested tinymce212 with FF and it worked, IE7 gave me a JS error so stopped the browser working, not the popup and the latest Opera would all me to even click in the tinymce editor area at all.

                    Cheers

                    Ross
                      Ross Sivills - MD AugmentBLU Edinburgh, Scotland UK
                      AugmentBLU - MODX Partner

                      BLUcart - MODX Revolution E-Commerce & Shopping Cart
                      • 12983
                      • 108 Posts
                      Quote from: ProWebscape at Jun 19, 2008, 06:48 AM

                      rossco have you thought about using a simpler wysiywyg like
                      - http://markitup.jaysalvat.com/home/
                      - http://projects.bundleweb.com.ar/jWYSIWYG/

                      That might be a little easier. and if you need file manager functionality, you could add that on seperately.

                      I do not agree with this suggestion (thanks for the links by the way!).
                      The first one simply is not a wysiwyg editor.
                      The second one: I’ve just tried the demo following your link, and I can already see that Opera 9.27 doesn’t display the buttons (you have to hover with mouse to let them appear). This means not enough care for main browsers support, i.e. not a mature project like TinyMCE is.

                      TinyMCE is the way to go. I’ve just found a nice and working way to add maxlength functionality to it, thanks to its wide community base.

                      So maybe it’s not perfect, but it’s on a good road.