<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: zen cart order process customization</title>
	<atom:link href="http://www.zencartonline.com/2007/11/14/zen-cart-order-process-customization/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.zencartonline.com/2007/11/14/zen-cart-order-process-customization/</link>
	<description>Zen cart customization, themes, consulting, hosting</description>
	<lastBuildDate>Wed, 02 Sep 2009 12:11:57 -0400</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Tim Stanton</title>
		<link>http://www.zencartonline.com/2007/11/14/zen-cart-order-process-customization/comment-page-1/#comment-10</link>
		<dc:creator>Tim Stanton</dc:creator>
		<pubDate>Wed, 30 Jan 2008 00:41:05 +0000</pubDate>
		<guid isPermaLink="false">http://www.zencartonline.com/2007/11/14/zen-cart-order-process-customization/#comment-10</guid>
		<description>I&#039;m trying to duplicate the functionality of printrunner.com. Particularly the way the print pricing works. The rest of ZenCart seems to work fine.
I created this menu, it is a sample of what I want to have show up on the product pages, but I don&#039;t know how to integrate this kind of thing:
&lt;code&gt;
&lt;?php
if ( ! isset($qty)) {$qty = 500 ; }
if ( ! isset($pages)) {$pages = 1 ; }
if ( ! isset($cover)) {$cover = 2 ; }
if ( ! isset($coverstock)) {$coverstock = 0 ; }
if ( ! isset($inside)) {$inside = 2 ; }
if ( ! isset($insidestock)) {$insidestock = 0 ; }
extract($_REQUEST);
print&quot;Booklet Pricing&quot;;
Print&quot;&quot;;
Print &#039;&#039;;
print &quot;Quantity: &quot;;
$qty8=&quot;option value&quot;;
if ($qty == 1000) $qty8=&quot;option selected value&quot;;
$qty12=&quot;option value&quot;;
if ($qty == 2000) $qty12=&quot;option selected value&quot;;
$qty16=&quot;option value&quot;;
if ($qty == 3000) $qty16=&quot;option selected value&quot;;
$qty20=&quot;option value&quot;;
if ($qty == 4000) $qty20=&quot;option selected value&quot;;
$qty24=&quot;option value&quot;;
if ($qty == 5000) $qty24=&quot;option selected value&quot;;
$qty28=&quot;option value&quot;;
if ($qty == 6000) $qty28=&quot;option selected value&quot;;
$qty32=&quot;option value&quot;;
if ($qty == 7000) $qty32=&quot;option selected value&quot;;
$qty36=&quot;option value&quot;;
if ($qty == 8000) $qty36=&quot;option selected value&quot;;
$qty40=&quot;option value&quot;;
if ($qty == 9000) $qty40=&quot;option selected value&quot;;
print &quot;&quot;;
print &quot;500&quot;;
print &quot;1000&quot;;
print &quot;2000&quot;;
print &quot;3000&quot;;
print &quot;4000&quot;;
print &quot;5000&quot;;
print &quot;6000&quot;;
print &quot;7000&quot;;
print &quot;8000&quot;;
print &quot;9000&quot;;
print &quot;&quot;;
print &quot;&quot;;


$page8=&quot;option value&quot;;
if ($pages == 1) $page8=&quot;option selected value&quot;;
$page12=&quot;option value&quot;;
if ($pages == 2) $page12=&quot;option selected value&quot;;
$page16=&quot;option value&quot;;
if ($pages == 3) $page16=&quot;option selected value&quot;;
$page20=&quot;option value&quot;;
if ($pages == 4) $page20=&quot;option selected value&quot;;
$page24=&quot;option value&quot;;
if ($pages == 5) $page24=&quot;option selected value&quot;;
$page28=&quot;option value&quot;;
if ($pages == 6) $page28=&quot;option selected value&quot;;
$page32=&quot;option value&quot;;
if ($pages == 7) $page32=&quot;option selected value&quot;;
$page36=&quot;option value&quot;;
if ($pages == 8) $page36=&quot;option selected value&quot;;
$page40=&quot;option value&quot;;
if ($pages == 9) $page40=&quot;option selected value&quot;;
print &quot;Number of pages (including cover) &quot;;
print &quot;&quot;;
print &quot;8 pages&quot;;
print &quot;12 pages&quot;;
print &quot;16 pages&quot;;
print &quot;20 pages&quot;;
print &quot;24 pages&quot;;
print &quot;28 pages&quot;;
print &quot;32 pages&quot;;
print &quot;36 pages&quot;;
print &quot;40 pages&quot;;
print &quot;&quot;;
print &quot;&quot;;

