Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.



Recommended Posts

I have installed the latest snapshop , restored my db and all semms to be working fine , exept this :


Warning: mt_rand(): Invalid range: 0..0 in /export/home/lummet.dk/www/catalog/includes/functions/general.php on line 1137


What is that , and how do i fix it.


Belov is the code.




// Return a random value

 function tep_rand($min = null, $max = null) {

   static $seeded;


   if (!$seeded) {


     $seeded = true;


   if (!isset($min) && !isset($max)) {

     return mt_rand();

   } else {

     return mt_rand($min, $max);




Hope some on knows the awnser to this  :wink:

Link to comment
Share on other sites

This has been discussed in numerous threads today. The problem is solved, CVS is updated.



You can't have everything. That's why trains have difficulty crossing oceans, and hippos did not adapt to fly. -- from the OpenBSD mailinglist.

Link to comment
Share on other sites

Thanks a lot to Jan and his answer is quoted as follows:


The snapshot of tomorrow will have the changes included. The current snapshot was build last night.


You can however make the (simple) change yourself by looking at this:




For more details please read:









renato coto

Link to comment
Share on other sites


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

  • Create New...