Jump to content

overflow isnt working...


dbradbury

Recommended Posts

i have php on a page, and set a table cells overflow to scroll, and set the cells height to about 250px, and i made sure that the text i entered would go over the height of the cell...

 

but all that has happened is its extended the page and made the cell height taller...

 

main code for the cell i require overflow:

<td class="MDinfo">
<?php
	echo 'Our Musical Director: '.$row['post_subject'].'<br><br>';
	echo nl2br($row['post_text']);
?>
</td>

 

and my style sheet for the class:

.MDinfo{
height:250px;
overflow:auto;
text-align:left;
vertical-align:top;
padding-top:10px;
}

 

and ive changed the text align to right, and tried and that works, its just the overflow :s

Link to comment
https://forums.phpfreaks.com/topic/192299-overflow-isnt-working/
Share on other sites

If I remember correctly table cells don't support overflow.

So you can go about it two ways I guess...

 

1) You wrap the content in a div (<td><div style="height: 200px; overflow: auto;"></div></td>)

or

2) You set the table cell to some other display value, like display: block;

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.