I've tried to set their width - when I wasn't running this inside a CSS page it'd work out alright, but here you can see on the enemy HP that the enemy health is at full, but the bar is long (the enemy health is the right size - 100 pixels). I've put width='100' pretty much everywhere. I suspect it's something to do with the CSS layout that's making it try and fill the space instead of work at a fixed space, but I'm a CSS noob so I dunno! I think the player HP is doing the same problem but I'll just focus on the opponent HP for now.
Any help appreciated!
HTML table cells are too large
- Jackolantern
- Posts: 10891
- Joined: Wed Jul 01, 2009 11:00 pm
Re: HTML table cells are too large
You have width = "100" or width: 100px; ? Are you talking about CSS styles?
The indelible lord of tl;dr
Re: HTML table cells are too large
Ah, you put me onto something to try out and search for! Thanks!
I found sticking
in the table finally made it stick to one size rather than self adjusting.
And yeah, I can see it's a style and so I should probably be putting this in a style sheet and using a div here. But for now I'm just happy to get the bars working again!
I'll just leave it a day longer to make sure it all remains working, then I'll edit the title to solved!
And here's a screenshot of the game currently - I'm using a CSS template (that I found that has free use!) now! Which is a nice bit of side polish!
I found sticking
Code: Select all
style='width:450px'
And yeah, I can see it's a style and so I should probably be putting this in a style sheet and using a div here. But for now I'm just happy to get the bars working again!
I'll just leave it a day longer to make sure it all remains working, then I'll edit the title to solved!
And here's a screenshot of the game currently - I'm using a CSS template (that I found that has free use!) now! Which is a nice bit of side polish!
- Jackolantern
- Posts: 10891
- Joined: Wed Jul 01, 2009 11:00 pm
Re: HTML table cells are too large
Nice looking!
And glad I could help, even though I am not sure what I did
And glad I could help, even though I am not sure what I did
The indelible lord of tl;dr