View Single Post
  #3  
Old 02-03-2012, 05:44 AM
 
N00dles N00dles is offline
 

Advanced Member
  
Join Date: Jul 2011
Posts: 43
 

Default Re: Available stock to featured admin

Thank you for the help this will help me understand how xcart works more now.

If I add the code As in_stock to the query the featured products goes blank as if there are none set.
If I take it away from the query, I get the amount of products avaiable but the Featured Active is removed so no checked boxs to the active featured products.

Works to a limit with {$products[prod_num].avail} , no active check boxes

its conflicting with this {$products[prod_num].productid}][avail]"{if $products[prod_num].avail eq "Y"}
So now its the other way around i get what i want but the active is now not a Y or N

Code:
$products = func_query ("SELECT $sql_tbl[featured_products].productid, $sql_tbl[products].product, $sql_tbl[featured_products].product_order, $sql_tbl[featured_products].avail, $sql_tbl[products].avail from $sql_tbl[featured_products], $sql_tbl[products] where $sql_tbl[featured_products].productid=$sql_tbl[products].productid AND $sql_tbl[featured_products].categoryid='$f_cat' order by $sql_tbl[featured_products].product_order");
__________________
x-cart 4.4.3
Reply With Quote