Print &quot;Cover color: &quot;;
$a=&quot;option value&quot;;
if ($cover == 1) $a=&quot;option selected value&quot;;
$b=&quot;option value&quot;;
if ($cover == 2) $b=&quot;option selected value&quot;;
print &quot;&quot;;
print &quot;Black &amp; White&quot;;
print &quot;2-color&quot;;
print &quot;4-color&quot;;
print &quot;&quot;;
print &quot;&quot;;

Print &quot;Cover paper: &quot;;
$aaa=&quot;option value&quot;;
if ($coverstock == 1) $aaa=&quot;option selected value&quot;;
$bbb=&quot;option value&quot;;
if ($coverstock == 2) $bbb=&quot;option selected value&quot;;
print &quot;&quot;;
print &quot;80lb. gloss cover&quot;;
print &quot;80lb. dull cover&quot;;
print &quot;100lb. gloss cover&quot;;
print &quot;&quot;;
print &quot;&quot;;

Print &quot;Inside color: &quot;;
$aa=&quot;option value&quot;;
if ($inside == 1) $aa=&quot;option selected value&quot;;
$bb=&quot;option value&quot;;
if ($inside == 2) $bb=&quot;option selected value&quot;;
print &quot;&quot;;
print &quot;Black &amp; White&quot;;
print &quot;2-color&quot;;
print &quot;4-color&quot;;
print &quot;&quot;;
print &quot;&quot;;

Print &quot;Inside paper: &quot;;
$abb=&quot;option value&quot;;
if ($insidestock == 1) $abb=&quot;option selected value&quot;;
$baa=&quot;option value&quot;;
if ($insidestock == 2) $baa=&quot;option selected value&quot;;
print &quot;&quot;;
print &quot;80lb. gloss text&quot;;
print &quot;80lb. dull text&quot;;
print &quot;100lb. gloss text&quot;;
print &quot;&quot;;
print &quot;&quot;;

print &quot;&lt;input type=\&quot;submit\&quot; value=\&quot;Calculate\&quot; &quot;;
if ($cover == 0) $coversetup = 129.58;
if ($cover == 1) $coversetup = 230;
if ($cover == 2) $coversetup = 380;
if ($inside == 0) $insidesetup = 129.58;
if ($inside == 1) $insidesetup = 230;
if ($inside == 2) $insidesetup = 380;
if ($coverstock == 0) $coverpaper = 0.069155;
if ($coverstock == 1) $coverpaper = 0.072155;
if ($coverstock == 2) $coverpaper = 0.08;
if ($insidestock == 0) $insidepaper = 0.0365275;
if ($insidestock == 1) $insidepaper = 0.0375275;
if ($insidestock == 2) $insidepaper = 0.04;
$press = .028;
$covercost = $coversetup + (($coverpaper + $press) * $qty);
$insidecost = ($insidesetup * $pages) + (($qty * $pages) * ($press + $insidepaper));
$price = $covercost + $insidecost;
print &quot;&quot;;

