.id
4945
.gutitle
fpd_shipping_form
.title
fpd_shipping_form
.file
.extension
.name
.user_id
7
.notes
.body
<var C = GLOBAL.Def.Style.color>
<var Purchase = caller.Purchase>
<var Product = caller.Product>



<!--- did they already complete their shipping order? --->
<if Purchase.shipordered_unsignedint EQ 1>

<!--- display "you already ordered it" message. --->

<div style="background:##ffc; border:1px solid #C.g4#; padding:15px;" class="rounded">
<h3>
<img src="http://#this_domain#/file:/icon-simplistica_accept?&picwidth=24" style="height:1em;">
We're Shipping This to You.
</h3>
<div style="width:420px; class="copy">
<p>
You placed your shipping order #timeAgo(Purchase.shipordered_datetime)#. Shipping requests
take Fentriss.com a few weeks to complete.
</p>
<p>
Please <a href="http://fentriss.com/contact">contact us</a> if you have any questions
or concerns.
</p>
</div>
<div>&nbsp;</div>
<big><div align="right">
<a href="http://#this_domain#/store">Return to Fentriss Store &gt;</a>
</div></big>
</div>

<BREAK>

</if>



<!--- shipping form --->
<postform>

<var _status = "">
<var _shipaddress = "">

<if isDefined("POST.do_ship") AND POST.do_ship EQ 1>

<if _status EQ "">
<ensure variable="POST.shipsize" value="">
<if POST.shipsize EQ "">
<var _status = "Please enter your size.">
</if>
</if>

<if _status EQ "">
<ensure variable="POST.shipname" value="">
<if POST.shipname NEQ "">
<var _shipaddress = _shipaddress & CHR(10) & trim(POST.shipname)>
<else>
<var _status = "Please enter a shipping name.">
</if>
</if>
<if _status EQ "">
<ensure variable="POST.shipaddress" value="">
<if POST.shipaddress NEQ "">
<var _shipaddress = _shipaddress & CHR(10) & trim(POST.shipaddress)>
<else>
<var _status = "Please enter a shipping street address.">
</if>
</if>
<if _status EQ "">
<ensure variable="POST.shipapt" value="">
<if POST.shipapt NEQ "">
<var _shipaddress = _shipaddress & ", " & trim(POST.shipapt)>
</if>
</if>
<if _status EQ "">
<ensure variable="POST.shipcity" value="">
<if POST.shipcity NEQ "">
<var _shipaddress = _shipaddress & CHR(10) & trim(POST.shipcity)>
<else>
<var _status = "Please enter a shipping city.">
</if>
</if>
<if _status EQ "">
<ensure variable="POST.shipstate" value="">
<if POST.shipstate NEQ "">
<var _shipaddress = _shipaddress & ", " & trim(POST.shipstate)>
<else>
<var _status = "Please enter a shipping state.">
</if>
</if>
<if _status EQ "">
<ensure variable="POST.shipzip" value="">
<if POST.shipzip NEQ "">
<var _shipaddress = _shipaddress & CHR(10) & trim(POST.shipzip)>
<else>
<var _status = "Please enter a shipping zip code.">
</if>
</if>

<var _shipaddress = trim(_shipaddress)>

<if _status EQ "">
<var _status = 1>
</if>

</if>

<if _status EQ 1>

<!--- update purchase --->
<update orb="fpurchase" where="fpurchase.id = #Purchase.id#"
shipordered_unsignedint="1"
shipordered_datetime="#createodbcdatetime(Now())#"
shipped_unsignedint="0"
shipaddress="#_shipaddress#"
shipnotes=""
shipsize="">

<!--- email steve --->
<email to="steve@fentriss.com" from="Steve" subject="FenShipping Order: #escapeMarkup(Product.title)#">#escapeMarkup(Product.title)##CHR(10)#Size #escapeMarkup(POST.shipsize)##CHR(10)##CHR(10)#/fpurchase-#Purchase.id##CHR(10)##CHR(10)##_shipaddress##CHR(10)##CHR(10)##CHR(10)#CGI: #SerializeJSON(cgi)#</email>

<!--- purchase has been updated. refresh page so user will see
"we're shipping this to you" --->
<goto url="http://#this_domain#/#so_slash_string#">
<BREAK>

<else>

<tag.unit_css>


<if _status NEQ "">
<div style="margin:1em; border:2px solid ##900; color:##000; padding:7px;" class="rounded">
<b>#_status#</b>
</div>
<div>&nbsp;</div>
</if>

<div>&nbsp;</div>

<h3>What Size Do You Wear?</h3>


<div class="unit">
<div class="unit_left">
Shirt Size:
</div>
<div class="unit_right">
<ensure variable="POST.shipsize" value="">
<select name="shipsize">
<option value="">(choose)</option>
<loop list="XS,S,M,L,XL,XXL" index="_size">
<option value="#_size#"<if POST.shipsize EQ _size> selected</if>>#_size#</option>
</loop>
</select>
</div>
</div>



<h3>Where Should We Ship This?</h3>


<div class="unit">
<div class="unit_left">
Ship To:
</div>
<div class="unit_right">
<ensure variable="POST.shipname" value="">
<input type="text" name="shipname" value="#escapeDoubleQuotes(POST.shipname)#">
</div>
</div>

<div class="unit">
<div class="unit_left">
Street Address:
</div>
<div class="unit_right">
<ensure variable="POST.shipaddress" value="">
<input type="text" name="shipaddress" value="#escapeDoubleQuotes(POST.shipaddress)#">
</div>
</div>

<div class="unit">
<div class="unit_left">
Apartment No.
</div>
<div class="unit_right">
<ensure variable="POST.shipapt" value="">
<input type="text" name="shipapt" value="#escapeDoubleQuotes(POST.shipapt)#" style="width:4em;">
</div>
</div>

<div class="unit">
<div class="unit_left">
City:
</div>
<div class="unit_right">
<ensure variable="POST.shipcity" value="">
<input type="text" name="shipcity" value="#escapeDoubleQuotes(POST.shipcity)#">
</div>
</div>

<div class="unit">
<div class="unit_left">
State:
</div>
<div class="unit_right">
<ensure variable="POST.shipstate" value="">
<input type="text" name="shipstate" value="#escapeDoubleQuotes(POST.shipstate)#" style="width:4em;">
</div>
</div>

<div class="unit">
<div class="unit_left">
Zip Code:
</div>
<div class="unit_right">
<ensure variable="POST.shipzip" value="">
<input type="text" name="shipzip" value="#escapeDoubleQuotes(POST.shipzip)#" style="width:8em;">
</div>
</div>

<div class="unit">
<div class="unit_left">
&nbsp;
</div>
<div class="unit_right">
<input type="submit" class="f_smallbtn" value="Place Shipping Order" style="cursor:pointer;">
</div>
</div>

<input type="hidden" style="display:none;" name="do_ship" value="1">

</if>

</postform>
 
.sum_double
0.00
.producttype
.productincludes
.physical_unsignedint
0
.isprotected_unsignedint
0
.overridesiteheader_unsignedint
0