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

[OLmws] Re: Is there a way to hide the "javascript:return cClick();" message?

Expand Messages
  • dave_rado
    Hi Fote ... You don t specify CDATA for an img element which is actual XHTML markup in the body of the document. Thanks for the detailed
    Message 1 of 9 , Feb 21, 2008
    • 0 Attachment
      Hi Fote

      --- In overlibmws@yahoogroups.com, "Foteos Macrides" <fote@...> wrote:

      <snip> You don't specify CDATA for an img element which is actual
      XHTML markup in the body of the document. </snip>

      Thanks for the detailed explanation.

      The reason I mistakenly thought I had to was that my code doesn't
      validate due to the unescaped < and > signs in a href links that are
      inside pop-ups. But I have now noticed you use < and > to get
      round that, so I guess I'll have to do likewise. (sigh!)


      <snip> (so move that definition out to a .js file as well).

      The reason I haven't is that I want the image url to be relative, not
      absolute; and whereas external css files allow me to use relative urls
      (because theirs are relative to the location of the css file),
      external js files don't (because theirs are relative to the location
      of the html file, which varies). I don't think there's a way round that?


      Dave
    • Foteos Macrides
      Dave, What s most commonly done is to always have an images directory off each site s root, so you can always use it in javascript definitions (e.g.,
      Message 2 of 9 , Feb 22, 2008
      • 0 Attachment
        Dave,
         
        What's most commonly done is to always have an images directory off each site's root, so you can always use it in javascript definitions (e.g., '/images/foo.gif') regardless of whether they are in a script block or imported .js file.
         
        You should not use raw angle brackets in the attribute values of active markup in the body, but instead use HTML entities (which the HTML or XHTML parser converts to raw angle brackets before passing them to the javascript interpreter), but do use raw angle brackets in the javascript string variable definitions within script blocks or imported .js files (because the HTML or XHTML parser doesn't covert any HTML entities in those blocks or files until later, i.e., if they are later used as HTML or XHTML markup intentionally by the javascript engine).  See the basic information about the overlib and overlib2 lead arguments in the Command Reference:
         
         
        Fote
        --
         
        ----- Original Message -----
        From: dave_rado
        Sent: Thursday, February 21, 2008 6:08 PM
        Subject: [OLmws] Re: Is there a way to hide the "javascript:return cClick();" message?

        Hi Fote

        --- In overlibmws@yahoogroups.com, Foteos Macrides wrote:

        <snip> You don't specify CDATA for an img element which is actual XHTML markup in the body of the document. </snip>

        Thanks for the detailed explanation.

        The reason I mistakenly thought I had to was that my code doesn't validate due to the unescaped < and > signs in a href links that are inside pop-ups. But I have now noticed you use &lt; and &gt; to get round that, so I guess I'll have to do likewise. (sigh!)


        <snip> (so move that definition out to a .js file as well).

        The reason I haven't is that I want the image url to be relative, not absolute; and whereas external css files allow me to use relative urls (because theirs are relative to the location of the css file), external js files don't (because theirs are relative to the location of the html file, which varies). I don't think there's a way round that?


        Dave
      • dave_rado
        Hi Fote ... each site s root, so you can always use it in javascript definitions (e.g., /images/foo.gif ) regardless of whether they are in a script block or
        Message 3 of 9 , Feb 23, 2008
        • 0 Attachment
          Hi Fote

          --- In overlibmws@yahoogroups.com, "Foteos Macrides" <fote@...> wrote:

          > What's most commonly done is to always have an images directory off
          each site's root, so you can always use it in javascript definitions
          (e.g., '/images/foo.gif') regardless of whether they are in a script
          block or imported .js file.

          I didn't know about root-relative links - thanks - but unfortunately
          they don't work in my local webs (which is where I do all my
          development work - often without access to the internet, because I
          like to work outside!) For example, if I'm working on the local web
          http://localhost/davesweb/, my browser (and Dreamweaver and even
          FrontPage) think the web's root is http://localhost/, whereas it is
          actually http://localhost/davesweb/. Does this imply there must be
          something wrong with the way I've set up the webs in IIS? I can't see
          anything obviously wrong when I look at the local webs in IIS but m
          Maybe I should post about this to an IIS newsgroup?



          > You should not use raw angle brackets in the attribute values of
          active markup in the body, but instead use HTML entities (which the
          HTML or XHTML parser converts to raw angle brackets before passing
          them to the javascript interpreter), but do use raw angle brackets in
          the javascript string variable definitions within script blocks or
          imported .js files (because the HTML or XHTML parser doesn't covert
          any HTML entities in those blocks or files until later, i.e., if they
          are later used as HTML or XHTML markup intentionally by the javascript
          engine). See the basic information about the overlib and overlib2
          lead arguments in the Command Reference:
          >
          > http://www.macridesweb.com/oltest/commandRef.html#content

          Many thanks, very helpful information and link.

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