Link to home
Start Free TrialLog in
Avatar of mrichmon
mrichmon

asked on

Dynamically set the nowrap property of a table cell

What is the correct syntax to set the nowrap property of a dynamically created table cell?

Is it :

var mytd;
....
mytd = document.createElement("TD");
mytd.nowrap = true;
...

I know about the element.setAttribute(name, value) but nowrap doesn't have a value....

I would guess that the above is correct since

mytd.readOnly = true;

works, but I am not sure that the capitalization is correct...
ASKER CERTIFIED SOLUTION
Avatar of lil_puffball
lil_puffball
Flag of Canada image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of mrichmon
mrichmon

ASKER

Thanks!
You're welcome. Thanks for the points and the A. :)