PDA

View Full Version : change the height of div element



fdi
07-08-2009, 01:30 PM
Hello

I need to write code to change the hieght of "container" div if the height of child table of this div greater than 500px;

the cild table of this div does not have ID

I need this code to use it in joomla tamplate so I can't write id to the table

any idea please

I know this

var tblHeight = document.getElementById('tableID').clientHeight;

it;s not work with my problem

thank you so much

Jesdisciple
07-10-2009, 04:04 AM
How does the line you posted not work? Did you somehow determine the value which was read? How was the value not what you expected?

(I'm assuming that you know the id of the table, which is easily enough to accomplish what you want.)