Loading ...
Sorry, an error occurred while loading the content.
 

RTE and tags

Expand Messages
  • dschn7
    I ve noticed that if I create a link via either cmd_inserthtml or cmd_insertimage the image src attribute is always rewritten to include the local hostname. Is
    Message 1 of 2 , Dec 28, 2007
      I've noticed that if I create a link via either cmd_inserthtml or
      cmd_insertimage the image src attribute is always rewritten to include
      the local hostname. Is there a way you can turn off the hostname
      prepending, or override it temporarily?

      To illustrate better:

      editor.execCommand('insertimage', '/images/test.jpg');
      editor.getEditorHTML() --> <img src='http://localhost/images/test.jpg'>

      editor.execCommand('inserthtml', "<img src='/images/test.jpg' />");
      editor.getEditorHTML() --> <img src='http://localhost/images/test.jpg'>

      I want it to be as-is: <img src='/images/test.jpg'>
    • dav.glass@yahoo.com
      dschn7 -- This is something that designMode does on it s own. Please feel free to put in a feature request to add this filtering:
      Message 2 of 2 , Dec 28, 2007
        dschn7 --

        This is something that designMode does on it's own.

        Please feel free to put in a feature request to add this filtering:
        http://developer.yahoo.com/yui/editor/#filingbugs

        Dav
         
        Dav Glass
        dav.glass@...
        blog.davglass.com
         
         
        + Windows: n. - The most successful computer virus, ever. +
        + A computer without a Microsoft operating system is like a dog
        without bricks tied to its head +
        + A Microsoft Certified Systems Engineer is to computing what a
        McDonalds Certified Food Specialist is to fine cuisine +


        ----- Original Message ----
        From: dschn7 <dschn7@...>
        To: ydn-javascript@yahoogroups.com
        Sent: Friday, December 28, 2007 9:06:06 PM
        Subject: [ydn-javascript] RTE and <img> tags

        I've noticed that if I create a link via either cmd_inserthtml or
        cmd_insertimage the image src attribute is always rewritten to include
        the local hostname. Is there a way you can turn off the hostname
        prepending, or override it temporarily?

        To illustrate better:

        editor.execCommand('insertimage', '/images/test.jpg');
        editor.getEditorHTML() --> <img src='http://localhost/images/test.jpg'>

        editor.execCommand('inserthtml', "<img src='/images/test.jpg' />");
        editor.getEditorHTML() --> <img src='http://localhost/images/test.jpg'>

        I want it to be as-is: <img src='/images/test.jpg'>






        Yahoo! Groups Links

        <*> To visit your group on the web, go to:
            http://groups.yahoo.com/group/ydn-javascript/

        <*> Your email settings:
            Individual Email | Traditional

        <*> To change settings online go to:
            http://groups.yahoo.com/group/ydn-javascript/join
            (Yahoo! ID required)

        <*> To change settings via email:
            mailto:ydn-javascript-digest@yahoogroups.com
            mailto:ydn-javascript-fullfeatured@yahoogroups.com

        <*> To unsubscribe from this group, send an email to:
            ydn-javascript-unsubscribe@yahoogroups.com

        <*> Your use of Yahoo! Groups is subject to:
            http://docs.yahoo.com/info/terms/


      Your message has been successfully submitted and would be delivered to recipients shortly.