Jump to content

Inline Javascript


mobone
 Share

Recommended Posts

This prints a table with only 50% width, when it should be 100%.

function print_everything() {hp_table='<table cellpadding="0" cellspacing="0" class="style2" style="width:100px"><tr><td class="style3" style=width:"';hp_table+=characters['opponent']['hp'];hp_table+='%"> </td><td> </td></tr></table>';}

Link to comment
Share on other sites

It looks like the style attribute is missing quotes around it.hp_table='<table cellpadding="0" cellspacing="0" class="style2" style="width:100px"><tr><td class="style3" style="width:';hp_table+=characters['opponent']['hp'];hp_table+='%"> </td><td> </td></tr></table>';

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...