|
Server : Apache/2.4.62 System : FreeBSD fbsdweb2.web.rcn.net 14.1-RELEASE FreeBSD 14.1-RELEASE releng/14.1-n267679-10e31f0946d8 GENERIC amd64 User : www ( 80) PHP Version : 8.3.8 Disable Function : NONE Directory : /domains/thomasjolly1/cgi-bin/ |
Upload File : |
#############################################################################
# SetCookies - by Richie Carey February 1998 #
#############################################################################
sub SetCookies
{
###########################################################################################
# After requiring the cookie-lib.pl library which contains the routines for setting and #
# reading cookies, this first section sets the necessary cookies within the visitors #
# browser. #
###########################################################################################
# Set the $domain to the domain of the server running this script exactly as shown. Then,
# set the path to the directory of web_store.cgi. If you don't set the path, your cookie
# would be returned to any site on that domain.
###########################################################################################
$cookie{'cart_id'} = "$cart_id";
# Set the domain to be correct for your domain
$domain = $sc_domain_name_for_cookie;
# The path to your 'store' directory
$path = $sc_path_for_cookie;
# Leave this as is.
$secure = "";
# Cookie will expire in 24 hours
$now = time;
# Second in twenty four hours
$twenty_four_hours = "86400";
$expiration = $now+$twenty_four_hours;#number of days until cookie expires
&set_cookie($expiration,$domain,$path,$secure);
}
############################################################################################
sub StoreHeader
{
open (HEADER, "$sc_store_header_file");
while (<HEADER>)
{
print $_;
}
close (HEADER);
}
############################################################################################
sub StoreFooter
{
open (FOOTER, "$sc_store_footer_file");
while (<FOOTER>)
{
print $_;
}
close (FOOTER);
}
############################################################################################
sub define_shipping_logic
{
$shipping_price = &format_price($shipping_percentage*$subtotal);
return $shipping_price;
}
############################################################################################
1;