Got it - changed the function to this -
<script type="text/javascript">
function minimumCheck(value) {
if (value < 6.00) {
alert("There is a $6.00 minimum order at Armydogtags.com");
return false;
}
return true;
}
</script>
and the form tag to this -
onSubmit="return(minimumCheck(<?php echo $ADTCart->TotalColumn("TotalPrice")
?>))">
--
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs, Tutorials & Resources
==================
"Murray *ACE*" <forums@HAHAgreat-web-sights.com> wrote in message
news:g6aeup$q41$1@forums.macromedia.com...
>I have a shopping cart page and I want to apply a minimum order restriction
>of $6 to it. The form tag looks like this -
>
> <form action="<?php echo
> ($_SERVER["PHP_SELF"].(isset($_SERVER["QUERY_STRING"])?"?".htmlentities($_SERVER["QUERY_STRING"]):""));?>"
> method="post" onSubmit="minimumCheck(<?php echo
> $ADTCart->TotalColumn("TotalPrice") ?>)">
>
> The function itself is this -
>
> <script type="text/javascript">
> function minimumCheck(value) {
> if (value < 6.00) {
> alert("There is a $6.00 minimum order at blahblahblah.com");
> return false;
> }
> }
> </script>
>
>
> The javascript fires, and pops the alert, but the form submits! Why is
> that return false not kicking in?
>
> --
> Murray --- ICQ 71997575
> Adobe Community Expert
> (If you *MUST* email me, don't LAUGH when you do so!)
> ==================
> http://www.projectseven.com/go - DW FAQs, Tutorials & Resources
> http://www.dwfaq.com - DW FAQs, Tutorials & Resources
> ==================
>
>