Print &quot;Total Price: \$&quot;;
Echo round($price, 2);
print &quot;&quot;;
?&gt;&lt;/code&gt;</description>
		<content:encoded><![CDATA[<p>I&#8217;m trying to duplicate the functionality of printrunner.com. Particularly the way the print pricing works. The rest of ZenCart seems to work fine.<br />
I created this menu, it is a sample of what I want to have show up on the product pages, but I don&#8217;t know how to integrate this kind of thing:<br />
<code><br />
&lt;?php<br />
if ( ! isset($qty)) {$qty = 500 ; }<br />
if ( ! isset($pages)) {$pages = 1 ; }<br />
if ( ! isset($cover)) {$cover = 2 ; }<br />
if ( ! isset($coverstock)) {$coverstock = 0 ; }<br />
if ( ! isset($inside)) {$inside = 2 ; }<br />
if ( ! isset($insidestock)) {$insidestock = 0 ; }<br />
extract($_REQUEST);<br />
print"Booklet Pricing";<br />
Print"";<br />
Print '';<br />
print "Quantity: ";<br />
$qty8="option value";<br />
if ($qty == 1000) $qty8="option selected value";<br />
$qty12="option value";<br />
if ($qty == 2000) $qty12="option selected value";<br />
$qty16="option value";<br />
if ($qty == 3000) $qty16="option selected value";<br />
$qty20="option value";<br />
if ($qty == 4000) $qty20="option selected value";<br />
$qty24="option value";<br />
if ($qty == 5000) $qty24="option selected value";<br />
$qty28="option value";<br />
if ($qty == 6000) $qty28="option selected value";<br />
$qty32="option value";<br />
if ($qty == 7000) $qty32="option selected value";<br />
$qty36="option value";<br />
if ($qty == 8000) $qty36="option selected value";<br />
$qty40="option value";<br />
if ($qty == 9000) $qty40="option selected value";<br />
print "";<br />
print "500";<br />
print "1000";<br />
print "2000";<br />
print "3000";<br />
print "4000";<br />
print "5000";<br />
print "6000";<br />
print "7000";<br />
print "8000";<br />
print "9000";<br />
print "";<br />
print "";</p>
<p>$page8="option value";<br />
if ($pages == 1) $page8="option selected value";<br />
$page12="option value";<br />
if ($pages == 2) $page12="option selected value";<br />
$page16="option value";<br />
if ($pages == 3) $page16="option selected value";<br />
$page20="option value";<br />
if ($pages == 4) $page20="option selected value";<br />
$page24="option value";<br />
if ($pages == 5) $page24="option selected value";<br />
$page28="option value";<br />
if ($pages == 6) $page28="option selected value";<br />
$page32="option value";<br />
if ($pages == 7) $page32="option selected value";<br />
$page36="option value";<br />
if ($pages == <img src='http://www.zencartonline.com/wp-includes/images/smilies/icon_cool.gif' alt='8)' class='wp-smiley' /> $page36="option selected value";<br />
$page40="option value";<br />
if ($pages == 9) $page40="option selected value";<br />
print "Number of pages (including cover) ";<br />
print "";<br />
print "8 pages";<br />
print "12 pages";<br />
print "16 pages";<br />
print "20 pages";<br />
print "24 pages";<br />
print "28 pages";<br />
print "32 pages";<br />
print "36 pages";<br />
print "40 pages";<br />
print "";<br />
print "";</p>
<p>Print "Cover color: ";<br />
$a="option value";<br />
if ($cover == 1) $a="option selected value";<br />
$b="option value";<br />
if ($cover == 2) $b="option selected value";<br />
print "";<br />
print "Black &amp; White";<br />
print "2-color";<br />
print "4-color";<br />
print "";<br />
print "";</p>
<p>Print "Cover paper: ";<br />
$aaa="option value";<br />
if ($coverstock == 1) $aaa="option selected value";<br />
$bbb="option value";<br />
if ($coverstock == 2) $bbb="option selected value";<br />
print "";<br />
print "80lb. gloss cover";<br />
print "80lb. dull cover";<br />
print "100lb. gloss cover";<br />
print "";<br />
print "";</p>
<p>Print "Inside color: ";<br />
$aa="option value";<br />
if ($inside == 1) $aa="option selected value";<br />
$bb="option value";<br />
if ($inside == 2) $bb="option selected value";<br />
print "";<br />
print "Black &amp; White";<br />
print "2-color";<br />
print "4-color";<br />
print "";<br />
print "";</p>
<p>Print "Inside paper: ";<br />
$abb="option value";<br />
if ($insidestock == 1) $abb="option selected value";<br />
$baa="option value";<br />
if ($insidestock == 2) $baa="option selected value";<br />
print "";<br />
print "80lb. gloss text";<br />
print "80lb. dull text";<br />
print "100lb. gloss text";<br />
print "";<br />
print "";</p>
<p>print "&lt;input type=\"submit\" value=\"Calculate\" ";<br />
if ($cover == 0) $coversetup = 129.58;<br />
if ($cover == 1) $coversetup = 230;<br />
if ($cover == 2) $coversetup = 380;<br />
if ($inside == 0) $insidesetup = 129.58;<br />
if ($inside == 1) $insidesetup = 230;<br />
if ($inside == 2) $insidesetup = 380;<br />
if ($coverstock == 0) $coverpaper = 0.069155;<br />
if ($coverstock == 1) $coverpaper = 0.072155;<br />
if ($coverstock == 2) $coverpaper = 0.08;<br />
if ($insidestock == 0) $insidepaper = 0.0365275;<br />
if ($insidestock == 1) $insidepaper = 0.0375275;<br />
if ($insidestock == 2) $insidepaper = 0.04;<br />
$press = .028;<br />
$covercost = $coversetup + (($coverpaper + $press) * $qty);<br />
$insidecost = ($insidesetup * $pages) + (($qty * $pages) * ($press + $insidepaper));<br />
$price = $covercost + $insidecost;<br />
print "";</p>
<p>Print "Total Price: \$";<br />
Echo round($price, 2);<br />
print "";<br />
?&gt;</code></p>
]]></content:encoded>
	</item>
</channel>
</rss>
