1. #1
    Sencha Premium Member
    Join Date
    Nov 2007
    Posts
    399
    Vote Rating
    11
    Mthor will become famous soon enough

      0  

    Default xTemplate <div> tap in architect

    xTemplate <div> tap in architect


    I need to call a function when a <div> is clicked in xtemplate. Not haveing any success doing this in architect. Any ideas?

    so if a <div id="myDiv">this div gets tapped</div> how to read that event and call a function in architect

  2. #2
    Sencha - Architect Dev Team aconran's Avatar
    Join Date
    Mar 2007
    Posts
    8,185
    Vote Rating
    63
    aconran is just really nice aconran is just really nice aconran is just really nice aconran is just really nice aconran is just really nice

      0  

    Default


    Is this a component? a container? a panel?

    Grab a reference to the element of the component and set a click event handler via the Ext.Element API.

    Can there be multiple ones of these divs? of these components? You may be better off using a css class and then using the delegate configuration.
    Aaron Conran
    @aconran
    Sencha Architect Development Team

  3. #3
    Sencha Premium Member
    Join Date
    Nov 2007
    Posts
    399
    Vote Rating
    11
    Mthor will become famous soon enough

      0  

    Default


    I had a tpl in a container. I wanted to tap a div element, I achieved this through the element, thanks for your help