hi found a solution and for education purposes the following info is provided
modify products.php by adding the function (number of products in store is limited to 100)
Code:
function products_allowed(){
global $db;
global $product_limit;
$product_limit = 100;
$products = $db->Execute("select count(*) as count from " . TABLE_PRODUCTS . " where products_status = '1'");
if ($products->fields['count'] >= $product_limit){return 'true';}
return 'false';
}
add the following case statments
Code:
case 'new_product':
if (products_allowed() == 'true') header("location: product_limit_denied.php");
break;
case 'insert_product':
if (products_allowed() == 'true') header("location: product_limit_denied.php");
break;
then use the file denied.php from admin profiles module , in this example I renamed the file to product_limit_denied.php
this is for educational purposes and is not supported or guaranteed to work.
Bookmarks