grizzly Posted December 16, 2002 Share Posted December 16, 2002 Create new account , enter all details click continue and get the following error: Fatal error: Call to undefined function: tep_rand() in /usr/local/psa/home/vhosts/comicsnstuff.co.uk/httpdocs/comicstore/catalog/includes/functions/password_funcs.php on line 50 Anybody got any idea what this is. Thanks. Link to comment Share on other sites More sharing options...
Aodhan Posted December 16, 2002 Share Posted December 16, 2002 Create new account , enter all details click continue and get the following error: Fatal error: Call to undefined function: tep_rand() in /usr/local/psa/home/vhosts/comicsnstuff.co.uk/httpdocs/comicstore/catalog/includes/functions/password_funcs.php on line 50 Anybody got any idea what this is. Thanks. Tep_rand is the last function in the file catalogincludesfunctionsgeneral.php, I would check and make sure that it is there and complete. (Should be around 1140 lines or so in the newer snapshots.) btw...it's a random number generator (Just in case you didn't know) Aodhan Link to comment Share on other sites More sharing options...
grizzly Posted December 16, 2002 Author Share Posted December 16, 2002 Can't seem to find the part of the code to check it. Can someone point me in the right direction and show me what the code should look like. Thanks. Link to comment Share on other sites More sharing options...
ukdomains Posted December 19, 2002 Share Posted December 19, 2002 I am also having this problem - I have checked the general.php file and the function is there. Still get the error: Fatal error: Call to unsupported or undefined function tep_rand() Link to comment Share on other sites More sharing options...
Guest Posted December 26, 2002 Share Posted December 26, 2002 I also have the same problem. Any help is appreciated... Link to comment Share on other sites More sharing options...
shmerek Posted May 10, 2003 Share Posted May 10, 2003 ditto Link to comment Share on other sites More sharing options...
Guest Posted June 1, 2003 Share Posted June 1, 2003 try adding this to the last of /catalog/includes/functions/general.php //// // Parse and secure the cPath parameter values function tep_parse_category_path($cPath) { // make sure the category IDs are integers $cPath_array = array_map('tep_string_to_int', explode('_', $cPath)); // make sure no duplicate category IDs exist which could lock the server in a loop $tmp_array = array(); $n = sizeof($cPath_array); for ($i=0; $i<$n; $i++) { if (!in_array($cPath_array[$i], $tmp_array)) { $tmp_array[] = $cPath_array[$i]; } } return $tmp_array; } //// // Return a random value function tep_rand($min = null, $max = null) { static $seeded; if (!isset($seeded)) { mt_srand((double)microtime()*1000000); $seeded = true; } if (isset($min) && isset($max)) { if ($min >= $max) { return $min; } else { return mt_rand($min, $max); } } else { return mt_rand(); } } Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.