Disable events of content inside DIV

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • pragathik
    New Member
    • Oct 2007
    • 21

    Disable events of content inside DIV

    hi,
    below is my code
    [code=html]
    <html>
    <body>
    <div>

    //HTML goes here with events like onclick,onchang e

    </div>[/code]

    at run time i have to disable all the events for the tags which are inside the DIV tag.

    i dont want to get all the code which is inside <div> tag to be in loop and
    disabling of events one by one.

    plz help me
    thnks
    Last edited by acoder; Oct 26 '07, 08:18 AM. Reason: fixed code tags
  • acoder
    Recognized Expert MVP
    • Nov 2006
    • 16032

    #2
    Originally posted by pragathik
    at run time i have to disable all the events for the tags which are inside the DIV tag.

    i dont want to get all the code which is inside <div> tag to be in loop and
    disabling of events one by one.
    So, don't add/attach events in the first place and only add them when required.

    Comment

    • pragathik
      New Member
      • Oct 2007
      • 21

      #3
      actually,the same piece of code we will use many places where

      the events are necessary. so in the run time only i need to disable the events inside div tag

      Comment

      • acoder
        Recognized Expert MVP
        • Nov 2006
        • 16032

        #4
        Originally posted by pragathik
        actually,the same piece of code we will use many places where the events are necessary. so in the run time only i need to disable the events inside div tag
        Add the events to other elements, just don't add the events to the div tag.

        Comment

        Working...