ID: 24095 Comment by: joe at monkeydepartment dot com Reported By: generic at thetahat dot com Status: Open Bug Type: Feature/Change Request Operating System: Windows XP SP1 PHP Version: 4.3.2 New Comment:
This problem still exists in PHP5 and it is obnoxious. It would be trivial to set up phpinfo's CSS so it descends from a style called "phpinfo". Then phpinfo() could enclose itself in a <div class="phpinfo">, without any further modifications to itself. Like this: <style> .phpinfo body {style=whatever} .phpinfo td {style=whatever} .phpinfo table {style=whatever} etc, etc, etc </style> Then anything within a <div class="phpinfo"> will inherit those styles. Absolutely basic CSS and it doesn't even require changing the actual phpinfo() output. Previous Comments: ------------------------------------------------------------------------ [2004-04-01 14:53:17] csaba at alum dot mit dot edu Yes, phpinfo is a super function, but it should also be a nice player and please not hog the styles on my previously generated elements. Here's an example that illustrates this (tried on IE6 on Win2K with PHP 5.0.0RC1). The TEXTAREA element is supposed to fill the first (multi rowspan) TD element. if you uncomment the phpinfo line at the bottom, then you'll see that the TEXTAREA element nearly disappears. This is because the style sheet genereated by phpinfo sets the TD style to have vertical-align:baseline. Notice that the body color changes for similar reasons. And the links would change, too, if I had them. Csaba Gabor <html> <head><title>PHP output result page</title></head> <body bgcolor=yellow onLoad= "var mytd=document.getElementById('mytd');mytd.style.height=mytd.offsetHeight"> <table bgcolor="orange" border=1 id=mytd> <tr><td rowspan=3><textarea style="width:100%;height:100%"> This should ALREADY fill the cell</textarea></td> <td>One</td></tr> <tr><td>Two</td></tr> <tr><td>Three</td></tr> </table> </body> </html> <?php //phpinfo() ?> ------------------------------------------------------------------------ [2003-06-09 08:52:30] generic at thetahat dot com I'm all for using styles on the phpinfo output but since it's redefining basic page elements it's difficult to include phpinfo output on a page when debugging. The choice of style names are all that need to change. For instance, instead of redefining "table", use a class name like #phpinfotable and instead of a basic names like ".e" use ".phpinfocell", instead of "h1" use "h1.phpinfo", "a:link#phpinfo", etc. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=24095&edit=1