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

Re: [ydn-javascript] RE: Absolute Links in Editor

Expand Messages
  • Dav Glass
    Dale -- Please file all bug reports here: http://developer.yahoo.com/yui/editor/#filingbugs Dav Glass dav.glass@yahoo.com blog.davglass.com + Windows: n. - The
    Message 1 of 4 , Mar 4 6:36 AM
    • 0 Attachment
      Dale --

      Please file all bug reports here:
      http://developer.yahoo.com/yui/editor/#filingbugs
       
      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: Dale Burrell <dale_burrell@...>
      To: ydn-javascript@yahoogroups.com
      Sent: Monday, March 3, 2008 11:51:59 PM
      Subject: Re: [ydn-javascript] RE: Absolute Links in Editor

      OK - I think I have found the cause... if this is a bug or possible new feature can someone tell me how to let the development team know.

      Basically the following code:

              setEditorHTML: function(html) {
                  html = this._cleanIncomingHTML(html);
                  this._getDoc().body.innerHTML = html;
                  this.nodeChange();
              },

      has a problem under IE because the incoming HTML is parsed by IE before being used to populate the document. This makes all the tags upper case and makes all the paths absolute. Interestingly enough the code to initialise the editor is completely different, so it is only ever a problem when calling setEditorHTML.

      I have tried the following which uses some code from _setInitialContent and it seems to work:

              setEditorHTML: function(html) {
                  html = this._cleanIncomingHTML(html);
                  this._getDoc().open();
                  this._getDoc().write(html);
                  this._getDoc().close();
                  this.nodeChange();
              },

      It may need some browser conditionality added because in _setInitialContent it has more code than this.

      ----- Original Message ----
      From: Dale Burrell <dale_burrell@...>
      To: ydn-javascript@yahoogroups.com
      Sent: Tuesday, 4 March, 2008 8:08:52 PM
      Subject: Re: [ydn-javascript] RE: Absolute Links in Editor

      Further I've just realised this is IE only behaviour... is there some way to avoid having this parsing operation happen?

      ----- Original Message ----
      From: Dale Burrell <dale_burrell@...>
      To: ydn-javascript@yahoogroups.com
      Sent: Tuesday, 4 March, 2008 7:50:38 PM
      Subject: [ydn-javascript] RE: Absolute Links in Editor

      Hi,

      The Rich Text Editor seems to automatically convert all links to absolute links. I'm using the configuration from the examples that allows me to switch between the view and the HTML.

      Now this automatic link fixing is a real pain when I have a development server and live server e.g.

      <A title=Test href="display.aspx" target="">safdsadf</A>

      automatically becomes

      <A title=Test href="http://localhost:2688/Admin/display.aspx" target="">safdsadf</A>

      Which of course does not work on the live server.

      I assumed it was the cleanHTML() function and managed to disable that... but it wasn't... something else still gets it hands on the data before I do and makes the HTML tags upper case... and plays with my links.. and more.

      Is there some way I can disable this behaviour?

      Cheers,

      Dale




      Send instant messages to your online friends http://au.messenger.yahoo.com



      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/



      Send instant messages to your online friends http://au.messenger.yahoo.com


      Send instant messages to your online friends http://au.messenger.yahoo.com

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