Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Could this be memory problems ??


peterr

Recommended Posts

Hi,

 

I'm trying to help someone move their website, it's working okay, except for one problem, that has me baffled. :unsure:

 

It is the right hand table boxes where the problem is happening, although _very_ similar problems (code appearing to be overwritten) is also happening in the footer sometimes ??

 

Here is the generated code, for the right hand 'currency' box.

 

<!-- currencies //-->

          <tr>

            <td>

 

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

  <tr>

    <td height="14" class="infoBoxHeading"><img src="images/infobox/corner_right_left.gif" border="0" alt=""></td>

    <td width="100%" height="14" class="infoBoxHeading">Currencies</td>

    <td height="14" class="infoBoxHeading" nowrap><img src="images/pixel_trans.gif" border="0" alt="" width="11" height="11"></td>

  </tr>

</<table border="0" width="100%" cellspacing="0" cellpadding="1" class="infoBox">

  <tr>

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

 

  <tr>

    <td><img src="images/pixel_trans.gif" border="0" alt="" width="1" height="1"></td>

  </tr>

  <tr>

    <td align="center" class="boxText"><form name="currencies" action="http://example.com/catalog/index.php" method="get"><select name="currency" onChange="this.form.submit();" style="width: 100%"><option value="CA" SELECTED>Canadian Funds</option></select><input type="hidden" name="osCsid" value="some_osCsid#"></form></td>

  </tr>

  <tr>

    <td><img src="images/pixel_trans.gif" border="0" alt="" width="1" height="1"></td>

 

  </tr>

</table>

</td>

  </tr>

</table>

            </td>

          </tr>

<!-- currencies_eof //-->

 

Notice the line in blue, it is actually a comment ??

 

What _should_ be happening after the preceeding end of table row is:

 

  </tr>
</table>
<table border="0" width="100%" cellspacing="0" cellpadding="1" class="infoBox">

 

Line 67 of /catalog/includes/classes/boxes.php

 

    $tableBox_string .= '</table>' . "\n";

 

appears to be the ONLY place where the end of table is generated, and I'm wondering if the var $tableBox_string does initially have the end of table appended to it (because it works just fine for the other right hand boxes), but, somehow, when it goes to add the next line .........

 

<table border="0" width="100%" cellspacing="0" cellpadding="1" class="infoBox">

 

the position of where it has to append the next line of html code is corrupted somehow ?? I did have a bit of a look at message_stack.php, but got lost. :)

 

What do you think could cause this ?

 

Thanks,

 

Peter

Link to comment
Share on other sites

Quoted from our bug reporter

 

This is a bug in PHP that shows up under certain circumstances.

 

Details can be found here:

 

http://bugs.php.net/bug.php?id=19553

http://bugs.php.net/bug.php?id=17236

 

Here are possible solutions/workarounds:

 

- Change the .htaccess file in the catalog directory. Remove the comment in front of the line reading

# php_value session.use_trans_sid 0

 

- Update PHP to 4.3.x - the problem is solved here.

 

- Force cookie usage

 

HTH

 

Jan Wildeboer

Mark Evans

osCommerce Monkey & Lead Guitarist for "Sparky + the Monkeys" (Album on sale in all good record shops)

 

---------------------------------------

Software is like sex: It's better when it's free. (Linus Torvalds)

Link to comment
Share on other sites

Hi Mark,

 

Thanks a lot for your help on that, it's been one of those 'hair pulling out' experiences (ouch). :D

 

Yes, the version of PHP is 4.2.3 (bit of an old version), and "enable-trans-sid" is set.

 

If we can't use the:

 

php_value session.use_trans_sid 0

 

in the .htaccess (some servers don't support it), then we will mod PHP.INI, and if it still doesn't work, then , from the bugs you mentioned on php.net, it is fixed in php-4.3.0pre2 , so we would need to update PHP, as a last resort (but better to be on a newer version anyway).

 

Thanks, :)

 

Peter

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...