Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

mean?


Guest

Recommended Posts

Hi,

 

I had a problem with my server_info.php page in admin.

 

I added the admin/server_info.php version 1.4 and the contents are pushed

further out to the right and the left column is at the bottom of the page.

 

I turned it in as a bug and got this reply:

That's due to your _ENV["LS_COLORS"] environment value - it's one long string without any linebreaks.

 

Can someone please tell me what this means and how to fix my pages?

 

Thanks!

Link to comment
Share on other sites

this just means that one of the lines in your server_info is reeeeeally long and doesn't wrap so it displaces the rest of the page .

It is nothing to be concerned about as it only affects that page .. which consequently is pretty much an fyi page anyway.

Link to comment
Share on other sites

Can you please tell me what is wrong with this code?

 

I never had this problem with php 4.2.3 and was not having any problem with 4.3.1 except for this one page and it is messed up on all my sites....I would like to see it normal.

 

I have looked but don't see any very long lines.

 

 

<?php

/*

$Id: server_info.php,v 1.4 2003/03/17 15:43:10 hpdl Exp $

 

osCommerce, Open Source E-Commerce Solutions

http://www.oscommerce.com

 

Copyright © 2002 osCommerce

 

Released under the GNU General Public License

*/

 

require('includes/application_top.php');

 

$system = tep_get_system_information();

?>

<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">

<html <?php echo HTML_PARAMS; ?>>

<head>

<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">

<title><?php echo TITLE; ?></title>

<link rel="stylesheet" type="text/css" href="includes/stylesheet.css">

</head>

<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0" bgcolor="#FFFFFF">

<!-- header //-->

<?php require(DIR_WS_INCLUDES . 'header.php'); ?>

<!-- header_eof //-->

 

<!-- body //-->

<table border="0" width="100%" cellspacing="2" cellpadding="2">

<tr>

<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="1" cellpadding="1" class="columnLeft">

<!-- left_navigation //-->

<?php require(DIR_WS_INCLUDES . 'column_left.php'); ?>

<!-- left_navigation_eof //-->

</table></td>

<!-- body_text //-->

<td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="2">

<tr>

<td><table border="0" width="100%" cellspacing="0" cellpadding="0">

<tr>

<td class="pageHeading"><?php echo HEADING_TITLE; ?></td>

<td class="pageHeading" align="right">

<?php echo tep_draw_separator('pixel_trans.gif', HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?></td>

</tr>

</table></td>

</tr>

<tr>

<td><table border="0" width="100%" cellspacing="0" cellpadding="2">

<tr>

<td align="center"><table border="0" cellspacing="0" cellpadding="3">

<tr>

<td class="smallText"><b><?php echo TITLE_SERVER_HOST; ?></b></td>

<td class="smallText"><?php echo $system['host'] . ' (' . $system['ip'] . ')'; ?></td>

<td class="smallText">     <b><?php echo TITLE_DATABASE_HOST; ?></b></td>

<td class="smallText"><?php echo $system['db_server'] . ' (' . $system['db_ip'] . ')'; ?></td>

</tr>

<tr>

<td class="smallText"><b><?php echo TITLE_SERVER_OS; ?></b></td>

<td class="smallText"><?php echo $system['system'] . ' ' . $system['kernel']; ?></td>

<td class="smallText">     <b><?php echo TITLE_DATABASE; ?></b></td>

<td class="smallText"><?php echo $system['db_version']; ?></td>

</tr>

<tr>

<td class="smallText"><b><?php echo TITLE_SERVER_DATE; ?></b></td>

<td class="smallText"><?php echo $system['date']; ?></td>

<td class="smallText">     <b><?php echo TITLE_DATABASE_DATE; ?></b></td>

<td class="smallText"><?php echo $system['db_date']; ?></td>

</tr>

<tr>

<td class="smallText"><b><?php echo TITLE_SERVER_UP_TIME; ?></b></td>

<td colspan="3" class="smallText"><?php echo $system['uptime']; ?></td>

</tr>

<tr>

<td colspan="4"><?php echo tep_draw_separator('pixel_trans.gif', '1', '5'); ?></td>

</tr>

<tr>

<td class="smallText"><b><?php echo TITLE_HTTP_SERVER; ?></b></td>

<td colspan="3" class="smallText"><?php echo $system['http_server']; ?></td>

</tr>

<tr>

<td class="smallText"><b><?php echo TITLE_PHP_VERSION; ?></b></td>

<td colspan="3" class="smallText"><?php echo $system['php'] . ' (' . TITLE_ZEND_VERSION . ' ' . $system['zend'] . ')'; ?></td>

</tr>

</table></td>

</tr>

 

</table></td>

</tr>

<tr>

<td><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?></td>

</tr>

<tr>

<td>

<?php

if (function_exists('ob_start')) {

ob_start();

phpinfo();

$phpinfo = ob_get_contents();

ob_end_clean();

 

$phpinfo = str_replace('border: 1px', '', $phpinfo);

ereg("(<style type="text/css">{1})(.*)(</style>{1})", $phpinfo, $regs);

echo '<style type="text/css">' . $regs[2] . '</style>';

ereg("(<body>{1})(.*)(</body>{1})", $phpinfo, $regs);

echo $regs[2];

} else {

phpinfo();

}

?>

</td>

</tr>

</table></td>

<!-- body_text_eof //-->

</tr>

</table>

<!-- body_eof //-->

 

<!-- footer //-->

<?php require(DIR_WS_INCLUDES . 'footer.php'); ?>

<!-- footer_eof //-->

<br>

</body>

</html>

<?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>

Link to comment
Share on other sites

view that page in your admin .. then from the browser menu ..

select edit > find

put this in the search box

LS_COLORS

 

You will see that it is indeed about 9.75 miles long :shock:

 

hope this helps

Link to comment
Share on other sites

I know it looks like that but I have no idea how to fix it.

 

I just copied it from cvs like any other page and then noticed this.

Link to comment
Share on other sites

you can't fix it to my knowledge ..

it is a server variable being read by

phpinfo()

 

The only thing I can suggest is to remove

<?php 

if (function_exists('ob_start')) { 

ob_start(); 

phpinfo(); 

$phpinfo = ob_get_contents(); 

ob_end_clean(); 



$phpinfo = str_replace('border: 1px', '', $phpinfo); 

ereg("(<style type="text/css">{1})(.*)(</style>{1})", $phpinfo, $regs); 

echo '<style type="text/css">' . $regs[2] . '</style>'; 

ereg("(<body>{1})(.*)(</body>{1})", $phpinfo, $regs); 

echo $regs[2]; 

} else { 

phpinfo(); 

} 

?>

 

but ..that kinda defeats the purpose :?

Link to comment
Share on other sites

maybe this will help..

 

create a file called phpinfo.php (name doesn't really matter .. as long as it is .php)

 

in it put only

<?php

phpinfo(); 

?>

 

nothing more nothing less.

 

Upload it to your server and call it from a browser.

 

You wil see that LS_COLORS is just a standard variable that happens to be spaztically long .

 

Perhaps someone knows how to run phpinfo() and exclude a particular variable .. but I have not seen that done.

Link to comment
Share on other sites

I finally see what you are talking about. That variable is very long but the boxes on the page are centered.

 

In the one that doesn't work all of the above information is moved to the right side and down.

 

I guess it has something to do with php 4.3.1 because 4.2.3 didn't do this.

 

I asked my server people and they said it has to do with the way php outputs the information.

 

Oh well...

Link to comment
Share on other sites

Caz,

 

I removed that code and it shows just the necessary top stuff on the server which is fine for my clients so will leave it off for now.

 

Thanks for everyone's help!

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...