100
100
$ time_start =microtime_float ();
101
101
102
102
if ($ _REQUEST ['phpinfo ' ]){
103
- ob_start ();phpinfo ();$ sqldr ='<div style="font-size:130%"> ' .ob_get_clean ().'</div> ' ;
103
+ ob_start ();
104
+ phpinfo ();
105
+ $ html = ob_get_clean ();
106
+ preg_match ("/<body[^>]*>(.*?)<\/body>/is " , $ html , $ matches ); // show only <body>-content
107
+ $ sqldr ='<div class="phpinfo"> ' .$ matches [1 ].'</div> ' ;
104
108
}else {
105
109
if ($ DB ['db ' ]){
106
110
if ($ _REQUEST ['shex ' ]){
@@ -268,16 +272,16 @@ function print_header(){
268
272
<meta charset="utf-8">
269
273
<style type="text/css">
270
274
body{font-family:Arial,sans-serif;font-size:80%;padding:0;margin:0}
271
- th,td{padding:0;margin:0}
272
275
div{padding:3px}
273
276
pre{font-size:125%}
274
277
.nav{text-align:center}
275
278
.ft{text-align:right;margin-top:20px;font-size:smaller}
276
279
.inv{background-color:#069;color:#FFF}
277
280
.inv a{color:#FFF}
278
- table.res{width:100%;border-collapse:collapse;}
281
+ table{border-collapse:collapse;}
282
+ table.res{width:100%;}
279
283
table.wa{width:auto}
280
- table.res th,table.res td{padding:2px;border:1px solid #fff;vertical-align:top}
284
+ table.res th,table.res td{padding:2px;border:1px solid #fff;vertical-align:top}
281
285
table.restr{vertical-align:top}
282
286
tr.e{background-color:#CCC}
283
287
tr.o{background-color:#EEE}
@@ -288,8 +292,16 @@ function print_header(){
288
292
.frm{width:400px;border:1px solid #999;background-color:#eee;text-align:left}
289
293
.frm label .l{width:100px;float:left}
290
294
.dot{border-bottom:1px dotted #000}
291
- .ajax{text-decoration:none;border-bottom: 1px dashed;}
295
+ .ajax{text-decoration:none;border-bottom: 1px dashed;}
292
296
.qnav{width:30px}
297
+ .phpinfo a {text-decoration:none;}
298
+ .phpinfo hr {display:none;}
299
+ .phpinfo img {float:right;}
300
+ .phpinfo .center {text-align:center;}
301
+ .phpinfo table {margin:0 auto;}
302
+ .phpinfo table td, .phpinfo table th {border:1px solid #000000;text-align:left;vertical-align:baseline;}
303
+ .phpinfo table .e {background-color:#ccccff;font-weight:bold;}
304
+ .phpinfo table .v {background-color:#cccccc;}
293
305
</style>
294
306
295
307
<script type="text/javascript">
0 commit comments