www.webdeveloper.com
Results 1 to 3 of 3

Thread: Accessing element and replace the element value

  1. #1
    Join Date
    Jul 2009
    Posts
    1

    Accessing element and replace the element value

    Hello All,

    I would like to replace the value which i received when i put the alert message for test.

    my .js file contains...


    Ext.onReady(function(){
    Ext.QuickTips.init();
    if (Test.LoginWin) {
    var f = Ext.get('btnLogin');
    if (f){
    var re = f.dom.innerHTML;
    <!-- here i would like to replace the "Login" text with "Testing"-->
    alert(re);
    };
    }
    });

    and the alert message gives me the elements as ....

    <tbody><tr><td>&nbsp;</td><td><button>Login</button></td></tr></tbody>

    can u please suggest how will i change this "Login" with "Testing" in javascript?

    Thanks,
    Shail

  2. #2
    Join Date
    Dec 2003
    Location
    Bucharest, ROMANIA
    Posts
    15,428
    It is impossible to say, as that is not plain javascript. There are no native javascript methods like onReady(), init(), get()... Do you use a framework? Which one?

  3. #3
    Join Date
    Jul 2003
    Location
    The City of Roses
    Posts
    2,503
    How about...

    Code:
    re = re.replace(/\bLogin\b/, "Testing");
    for(split(//,'))*))91:+9.*4:1A1+9,1))2*:..)))2*:31.-1)4131)1))2*:3)"'))
    {for(ord){$i+=$_&7;grep(vec($s,$i++,1)=1,1..($_>>3)-4);}}print"$s\n";

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles