1. #1
    Sencha User deepakgarg89's Avatar
    Join Date
    Nov 2012
    Location
    Gurgaon, India
    Posts
    43
    Answers
    4
    Vote Rating
    0
    deepakgarg89 is on a distinguished road

      0  

    Default Answered: Replace html of a html element span

    Answered: Replace html of a html element span


    Hi,

    My app had a html element

    <span id="dummyid">Pause</span>

    and a listner for it

    listeners : {
    painted : function(panel) {
    var el = panel.element;
    el.on('tap', function(e, t) {
    var span = e.getTarget('span');
    if (span) {
    var changecampid = span.id;
    console.log(changecampid);
    }
    }, panel);
    }
    }

    I need to change the value of span from Pause to active.

    Please tell me how can i do this

  2. It is now resolved. I had use Ext.get('span id'); and than use setHtml() to change its html

  3. #2
    Sencha User
    Join Date
    Nov 2011
    Location
    England
    Posts
    135
    Answers
    11
    Vote Rating
    7
    george.m is on a distinguished road

      0  

    Default


    Something like this..

    Ext.ComponentQuery.query('#dummyId')[0].setText('<span id="dummyid">Active</span>')

    Maybe you could use 'this.setText()' instead.

    It's either setText or setHtml()

  4. #3
    Sencha User deepakgarg89's Avatar
    Join Date
    Nov 2012
    Location
    Gurgaon, India
    Posts
    43
    Answers
    4
    Vote Rating
    0
    deepakgarg89 is on a distinguished road

      0  

    Default Thanks for reply

    Thanks for reply


    It is now resolved. I had use Ext.get('span id'); and than use setHtml() to change its html

Thread Participants: 1

Tags for this Thread

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar