Flash Games
 FAQ   Search   Memberlist   Usergroups   Register  Profile   Log in to check your private messages   Log in 


JS / "eval" function issue



 

Post new topic   Reply to topic  
   DEVPPL Forum Index -> JavaScript Forum
View previous topic :: View next topic  
Author Message
dorinp



Joined: 28 Jun 2008
Posts: 1

PostPosted: Sat Jun 28, 2008 5:29 pm    Post subject: JS / "eval" function issue Reply with quote

Hi,
Have you deal with this 'eval' function issue ?
In the js code below - variant a) work well but the b) is not working.
Have you any idea why? It's a JS bug ?
Thanks,
Dorin

//--------JS script----------
function test()
{
html_code = '<div id="mydiv"></div>';
document.write(html_code);

// variante a)
document.all.mydiv.innerHTML = '123';
//variant b)
eval('document.all.mydiv.innerHTML') = '123';
}
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    DEVPPL Forum Index -> JavaScript Forum All times are GMT + 1 Hour
Page 1 of 1

 
 
Welcome to DEVPPL.com
You are not logged in, which means that you can't post in the forums.
Click here to Register

If you are a current member here on DEVPPL, please login below:

User: Pass:
Log me on automatically each visit:

 


Powered by phpBB © 2001, 2005 phpBB Group - Modified by DEVPPL

Flash Games - Sitemap