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

Re: [JavaScript] html tag properties

Expand Messages
  • Garvin Casimir
    you see the DOM does not cover event handlers like onCLick and onMouseOver etc...that is what i want really... ...
    Message 1 of 9 , Jun 4, 2003
      you see the DOM does not cover event handlers like
      onCLick and onMouseOver etc...that is what i want
      really...

      --- shortestpath <shortestpath@...> wrote:
      > you want to use DOM. For example, something like:
      >
      > document.getElementById("theTable").style.border =
      > 5;
      >
      > and in your table tag you would have id="theTable".
      >
      > http://www.w3.org/TR/1998/REC-DOM-Level-1-19981001/
      >
      http://www.w3.org/TR/2000/REC-DOM-Level-2-Style-20001113/
      >
      >
      > --- Garvin Casimir <khing2@...> wrote:
      > is there a name for the differnt options within an
      > html tag?? Or better yet is there a way to access or
      > change them??
      >
      > example <table border=1 cellpadding=3 width=10
      > height=5
      >
      > is there a way to refer to these options i have set
      > like border=1
      >
      > like table.tagOptions[0].value
      > or table.tagOptions.cellpadding=5
      >
      > one might wonder why i need to access this...i need
      > it
      > cause i am dynamically creating some objects and i
      > need to be able to set those properties to the tags
      > after i have created them in a separate
      > function...does anyone have any insight on this?
      >
      > __________________________________
      > Do you Yahoo!?
      > Yahoo! Calendar - Free online calendar with sync to
      > Outlook(TM).
      > http://calendar.yahoo.com
      >
      >


      =====
      HTTP://SILASCO.PORT5.COM/TONES/

      __________________________________
      Do you Yahoo!?
      Yahoo! Calendar - Free online calendar with sync to Outlook(TM).
      http://calendar.yahoo.com
    • shortestpath
      can you be specific in what you want really? ... you see the DOM does not cover event handlers like onCLick and onMouseOver etc...that is what i want really...
      Message 2 of 9 , Jun 4, 2003
        can you be specific in what you want really?

        --- Garvin Casimir <khing2@...> wrote:
        you see the DOM does not cover event handlers like
        onCLick and onMouseOver etc...that is what i want
        really...

        --- shortestpath <shortestpath@...> wrote:
        > you want to use DOM. For example, something like:
        >
        > document.getElementById("theTable").style.border =
        > 5;
        >
        > and in your table tag you would have id="theTable".
        >
        > http://www.w3.org/TR/1998/REC-DOM-Level-1-19981001/
        >
        http://www.w3.org/TR/2000/REC-DOM-Level-2-Style-20001113/
        >
        >
        > --- Garvin Casimir <khing2@...> wrote:
        > is there a name for the differnt options within an
        > html tag?? Or better yet is there a way to access or
        > change them??
        >
        > example <table border=1 cellpadding=3 width=10
        > height=5
        >
        > is there a way to refer to these options i have set
        > like border=1
        >
        > like table.tagOptions[0].value
        > or table.tagOptions.cellpadding=5
        >
        > one might wonder why i need to access this...i need
        > it
        > cause i am dynamically creating some objects and i
        > need to be able to set those properties to the tags
        > after i have created them in a separate
        > function...does anyone have any insight on this?

        __________________________________
        Do you Yahoo!?
        Yahoo! Calendar - Free online calendar with sync to Outlook(TM).
        http://calendar.yahoo.com
      • Garvin Casimir
        i want to be able to set event handlers outside of the tag...in a funciton... when i do this function set_events(){ my_element.onClick=alert(foo) } instead of
        Message 3 of 9 , Jun 5, 2003
          i want to be able to set event handlers outside of the
          tag...in a funciton...

          when i do this

          function set_events(){
          my_element.onClick=alert(foo)
          }

          instead of setting the event handler it just executes
          the alert when the function is called...its strange
          cause i am pretty sure if i do it outside of a
          function it will work....


          --- shortestpath <shortestpath@...> wrote:
          > can you be specific in what you want really?
          >
          > --- Garvin Casimir <khing2@...> wrote:
          > you see the DOM does not cover event handlers like
          > onCLick and onMouseOver etc...that is what i want
          > really...
          >
          > --- shortestpath <shortestpath@...> wrote:
          > > you want to use DOM. For example, something like:
          > >
          > > document.getElementById("theTable").style.border =
          > > 5;
          > >
          > > and in your table tag you would have
          > id="theTable".
          > >
          > >
          > http://www.w3.org/TR/1998/REC-DOM-Level-1-19981001/
          > >
          >
          http://www.w3.org/TR/2000/REC-DOM-Level-2-Style-20001113/
          > >
          > >
          > > --- Garvin Casimir <khing2@...> wrote:
          > > is there a name for the differnt options within an
          > > html tag?? Or better yet is there a way to access
          > or
          > > change them??
          > >
          > > example <table border=1 cellpadding=3 width=10
          > > height=5
          > >
          > > is there a way to refer to these options i have
          > set
          > > like border=1
          > >
          > > like table.tagOptions[0].value
          > > or table.tagOptions.cellpadding=5
          > >
          > > one might wonder why i need to access this...i
          > need
          > > it
          > > cause i am dynamically creating some objects and i
          > > need to be able to set those properties to the
          > tags
          > > after i have created them in a separate
          > > function...does anyone have any insight on this?
          >
          > __________________________________
          > Do you Yahoo!?
          > Yahoo! Calendar - Free online calendar with sync to
          > Outlook(TM).
          > http://calendar.yahoo.com
          >
          >


          =====
          HTTP://SILASCO.PORT5.COM/TONES/

          __________________________________
          Do you Yahoo!?
          Yahoo! Calendar - Free online calendar with sync to Outlook(TM).
          http://calendar.yahoo.com
        • Chris Scott
          Hi Garvin, ... Try... function set_events(){ my_element.onclick=function(){alert( some text )}; } HTH, Chris
          Message 4 of 9 , Jun 5, 2003
            Hi Garvin,

            > i want to be able to set event handlers outside of the
            > tag...in a funciton...
            >
            > when i do this
            >
            > function set_events(){
            > my_element.onClick=alert(foo)
            > }
            >
            > instead of setting the event handler it just executes
            > the alert when the function is called...its strange
            > cause i am pretty sure if i do it outside of a
            > function it will work....

            Try...

            function set_events(){
            my_element.onclick=function(){alert("some text")};
            }

            HTH,

            Chris
          • Garvin Casimir
            i will try it...thanx ... ===== HTTP://SILASCO.PORT5.COM/TONES/ __________________________________ Do you Yahoo!? Yahoo! Calendar - Free online calendar with
            Message 5 of 9 , Jun 5, 2003
              i will try it...thanx

              --- Chris Scott <chris@...> wrote:
              > Hi Garvin,
              >
              > > i want to be able to set event handlers outside of
              > the
              > > tag...in a funciton...
              > >
              > > when i do this
              > >
              > > function set_events(){
              > > my_element.onClick=alert(foo)
              > > }
              > >
              > > instead of setting the event handler it just
              > executes
              > > the alert when the function is called...its
              > strange
              > > cause i am pretty sure if i do it outside of a
              > > function it will work....
              >
              > Try...
              >
              > function set_events(){
              > my_element.onclick=function(){alert("some
              > text")};
              > }
              >
              > HTH,
              >
              > Chris
              >
              >
              >


              =====
              HTTP://SILASCO.PORT5.COM/TONES/

              __________________________________
              Do you Yahoo!?
              Yahoo! Calendar - Free online calendar with sync to Outlook(TM).
              http://calendar.yahoo.com
            Your message has been successfully submitted and would be delivered to recipients shortly.