I Curently use the advanced user guid option of dispatched in X days javascript option (with some customisation), but I would like to let customers know how many are available as well but only when that item is in stock. I have tried the following
<SCRIPT LANGUAGE="JavaScript" TYPE="text/javascript">
function Levels(pItem)
<!--
{
var strIDs = 'Stock Message: '
{
if (pItem >= 1)
{
strIDs = ' NETUOTEVAR:STOCKLEVEL available for <br>dispatch in 24 Hours'
}
else if (pItem <= -998)
{
strIDs = 'Out of stock from<br>supplier'
}
else
{
strIDs = 'Normally Dispatched in<br>CUSTOMVAR:LEAD'
}
}
return strIDs
}
//-->
</script>
But this produces the folowing for Items in stock
NETQUOTEVAR:STOCKLEVEL available for
dispatch in 24 Hours
I think that the javascript dose not like the NETQUOTEVAR as it is already in use.
Any clever bods out there who can help!
<SCRIPT LANGUAGE="JavaScript" TYPE="text/javascript">
function Levels(pItem)
<!--
{
var strIDs = 'Stock Message: '
{
if (pItem >= 1)
{
strIDs = ' NETUOTEVAR:STOCKLEVEL available for <br>dispatch in 24 Hours'
}
else if (pItem <= -998)
{
strIDs = 'Out of stock from<br>supplier'
}
else
{
strIDs = 'Normally Dispatched in<br>CUSTOMVAR:LEAD'
}
}
return strIDs
}
//-->
</script>
But this produces the folowing for Items in stock
NETQUOTEVAR:STOCKLEVEL available for
dispatch in 24 Hours
I think that the javascript dose not like the NETQUOTEVAR as it is already in use.
Any clever bods out there who can help!
Comment