It is currently Thu Mar 28, 2024 9:16 am


All times are UTC


Forum rules


Please click here to view the forum rules



Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Hi, the control panel won't display the PHP version... but!
PostPosted: Wed Jul 18, 2007 5:19 pm 
Getting Started
Getting Started

Joined: Sun Jul 15, 2007 12:06 pm
Posts: 59
I found that doing this helps:
<?
phpinfo();
?>
Then I looked at the HTML code, it was a simple table, now
I have decided to make my own. It shows all of your simple
information, though you have to enter your details. It is in
HTML.

Here you go:
http://forum.freehostia.com/viewtopic.php?p=10510#10510

If that was unavailable, here you are:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd">
<html><head>
<style type="text/css"><!--
body {background-color: #ffffff; color: #000000;}
body, td, th, h1, h2 {font-family: sans-serif;}
pre {margin: 0px; font-family: monospace;}
a:link {color: #000099; text-decoration: none; background-color: #ffffff;}
a:hover {text-decoration: underline;}
table {border-collapse: collapse;}
.center {text-align: center;}
.center table { margin-left: auto; margin-right: auto; text-align: left;}
.center th { text-align: center !important; }
td, th { border: 1px solid #000000; font-size: 75%; vertical-align: baseline;}
h1 {font-size: 150%;}
h2 {font-size: 125%;}
.p {text-align: left;}
.e {background-color: #ccccff; font-weight: bold; color: #000000;}
.h {background-color: #9999cc; font-weight: bold; color: #000000;}
.v {background-color: #cccccc; color: #000000;}
i {color: #666666; background-color: #cccccc;}
img {float: right; border: 0px;}
hr {width: 600px; background-color: #cccccc; border: 0px; height: 1px; color: #000000;}
//--></style>
<title>phpinfo()</title></head>
<body alink="#000000" link="#000000"><div class="center">
<table border="0" cellpadding="3" width="600">
<tr class="h"><td>
<a href="http://www.php.net/"></a><h1 class="p">
Server Info</h1>
</td></tr>
</table><br />
<table border="0" cellpadding="3" width="600" style="color: #000000; height: 198px">
<tr><td class="e">
Host(s)</td><td class="v">
<a href="http://www.freehostia.com/"><span style="background-color: scrollbar">FreeHostia.com</span></a></td></tr>
<tr><td class="e">
Disk(s) Space</td><td class="v">
&nbps Your account disk(s) space &nbps; </td></tr>
<tr><td class="e">
Minimum Server Configuration</td><td class="v"> &nbps Your account config &nbps; </td></tr>
<tr><td class="e">
PHP Info</td><td class="v">
<a href="info.php"><span style="background-color: scrollbar">Available on another page</span></a></td></tr>
<tr><td class="e" style="height: 14px">
Apache</td><td class="v" style="height: 14px">
enabled</td></tr>
<tr></tr>
<tr></tr>
<tr></tr>
<tr></tr>
<tr><td class="e" style="height: 19px">Registered PHP Streams </td><td class="v" style="height: 19px">php, http, ftp, https, ftps, compress.zlib </td></tr>
</table>
</div></body></html>


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jul 19, 2007 6:07 am 
Moderator
Moderator

Joined: Tue Feb 27, 2007 12:18 am
Posts: 521
That seems like a waist of time. Why would you want to enter you own information when

Code:
<?php
phpinfo();
?>

gives you all the information you need?

If you find its too much information then you can do
Code:
<?php
     phpinfo(INFO_GENERAL);
?>

For what modules are active
Code:
<?php
   phpinfo(INFO_MODULES);
?>

and it you want it super colorfull then you can do this


Code:
<?php

ob_start();
phpinfo();
$phpinfo = ob_get_contents();
ob_end_clean();

preg_match_all('/#[0-9a-fA-F]{6}/', $phpinfo, $rawmatches);
for ($i = 0; $i < count($rawmatches[0]); $i++)
   $matches[] = $rawmatches[0][$i];
$matches = array_unique($matches);

$hexvalue = '0123456789abcdef';

$j = 0;
foreach ($matches as $match)
{

   $r = '#';
   $searches[$j] = $match;
   for ($i = 0; $i < 6; $i++)
      $r .= substr($hexvalue, mt_rand(0, 15), 1);
   $replacements[$j++] = $r;
   unset($r);
}

for ($i = 0; $i < count($searches); $i++)
   $phpinfo = str_replace($searches, $replacements, $phpinfo);
echo $phpinfo;
?>

_________________
http://www.mjmclocks.co.uk


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ]  Moderators: Moderators, Support Team

All times are UTC


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Hosting | Domains | Servers | Extras | Order | Support | Contacts | FreeHostia © 2011