"IN" Snippets


Basket #192446

Methods for splitting strings to arrays
Created: 1540319813
View "Basket #192446"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

Basket #183711

Methods for splitting strings to arrays
Created: 1537985626
View "Basket #183711"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> <hr> <mvt:eval expr="s.tm_mon" />/<mvt:eval expr="s.tm_mday" />/<mvt:eval expr="s.tm_year" />
 

Basket #183705

Methods for splitting strings to arrays
Created: 1537985251
View "Basket #183705"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> <hr> <mvt:eval expr="s.tm_month" />/<mvt:eval expr="s.tm_day" />/<mvt:eval expr="s.tm_year" /> <hr> <mvt:assign name="g.return_value" value="time_t_month( timet, local )" /> &mvt:global:return_value; </hr>
 

Basket #183703

Methods for splitting strings to arrays
Created: 1537985209
View "Basket #183703"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> <hr> <mvt:eval expr="s.tm_month" />/<mvt:eval expr="s.tm_day" />/<mvt:eval expr="s.tm_year" /> <hr> <mvt:assign name="g.return_value" value="time_t_month( timet, local )" /> </hr>
 

Basket #183701

Methods for splitting strings to arrays
Created: 1537985134
View "Basket #183701"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> <hr> <mvt:eval expr="s.tm_month" />/<mvt:eval expr="s.tm_day" />/<mvt:eval expr="s.tm_year" />
 

Basket #183699

Methods for splitting strings to arrays
Created: 1537985087
View "Basket #183699"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> <mvt:eval expr="s.tm_year" />
 

Basket #183697

Methods for splitting strings to arrays
Created: 1537985068
View "Basket #183697"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> <mvt:eval expr="time_t_dayofmonth( timet, local )" />
 

Basket #183695

Methods for splitting strings to arrays
Created: 1537985055
View "Basket #183695"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> <mvt:eval expr="time_t_dayofmonth( timet, time_zone )" />
 

Basket #183693

Methods for splitting strings to arrays
Created: 1537985030
View "Basket #183693"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> time_t_dayofmonth( timet, time_zone )
 

Basket #177271

Methods for splitting strings to arrays
Created: 1536952946
View "Basket #177271"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', l.settings:promoArray )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="promoArray"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

Basket #168496

Delete all characters from string except characters that you define.
Created: 1534178644
View "Basket #168496"
<mvt:comment>define your allowed characters</mvt:comment> <mvt:assign name="g.allowed" value="'abcdefghijklmnopqrstuvwxyz '" /> <mvt:comment>the string to scrub</mvt:comment> <mvt:assign name="g.string" value="'Test123-!hello'" /> <mvt:assign name="g.counter" value="1" /> <mvt:comment>for each letter in string</mvt:comment> <mvt:while expr="g.counter LE len(g.string)"> <mvt:comment>if this letter is contained in allowed, increment</mvt:comment> <mvt:if expr="substring(g.string, g.counter, 1) CIN g.allowed"> <mvt:assign name="g.counter" value="g.counter+1" /> <mvt:else> <mvt:comment>if letter is not in allowed, delete it, we don't need to increment because we just made the string 1 shorter</mvt:comment> <mvt:assign name="g.string" value="substring(g.string, 1, g.counter-1 ) $ substring(g.string, g.counter+1, (len(g.string)+1)-g.counter)" /> </mvt:if> </mvt:while> &mvt:global:string;
 

trim off first and last character of a string

trim off first and last character of a string to get rid of the 1st and last chars
Created: 1533316451
View "trim off first and last character of a string"
<mvt:assign name="g.foo" value="'#this is my test text#'" /> &mvte:global:foo;<BR></BR> <mvt:assign name="g.foo" value="substring(g.foo, 2, len(g.foo) - 2))" /> &mvte:global:foo;
 

Basket #166763

Created: 1533316386
View "Basket #166763"
<mvt:assign name="g.foo" value="'#this is my test text#'" /> &mvte:global:foo;<BR></BR> <mvt:assign name="g.foo" value="substring(g.foo, 2, len(g.foo) - 2))" /> &mvte:global:foo;
 

Basket #166761

Created: 1533316366
View "Basket #166761"
<mvt:assign name="g.foo" value="'#this is my test text#'" /> &mvte:global:foo; <mvt:assign name="g.foo" value="substring(g.foo, 2, len(g.foo) - 2))" /> &mvte:global:foo;
 

Basket #166759

Created: 1533316330
View "Basket #166759"
<mvt:assign name="l.settings:global:foo" value="'#this is my test text#'" /> &mvte:global:foo; <mvt:assign name="l.settings:global:foo" value="substring(l.settings:global:foo, 2, len(l.settings:global:foo) - 2))" /> &mvte:global:foo;
 

Basket #166757

Created: 1533316313
View "Basket #166757"
<mvt:assign name="g.foo" value="'#this is my test text#'" /> &mvte:global:foo; <mvt:assign name="l.settings:global:foo" value="substring(l.settings:global:foo, 2, len(l.settings:global:foo) - 2))" /> &mvte:global:foo;
 

Basket #157063

Methods for splitting strings to arrays
Created: 1532630429
View "Basket #157063"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:assign name="line" array="global:splitString[0]"/> <p>&mvt:line;</p> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

Basket #157060

Methods for splitting strings to arrays
Created: 1532630347
View "Basket #157060"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <p>here &mvt:l.success</p> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

Basket #157057

Methods for splitting strings to arrays
Created: 1532630327
View "Basket #157057"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <p>here &mvt:success</p> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

Basket #157055

Methods for splitting strings to arrays
Created: 1532630321
View "Basket #157055"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <p>here &mvt:l.success</p> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

Basket #157053

Methods for splitting strings to arrays
Created: 1532630313
View "Basket #157053"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <p>&mvt:l.success</p> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

Basket #141256

Delete all characters from string except characters that you define.
Created: 1528997578
View "Basket #141256"
<mvt:comment>define your allowed characters</mvt:comment> <mvt:assign name="g.allowed" value="'abcdefghijklmnopqrstuvwxyz'" /> <mvt:comment>the string to scrub</mvt:comment> <mvt:assign name="g.string" value="'Test 123 -!hello'" /> <mvt:assign name="g.counter" value="1" /> <mvt:comment>for each letter in string</mvt:comment> <mvt:while expr="g.counter LE len(g.string)"> <mvt:comment>if this letter is contained in allowed, increment</mvt:comment> <mvt:if expr="substring(g.string, g.counter, 1) CIN g.allowed"> <mvt:assign name="g.counter" value="g.counter+1" /> <mvt:else> <mvt:comment>if letter is not in allowed, delete it, we don't need to increment because we just made the string 1 shorter</mvt:comment> <mvt:assign name="g.string" value="substring(g.string, 1, g.counter-1 ) $ substring(g.string, g.counter+1, (len(g.string)+1)-g.counter)" /> </mvt:if> </mvt:while> &mvt:global:string;
 

Basket #141211

Methods for splitting strings to arrays
Created: 1528985948
View "Basket #141211"
"get the second word of this sentence".split(' ')[1];
 

Basket #124429

[Documentation](http://www.miva.com/template-language/miva_template_language/entities_&_encoding.html) [Video Tutorial](http://www.miva.com/videos/web_developers/output-encoding)
Created: 1525541256
View "Basket #124429"
<mvt:if expr="0 EQ 0"> Note: This item is not available for export outside the US. </mvt:if>
 

Basket #124427

[Documentation](http://www.miva.com/template-language/miva_template_language/entities_&_encoding.html) [Video Tutorial](http://www.miva.com/videos/web_developers/output-encoding)
Created: 1525541246
View "Basket #124427"
<mvt:if expr="0 EQ 0"> &mvt:"Note: This item is not available for export outside the US." </mvt:if>
 

Basket #124425

[Documentation](http://www.miva.com/template-language/miva_template_language/entities_&_encoding.html) [Video Tutorial](http://www.miva.com/videos/web_developers/output-encoding)
Created: 1525541237
View "Basket #124425"
<mvt:assign name="l.settings:sample" value="'<i>Hello World.</i>'" /> <h2>No Encoding</h2> &mvt:sample; <h2>Entity Encoding </h2> <p><small>Can help prevent cross side scripiting</small></p> &mvte:sample; <h2>Attribute Encoding </h2> <p><small>Great for URLs</small></p> &mvta:sample; <h2>JavaScript Encoding</h2> &mvtj:sample; <h2>Sluggified Encoding</h2> &mvts:sample; <mvt:comment> <!-- Click the Result's "View Source" Button for more details. --> </mvt:comment> <mvt:if expr="0 EQ 0"> &mvt:"Note: This item is not available for export outside the US." </mvt:if>
 

Basket #104936

Methods for splitting strings to arrays
Created: 1522340916
View "Basket #104936"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> &mvt:global:string; <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

Basket #104934

Methods for splitting strings to arrays
Created: 1522340908
View "Basket #104934"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> &mvt:g.string; <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 
View "Basket #103068"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> l.settings:readytheme:social_active l.settings:readytheme:social_facebook; l.settings:readytheme:social_twitter; l.settings:readytheme:social_instagram; l.settings:readytheme:social_googleplus; l.settings:readytheme:social_youtube; l.settings:readytheme:social_vimeo; l.settings:readytheme:social_pinterest; l.settings:readytheme:social_flickr; <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 
View "Basket #103066"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:if expr="l.settings:readytheme:social_active"> <mvt:comment>&mvt:readytheme:social_facebook; </mvt:comment> <mvt:comment>&mvt:readytheme:social_twitter; </mvt:comment> <mvt:comment>&mvt:readytheme:social_instagram; </mvt:comment> <mvt:comment>&mvt:readytheme:social_googleplus; </mvt:comment> <mvt:comment>&mvt:readytheme:social_youtube; </mvt:comment> <mvt:comment>&mvt:readytheme:social_vimeo; </mvt:comment> <mvt:comment>&mvt:readytheme:social_pinterest; </mvt:comment> <mvt:comment>&mvt:readytheme:social_flickr; </mvt:comment> </mvt:if> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 
View "Basket #103065"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:if expr="l.settings:readytheme:social_active"> <!-- &mvt:readytheme:social_facebook; --> <!-- &mvt:readytheme:social_twitter; --> <!-- &mvt:readytheme:social_instagram; --> <!-- &mvt:readytheme:social_googleplus; --> <!-- &mvt:readytheme:social_youtube; --> <!-- &mvt:readytheme:social_vimeo; --> <!-- &mvt:readytheme:social_pinterest; --> <!-- &mvt:readytheme:social_flickr; --> </mvt:if> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 
View "Basket #103064"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:if expr="l.settings:readytheme:social_active"> <a href="&mvt:readytheme:social_facebook;">Facebook</a> <a href="&mvt:readytheme:social_twitter;">Twitter</a> <a href="&mvt:readytheme:social_instagram;">Instagram</a> <a href="&mvt:readytheme:social_googleplus;">Google+</a> <a href="&mvt:readytheme:social_youtube;">Youtube</a> <a href="&mvt:readytheme:social_vimeo;">Vimeo</a> <a href="&mvt:readytheme:social_pinterest;">Pinterest</a> <a href="&mvt:readytheme:social_flickr;">Flickr</a> </mvt:if> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 
View "Basket #103063"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:if expr="l.settings:readytheme:social_active"> <a href="&mvt:social_youtube;">Youtube</a> <a href="&mvt:social_vimeo;">Vimeo</a> <a href="&mvt:social_pinterest;">Pinterest</a> </mvt:if> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 
View "Basket #103062"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:if expr="l.settings:readytheme:social_active"> <a href="&mvt:readytheme:social_facebook;">Facebook</a> <a href="&mvt:readytheme:social_twitter;">Twitter</a> <a href="&mvt:readytheme:social_instagram;">Instagram</a> <a href="&mvt:readytheme:social_googleplus;">Google+</a> <a href="&mvt:readytheme:social_youtube;">Youtube</a> <a href="&mvt:readytheme:social_vimeo;">Vimeo</a> <a href="&mvt:readytheme:social_pinterest;">Pinterest</a> </mvt:if> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 
View "Basket #103060"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:if expr="l.settings:readytheme:social_active"> <a href="">Facebook</a> <a href="">Twitter</a> <a href="">Instagram</a> <a href="">Google+</a> <a href="">Youtube</a> <a href="">Vimeo</a> <a href="">Pinterest</a> </mvt:if> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 
View "Basket #103058"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:if expr="l.settings:readytheme:social_active"> <a href="&mvt:readytheme:social_facebook;">Facebook</a> <a href="&mvt:readytheme:social_twitter;">Twitter</a> <a href="&mvt:readytheme:social_instagram;">Instagram</a> <a href="&mvt:readytheme:social_googleplus;">Google+</a> <a href="&mvt:readytheme:social_youtube;">Youtube</a> <a href="&mvt:readytheme:social_vimeo;">Vimeo</a> <a href="&mvt:readytheme:social_pinterest;">Pinterest</a> </mvt:if> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 
View "Basket #103057"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:if expr="l.settings:readytheme:social_active"> <a href="&mvt:readytheme:social_facebook;">Facebook</a> <a href="&mvt:readytheme:social_twitter;">Twitter</a> <a href="&mvt:readytheme:social_instagram;">Instagram</a> <a href="&mvt:readytheme:social_googleplus;">Google+</a> <a href="&mvt:readytheme:social_youtube;">Youtube</a> <a href="&mvt:readytheme:social_vimeo;">Vimeo</a> <a href="&mvt:readytheme:social_pinterest;">Pinterest</a> <a href="&mvt:readytheme:social_flickr;">Flickr</a> </mvt:if> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 
View "ReadyTheme Settings"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:if expr="l.settings:readytheme:social_active"> </mvt:if> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 
View "ReadyTheme Settings"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:if expr="l.settings:readytheme:social_active"> <a href="&mvt:readytheme:social_facebook;">Facebook</a> <a href="&mvt:readytheme:social_twitter;">Twitter</a> <a href="&mvt:readytheme:social_instagram;">Instagram</a> <a href="&mvt:readytheme:social_googleplus;">Google+</a> <a href="&mvt:readytheme:social_youtube;">Youtube</a> <a href="&mvt:readytheme:social_vimeo;">Vimeo</a> <a href="&mvt:readytheme:social_pinterest;">Pinterest</a> <a href="&mvt:readytheme:social_flickr;">Flickr</a> </mvt:if> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 
View "ReadyTheme Settings"
<!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div> <!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:if expr="l.settings:readytheme:social_active"> <a href="&mvt:readytheme:social_facebook;">Facebook</a> <a href="&mvt:readytheme:social_twitter;">Twitter</a> <a href="&mvt:readytheme:social_instagram;">Instagram</a> <a href="&mvt:readytheme:social_googleplus;">Google+</a> <a href="&mvt:readytheme:social_youtube;">Youtube</a> <a href="&mvt:readytheme:social_vimeo;">Vimeo</a> <a href="&mvt:readytheme:social_pinterest;">Pinterest</a> <a href="&mvt:readytheme:social_flickr;">Flickr</a> </mvt:if> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 

Basket #98795

Default code to display the ReadyTheme Settings section.
Created: 1520623830
View "Basket #98795"
<!-- Look & Feel --> <mvt:item name="readytheme" param="css" /> <!-- Social Icons --> <mvt:item name="readytheme" param="thirdpartysharing" /> <!-- Trust Symbol --> <mvt:item name="readytheme" param="trustsymbol" /> <!-- Logo --> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div>
 

Basket #98793

Default code to display the ReadyTheme Settings section.
Created: 1520623760
View "Basket #98793"
<div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div>
 

Basket #98791

Default code to display the ReadyTheme Settings section.
Created: 1520623738
View "Basket #98791"
<!-- Look & Feel --> <mvt:item name="readytheme" param="css" /> <!-- Social Icons --> <mvt:item name="readytheme" param="thirdpartysharing" /> <!-- Trust Symbol --> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"> </a> </mvt:if> </div>
 

Basket #98790

Default code to display the ReadyTheme Settings section.
Created: 1520623731
View "Basket #98790"
<!-- Look & Feel --> <mvt:item name="readytheme" param="css" /> <!-- Social Icons --> <mvt:item name="readytheme" param="thirdpartysharing" /> <!-- Trust Symbol --> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"> <img src="&mvt:readytheme:logo_image;"/> </a> </mvt:if> </div>
 

Basket #98786

Default code to display the ReadyTheme Settings section.
Created: 1520623716
View "Basket #98786"
<!-- Look & Feel --> <mvt:item name="readytheme" param="css" /> <!-- Social Icons --> <mvt:item name="readytheme" param="thirdpartysharing" /> <!-- Trust Symbol --> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"> <img src="&mvt:readytheme:logo_image;"/> </a> </mvt:if> </div>
 

Basket #98785

Default code to display the ReadyTheme Settings section.
Created: 1520623707
View "Basket #98785"
<!-- Look & Feel --> <mvt:item name="readytheme" param="css" /> <!-- Social Icons --> <mvt:item name="readytheme" param="thirdpartysharing" /> <!-- Trust Symbol --> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"> <img src="&mvte:readytheme:logo_image;"/> </a> </mvt:if> </div>
 

Basket #98783

Default code to display the ReadyTheme Settings section.
Created: 1520623685
View "Basket #98783"
<!-- Look & Feel --> <mvt:item name="readytheme" param="css" /> <!-- Social Icons --> <mvt:item name="readytheme" param="thirdpartysharing" /> <!-- Trust Symbol --> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"> </a> </mvt:if> </div>
 

Basket #98782

Default code to display the ReadyTheme Settings section.
Created: 1520623662
View "Basket #98782"
<!-- Look & Feel --> <mvt:item name="readytheme" param="css" /> <!-- Social Icons --> <mvt:item name="readytheme" param="thirdpartysharing" /> <!-- Trust Symbol --> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"> <img src="&mvte:readytheme:logo_image;"/> </a> </mvt:if> </div>
 

Basket #98781

Default code to display the ReadyTheme Settings section.
Created: 1520623656
View "Basket #98781"
<!-- Look & Feel --> <mvt:item name="readytheme" param="css" /> <!-- Social Icons --> <mvt:item name="readytheme" param="thirdpartysharing" /> <!-- Trust Symbol --> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"> <img src="&mvte:readytheme:logo_image;" /> </a> </mvt:if> </div>
 

Basket #98780

Default code to display the ReadyTheme Settings section.
Created: 1520623636
View "Basket #98780"
<!-- Look & Feel --> <mvt:item name="readytheme" param="css" /> <!-- Social Icons --> <mvt:item name="readytheme" param="thirdpartysharing" /> <!-- Trust Symbol --> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"> <img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" /> </a> </mvt:if> </div>
 

Basket #98778

Default code to display the ReadyTheme Settings section.
Created: 1520623554
View "Basket #98778"
<!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"> <img src="&mvte:readytheme:logo_image;" /> </a> </mvt:if> </div>
 

Basket #98776

Default code to display the ReadyTheme Settings section.
Created: 1520623501
View "Basket #98776"
<!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> </div>
 

Basket #98775

Default code to display the ReadyTheme Settings section.
Created: 1520623490
View "Basket #98775"
<!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> </div>
 

Basket #98774

Default code to display the ReadyTheme Settings section.
Created: 1520623480
View "Basket #98774"
<!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> </mvt:if> </div>
 

Basket #98773

Default code to display the ReadyTheme Settings section.
Created: 1520623415
View "Basket #98773"
<!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div>
 

ReadyTheme Settings

Default code to display the ReadyTheme Settings section.
Created: 1520623387
View "ReadyTheme Settings"
<!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" />
 

ReadyTheme Settings

Default code to display the ReadyTheme Settings section.
Created: 1520623374
View "ReadyTheme Settings"
<!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div>
 

ReadyTheme Settings

Default code to display the ReadyTheme Settings section.
Created: 1520623295
View "ReadyTheme Settings"
<!--Look & Feel--> <mvt:item name="readytheme" param="css" /> <!--Social Icons--> <mvt:item name="readytheme" param="thirdpartysharing" /> <!--Trust Symbol--> <mvt:item name="readytheme" param="trustsymbol" /> <!--Logo Code--> <div class="logo"> <mvt:if expr="l.settings:readytheme:logo_type EQ 'text'"> <a href="http://&mvt:global:domain:name;"> <span class="logo-name">&mvt:readytheme:logo_name;</span> <span class="logo-tagline">&mvt:readytheme:logo_tagline;</span> </a> <mvt:elseif expr="l.settings:readytheme:logo_type EQ 'image'"> <a href="http://&mvt:global:domain:name;"><img src="&mvte:readytheme:logo_image;" alt="&mvt:readytheme:logo_alt;" title="&mvt:readytheme:logo_alt;" border="0" /></a> <mvt:else> </mvt:if> </div>
 

Basket #97753

Methods for splitting strings to arrays
Created: 1519952006
View "Basket #97753"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

Basket #68875

capitalize a string
Created: 1510761276
View "Basket #68875"
<mvt:assign name="g.str" value="'caleb was a dog'" /> <mvt:assign name="g.capitalize" value="toupper(substring(g.str,0,1)) $ subString(g.str,2,len(g.str))" /> &mvt:global:capitalize;
 

Basket #57957

Methods for splitting strings to arrays
Created: 1504715800
View "Basket #57957"
<mvt:assign name="g.array[1]" value=" 'apple' "/> <mvt:assign name="g.array[2]" value=" 'orange' "/> <mvt:assign name="g.array[3]" value=" 'banana' "/> &mvt:global:array; <mvt:assign name="g.randomFruit" value="g.array[ random( miva_array_max(g.array) ) ]" /> &mvte:global:randomFruit; <mvt:assign name="l.settings:number" value="random(3)" /> &mvt:number;
 

Basket #55979

capitalize a string
Created: 1503004065
View "Basket #55979"
<h2>MivaScript MOD</h2> <p>MivaScript has a built in Modulus opperator: <code>MOD</code></p> <mvt:assign name="l.settings:total_ports" value="112" /> <mvt:assign name="l.settings:total_blocks" value="floor((l.settings:total_ports -1) / 24) +1" /> <code>total blocks:</code>&mvt:total_blocks;<br></br> <mvt:if expr="l.settings:total_ports GE 112"> <code>wait! please call us</code> </mvt:if>
 
View "Get Everything after a String"
<mvt:assign name="g.string" value="'something.com/goes-here.html'" /> <mvt:assign name="g.split" value="'.com'" /> <mvt:assign name="g.after_index" value="(g.split CIN g.string) + len(g.split)" /> <mvt:assign name="g.after" value="substring( g.string, g.after_index , len(g.string) )" /> &mvte:global:after;
 

Basket #52503

Methods for splitting strings to arrays
Created: 1501196880
View "Basket #52503"
<mvt:assign name="g.string" value="'asdfasdf'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:assign name="g.relprod_arr_len" value="miva_array_elements(g.splitString )" /> Cookie recentproductd array length: &mvt:global:relprod_arr_len; <br> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

Basket #51494

Methods for splitting strings to arrays
Created: 1500068671
View "Basket #51494"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> <mvt:assign name="g.randomNumber" value="random(99)" /> &mvt:global:randomNumber;
 
View "Basket #47367"
<mvt:assign name="g.cc_num_dirty" value="'44a44-5555/3333A1111-adasdsadasdas!'" /> <mvt:while expr="l.character_counter LT len(g.cc_num_dirty)"> <mvt:assign name="l.character_counter" value="l.character_counter + 1" /> <mvt:assign name="l.character" value="substring_var( g.cc_num_dirty, l.character_counter, 1 )"/> <mvt:if expr="isdigit(l.character)"> <mvt:if expr="l.digit_counter GT 0 AND l.digit_counter MOD 4 EQ 0"> <mvt:assign name="g.cc_num_clean" value="g.cc_num_clean $ '-'" /> </mvt:if> <mvt:assign name="g.cc_num_clean" value="g.cc_num_clean $ l.character" /> <mvt:assign name="l.digit_counter" value="l.digit_counter + 1" /> </mvt:if> </mvt:while> abc &mvte:global:cc_num_clean;
 
View "Basket #40110"
<mvt:assign name="g.string" value="'three,three,three,four,four'" /> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, ',', l.settings:array )" /> <!-- @@ &mvt:global:MvDO_Error; --> <h3>Continue</h3> <mvt:foreach iterator="item" array="array"> <mvt:if expr="l.settings:item EQ 'three'"> test-three</br> <mvt:foreachcontinue /> </mvt:if> &mvt:item;</br> <mvt:if expr="l.settings:item EQ 'four'"> test-four</br> &mvt:item;</br> <mvt:foreachcontinue /> </mvt:if> </mvt:foreach> <h3>Stop</h3> <mvt:foreach iterator="item" array="array"> <mvt:if expr="l.settings:item EQ 'three'"> <mvt:foreachstop /> </mvt:if> &mvt:item;</br> </mvt:foreach>
 

Basket #29601

capitalize a string
Created: 1485552377
View "Basket #29601"
<mvt:assign name="g.str" value="'chris dye'" /> <mvt:assign name="g.capitalize" value="toupper(substring(g.str,0,1)) $ subString(g.str,2,len(g.str))" /> &mvt:global:capitalize;
 

Basket #18886

Grab the 3 letter extension off of an image file. Could be improved to look for last ',' and grab all after in case of variations like '.jpeg'.
Created: 1473454796
View "Basket #18886"
<mvt:assign name="g.url" value="'http://dev.mcrmedical.com/mm5/graphics/00000001/fak28-MCR-first-aid-kit-front.jpeg'" /> <mvt:assign name="g.extension" value="substring(g.url,(len(g.url)-3),4)" /> &mvt:global:extension;
 
View "Estimate Order Shipping Date"
<mvt:comment> Account for Daylight Savings time </mvt:comment> <mvt:if expr="s.tm_isdst"> <mvt:assign name="g.Timezone_Offset" value="'-5'" /> <mvt:assign name="g.Timezone_Abbreviation" value="'CDT'" /> <mvt:else> <mvt:assign name="g.Timezone_Offset" value="'-6'" /> <mvt:assign name="g.Timezone_Abbreviation" value="'CST'" /> </mvt:if> <mvt:if expr="s.tm_isdst"> <p>Daylight savings time <b>IS</b> in effect. Timezone Offset: &mvte:global:Timezone_Offset;</p> <mvt:else> <p>Daylight savings time is <b>NOT</b> in effect. Timezone Offset: &mvte:global:Timezone_Offset;</p> </mvt:if> <hr> <mvt:comment> Assign a Days-of-the-week text array for later </mvt:comment> <mvt:assign name="l.settings:daysofweek[1]" value="'Sunday'" /> <mvt:assign name="l.settings:daysofweek[2]" value="'Monday'" /> <mvt:assign name="l.settings:daysofweek[3]" value="'Tuesday'" /> <mvt:assign name="l.settings:daysofweek[4]" value="'Wednesday'" /> <mvt:assign name="l.settings:daysofweek[5]" value="'Thursday'" /> <mvt:assign name="l.settings:daysofweek[6]" value="'Friday'" /> <mvt:assign name="l.settings:daysofweek[7]" value="'Saturday'" /> <mvt:comment> Prepare days to simulate & test senarios </mvt:comment> <mvt:assign name="l.settings:senarios[1]:descrip" value="'Monday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[1]:timestamp" value="1470657660" /> <mvt:assign name="l.settings:senarios[2]:descrip" value="'Monday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[2]:timestamp" value="1470693660" /> <mvt:assign name="l.settings:senarios[3]:descrip" value="'Tuesday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[3]:timestamp" value="1470744060" /> <mvt:assign name="l.settings:senarios[4]:descrip" value="'Tuesday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[4]:timestamp" value="1470780060" /> <mvt:assign name="l.settings:senarios[5]:descrip" value="'Wednesday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[5]:timestamp" value="1470830460" /> <mvt:assign name="l.settings:senarios[6]:descrip" value="'Wednesday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[6]:timestamp" value="1470866460" /> <mvt:assign name="l.settings:senarios[7]:descrip" value="'Thursday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[7]:timestamp" value="1470916860" /> <mvt:assign name="l.settings:senarios[8]:descrip" value="'Thursday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[8]:timestamp" value="1470952860" /> <mvt:assign name="l.settings:senarios[9]:descrip" value="'Friday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[9]:timestamp" value="1471003260" /> <mvt:assign name="l.settings:senarios[10]:descrip" value="'Friday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[10]:timestamp" value="1471039260" /> <mvt:assign name="l.settings:senarios[11]:descrip" value="'Saturday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[11]:timestamp" value="1471089660" /> <mvt:assign name="l.settings:senarios[12]:descrip" value="'Saturday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[12]:timestamp" value="1471125660" /> <mvt:assign name="l.settings:senarios[13]:descrip" value="'Sunday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[13]:timestamp" value="1471089660" /> <mvt:assign name="l.settings:senarios[14]:descrip" value="'Sunday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[14]:timestamp" value="1471125660" /> <mvt:comment> Loop over each senario and test the estimation logic </mvt:comment> <mvt:foreach iterator="senario" array="senarios"> <mvt:comment> Assign some date-time variables that make it easier to read, write, and compare dates when we apply the estimation logic </mvt:comment> <mvt:assign name="l.settings:senario:date:year" value="time_t_year( l.settings:senario:timestamp, g.Timezone_Offset )" /> <mvt:assign name="l.settings:senario:date:month" value="padl(time_t_month( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:day" value="padl(time_t_dayofmonth( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:dayofweek" value="time_t_dayofweek( l.settings:senario:timestamp, g.Timezone_Offset )" /> <mvt:assign name="l.settings:senario:date:dayofweek_formatted" value="l.settings:daysofweek[time_t_dayofweek( l.settings:senario:timestamp, g.Timezone_Offset )]" /> <mvt:assign name="l.settings:senario:date:hour" value="padl(time_t_hour( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:min" value="padl(time_t_min( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:sec" value="padl(time_t_sec( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:formatted" value="l.settings:senario:date:year $ '-' $ l.settings:senario:date:month $ '-' $ l.settings:senario:date:day $ ' ' $ l.settings:senario:date:hour $ ':' $ l.settings:senario:date:min $ ':' $ l.settings:senario:date:sec $ ' ' $ g.Timezone_Offset" /> <h2>Senario: &mvt:senario:descrip;<small>&mvt:senario:date:formatted;</small></h2> <mvt:if expr="l.settings:senario:date:dayofweek_formatted CIN 'Monday, Tuesday, Wednesday, Thursday' AND l.settings:senario:date:hour LT 10"> <mvt:comment> Estimation Logic: Ship Today </mvt:comment> <mvt:assign name="l.settings:senario:cutoff:hours" value="10 - l.settings:senario:date:hour" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="60 - l.settings:senario:date:min" /> <mvt:if expr="l.settings:senario:cutoff:minutes EQ 60"> <mvt:assign name="l.settings:senario:cutoff:hours" value="l.settings:senario:cutoff:hours + 1" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="0" /> </mvt:if> <h3>Order within <b>&mvt:senario:cutoff:hours; hours &mvt:senario:cutoff:minutes; minutes</b>, and it should ship today.</h3> <mvt:elseif expr="l.settings:senario:date:dayofweek_formatted CIN 'Monday, Tuesday, Wednesday' AND l.settings:senario:date:hour GE 10"> <mvt:comment> Estimation Logic: Ship Tomorrow </mvt:comment> <mvt:assign name="l.settings:senario:cutoff:hours" value="34 - l.settings:senario:date:hour" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="60 - l.settings:senario:date:min" /> <mvt:if expr="l.settings:senario:cutoff:minutes EQ 60"> <mvt:assign name="l.settings:senario:cutoff:hours" value="l.settings:senario:cutoff:hours + 1" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="0" /> </mvt:if> <mvt:comment><h3>Order within <b>&mvt:senario:cutoff:hours; hours &mvt:senario:cutoff:minutes; minutes</b> and it should ship tomorrow.</h3></mvt:comment> <h3>Order today, and it should ship tomorrow.</h3> <mvt:else> <mvt:comment> Estimation Logic: Ship Monday </mvt:comment> <h3>Order today, and it should ship on Monday.</h3> </mvt:if> <p> <small> <ul> <li>From Monday to Thursday, orders placed <i>before</i> 10am will <b>ship the same day</b></li> <li>From Monday to Wednesday, orders placed <i>after</i> 10am will <b>ship the next day</b></li> <li>All other others (Thursday after 10am to Monday before 10 am) will be <b>shipped on Monday</b>.</li> </ul> </small> </p> <br><hr><br> </mvt:foreach> <mvt:comment> Just a Debugging Helper </mvt:comment> <mvt:comment> <mvt:eval expr="glosub(miva_array_serialize(l.settings:senarios), ',', '<br>')" /> </mvt:comment>
 
View "Estimate Order Shipping Date"
<mvt:comment> Account for Daylight Savings time </mvt:comment> <mvt:if expr="s.tm_isdst"> <mvt:assign name="g.Timezone_Offset" value="'-5'" /> <mvt:assign name="g.Timezone_Abbreviation" value="'CDT'" /> <mvt:else> <mvt:assign name="g.Timezone_Offset" value="'-6'" /> <mvt:assign name="g.Timezone_Abbreviation" value="'CST'" /> </mvt:if> <mvt:if expr="s.tm_isdst"> <p>Daylight savings time <b>IS</b> in effect. Timezone Offset: &mvte:global:Timezone_Offset;</p> <mvt:else> <p>Daylight savings time is <b>NOT</b> in effect. Timezone Offset: &mvte:global:Timezone_Offset;</p> </mvt:if> <hr> <mvt:comment> Assign a Days-of-the-week text array for later </mvt:comment> <mvt:assign name="l.settings:daysofweek[1]" value="'Sunday'" /> <mvt:assign name="l.settings:daysofweek[2]" value="'Monday'" /> <mvt:assign name="l.settings:daysofweek[3]" value="'Tuesday'" /> <mvt:assign name="l.settings:daysofweek[4]" value="'Wednesday'" /> <mvt:assign name="l.settings:daysofweek[5]" value="'Thursday'" /> <mvt:assign name="l.settings:daysofweek[6]" value="'Friday'" /> <mvt:assign name="l.settings:daysofweek[7]" value="'Saturday'" /> <mvt:comment> Prepare days to simulate & test senarios </mvt:comment> <mvt:assign name="l.settings:senarios[1]:descrip" value="'Monday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[1]:timestamp" value="1470657660" /> <mvt:assign name="l.settings:senarios[2]:descrip" value="'Monday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[2]:timestamp" value="1470693660" /> <mvt:assign name="l.settings:senarios[3]:descrip" value="'Tuesday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[3]:timestamp" value="1470744060" /> <mvt:assign name="l.settings:senarios[4]:descrip" value="'Tuesday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[4]:timestamp" value="1470780060" /> <mvt:assign name="l.settings:senarios[5]:descrip" value="'Wednesday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[5]:timestamp" value="1470830460" /> <mvt:assign name="l.settings:senarios[6]:descrip" value="'Wednesday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[6]:timestamp" value="1470866460" /> <mvt:assign name="l.settings:senarios[7]:descrip" value="'Thursday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[7]:timestamp" value="1470916860" /> <mvt:assign name="l.settings:senarios[8]:descrip" value="'Thursday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[8]:timestamp" value="1470952860" /> <mvt:assign name="l.settings:senarios[9]:descrip" value="'Friday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[9]:timestamp" value="1471003260" /> <mvt:assign name="l.settings:senarios[10]:descrip" value="'Friday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[10]:timestamp" value="1471039260" /> <mvt:assign name="l.settings:senarios[11]:descrip" value="'Saturday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[11]:timestamp" value="1471089660" /> <mvt:assign name="l.settings:senarios[12]:descrip" value="'Saturday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[12]:timestamp" value="1471125660" /> <mvt:assign name="l.settings:senarios[13]:descrip" value="'Sunday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[13]:timestamp" value="1471089660" /> <mvt:assign name="l.settings:senarios[14]:descrip" value="'Sunday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[14]:timestamp" value="1471125660" /> <mvt:comment> Loop over each senario and test the estimation logic </mvt:comment> <mvt:foreach iterator="senario" array="senarios"> <mvt:comment> Assign some date-time variables that make it easier to read, write, and compare dates when we apply the estimation logic </mvt:comment> <mvt:assign name="l.settings:senario:date:year" value="time_t_year( l.settings:senario:timestamp, g.Timezone_Offset )" /> <mvt:assign name="l.settings:senario:date:month" value="padl(time_t_month( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:day" value="padl(time_t_dayofmonth( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:dayofweek" value="time_t_dayofweek( l.settings:senario:timestamp, g.Timezone_Offset )" /> <mvt:assign name="l.settings:senario:date:dayofweek_formatted" value="l.settings:daysofweek[time_t_dayofweek( l.settings:senario:timestamp, g.Timezone_Offset )]" /> <mvt:assign name="l.settings:senario:date:24hour" value="padl(time_t_hour( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:min" value="padl(time_t_min( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:sec" value="padl(time_t_sec( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:formatted" value="l.settings:senario:date:year $ '-' $ l.settings:senario:date:month $ '-' $ l.settings:senario:date:day $ ' ' $ l.settings:senario:date:24hour $ ':' $ l.settings:senario:date:min $ ':' $ l.settings:senario:date:sec $ ' ' $ g.Timezone_Offset" /> <h2 style='color: gray'> Senario #<mvt:eval expr="POS1"/>: &mvt:senario:descrip; <small>&mvt:senario:date:formatted;</small> </h2> <mvt:if expr="l.settings:senario:date:dayofweek_formatted CIN 'Monday, Tuesday, Wednesday, Thursday' AND l.settings:senario:date:24hour LT 10"> <mvt:comment> Estimation Logic: Ship Today </mvt:comment> <mvt:assign name="l.settings:senario:cutoff:hours" value="10 - l.settings:senario:date:24hour" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="60 - l.settings:senario:date:min" /> <mvt:if expr="l.settings:senario:cutoff:minutes EQ 60"> <mvt:assign name="l.settings:senario:cutoff:hours" value="l.settings:senario:cutoff:hours + 1" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="0" /> </mvt:if> <h3>Order within <b>&mvt:senario:cutoff:hours; hours &mvt:senario:cutoff:minutes; minutes</b>, and it should ship today.</h3> <mvt:elseif expr="l.settings:senario:date:dayofweek_formatted CIN 'Monday, Tuesday, Wednesday' AND l.settings:senario:date:24hour GE 10"> <mvt:comment> Estimation Logic: Ship Tomorrow </mvt:comment> <mvt:assign name="l.settings:senario:cutoff:hours" value="34 - l.settings:senario:date:24hour" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="60 - l.settings:senario:date:min" /> <mvt:if expr="l.settings:senario:cutoff:minutes EQ 60"> <mvt:assign name="l.settings:senario:cutoff:hours" value="l.settings:senario:cutoff:hours + 1" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="0" /> </mvt:if> <mvt:comment><h3>Order within <b>&mvt:senario:cutoff:hours; hours &mvt:senario:cutoff:minutes; minutes</b> and it should ship tomorrow.</h3></mvt:comment> <h3>Order today, and it should ship tomorrow.</h3> <mvt:else> <mvt:comment> Estimation Logic: Ship Monday </mvt:comment> <h3>Order today, and it should ship on Monday.</h3> </mvt:if> <p> <small> <ul> <li>From Monday to Thursday, orders placed <i>before</i> 10am will ship the same day.</li> <li>From Monday to Wednesday, orders placed <i>after</i> 10am will ship the next day.</li> <li>All other others (Thursday after 10am to Monday before 10 am) will be shipped on Monday.</li> </ul> </small> </p> <br><br><hr><br><br> </mvt:foreach> <mvt:comment> Just a Debugging Helper </mvt:comment> <mvt:comment><mvt:eval expr="glosub(miva_array_serialize(l.settings:senarios), ',', '<br>')" /></mvt:comment>
 
View "Estimate Order Shipping Date"
<mvt:comment> Account for Daylight Savings time </mvt:comment> <mvt:if expr="s.tm_isdst"> <mvt:assign name="g.Timezone_Offset" value="'-5'" /> <mvt:assign name="g.Timezone_Abbreviation" value="'CDT'" /> <mvt:else> <mvt:assign name="g.Timezone_Offset" value="'-6'" /> <mvt:assign name="g.Timezone_Abbreviation" value="'CST'" /> </mvt:if> <mvt:if expr="s.tm_isdst"> <p>Daylight savings time <b>IS</b> in effect. Timezone Offset: &mvte:global:Timezone_Offset;</p> <mvt:else> <p>Daylight savings time is <b>NOT</b> in effect. Timezone Offset: &mvte:global:Timezone_Offset;</p> </mvt:if> <hr> <mvt:comment> Assign a Days-of-the-week text array for later </mvt:comment> <mvt:assign name="l.settings:daysofweek[1]" value="'Sunday'" /> <mvt:assign name="l.settings:daysofweek[2]" value="'Monday'" /> <mvt:assign name="l.settings:daysofweek[3]" value="'Tuesday'" /> <mvt:assign name="l.settings:daysofweek[4]" value="'Wednesday'" /> <mvt:assign name="l.settings:daysofweek[5]" value="'Thursday'" /> <mvt:assign name="l.settings:daysofweek[6]" value="'Friday'" /> <mvt:assign name="l.settings:daysofweek[7]" value="'Saturday'" /> <mvt:comment> Prepare days to simulate & test senarios </mvt:comment> <mvt:assign name="l.settings:senarios[1]:descrip" value="'Monday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[1]:timestamp" value="1470657660" /> <mvt:assign name="l.settings:senarios[2]:descrip" value="'Monday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[2]:timestamp" value="1470693660" /> <mvt:assign name="l.settings:senarios[3]:descrip" value="'Tuesday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[3]:timestamp" value="1470744060" /> <mvt:assign name="l.settings:senarios[4]:descrip" value="'Tuesday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[4]:timestamp" value="1470780060" /> <mvt:assign name="l.settings:senarios[5]:descrip" value="'Wednesday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[5]:timestamp" value="1470830460" /> <mvt:assign name="l.settings:senarios[6]:descrip" value="'Wednesday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[6]:timestamp" value="1470866460" /> <mvt:assign name="l.settings:senarios[7]:descrip" value="'Thursday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[7]:timestamp" value="1470916860" /> <mvt:assign name="l.settings:senarios[8]:descrip" value="'Thursday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[8]:timestamp" value="1470952860" /> <mvt:assign name="l.settings:senarios[9]:descrip" value="'Friday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[9]:timestamp" value="1471003260" /> <mvt:assign name="l.settings:senarios[10]:descrip" value="'Friday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[10]:timestamp" value="1471039260" /> <mvt:assign name="l.settings:senarios[11]:descrip" value="'Saturday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[11]:timestamp" value="1471089660" /> <mvt:assign name="l.settings:senarios[12]:descrip" value="'Saturday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[12]:timestamp" value="1471125660" /> <mvt:assign name="l.settings:senarios[13]:descrip" value="'Sunday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[13]:timestamp" value="1471089660" /> <mvt:assign name="l.settings:senarios[14]:descrip" value="'Sunday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[14]:timestamp" value="1471125660" /> <mvt:comment> Loop over each senario and test the estimation logic </mvt:comment> <mvt:foreach iterator="senario" array="senarios"> <mvt:comment> Assign some date-time variables that make it easier to read, write, and compare dates when we apply the estimation logic </mvt:comment> <mvt:assign name="l.settings:senario:date:year" value="time_t_year( l.settings:senario:timestamp, g.Timezone_Offset )" /> <mvt:assign name="l.settings:senario:date:month" value="padl(time_t_month( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:day" value="padl(time_t_dayofmonth( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:dayofweek" value="time_t_dayofweek( l.settings:senario:timestamp, g.Timezone_Offset )" /> <mvt:assign name="l.settings:senario:date:dayofweek_formatted" value="l.settings:daysofweek[time_t_dayofweek( l.settings:senario:timestamp, g.Timezone_Offset )]" /> <mvt:assign name="l.settings:senario:date:24hour" value="padl(time_t_hour( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:min" value="padl(time_t_min( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:sec" value="padl(time_t_sec( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:formatted" value="l.settings:senario:date:year $ '-' $ l.settings:senario:date:month $ '-' $ l.settings:senario:date:day $ ' ' $ l.settings:senario:date:24hour $ ':' $ l.settings:senario:date:min $ ':' $ l.settings:senario:date:sec $ ' ' $ g.Timezone_Offset" /> <h2 style='color: gray'> Senario #<mvt:eval expr="POS1"/>: &mvt:senario:descrip; <small>&mvt:senario:date:formatted;</small> </h2> <mvt:if expr="l.settings:senario:date:dayofweek_formatted CIN 'Monday, Tuesday, Wednesday, Thursday' AND l.settings:senario:date:24hour LT 10"> <mvt:comment> Estimation Logic: Ship Today </mvt:comment> <mvt:assign name="l.settings:senario:cutoff:hours" value="10 - l.settings:senario:date:24hour" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="60 - l.settings:senario:date:min" /> <mvt:if expr="l.settings:senario:cutoff:minutes EQ 60"> <mvt:assign name="l.settings:senario:cutoff:hours" value="l.settings:senario:cutoff:hours + 1" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="0" /> </mvt:if> <h3>Order within <b>&mvt:senario:cutoff:hours; hours &mvt:senario:cutoff:minutes; minutes</b>, and it should ship today.</h3> <mvt:elseif expr="l.settings:senario:date:dayofweek_formatted CIN 'Monday, Tuesday, Wednesday' AND l.settings:senario:date:24hour GE 10"> <mvt:comment> Estimation Logic: Ship Tomorrow </mvt:comment> <mvt:assign name="l.settings:senario:cutoff:hours" value="34 - l.settings:senario:date:24hour" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="60 - l.settings:senario:date:min" /> <mvt:if expr="l.settings:senario:cutoff:minutes EQ 60"> <mvt:assign name="l.settings:senario:cutoff:hours" value="l.settings:senario:cutoff:hours + 1" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="0" /> </mvt:if> <mvt:comment><h3>Order within <b>&mvt:senario:cutoff:hours; hours &mvt:senario:cutoff:minutes; minutes</b> and it should ship tomorrow.</h3></mvt:comment> <h3>Order today, and it should ship tomorrow.</h3> <mvt:else> <mvt:comment> Estimation Logic: Ship Monday </mvt:comment> <h3>Order today, and it should ship on Monday.</h3> </mvt:if> <p> <small> <ul> <li>From Monday to Thursday, orders placed <i>before</i> 10am will ship the same day.</li> <li>From Monday to Wednesday, orders placed <i>after</i> 10am will ship the next day.</li> <li>All other others (Thursday after 10am to Monday before 10 am) will be shipped on Monday.</li> </ul> </small> </p> <br><br><hr><br><br> </mvt:foreach> <mvt:comment> Just a Debugging Helper </mvt:comment> <mvt:eval expr="glosub(miva_array_serialize(l.settings:senarios), ',', '<br>')" />
 
View "Estimate Order Shipping Date"
<mvt:comment> Account for Daylight Savings time </mvt:comment> <mvt:if expr="s.tm_isdst"> <mvt:assign name="g.Timezone_Offset" value="'-5'" /> <mvt:assign name="g.Timezone_Abbreviation" value="'CDT'" /> <mvt:else> <mvt:assign name="g.Timezone_Offset" value="'-6'" /> <mvt:assign name="g.Timezone_Abbreviation" value="'CST'" /> </mvt:if> <mvt:if expr="s.tm_isdst"> <p>Daylight savings time <b>IS</b> in effect. Timezone Offset: &mvte:global:Timezone_Offset;</p> <mvt:else> <p>Daylight savings time is <b>NOT</b> in effect. Timezone Offset: &mvte:global:Timezone_Offset;</p> </mvt:if> <hr> <mvt:comment> Assign a Days-of-the-week text array for later </mvt:comment> <mvt:assign name="l.settings:daysofweek[1]" value="'Sunday'" /> <mvt:assign name="l.settings:daysofweek[2]" value="'Monday'" /> <mvt:assign name="l.settings:daysofweek[3]" value="'Tuesday'" /> <mvt:assign name="l.settings:daysofweek[4]" value="'Wednesday'" /> <mvt:assign name="l.settings:daysofweek[5]" value="'Thursday'" /> <mvt:assign name="l.settings:daysofweek[6]" value="'Friday'" /> <mvt:assign name="l.settings:daysofweek[7]" value="'Saturday'" /> <mvt:comment> Prepare days to simulate & test senarios </mvt:comment> <mvt:assign name="l.settings:senarios[1]:descrip" value="'Monday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[1]:timestamp" value="1470657660" /> <mvt:assign name="l.settings:senarios[2]:descrip" value="'Monday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[2]:timestamp" value="1470693660" /> <mvt:assign name="l.settings:senarios[3]:descrip" value="'Tuesday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[3]:timestamp" value="1470744060" /> <mvt:assign name="l.settings:senarios[4]:descrip" value="'Tuesday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[4]:timestamp" value="1470780060" /> <mvt:assign name="l.settings:senarios[5]:descrip" value="'Wednesday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[5]:timestamp" value="1470830460" /> <mvt:assign name="l.settings:senarios[6]:descrip" value="'Wednesday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[6]:timestamp" value="1470866460" /> <mvt:assign name="l.settings:senarios[7]:descrip" value="'Thursday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[7]:timestamp" value="1470916860" /> <mvt:assign name="l.settings:senarios[8]:descrip" value="'Thursday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[8]:timestamp" value="1470952860" /> <mvt:assign name="l.settings:senarios[9]:descrip" value="'Friday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[9]:timestamp" value="1471003260" /> <mvt:assign name="l.settings:senarios[10]:descrip" value="'Friday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[10]:timestamp" value="1471039260" /> <mvt:assign name="l.settings:senarios[11]:descrip" value="'Saturday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[11]:timestamp" value="1471089660" /> <mvt:assign name="l.settings:senarios[12]:descrip" value="'Saturday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[12]:timestamp" value="1471125660" /> <mvt:assign name="l.settings:senarios[13]:descrip" value="'Sunday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[13]:timestamp" value="1471089660" /> <mvt:assign name="l.settings:senarios[14]:descrip" value="'Sunday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[14]:timestamp" value="1471125660" /> <mvt:comment> Loop over each senario and test the estimation logic </mvt:comment> <mvt:foreach iterator="senario" array="senarios"> <mvt:comment> Assign some date-time variables that make it easier to read, write, and compare dates when we apply the estimation logic </mvt:comment> <mvt:assign name="l.settings:senario:date:year" value="time_t_year( l.settings:senario:timestamp, g.Timezone_Offset )" /> <mvt:assign name="l.settings:senario:date:month" value="padl(time_t_month( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:day" value="padl(time_t_dayofmonth( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:dayofweek" value="time_t_dayofweek( l.settings:senario:timestamp, g.Timezone_Offset )" /> <mvt:assign name="l.settings:senario:date:dayofweek_formatted" value="l.settings:daysofweek[time_t_dayofweek( l.settings:senario:timestamp, g.Timezone_Offset )]" /> <mvt:assign name="l.settings:senario:date:24hour" value="padl(time_t_hour( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:min" value="padl(time_t_min( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:sec" value="padl(time_t_sec( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:formatted" value="l.settings:senario:date:year $ '-' $ l.settings:senario:date:month $ '-' $ l.settings:senario:date:day $ ' ' $ l.settings:senario:date:24hour $ ':' $ l.settings:senario:date:min $ ':' $ l.settings:senario:date:sec $ ' ' $ g.Timezone_Offset" /> <h2 style='color: gray'> Senario #<mvt:eval expr="POS1"/>: &mvt:senario:descrip; <small>&mvt:senario:date:formatted;</small> </h2> <mvt:if expr="l.settings:senario:date:dayofweek_formatted CIN 'Monday, Tuesday, Wednesday, Thursday' AND l.settings:senario:date:24hour LT 10"> <mvt:comment> Estimation Logic: Ship Today </mvt:comment> <mvt:assign name="l.settings:senario:cutoff:hours" value="10 - l.settings:senario:date:24hour" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="60 - l.settings:senario:date:min" /> <mvt:if expr="l.settings:senario:cutoff:minutes EQ 60"> <mvt:assign name="l.settings:senario:cutoff:hours" value="l.settings:senario:cutoff:hours + 1" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="0" /> </mvt:if> <h3>Order within <b>&mvt:senario:cutoff:hours; hours &mvt:senario:cutoff:minutes; minutes</b>, and it should ship today.</h3> <mvt:elseif expr="l.settings:senario:date:dayofweek_formatted CIN 'Monday, Tuesday, Wednesday' AND l.settings:senario:date:24hour GE 10"> <mvt:comment> Estimation Logic: Ship Tomorrow </mvt:comment> <mvt:assign name="l.settings:senario:cutoff:hours" value="34 - l.settings:senario:date:24hour" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="60 - l.settings:senario:date:min" /> <mvt:if expr="l.settings:senario:cutoff:minutes EQ 60"> <mvt:assign name="l.settings:senario:cutoff:hours" value="l.settings:senario:cutoff:hours + 1" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="0" /> </mvt:if> <mvt:comment><h3>Order within <b>&mvt:senario:cutoff:hours; hours &mvt:senario:cutoff:minutes; minutes</b> and it should ship tomorrow.</h3></mvt:comment> <h3>Order today, and it should ship tomorrow.</h3> <mvt:else> <mvt:comment> Estimation Logic: Ship Monday </mvt:comment> <h3>Order today, and it should ship on Monday.</h3> </mvt:if> <p> <small> <ul> <li>From Monday to Thursday, orders placed <i>before</i> 10am will <b>ship the same day</b></li> <li>From Monday to Wednesday, orders placed <i>after</i> 10am will <b>ship the next day</b></li> <li>All other others (Thursday after 10am to Monday before 10 am) will be <b>shipped on Monday</b>.</li> </ul> </small> </p> <br><hr><br> </mvt:foreach> <mvt:comment> Just a Debugging Helper </mvt:comment> <mvt:eval expr="glosub(miva_array_serialize(l.settings:senarios), ',', '<br>')" />
 
View "Estimate Order Shipping Date"
<mvt:if expr="s.tm_isdst"> <mvt:assign name="g.Timezone_Offset" value="'-5'" /> <mvt:assign name="g.Timezone_Abbreviation" value="'CDT'" /> <mvt:else> <mvt:assign name="g.Timezone_Offset" value="'-6'" /> <mvt:assign name="g.Timezone_Abbreviation" value="'CST'" /> </mvt:if> <mvt:if expr="s.tm_isdst"> <p>Daylight savings time <b>IS</b> in effect. Timezone Offset: &mvte:global:Timezone_Offset;</p> <mvt:else> <p>Daylight savings time is <b>NOT</b> in effect. Timezone Offset: &mvte:global:Timezone_Offset;</p> </mvt:if> <mvt:assign name="l.settings:daysofweek[1]" value="'Sunday'" /> <mvt:assign name="l.settings:daysofweek[2]" value="'Monday'" /> <mvt:assign name="l.settings:daysofweek[3]" value="'Tuesday'" /> <mvt:assign name="l.settings:daysofweek[4]" value="'Wednesday'" /> <mvt:assign name="l.settings:daysofweek[5]" value="'Thursday'" /> <mvt:assign name="l.settings:daysofweek[6]" value="'Friday'" /> <mvt:assign name="l.settings:daysofweek[7]" value="'Saturday'" /> <hr> <mvt:assign name="l.settings:senarios[1]:descrip" value="'Monday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[1]:timestamp" value="1470657660" /> <mvt:assign name="l.settings:senarios[2]:descrip" value="'Monday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[2]:timestamp" value="1470693660" /> <mvt:assign name="l.settings:senarios[3]:descrip" value="'Tuesday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[3]:timestamp" value="1470744060" /> <mvt:assign name="l.settings:senarios[4]:descrip" value="'Tuesday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[4]:timestamp" value="1470780060" /> <mvt:assign name="l.settings:senarios[5]:descrip" value="'Wednesday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[5]:timestamp" value="1470830460" /> <mvt:assign name="l.settings:senarios[6]:descrip" value="'Wednesday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[6]:timestamp" value="1470866460" /> <mvt:assign name="l.settings:senarios[7]:descrip" value="'Thursday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[7]:timestamp" value="1470916860" /> <mvt:assign name="l.settings:senarios[8]:descrip" value="'Thursday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[8]:timestamp" value="1470952860" /> <mvt:assign name="l.settings:senarios[9]:descrip" value="'Friday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[9]:timestamp" value="1471003260" /> <mvt:assign name="l.settings:senarios[10]:descrip" value="'Friday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[10]:timestamp" value="1471039260" /> <mvt:assign name="l.settings:senarios[11]:descrip" value="'Saturday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[11]:timestamp" value="1471089660" /> <mvt:assign name="l.settings:senarios[12]:descrip" value="'Saturday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[12]:timestamp" value="1471125660" /> <mvt:assign name="l.settings:senarios[13]:descrip" value="'Sunday - before 10am CT'" /> <mvt:assign name="l.settings:senarios[13]:timestamp" value="1471089660" /> <mvt:assign name="l.settings:senarios[14]:descrip" value="'Sunday - after 10am CT'" /> <mvt:assign name="l.settings:senarios[14]:timestamp" value="1471125660" /> <mvt:foreach iterator="senario" array="senarios"> <mvt:assign name="l.settings:senario:date:year" value="time_t_year( l.settings:senario:timestamp, g.Timezone_Offset )" /> <mvt:assign name="l.settings:senario:date:month" value="padl(time_t_month( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:day" value="padl(time_t_dayofmonth( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:dayofweek" value="time_t_dayofweek( l.settings:senario:timestamp, g.Timezone_Offset )" /> <mvt:assign name="l.settings:senario:date:dayofweek_formatted" value="l.settings:daysofweek[time_t_dayofweek( l.settings:senario:timestamp, g.Timezone_Offset )]" /> <mvt:assign name="l.settings:senario:date:24hour" value="padl(time_t_hour( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:min" value="padl(time_t_min( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:sec" value="padl(time_t_sec( l.settings:senario:timestamp, g.Timezone_Offset ), 2, 0)" /> <mvt:assign name="l.settings:senario:date:formatted" value="l.settings:senario:date:year $ '-' $ l.settings:senario:date:month $ '-' $ l.settings:senario:date:day $ ' ' $ l.settings:senario:date:24hour $ ':' $ l.settings:senario:date:min $ ':' $ l.settings:senario:date:sec $ ' ' $ g.Timezone_Offset" /> <h2 style="color: gray;">Senario #<mvt:eval expr="POS1"/>: &mvt:senario:descrip; <small>&mvt:senario:date:formatted;</small></h2> <mvt:if expr="l.settings:senario:date:dayofweek_formatted CIN 'Monday, Tuesday, Wednesday, Thursday' AND l.settings:senario:date:24hour LT 10"> <mvt:comment> Ship Today </mvt:comment> <mvt:assign name="l.settings:senario:cutoff:hours" value="10 - l.settings:senario:date:24hour" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="60 - l.settings:senario:date:min" /> <mvt:if expr="l.settings:senario:cutoff:minutes EQ 60"> <mvt:assign name="l.settings:senario:cutoff:hours" value="l.settings:senario:cutoff:hours + 1" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="0" /> </mvt:if> <h3>Order within <b>&mvt:senario:cutoff:hours; hours &mvt:senario:cutoff:minutes; minutes</b> and it should ship today.</h3> <mvt:elseif expr="l.settings:senario:date:dayofweek_formatted CIN 'Monday, Tuesday, Wednesday' AND l.settings:senario:date:24hour GE 10"> <mvt:comment> | Ship Tomorrow </mvt:comment> <mvt:assign name="l.settings:senario:cutoff:hours" value="34 - l.settings:senario:date:24hour" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="60 - l.settings:senario:date:min" /> <mvt:if expr="l.settings:senario:cutoff:minutes EQ 60"> <mvt:assign name="l.settings:senario:cutoff:hours" value="l.settings:senario:cutoff:hours + 1" /> <mvt:assign name="l.settings:senario:cutoff:minutes" value="0" /> </mvt:if> <mvt:comment><h3>Order within <b>&mvt:senario:cutoff:hours; hours &mvt:senario:cutoff:minutes; minutes</b> and it should ship tomorrow.</h3></mvt:comment> <h3>Order today and it should ship tomorrow.</h3> <mvt:else> <mvt:comment> Ship Monday </mvt:comment> <h3>Order today and it should ship monday.</h3> </mvt:if> <p> <small> <ul> <li>From Monday to Thursday, orders placed <i>before</i> 10am will <b>ship the same day</b></li> <li>From Monday to Wednesday, orders placed <i>after</i> 10am will <b>ship the next day</b></li> <li>All other others (Thursday after 10am to Monday before 10 am) will be <b>shipped on Monday</b>.</li> </ul> </small> </p> <br><hr><br> </mvt:foreach> <mvt:eval expr="glosub(miva_array_serialize(l.settings:senarios), ',', '<br>')" />
 

String splitting

Methods for splitting strings to arrays
Created: 1465312162
View "String splitting"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <mvt:assign name="g.startTime" value="s.dyn_tm_usec" /> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> </br>Completed in <mvt:eval expr="s.dyn_tm_usec - g.startTime" /> milliseconds. <hr> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.startTime" value="s.dyn_tm_usec" /> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> </br>Completed in <mvt:eval expr="s.dyn_tm_usec - g.startTime" /> milliseconds. <hr> <h3>Get Token</h3> <p>Doesn't support multi-character splitting, a little harder to read in my opinion</p> <mvt:assign name="g.startTime" value="s.dyn_tm_usec" /> <mvt:assign name="g.nl" value="'|'" /> <mvt:assign name="l.count" value="1" /> <mvt:assign name="l.token" value="gettoken(g.string, g.nl , l.count)" /> <mvt:while expr="NOT ISNULL l.token"> <mvt:assign name="l.array_length" value="miva_array_insert( l.settings:my_array, l.token, -1 )" /> <mvt:assign name="l.count" value="l.count + 1" /> <mvt:assign name="l.token" value="gettoken(g.string, g.nl , l.count)" /> </mvt:while> <mvt:foreach iterator="row" array="my_array"> &mvt:row;</br> </mvt:foreach> </br>Completed in <mvt:eval expr="s.dyn_tm_usec - g.startTime" /> milliseconds. <hr> <h3>New MivaScript Split String</h3> <p>Probably easiest to use</p> <mvt:assign name="g.startTime" value="s.dyn_tm_usec" /> <mvt:assign name="g.array" value="miva_splitstring(g.string, '|', g.array, NULL)" /> <mvt:foreach iterator="row" array="my_array"> &mvt:row;</br> </mvt:foreach> </br>Completed in <mvt:eval expr="s.dyn_tm_usec - g.startTime" /> milliseconds.
 

string scrubber

Delete all characters from string except characters that you define.
Created: 1462377050
View "string scrubber"
<mvt:comment>define your allowed characters</mvt:comment> <mvt:assign name="g.allowed" value="'abcdefghijklmnopqrstuvwxyz'" /> <mvt:comment>the string to scrub</mvt:comment> <mvt:assign name="g.string" value="'Test123-!hello'" /> <mvt:assign name="g.counter" value="1" /> <mvt:comment>for each letter in string</mvt:comment> <mvt:while expr="g.counter LE len(g.string)"> <mvt:comment>if this letter is contained in allowed, increment</mvt:comment> <mvt:if expr="substring(g.string, g.counter, 1) CIN g.allowed"> <mvt:assign name="g.counter" value="g.counter+1" /> <mvt:else> <mvt:comment>if letter is not in allowed, delete it, we don't need to increment because we just made the string 1 shorter</mvt:comment> <mvt:assign name="g.string" value="substring(g.string, 1, g.counter-1 ) $ substring(g.string, g.counter+1, (len(g.string)+1)-g.counter)" /> </mvt:if> </mvt:while> &mvt:global:string;
 

Basket #16315

Methods for splitting strings to arrays
Created: 1461119732
View "Basket #16315"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

Basket #15788

Created: 1460056611
View "Basket #15788"
<mvt:comment><!-- Days --></mvt:comment> <mvt:assign name="g.timezone_offset" value="'local'" /> <mvt:assign name="l.settings:days[1]:name" value="'Sunday'" /> <mvt:assign name="l.settings:days[1]:time" value="1431284400" /> <mvt:assign name="l.settings:days[2]:name" value="'Monday'" /> <mvt:assign name="l.settings:days[2]:time" value="1431370800" /> <mvt:assign name="l.settings:days[3]:name" value="'Tuesday'" /> <mvt:assign name="l.settings:days[3]:time" value="1431457200" /> <mvt:assign name="l.settings:days[4]:name" value="'Wednesday'" /> <mvt:assign name="l.settings:days[4]:time" value="1431543600" /> <mvt:assign name="l.settings:days[5]:name" value="'Thursday'" /> <mvt:assign name="l.settings:days[5]:time" value="1431630000" /> <mvt:assign name="l.settings:days[6]:name" value="'Friday'" /> <mvt:assign name="l.settings:days[6]:time" value="1431716400" /> <mvt:assign name="l.settings:days[7]:name" value="'Saturday'" /> <mvt:assign name="l.settings:days[7]:time" value="1431802800" /> <mvt:comment><!-- Shipping Methods --></mvt:comment> <mvt:assign name="l.settings:shippingmethods[1]:name" value="'Next Day'" /> <mvt:assign name="l.settings:shippingmethods[1]:delivery:min" value="1" /> <mvt:assign name="l.settings:shippingmethods[1]:delivery:max" value="1" /> <mvt:assign name="l.settings:shippingmethods[2]:name" value="'2nd Day'" /> <mvt:assign name="l.settings:shippingmethods[2]:delivery:min" value="2" /> <mvt:assign name="l.settings:shippingmethods[2]:delivery:max" value="2" /> <mvt:assign name="l.settings:shippingmethods[3]:name" value="'Ground'" /> <mvt:assign name="l.settings:shippingmethods[3]:delivery:min" value="7" /> <mvt:assign name="l.settings:shippingmethods[3]:delivery:max" value="10" /> <mvt:foreach iterator="day" array="days"> <mvt:assign name="l.settings:day:month" value="time_t_month( l.settings:day:time, g.timezone_offset )" /> <mvt:assign name="l.settings:day:day" value="time_t_dayofmonth( l.settings:day:time, g.timezone_offset )" /> <mvt:assign name="l.settings:day:formatted_date" value="l.settings:day:month $ '/' $ l.settings:day:day" /> <h2>Order Placed: &mvt:day:name; @ &mvt:day:formatted_date;</h2> <mvt:foreach iterator="method" array="shippingmethods"> <mvt:assign name="l.settings:method:elapsed:days" value="0" /> <mvt:assign name="l.settings:method:shipping:days" value="0" /> <mvt:assign name="l.settings:method:processing:days" value="4" /> <mvt:assign name="l.settings:method:delivered" value="''" /> <mvt:assign name="l.settings:method:estimated:min" value="''" /> <mvt:assign name="l.settings:method:estimated:max" value="''" /> <mvt:while expr="ISNULL l.settings:method:delivered"> <mvt:assign name="l.settings:method:counter" value="l.settings:method:counter + 1" /> <mvt:assign name="l.settings:method:elapsed:days" value="l.settings:method:elapsed:days + 1" /> <mvt:assign name="l.settings:method:elapsed:duration" value="60 * 60 * 24 * l.settings:method:elapsed:days" /> <mvt:assign name="l.settings:method:elapsed:future_time" value="l.settings:day:time + l.settings:method:elapsed:duration"/> <mvt:assign name="l.settings:method:estimated:month" value="time_t_month( l.settings:method:elapsed:future_time, g.timezone_offset )" /> <mvt:assign name="l.settings:method:estimated:day" value="time_t_dayofmonth( l.settings:method:elapsed:future_time, g.timezone_offset )" /> <mvt:assign name="l.settings:method:estimated:dayofweek" value="time_t_dayofweek( l.settings:method:elapsed:future_time, g.timezone_offset )" /> <mvt:if expr="l.settings:method:estimated:dayofweek GT 1 AND l.settings:method:estimated:dayofweek LT 7"> <mvt:if expr="l.settings:method:processing:days EQ 0"> </mvt:if> <mvt:assign name="l.settings:method:processing:days" value="l.settings:method:processing:days + 1" /> </mvt:if> <mvt:if expr="l.settings:method:processing:days GT 1 AND l.settings:method:estimated:dayofweek GT 1"> <mvt:assign name="l.settings:method:shipping:days" value="l.settings:method:shipping:days + 1" /> </mvt:if> <mvt:if expr="ISNULL l.settings:method:estimated:min AND l.settings:method:shipping:days GE l.settings:method:delivery:min AND (l.settings:method:estimated:dayofweek GT 1 AND l.settings:method:estimated:dayofweek LT 7)"> <mvt:assign name="l.settings:method:estimated:min" value="l.settings:method:estimated:month $ '/' $ l.settings:method:estimated:day" /> <mvt:assign name="l.settings:method:estimated:min_day" value="l.settings:days[l.settings:method:estimated:dayofweek]:name" /> </mvt:if> <mvt:if expr="ISNULL l.settings:method:estimated:max AND l.settings:method:shipping:days GE l.settings:method:delivery:max AND (l.settings:method:estimated:dayofweek GT 1 AND l.settings:method:estimated:dayofweek LT 7)"> <mvt:assign name="l.settings:method:estimated:max" value="l.settings:method:estimated:month $ '/' $ l.settings:method:estimated:day" /> <mvt:assign name="l.settings:method:estimated:max_day" value="l.settings:days[l.settings:method:estimated:dayofweek]:name" /> <mvt:assign name="l.settings:method:delivered" value="1" /> </mvt:if> </mvt:while> </mvt:foreach> <mvt:foreach iterator="method" array="shippingmethods"> <p> <b>&mvt:method:name;</b><br> Estimated Delivery: &mvt:method:delivery:min;<mvt:if expr="l.settings:method:delivery:min NE l.settings:method:delivery:max">-&mvt:method:delivery:max;</mvt:if> business day(s)<br> Should Arrive: &mvt:method:estimated:min_day; &mvt:method:estimated:min;<mvt:if expr="l.settings:method:delivery:min NE l.settings:method:delivery:max"> to &mvt:method:estimated:max_day; &mvt:method:estimated:max;</mvt:if> </p> </mvt:foreach> <hr> </mvt:foreach>
 

Snippet: 1460047868 - v1

Methods for splitting strings to arrays
Created: 1460047868
View "Snippet: 1460047868 - v1"
<mvt:assign name="g.string" value="'one|||two|||three|||four|||five|||six'" /> <h3>Split String mvt:do</h3> <mvt:assign name="g.startTime" value="s.dyn_tm_usec" /> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|||', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> </br>Completed in <mvt:eval expr="s.dyn_tm_usec - g.startTime" /> milliseconds. <hr> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.startTime" value="s.dyn_tm_usec" /> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|||',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> </br>Completed in <mvt:eval expr="s.dyn_tm_usec - g.startTime" /> milliseconds. <hr> <h3>Get Token</h3> <p>Doesn't support multi-character splitting, a little harder to read in my opinion</p> <mvt:assign name="g.startTime" value="s.dyn_tm_usec" /> <mvt:assign name="g.nl" value="'|||'" /> <mvt:assign name="l.count" value="1" /> <mvt:assign name="l.token" value="gettoken(g.string, g.nl , l.count)" /> <mvt:while expr="NOT ISNULL l.token"> <mvt:assign name="l.array_length" value="miva_array_insert( l.settings:my_array, l.token, -1 )" /> <mvt:assign name="l.count" value="l.count + 1" /> <mvt:assign name="l.token" value="gettoken(g.string, g.nl , l.count)" /> </mvt:while> <mvt:foreach iterator="row" array="my_array"> &mvt:row;</br> </mvt:foreach> </br>Completed in <mvt:eval expr="s.dyn_tm_usec - g.startTime" /> milliseconds.
 

String splitting

Methods for splitting strings to arrays
Created: 1460047755
View "String splitting"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <mvt:assign name="g.startTime" value="s.dyn_tm_usec" /> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> </br>Completed in <mvt:eval expr="s.dyn_tm_usec - g.startTime" /> milliseconds. <hr> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.startTime" value="s.dyn_tm_usec" /> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> </br>Completed in <mvt:eval expr="s.dyn_tm_usec - g.startTime" /> milliseconds. <hr> <h3>Get Token</h3> <p>Doesn't support multi-character splitting, a little harder to read in my opinion</p> <mvt:assign name="g.startTime" value="s.dyn_tm_usec" /> <mvt:assign name="g.nl" value="'|'" /> <mvt:assign name="l.count" value="1" /> <mvt:assign name="l.token" value="gettoken(g.string, g.nl , l.count)" /> <mvt:while expr="NOT ISNULL l.token"> <mvt:assign name="l.array_length" value="miva_array_insert( l.settings:my_array, l.token, -1 )" /> <mvt:assign name="l.count" value="l.count + 1" /> <mvt:assign name="l.token" value="gettoken(g.string, g.nl , l.count)" /> </mvt:while> <mvt:foreach iterator="row" array="my_array"> &mvt:row;</br> </mvt:foreach> </br>Completed in <mvt:eval expr="s.dyn_tm_usec - g.startTime" /> milliseconds.
 

String splitting

Methods for splitting strings to arrays
Created: 1460041211
View "String splitting"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <hr> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach> <hr> <h3>Get Token</h3> <p>Doesn't support multi-character splitting, a little harder to read in my opinion</p> <mvt:assign name="g.nl" value="'|'" /> <mvt:assign name="l.count" value="1" /> <mvt:assign name="l.token" value="gettoken(g.string, g.nl , l.count)" /> <mvt:while expr="NOT ISNULL l.token"> <mvt:assign name="l.array_length" value="miva_array_insert( l.settings:my_array, l.token, -1 )" /> <mvt:assign name="l.count" value="l.count + 1" /> <mvt:assign name="l.token" value="gettoken(g.string, g.nl , l.count)" /> </mvt:while> <mvt:foreach iterator="row" array="my_array"> &mvt:row;</br> </mvt:foreach>
 

String splitting

Methods for splitting strings to arrays
Created: 1460040170
View "String splitting"
<mvt:assign name="g.string" value="'one|two|three|four|five|six'" /> <h3>Split String mvt:do</h3> <p>Does not inherently support multi-character splitting, you'd have to perform a glosub first (see next example)</p> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, '|', g.splitString )" /> <!-- @@ &mvt:global:MvDO_Error; --> <mvt:foreach iterator="line" array="global:splitString"> &mvt:line;</br> </mvt:foreach> <br> <h3>Deserialize+Global Substitution</h3> <p>This method supports multi-character splitting, as you're just replacing your seperator with a single comma</p> <mvt:assign name="g.array" value="miva_array_deserialize( glosub(g.string,'|',',') )" /> <mvt:foreach iterator="line" array="global:array"> &mvt:line;</br> </mvt:foreach>
 

image extension

Grab the 3 letter extension off of an image file. Could be improved to look for last ',' and grab all after in case of variations like '.jpeg'.
Created: 1459875237
View "image extension"
<mvt:assign name="g.url" value="'http://dev.mcrmedical.com/mm5/graphics/00000001/fak28-MCR-first-aid-kit-front.jpg'" /> <mvt:assign name="g.extension" value="substring(g.url,(len(g.url)-3),4)" /> &mvt:global:extension;
 

image extension

Grab the 3 letter extension off of an image file. Could be improved to look for last ',' and grab all after in case of variations like '.jpeg'.
Created: 1459875200
View "image extension"
<mvt:assign name="g.url" value="'http://dev.mcrmedical.com/mm5/graphics/00000001/fak28-MCR-first-aid-kit-front.jpg'" /> <mvt:assign name="g.extension" value="substring(g.url,(len(g.url)-3),4)" /> &mvt:global:extension;
 
View "Basket #15478"
<mvt:assign name="g.string" value="'one,two,three,four,five'" /> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, ',', l.settings:array )" /> <!-- @@ &mvt:global:MvDO_Error; --> <h3>Continue</h3> <mvt:foreach iterator="item" array="array"> <mvt:if expr="l.settings:item EQ 'three'"> <mvt:foreachcontinue /> </mvt:if> &mvt:item;</br> </mvt:foreach> <h3>Stop</h3> <mvt:foreach iterator="item" array="array"> <mvt:if expr="l.settings:item EQ 'three'"> <mvt:foreachstop /> </mvt:if> &mvt:item;</br> </mvt:foreach>
 
View "Basket #15348"
<mvt:assign name="g.string" value="miva_array_deserialize('one,two,three,four,five')" /> <h3>Continue</h3> <mvt:foreach iterator="item" array="global:string"> <mvt:if expr="l.settings:item EQ 'three'"> <mvt:foreachcontinue /> </mvt:if> &mvt:item;</br> </mvt:foreach> <h3>Stop</h3> <mvt:foreach iterator="item" array="global:string"> <mvt:if expr="l.settings:item EQ 'three'"> <mvt:foreachstop /> </mvt:if> &mvt:item;</br> </mvt:foreach>
 
View "foreachcontinue and foreachstop"
<mvt:assign name="g.string" value="'one,two,three,four,five'" /> <mvt:do file="g.Module_Library_Utilities" name="l.success" value="SplitString( g.string, ',', l.settings:array )" /> <!-- @@ &mvt:global:MvDO_Error; --> <h3>Continue</h3> <mvt:foreach iterator="item" array="array"> <mvt:if expr="l.settings:item EQ 'three'"> <mvt:foreachcontinue /> </mvt:if> &mvt:item;</br> </mvt:foreach> <h3>Stop</h3> <mvt:foreach iterator="item" array="array"> <mvt:if expr="l.settings:item EQ 'three'"> <mvt:foreachstop /> </mvt:if> &mvt:item;</br> </mvt:foreach>
 

Basket #15324

[Documentation](http://www.miva.com/template-language/miva_template_language/entities_&_encoding.html) [Video Tutorial](http://www.miva.com/videos/web_developers/output-encoding)
Created: 1458616989
View "Basket #15324"
<mvt:assign name="l.settings:sample" value="'<i>Hello World.</i>'" /> <h2>No Encoding</h2> &mvt:sample; <h2>Entity Encoding </h2> <p><medium>Can help prevent cross side scripiting</medium></p> &mvte:sample; <h2>Attribute Encoding </h2> <p><small>Great WHAT URLs</small></p> &mvta:sample; <mvt:comment> <!-- Click the Result's "View Source" Button for more details. --> </mvt:comment> <H1>WHAT</H1>
 

MivaScript Operators

 mivascript  operators  NOT  ROUND  CRYPT  MOD  POW  math  string  IN  CIN  EIN  ECIN  EQ  LT  LE  GT  GE  ISNULL  AND  OR
Created: 1456865839
View "MivaScript Operators"
<h1>MivaScript Operator Examples</h1> <h2><a href="http://www.mivascript.com/topic/operators.html">Documentation</a></h2> <h2><a href="http://snippets.miva.com/id/1456864554/latest">snippets.miva.com Examples</a></h2> <h2><code>NOT</code></h2> NOT 0: <mvt:eval expr="NOT 0" /><br> NOT 1: <mvt:eval expr="NOT 1" /><br> NOT '': <mvt:eval expr="NOT ''" /><br> NOT 'foobar': <mvt:eval expr="NOT 'foobar'" /><br> <h2><code>ROUND</code></h2> <mvt:assign name="g.PI" value="3.14159265359" /> g.PI: &mvte:global:PI;<br> g.PI ROUND 0: <mvt:eval expr="g.PI ROUND 0" /><br> g.PI ROUND 1: <mvt:eval expr="g.PI ROUND 1" /><br> g.PI ROUND 2: <mvt:eval expr="g.PI ROUND 2" /><br> g.PI ROUND 3: <mvt:eval expr="g.PI ROUND 3" /><br> <h2><code>CRYPT</code></h2> <mvt:assign name="g.password" value="'open-sesame'" /> g.password: &mvte:global:password;<br> g.password CRYPT 'key': <mvt:eval expr="g.password CRYPT 'key'" /><br> g.password CRYPT 'other-key': <mvt:eval expr="g.password CRYPT 'other-key'" /><br> <h2><code>MOD</code></h2> 3 MOD 3: <mvt:eval expr="3 MOD 3"/><br> 4 MOD 3: <mvt:eval expr="4 MOD 3"/><br> 5 MOD 3: <mvt:eval expr="5 MOD 3"/><br> 6 MOD 3: <mvt:eval expr="6 MOD 3"/><br> 7 MOD 3: <mvt:eval expr="7 MOD 3"/><br> 8 MOD 3: <mvt:eval expr="8 MOD 3"/><br> 9 MOD 3: <mvt:eval expr="9 MOD 3"/><br> <h2><code>POW</code></h2> 2 POW 1: <mvt:eval expr="2 POW 1"/><br> 2 POW 2: <mvt:eval expr="2 POW 2"/><br> 2 POW 0: <mvt:eval expr="2 POW 0"/><br> 2 POW 3: <mvt:eval expr="2 POW 3"/><br> 2 POW 4: <mvt:eval expr="2 POW 4"/><br> <h2><code>+-*/</code> <small>Math Operators</small></h2> 3 + 3: <mvt:eval expr="3 + 3"/><br> 3 - 3: <mvt:eval expr="3 - 3"/><br> 3 * 3: <mvt:eval expr="3 * 3"/><br> 3 / 3: <mvt:eval expr="3 / 3"/><br> <h2><code>$</code> <small>String Concatination</small></h2> 'foo' $ 'bar': <mvt:eval expr="'foo' $ 'bar'"/><br> <mvt:assign name="g.name" value="'John'" /> 'Hello ' $ g.name: <mvt:eval expr="'Hello ' $ g.name"/><br> <h2><code>IN</code> <small>First String Position (Case Sensitive)</small></h2> 'apple' IN 'Banana': <mvt:eval expr="'apple' IN 'Banana'"/><br> 'ba' IN 'Banana': <mvt:eval expr="'ba' IN 'Banana'"/><br> 'Ba' IN 'Banana': <mvt:eval expr="'Ba' IN 'Banana'"/><br> 'an' IN 'Banana': <mvt:eval expr="'an' IN 'Banana'"/><br> <h2><code>CIN</code> <small>First String Position (Case In-sensitive)</small></h2> 'apple' CIN 'Banana': <mvt:eval expr="'apple' CIN 'Banana'"/><br> 'ba' CIN 'Banana': <mvt:eval expr="'ba' CIN 'Banana'"/><br> 'Ba' CIN 'Banana': <mvt:eval expr="'Ba' CIN 'Banana'"/><br> 'an' CIN 'Banana': <mvt:eval expr="'an' CIN 'Banana'"/><br> <h2><code>EIN</code> <small>Last String Position (Case Sensitive)</small></h2> 'apple' EIN 'Banana': <mvt:eval expr="'apple' EIN 'Banana'"/><br> 'ba' EIN 'Banana': <mvt:eval expr="'ba' EIN 'Banana'"/><br> 'Ba' EIN 'Banana': <mvt:eval expr="'Ba' EIN 'Banana'"/><br> 'an' EIN 'Banana': <mvt:eval expr="'an' EIN 'Banana'"/><br> ('an' IN 'Banana') !== ('an' EIN 'Banana'): (<mvt:eval expr="'an' IN 'Banana'"/>) !== (<mvt:eval expr="'an' EIN 'Banana'"/>)<br> <h2><code>ECIN</code> <small>Last String Position (Case In-sensitive)</small></h2> 'apple' ECIN 'Banana': <mvt:eval expr="'apple' ECIN 'Banana'"/><br> 'ba' ECIN 'Banana': <mvt:eval expr="'ba' ECIN 'Banana'"/><br> 'Ba' ECIN 'Banana': <mvt:eval expr="'Ba' ECIN 'Banana'"/><br> 'an' ECIN 'Banana': <mvt:eval expr="'an' ECIN 'Banana'"/><br> ('an' CIN 'Banana') !== ('an' ECIN 'Banana'): (<mvt:eval expr="'an' CIN 'Banana'"/>) !== (<mvt:eval expr="'an' ECIN 'Banana'"/>)<br> <h2>Value Comparison Opperators</h2> <h3><code>EQ</code></h3> 1 EQ 1: <mvt:eval expr="1 EQ 1"/><br> 1 EQ '1': <mvt:eval expr="1 EQ '1'"/><br> 1 EQ '01': <mvt:eval expr="1 EQ '01'"/><br> 1 EQ 2: <mvt:eval expr="1 EQ 2"/><br> 1 EQ 0: <mvt:eval expr="1 EQ 0"/><br> 1 EQ '': <mvt:eval expr="1 EQ ''"/><br> <h3><code>NE</code></h3> 1 NE 1: <mvt:eval expr="1 NE 1"/><br> 1 NE '1': <mvt:eval expr="1 NE '1'"/><br> 1 NE '01': <mvt:eval expr="1 NE '01'"/><br> 1 NE 2: <mvt:eval expr="1 NE 2"/><br> 1 NE 0: <mvt:eval expr="1 NE 0"/><br> 1 NE '': <mvt:eval expr="1 NE ''"/><br> <h3><code>LT</code></h3> 1 LT 1: <mvt:eval expr="1 LT 1"/><br> 1 LT '1': <mvt:eval expr="1 LT '1'"/><br> 1 LT '01': <mvt:eval expr="1 LT '01'"/><br> 1 LT 2: <mvt:eval expr="1 LT 2"/><br> 1 LT 0: <mvt:eval expr="1 LT 0"/><br> 1 LT '': <mvt:eval expr="1 LT ''"/><br> <h3><code>LE</code></h3> 1 LE 1: <mvt:eval expr="1 LE 1"/><br> 1 LE '1': <mvt:eval expr="1 LE '1'"/><br> 1 LE '01': <mvt:eval expr="1 LE '01'"/><br> 1 LE 2: <mvt:eval expr="1 LE 2"/><br> 1 LE 0: <mvt:eval expr="1 LE 0"/><br> 1 LE '': <mvt:eval expr="1 LE ''"/><br> <h3><code>GT</code></h3> 1 GT 1: <mvt:eval expr="1 GT 1"/><br> 1 GT '1': <mvt:eval expr="1 GT '1'"/><br> 1 GT '01': <mvt:eval expr="1 GT '01'"/><br> 1 GT 2: <mvt:eval expr="1 GT 2"/><br> 1 GT 0: <mvt:eval expr="1 GT 0"/><br> 1 GT '': <mvt:eval expr="1 GT ''"/><br> <h3><code>GE</code></h3> 1 GE 1: <mvt:eval expr="1 GE 1"/><br> 1 GE '1': <mvt:eval expr="1 GE '1'"/><br> 1 GE '01': <mvt:eval expr="1 GE '01'"/><br> 1 GE 2: <mvt:eval expr="1 GE 2"/><br> 1 GE 0: <mvt:eval expr="1 GE 0"/><br> 1 GE '': <mvt:eval expr="1 GE ''"/><br> <h3><code>ISNULL</code></h3> ISNULL 1: <mvt:eval expr="ISNULL 1"/><br> ISNULL '1': <mvt:eval expr="ISNULL '1'"/><br> ISNULL '01': <mvt:eval expr="ISNULL '01'"/><br> ISNULL 2: <mvt:eval expr="ISNULL 2"/><br> ISNULL 0: <mvt:eval expr="ISNULL 0"/><br> ISNULL '': <mvt:eval expr="ISNULL ''"/><br> <h2>Logical Comparison Opperators</h2> <h2><code>AND</code></h2> 1 AND 1: <mvt:eval expr="1 AND 1"/><br> 1 AND 0: <mvt:eval expr="1 AND 0"/><br> 1 EQ 1 AND 2 EQ 2: <mvt:eval expr="1 EQ 1 AND 2 EQ 2"/><br> 1 EQ 2 AND 2 EQ 2: <mvt:eval expr="1 EQ 2 AND 2 EQ 2"/><br> 1 EQ 2 AND 2 EQ 3: <mvt:eval expr="1 EQ 2 AND 2 EQ 3"/><br> <h2><code>OR</code></h2> 1 OR 1: <mvt:eval expr="1 OR 1"/><br> 1 OR 0: <mvt:eval expr="1 OR 0"/><br> 1 EQ 1 OR 2 EQ 2: <mvt:eval expr="1 EQ 1 OR 2 EQ 2"/><br> 1 EQ 2 OR 2 EQ 2: <mvt:eval expr="1 EQ 2 OR 2 EQ 2"/><br> 1 EQ 2 OR 2 EQ 3: <mvt:eval expr="1 EQ 2 OR 2 EQ 3"/><br>
 

MivaScript Operators

 mivascript  operators  NOT  ROUND  CRYPT  MOD  POW  math  string  IN  CIN  EIN  ECIN  EQ  LT  LE  GT  GE  ISNULL  AND  OR
Created: 1456865827
View "MivaScript Operators"
<h1>MivaScript Operator Examples</h1> <h2><a href="http://www.mivascript.com/topic/operators.html">Documentation</a></h2> <h2><a href="http://snippets.miva.com/id/1456864554/latest">snippets.miva.com Examples</a></h2>c <h2><code>NOT</code></h2> NOT 0: <mvt:eval expr="NOT 0" /><br> NOT 1: <mvt:eval expr="NOT 1" /><br> NOT '': <mvt:eval expr="NOT ''" /><br> NOT 'foobar': <mvt:eval expr="NOT 'foobar'" /><br> <h2><code>ROUND</code></h2> <mvt:assign name="g.PI" value="3.14159265359" /> g.PI: &mvte:global:PI;<br> g.PI ROUND 0: <mvt:eval expr="g.PI ROUND 0" /><br> g.PI ROUND 1: <mvt:eval expr="g.PI ROUND 1" /><br> g.PI ROUND 2: <mvt:eval expr="g.PI ROUND 2" /><br> g.PI ROUND 3: <mvt:eval expr="g.PI ROUND 3" /><br> <h2><code>CRYPT</code></h2> <mvt:assign name="g.password" value="'open-sesame'" /> g.password: &mvte:global:password;<br> g.password CRYPT 'key': <mvt:eval expr="g.password CRYPT 'key'" /><br> g.password CRYPT 'other-key': <mvt:eval expr="g.password CRYPT 'other-key'" /><br> <h2><code>MOD</code></h2> 3 MOD 3: <mvt:eval expr="3 MOD 3"/><br> 4 MOD 3: <mvt:eval expr="4 MOD 3"/><br> 5 MOD 3: <mvt:eval expr="5 MOD 3"/><br> 6 MOD 3: <mvt:eval expr="6 MOD 3"/><br> 7 MOD 3: <mvt:eval expr="7 MOD 3"/><br> 8 MOD 3: <mvt:eval expr="8 MOD 3"/><br> 9 MOD 3: <mvt:eval expr="9 MOD 3"/><br> <h2><code>POW</code></h2> 2 POW 1: <mvt:eval expr="2 POW 1"/><br> 2 POW 2: <mvt:eval expr="2 POW 2"/><br> 2 POW 0: <mvt:eval expr="2 POW 0"/><br> 2 POW 3: <mvt:eval expr="2 POW 3"/><br> 2 POW 4: <mvt:eval expr="2 POW 4"/><br> <h2><code>+-*/</code> <small>Math Operators</small></h2> 3 + 3: <mvt:eval expr="3 + 3"/><br> 3 - 3: <mvt:eval expr="3 - 3"/><br> 3 * 3: <mvt:eval expr="3 * 3"/><br> 3 / 3: <mvt:eval expr="3 / 3"/><br> <h2><code>$</code> <small>String Concatination</small></h2> 'foo' $ 'bar': <mvt:eval expr="'foo' $ 'bar'"/><br> <mvt:assign name="g.name" value="'John'" /> 'Hello ' $ g.name: <mvt:eval expr="'Hello ' $ g.name"/><br> <h2><code>IN</code> <small>First String Position (Case Sensitive)</small></h2> 'apple' IN 'Banana': <mvt:eval expr="'apple' IN 'Banana'"/><br> 'ba' IN 'Banana': <mvt:eval expr="'ba' IN 'Banana'"/><br> 'Ba' IN 'Banana': <mvt:eval expr="'Ba' IN 'Banana'"/><br> 'an' IN 'Banana': <mvt:eval expr="'an' IN 'Banana'"/><br> <h2><code>CIN</code> <small>First String Position (Case In-sensitive)</small></h2> 'apple' CIN 'Banana': <mvt:eval expr="'apple' CIN 'Banana'"/><br> 'ba' CIN 'Banana': <mvt:eval expr="'ba' CIN 'Banana'"/><br> 'Ba' CIN 'Banana': <mvt:eval expr="'Ba' CIN 'Banana'"/><br> 'an' CIN 'Banana': <mvt:eval expr="'an' CIN 'Banana'"/><br> <h2><code>EIN</code> <small>Last String Position (Case Sensitive)</small></h2> 'apple' EIN 'Banana': <mvt:eval expr="'apple' EIN 'Banana'"/><br> 'ba' EIN 'Banana': <mvt:eval expr="'ba' EIN 'Banana'"/><br> 'Ba' EIN 'Banana': <mvt:eval expr="'Ba' EIN 'Banana'"/><br> 'an' EIN 'Banana': <mvt:eval expr="'an' EIN 'Banana'"/><br> ('an' IN 'Banana') !== ('an' EIN 'Banana'): (<mvt:eval expr="'an' IN 'Banana'"/>) !== (<mvt:eval expr="'an' EIN 'Banana'"/>)<br> <h2><code>ECIN</code> <small>Last String Position (Case In-sensitive)</small></h2> 'apple' ECIN 'Banana': <mvt:eval expr="'apple' ECIN 'Banana'"/><br> 'ba' ECIN 'Banana': <mvt:eval expr="'ba' ECIN 'Banana'"/><br> 'Ba' ECIN 'Banana': <mvt:eval expr="'Ba' ECIN 'Banana'"/><br> 'an' ECIN 'Banana': <mvt:eval expr="'an' ECIN 'Banana'"/><br> ('an' CIN 'Banana') !== ('an' ECIN 'Banana'): (<mvt:eval expr="'an' CIN 'Banana'"/>) !== (<mvt:eval expr="'an' ECIN 'Banana'"/>)<br> <h2>Value Comparison Opperators</h2> <h3><code>EQ</code></h3> 1 EQ 1: <mvt:eval expr="1 EQ 1"/><br> 1 EQ '1': <mvt:eval expr="1 EQ '1'"/><br> 1 EQ '01': <mvt:eval expr="1 EQ '01'"/><br> 1 EQ 2: <mvt:eval expr="1 EQ 2"/><br> 1 EQ 0: <mvt:eval expr="1 EQ 0"/><br> 1 EQ '': <mvt:eval expr="1 EQ ''"/><br> <h3><code>NE</code></h3> 1 NE 1: <mvt:eval expr="1 NE 1"/><br> 1 NE '1': <mvt:eval expr="1 NE '1'"/><br> 1 NE '01': <mvt:eval expr="1 NE '01'"/><br> 1 NE 2: <mvt:eval expr="1 NE 2"/><br> 1 NE 0: <mvt:eval expr="1 NE 0"/><br> 1 NE '': <mvt:eval expr="1 NE ''"/><br> <h3><code>LT</code></h3> 1 LT 1: <mvt:eval expr="1 LT 1"/><br> 1 LT '1': <mvt:eval expr="1 LT '1'"/><br> 1 LT '01': <mvt:eval expr="1 LT '01'"/><br> 1 LT 2: <mvt:eval expr="1 LT 2"/><br> 1 LT 0: <mvt:eval expr="1 LT 0"/><br> 1 LT '': <mvt:eval expr="1 LT ''"/><br> <h3><code>LE</code></h3> 1 LE 1: <mvt:eval expr="1 LE 1"/><br> 1 LE '1': <mvt:eval expr="1 LE '1'"/><br> 1 LE '01': <mvt:eval expr="1 LE '01'"/><br> 1 LE 2: <mvt:eval expr="1 LE 2"/><br> 1 LE 0: <mvt:eval expr="1 LE 0"/><br> 1 LE '': <mvt:eval expr="1 LE ''"/><br> <h3><code>GT</code></h3> 1 GT 1: <mvt:eval expr="1 GT 1"/><br> 1 GT '1': <mvt:eval expr="1 GT '1'"/><br> 1 GT '01': <mvt:eval expr="1 GT '01'"/><br> 1 GT 2: <mvt:eval expr="1 GT 2"/><br> 1 GT 0: <mvt:eval expr="1 GT 0"/><br> 1 GT '': <mvt:eval expr="1 GT ''"/><br> <h3><code>GE</code></h3> 1 GE 1: <mvt:eval expr="1 GE 1"/><br> 1 GE '1': <mvt:eval expr="1 GE '1'"/><br> 1 GE '01': <mvt:eval expr="1 GE '01'"/><br> 1 GE 2: <mvt:eval expr="1 GE 2"/><br> 1 GE 0: <mvt:eval expr="1 GE 0"/><br> 1 GE '': <mvt:eval expr="1 GE ''"/><br> <h3><code>ISNULL</code></h3> ISNULL 1: <mvt:eval expr="ISNULL 1"/><br> ISNULL '1': <mvt:eval expr="ISNULL '1'"/><br> ISNULL '01': <mvt:eval expr="ISNULL '01'"/><br> ISNULL 2: <mvt:eval expr="ISNULL 2"/><br> ISNULL 0: <mvt:eval expr="ISNULL 0"/><br> ISNULL '': <mvt:eval expr="ISNULL ''"/><br> <h2>Logical Comparison Opperators</h2> <h2><code>AND</code></h2> 1 AND 1: <mvt:eval expr="1 AND 1"/><br> 1 AND 0: <mvt:eval expr="1 AND 0"/><br> 1 EQ 1 AND 2 EQ 2: <mvt:eval expr="1 EQ 1 AND 2 EQ 2"/><br> 1 EQ 2 AND 2 EQ 2: <mvt:eval expr="1 EQ 2 AND 2 EQ 2"/><br> 1 EQ 2 AND 2 EQ 3: <mvt:eval expr="1 EQ 2 AND 2 EQ 3"/><br> <h2><code>OR</code></h2> 1 OR 1: <mvt:eval expr="1 OR 1"/><br> 1 OR 0: <mvt:eval expr="1 OR 0"/><br> 1 EQ 1 OR 2 EQ 2: <mvt:eval expr="1 EQ 1 OR 2 EQ 2"/><br> 1 EQ 2 OR 2 EQ 2: <mvt:eval expr="1 EQ 2 OR 2 EQ 2"/><br> 1 EQ 2 OR 2 EQ 3: <mvt:eval expr="1 EQ 2 OR 2 EQ 3"/><br>
 

MivaScript Operators

 mivascript  operators  NOT  ROUND  CRYPT  MOD  POW  math  string  IN  CIN  EIN  ECIN  EQ  LT  LE  GT  GE  ISNULL  AND  OR
Created: 1456864554
View "MivaScript Operators"
<h1><A href="http://www.mivascript.com/topic/operators.html">MivaScript Operators</A></h1> <mvt:assign name="g.counter" value="1" /> <h2><code>NOT</code></h2> NOT 0: <mvt:eval expr="NOT 0" /><br> NOT 1: <mvt:eval expr="NOT 1" /><br> NOT '': <mvt:eval expr="NOT ''" /><br> NOT 'foobar': <mvt:eval expr="NOT 'foobar'" /><br> <h2><code>ROUND</code></h2> <mvt:assign name="g.PI" value="3.14159265359" /> g.PI: &mvte:global:PI;<br> g.PI ROUND 0: <mvt:eval expr="g.PI ROUND 0" /><br> g.PI ROUND 1: <mvt:eval expr="g.PI ROUND 1" /><br> g.PI ROUND 2: <mvt:eval expr="g.PI ROUND 2" /><br> g.PI ROUND 3: <mvt:eval expr="g.PI ROUND 3" /><br> <h2><code>CRYPT</code></h2> <mvt:assign name="g.password" value="'open-sesame'" /> g.password: &mvte:global:password;<br> g.password CRYPT 'key': <mvt:eval expr="g.password CRYPT 'key'" /><br> g.password CRYPT 'other-key': <mvt:eval expr="g.password CRYPT 'other-key'" /><br> <h2><code>MOD</code></h2> 3 MOD 3: <mvt:eval expr="3 MOD 3"/><br> 4 MOD 3: <mvt:eval expr="4 MOD 3"/><br> 5 MOD 3: <mvt:eval expr="5 MOD 3"/><br> 6 MOD 3: <mvt:eval expr="6 MOD 3"/><br> 7 MOD 3: <mvt:eval expr="7 MOD 3"/><br> 8 MOD 3: <mvt:eval expr="8 MOD 3"/><br> 9 MOD 3: <mvt:eval expr="9 MOD 3"/><br> <h2><code>POW</code></h2> 2 POW 1: <mvt:eval expr="2 POW 1"/><br> 2 POW 2: <mvt:eval expr="2 POW 2"/><br> 2 POW 0: <mvt:eval expr="2 POW 0"/><br> 2 POW 3: <mvt:eval expr="2 POW 3"/><br> 2 POW 4: <mvt:eval expr="2 POW 4"/><br> <h2><code>+-*/</code> <small>Math Operators</small></h2> 3 + 3: <mvt:eval expr="3 + 3"/><br> 3 - 3: <mvt:eval expr="3 - 3"/><br> 3 * 3: <mvt:eval expr="3 * 3"/><br> 3 / 3: <mvt:eval expr="3 / 3"/><br> <h2><code>$</code> <small>String Concatination</small></h2> 'foo' $ 'bar': <mvt:eval expr="'foo' $ 'bar'"/><br> <mvt:assign name="g.name" value="'John'" /> 'Hello ' $ g.name: <mvt:eval expr="'Hello ' $ g.name"/><br> <h2><code>IN</code> <small>First String Position (Case Sensitive)</small></h2> 'apple' IN 'Banana': <mvt:eval expr="'apple' IN 'Banana'"/><br> 'ba' IN 'Banana': <mvt:eval expr="'ba' IN 'Banana'"/><br> 'Ba' IN 'Banana': <mvt:eval expr="'Ba' IN 'Banana'"/><br> 'an' IN 'Banana': <mvt:eval expr="'an' IN 'Banana'"/><br> <h2><code>CIN</code> <small>First String Position (Case In-sensitive)</small></h2> 'apple' CIN 'Banana': <mvt:eval expr="'apple' CIN 'Banana'"/><br> 'ba' CIN 'Banana': <mvt:eval expr="'ba' CIN 'Banana'"/><br> 'Ba' CIN 'Banana': <mvt:eval expr="'Ba' CIN 'Banana'"/><br> 'an' CIN 'Banana': <mvt:eval expr="'an' CIN 'Banana'"/><br> <h2><code>EIN</code> <small>Last String Position (Case Sensitive)</small></h2> 'apple' EIN 'Banana': <mvt:eval expr="'apple' EIN 'Banana'"/><br> 'ba' EIN 'Banana': <mvt:eval expr="'ba' EIN 'Banana'"/><br> 'Ba' EIN 'Banana': <mvt:eval expr="'Ba' EIN 'Banana'"/><br> 'an' EIN 'Banana': <mvt:eval expr="'an' EIN 'Banana'"/><br> ('an' IN 'Banana') !== ('an' EIN 'Banana'): (<mvt:eval expr="'an' IN 'Banana'"/>) !== (<mvt:eval expr="'an' EIN 'Banana'"/>)<br> <h2><code>ECIN</code> <small>Last String Position (Case In-sensitive)</small></h2> 'apple' ECIN 'Banana': <mvt:eval expr="'apple' ECIN 'Banana'"/><br> 'ba' ECIN 'Banana': <mvt:eval expr="'ba' ECIN 'Banana'"/><br> 'Ba' ECIN 'Banana': <mvt:eval expr="'Ba' ECIN 'Banana'"/><br> 'an' ECIN 'Banana': <mvt:eval expr="'an' ECIN 'Banana'"/><br> ('an' CIN 'Banana') !== ('an' ECIN 'Banana'): (<mvt:eval expr="'an' CIN 'Banana'"/>) !== (<mvt:eval expr="'an' ECIN 'Banana'"/>)<br> <h2>Value Comparison Opperators</h2> <h3><code>EQ</code></h3> 1 EQ 1: <mvt:eval expr="1 EQ 1"/><br> 1 EQ '1': <mvt:eval expr="1 EQ '1'"/><br> 1 EQ '01': <mvt:eval expr="1 EQ '01'"/><br> 1 EQ 2: <mvt:eval expr="1 EQ 2"/><br> 1 EQ 0: <mvt:eval expr="1 EQ 0"/><br> 1 EQ '': <mvt:eval expr="1 EQ ''"/><br> <h3><code>NE</code></h3> 1 NE 1: <mvt:eval expr="1 NE 1"/><br> 1 NE '1': <mvt:eval expr="1 NE '1'"/><br> 1 NE '01': <mvt:eval expr="1 NE '01'"/><br> 1 NE 2: <mvt:eval expr="1 NE 2"/><br> 1 NE 0: <mvt:eval expr="1 NE 0"/><br> 1 NE '': <mvt:eval expr="1 NE ''"/><br> <h3><code>LT</code></h3> 1 LT 1: <mvt:eval expr="1 LT 1"/><br> 1 LT '1': <mvt:eval expr="1 LT '1'"/><br> 1 LT '01': <mvt:eval expr="1 LT '01'"/><br> 1 LT 2: <mvt:eval expr="1 LT 2"/><br> 1 LT 0: <mvt:eval expr="1 LT 0"/><br> 1 LT '': <mvt:eval expr="1 LT ''"/><br> <h3><code>LE</code></h3> 1 LE 1: <mvt:eval expr="1 LE 1"/><br> 1 LE '1': <mvt:eval expr="1 LE '1'"/><br> 1 LE '01': <mvt:eval expr="1 LE '01'"/><br> 1 LE 2: <mvt:eval expr="1 LE 2"/><br> 1 LE 0: <mvt:eval expr="1 LE 0"/><br> 1 LE '': <mvt:eval expr="1 LE ''"/><br> <h3><code>GT</code></h3> 1 GT 1: <mvt:eval expr="1 GT 1"/><br> 1 GT '1': <mvt:eval expr="1 GT '1'"/><br> 1 GT '01': <mvt:eval expr="1 GT '01'"/><br> 1 GT 2: <mvt:eval expr="1 GT 2"/><br> 1 GT 0: <mvt:eval expr="1 GT 0"/><br> 1 GT '': <mvt:eval expr="1 GT ''"/><br> <h3><code>GE</code></h3> 1 GE 1: <mvt:eval expr="1 GE 1"/><br> 1 GE '1': <mvt:eval expr="1 GE '1'"/><br> 1 GE '01': <mvt:eval expr="1 GE '01'"/><br> 1 GE 2: <mvt:eval expr="1 GE 2"/><br> 1 GE 0: <mvt:eval expr="1 GE 0"/><br> 1 GE '': <mvt:eval expr="1 GE ''"/><br> <h3><code>ISNULL</code></h3> ISNULL 1: <mvt:eval expr="ISNULL 1"/><br> ISNULL '1': <mvt:eval expr="ISNULL '1'"/><br> ISNULL '01': <mvt:eval expr="ISNULL '01'"/><br> ISNULL 2: <mvt:eval expr="ISNULL 2"/><br> ISNULL 0: <mvt:eval expr="ISNULL 0"/><br> ISNULL '': <mvt:eval expr="ISNULL ''"/><br> <h2>Logical Comparison Opperators</h2> <h2><code>AND</code></h2> 1 AND 1: <mvt:eval expr="1 AND 1"/><br> 1 AND 0: <mvt:eval expr="1 AND 0"/><br> 1 EQ 1 AND 2 EQ 2: <mvt:eval expr="1 EQ 1 AND 2 EQ 2"/><br> 1 EQ 2 AND 2 EQ 2: <mvt:eval expr="1 EQ 2 AND 2 EQ 2"/><br> 1 EQ 2 AND 2 EQ 3: <mvt:eval expr="1 EQ 2 AND 2 EQ 3"/><br> <h2><code>OR</code></h2> 1 OR 1: <mvt:eval expr="1 OR 1"/><br> 1 OR 0: <mvt:eval expr="1 OR 0"/><br> 1 EQ 1 OR 2 EQ 2: <mvt:eval expr="1 EQ 1 OR 2 EQ 2"/><br> 1 EQ 2 OR 2 EQ 2: <mvt:eval expr="1 EQ 2 OR 2 EQ 2"/><br> 1 EQ 2 OR 2 EQ 3: <mvt:eval expr="1 EQ 2 OR 2 EQ 3"/><br>
 

Basket #11760

Get the formatted date one week from now.
Created: 1455057431
View "Basket #11760"
<mvt:eval expr="7 - 3" />
 

capitalize

capitalize a string
Created: 1453744065
View "capitalize"
<mvt:assign name="g.str" value="'caleb'" /> <mvt:assign name="g.capitalize" value="toupper(substring(g.str,0,1)) $ subString(g.str,2,len(g.str))" /> &mvt:global:capitalize;
 

capitalize

capitalize a string
Created: 1453743986
View "capitalize"
<mvt:assign name="g.str" value="'caleb'" /> <mvt:assign name="g.firstLetter" value="substring(g.str,0,1)" /> <mvt:assign name="g.capitalize" value="toupper(g.firstLetter) $ subString(g.str,2,len(g.str))" /> &mvt:global:capitalize;
 

Basket #8353

Methods for splitting strings to arrays
Created: 1449263140
View "Basket #8353"
<mvt:assign name="g.test" value="'one two three four five'" /> <mvt:assign name="g.test2" value="'uno dos tres quatro cinco'" /> <mvt:assign name="g.null" value="miva_splitstring( g.test, ' ', g.array, NULL )" /> <mvt:assign name="g.null" value="miva_splitstring( g.test2, ' ', g.array2, NULL )" /> <mvt:assign name="g.output" value="g.array[1] $ '-' $ g.array[2] $ '-' $ g.array[3] $ '-' $ g.array2[1] $ '-' $ g.array2[2] $ '-' $ g.array2[3]" /> &mvt:global:output;
 
View "Credit Card Number Formatter & Cleaner "
<mvt:assign name="g.cc_num_dirty" value="'4444-5555/3333A1111-adasdsadasdas!'" /> <mvt:while expr="l.character_counter LT len(g.cc_num_dirty)"> <mvt:assign name="l.character_counter" value="l.character_counter + 1" /> <mvt:assign name="l.character" value="substring_var( g.cc_num_dirty, l.character_counter, 1 )"/> <mvt:if expr="isdigit(l.character)"> <mvt:if expr="l.digit_counter GT 0 AND l.digit_counter MOD 4 EQ 0"> <mvt:assign name="g.cc_num_clean" value="g.cc_num_clean $ '-'" /> </mvt:if> <mvt:assign name="g.cc_num_clean" value="g.cc_num_clean $ l.character" /> <mvt:assign name="l.digit_counter" value="l.digit_counter + 1" /> </mvt:if> </mvt:while> &mvte:global:cc_num_clean;
 
View "Credit Card Number Formatter & Cleaner "
<mvt:assign name="g.cc_num_dirty" value="'4444-5555/3333A1111-adasdsadasdas!'" /> <mvt:while expr="l.character_counter LT len(g.cc_num_dirty)"> <mvt:assign name="l.character_counter" value="l.character_counter + 1" /> <mvt:assign name="l.character" value="substring_var( g.cc_num_dirty, l.character_counter, 1 )"/> <mvt:if expr="isdigit(l.character)"> <mvt:if expr="l.digit_counter GT 0 AND l.digit_counter MOD 4 EQ 0"> <mvt:assign name="g.cc_num_clean" value="g.cc_num_clean $ '-'" /> </mvt:if> <mvt:assign name="g.cc_num_clean" value="g.cc_num_clean $ l.character" /> <mvt:assign name="l.digit_counter" value="l.digit_counter + 1" /> </mvt:if> </mvt:while> &mvte:global:cc_num_clean;
 
View "Estimated Shipping Delivery Dates"
<mvt:comment><!-- Days --></mvt:comment> <mvt:assign name="g.timezone_offset" value="'local'" /> <mvt:assign name="l.settings:days[1]:name" value="'Sunday'" /> <mvt:assign name="l.settings:days[1]:time" value="1431284400" /> <mvt:assign name="l.settings:days[2]:name" value="'Monday'" /> <mvt:assign name="l.settings:days[2]:time" value="1431370800" /> <mvt:assign name="l.settings:days[3]:name" value="'Tuesday'" /> <mvt:assign name="l.settings:days[3]:time" value="1431457200" /> <mvt:assign name="l.settings:days[4]:name" value="'Wednesday'" /> <mvt:assign name="l.settings:days[4]:time" value="1431543600" /> <mvt:assign name="l.settings:days[5]:name" value="'Thursday'" /> <mvt:assign name="l.settings:days[5]:time" value="1431630000" /> <mvt:assign name="l.settings:days[6]:name" value="'Friday'" /> <mvt:assign name="l.settings:days[6]:time" value="1431716400" /> <mvt:assign name="l.settings:days[7]:name" value="'Saturday'" /> <mvt:assign name="l.settings:days[7]:time" value="1431802800" /> <mvt:comment><!-- Shipping Methods --></mvt:comment> <mvt:assign name="l.settings:shippingmethods[1]:name" value="'Next Day'" /> <mvt:assign name="l.settings:shippingmethods[1]:delivery:min" value="1" /> <mvt:assign name="l.settings:shippingmethods[1]:delivery:max" value="1" /> <mvt:assign name="l.settings:shippingmethods[2]:name" value="'2nd Day'" /> <mvt:assign name="l.settings:shippingmethods[2]:delivery:min" value="2" /> <mvt:assign name="l.settings:shippingmethods[2]:delivery:max" value="2" /> <mvt:assign name="l.settings:shippingmethods[3]:name" value="'Ground'" /> <mvt:assign name="l.settings:shippingmethods[3]:delivery:min" value="7" /> <mvt:assign name="l.settings:shippingmethods[3]:delivery:max" value="10" /> <mvt:foreach iterator="day" array="days"> <mvt:assign name="l.settings:day:month" value="time_t_month( l.settings:day:time, g.timezone_offset )" /> <mvt:assign name="l.settings:day:day" value="time_t_dayofmonth( l.settings:day:time, g.timezone_offset )" /> <mvt:assign name="l.settings:day:formatted_date" value="l.settings:day:month $ '/' $ l.settings:day:day" /> <h2>Order Placed: &mvt:day:name; @ &mvt:day:formatted_date;</h2> <mvt:foreach iterator="method" array="shippingmethods"> <mvt:assign name="l.settings:method:elapsed:days" value="0" /> <mvt:assign name="l.settings:method:shipping:days" value="0" /> <mvt:assign name="l.settings:method:processing:days" value="0" /> <mvt:assign name="l.settings:method:delivered" value="''" /> <mvt:assign name="l.settings:method:estimated:min" value="''" /> <mvt:assign name="l.settings:method:estimated:max" value="''" /> <mvt:while expr="ISNULL l.settings:method:delivered"> <mvt:assign name="l.settings:method:counter" value="l.settings:method:counter + 1" /> <mvt:assign name="l.settings:method:elapsed:days" value="l.settings:method:elapsed:days + 1" /> <mvt:assign name="l.settings:method:elapsed:duration" value="60 * 60 * 24 * l.settings:method:elapsed:days" /> <mvt:assign name="l.settings:method:elapsed:future_time" value="l.settings:day:time + l.settings:method:elapsed:duration"/> <mvt:assign name="l.settings:method:estimated:month" value="time_t_month( l.settings:method:elapsed:future_time, g.timezone_offset )" /> <mvt:assign name="l.settings:method:estimated:day" value="time_t_dayofmonth( l.settings:method:elapsed:future_time, g.timezone_offset )" /> <mvt:assign name="l.settings:method:estimated:dayofweek" value="time_t_dayofweek( l.settings:method:elapsed:future_time, g.timezone_offset )" /> <mvt:if expr="l.settings:method:estimated:dayofweek GT 1 AND l.settings:method:estimated:dayofweek LT 7"> <mvt:if expr="l.settings:method:processing:days EQ 0"> </mvt:if> <mvt:assign name="l.settings:method:processing:days" value="l.settings:method:processing:days + 1" /> </mvt:if> <mvt:if expr="l.settings:method:processing:days GT 1 AND l.settings:method:estimated:dayofweek GT 1"> <mvt:assign name="l.settings:method:shipping:days" value="l.settings:method:shipping:days + 1" /> </mvt:if> <mvt:if expr="ISNULL l.settings:method:estimated:min AND l.settings:method:shipping:days GE l.settings:method:delivery:min AND (l.settings:method:estimated:dayofweek GT 1 AND l.settings:method:estimated:dayofweek LT 7)"> <mvt:assign name="l.settings:method:estimated:min" value="l.settings:method:estimated:month $ '/' $ l.settings:method:estimated:day" /> <mvt:assign name="l.settings:method:estimated:min_day" value="l.settings:days[l.settings:method:estimated:dayofweek]:name" /> </mvt:if> <mvt:if expr="ISNULL l.settings:method:estimated:max AND l.settings:method:shipping:days GE l.settings:method:delivery:max AND (l.settings:method:estimated:dayofweek GT 1 AND l.settings:method:estimated:dayofweek LT 7)"> <mvt:assign name="l.settings:method:estimated:max" value="l.settings:method:estimated:month $ '/' $ l.settings:method:estimated:day" /> <mvt:assign name="l.settings:method:estimated:max_day" value="l.settings:days[l.settings:method:estimated:dayofweek]:name" /> <mvt:assign name="l.settings:method:delivered" value="1" /> </mvt:if> </mvt:while> </mvt:foreach> <mvt:foreach iterator="method" array="shippingmethods"> <p> <b>&mvt:method:name;</b><br> Estimated Delivery: &mvt:method:delivery:min;<mvt:if expr="l.settings:method:delivery:min NE l.settings:method:delivery:max">-&mvt:method:delivery:max;</mvt:if> business day(s)<br> Should Arrive: &mvt:method:estimated:min_day; &mvt:method:estimated:min;<mvt:if expr="l.settings:method:delivery:min NE l.settings:method:delivery:max"> to &mvt:method:estimated:max_day; &mvt:method:estimated:max;</mvt:if> </p> </mvt:foreach> <hr> </mvt:foreach>
 
View "Estimated Shipping Delivery Dates"
<mvt:comment><!-- Days --></mvt:comment> <mvt:assign name="g.timezone_offset" value="'local'" /> <mvt:assign name="l.settings:days[1]:name" value="'Sunday'" /> <mvt:assign name="l.settings:days[1]:time" value="1431284400" /> <mvt:assign name="l.settings:days[2]:name" value="'Monday'" /> <mvt:assign name="l.settings:days[2]:time" value="1431370800" /> <mvt:assign name="l.settings:days[3]:name" value="'Tuesday'" /> <mvt:assign name="l.settings:days[3]:time" value="1431457200" /> <mvt:assign name="l.settings:days[4]:name" value="'Wednesday'" /> <mvt:assign name="l.settings:days[4]:time" value="1431543600" /> <mvt:assign name="l.settings:days[5]:name" value="'Thursday'" /> <mvt:assign name="l.settings:days[5]:time" value="1431630000" /> <mvt:assign name="l.settings:days[6]:name" value="'Friday'" /> <mvt:assign name="l.settings:days[6]:time" value="1431716400" /> <mvt:assign name="l.settings:days[7]:name" value="'Saturday'" /> <mvt:assign name="l.settings:days[7]:time" value="1431802800" /> <mvt:comment><!-- Shipping Methods --></mvt:comment> <mvt:assign name="l.settings:shippingmethods[1]:name" value="'Next Day'" /> <mvt:assign name="l.settings:shippingmethods[1]:delivery:min" value="1" /> <mvt:assign name="l.settings:shippingmethods[1]:delivery:max" value="1" /> <mvt:assign name="l.settings:shippingmethods[2]:name" value="'2nd Day'" /> <mvt:assign name="l.settings:shippingmethods[2]:delivery:min" value="2" /> <mvt:assign name="l.settings:shippingmethods[2]:delivery:max" value="2" /> <mvt:assign name="l.settings:shippingmethods[3]:name" value="'Ground'" /> <mvt:assign name="l.settings:shippingmethods[3]:delivery:min" value="7" /> <mvt:assign name="l.settings:shippingmethods[3]:delivery:max" value="10" /> <mvt:foreach iterator="day" array="days"> <mvt:assign name="l.settings:day:month" value="time_t_month( l.settings:day:time, g.timezone_offset )" /> <mvt:assign name="l.settings:day:day" value="time_t_dayofmonth( l.settings:day:time, g.timezone_offset )" /> <mvt:assign name="l.settings:day:formatted_date" value="l.settings:day:month $ '/' $ l.settings:day:day" /> <h2>Order Placed: &mvt:day:name; @ &mvt:day:formatted_date;</h2> <mvt:foreach iterator="method" array="shippingmethods"> <mvt:assign name="l.settings:method:elapsed:days" value="0" /> <mvt:assign name="l.settings:method:shipping:days" value="0" /> <mvt:assign name="l.settings:method:processing:days" value="0" /> <mvt:assign name="l.settings:method:delivered" value="''" /> <mvt:assign name="l.settings:method:estimated:min" value="''" /> <mvt:assign name="l.settings:method:estimated:max" value="''" /> <mvt:assign name="l.settings:method:counter" value="0" /> <mvt:comment> <!-- <br><br> <b>&mvt:method:name;</b><br> --> </mvt:comment> <mvt:while expr="ISNULL l.settings:method:delivered AND l.settings:method:counter LT 20"> <mvt:assign name="l.settings:method:counter" value="l.settings:method:counter + 1" /> <mvt:assign name="l.settings:method:elapsed:days" value="l.settings:method:elapsed:days + 1" /> <mvt:assign name="l.settings:method:elapsed:duration" value="60 * 60 * 24 * l.settings:method:elapsed:days" /> <mvt:assign name="l.settings:method:elapsed:future_time" value="l.settings:day:time + l.settings:method:elapsed:duration"/> <mvt:assign name="l.settings:method:estimated:month" value="time_t_month( l.settings:method:elapsed:future_time, g.timezone_offset )" /> <mvt:assign name="l.settings:method:estimated:day" value="time_t_dayofmonth( l.settings:method:elapsed:future_time, g.timezone_offset )" /> <mvt:assign name="l.settings:method:estimated:dayofweek" value="time_t_dayofweek( l.settings:method:elapsed:future_time, g.timezone_offset )" /> <mvt:if expr="l.settings:method:estimated:dayofweek GT 1 AND l.settings:method:estimated:dayofweek LT 7"> <mvt:if expr="l.settings:method:processing:days EQ 0"> <mvt:comment><!-- <mvt:eval expr="l.settings:days[l.settings:method:estimated:dayofweek]:name"/> Processing +1<br> --></mvt:comment> </mvt:if> <mvt:assign name="l.settings:method:processing:days" value="l.settings:method:processing:days + 1" /> </mvt:if> <mvt:if expr="l.settings:method:processing:days GT 1 AND l.settings:method:estimated:dayofweek GT 1"> <mvt:comment><!-- <mvt:eval expr="l.settings:days[l.settings:method:estimated:dayofweek]:name"/> Shipping +1<br> --></mvt:comment> <mvt:assign name="l.settings:method:shipping:days" value="l.settings:method:shipping:days + 1" /> </mvt:if> <mvt:if expr="ISNULL l.settings:method:estimated:min AND l.settings:method:shipping:days GE l.settings:method:delivery:min AND (l.settings:method:estimated:dayofweek GT 1 AND l.settings:method:estimated:dayofweek LT 7)"> <mvt:assign name="l.settings:method:estimated:min" value="l.settings:method:estimated:month $ '/' $ l.settings:method:estimated:day" /> <mvt:assign name="l.settings:method:estimated:min_day" value="l.settings:days[l.settings:method:estimated:dayofweek]:name" /> <mvt:comment><!-- Delivered (Min.): <mvt:eval expr="l.settings:days[l.settings:method:estimated:dayofweek]:name"/><br> --></mvt:comment> </mvt:if> <mvt:if expr="ISNULL l.settings:method:estimated:max AND l.settings:method:shipping:days GE l.settings:method:delivery:max AND (l.settings:method:estimated:dayofweek GT 1 AND l.settings:method:estimated:dayofweek LT 7)"> <mvt:assign name="l.settings:method:estimated:max" value="l.settings:method:estimated:month $ '/' $ l.settings:method:estimated:day" /> <mvt:assign name="l.settings:method:estimated:max_day" value="l.settings:days[l.settings:method:estimated:dayofweek]:name" /> <mvt:comment><!-- Delivered (Max.): <mvt:eval expr="l.settings:days[l.settings:method:estimated:dayofweek]:name"/><br> --></mvt:comment> <mvt:assign name="l.settings:method:delivered" value="1" /> </mvt:if> </mvt:while> </mvt:foreach> <mvt:foreach iterator="method" array="shippingmethods"> <p> <b>&mvt:method:name;</b><br> Estimated Delivery: &mvt:method:delivery:min;<mvt:if expr="l.settings:method:delivery:min NE l.settings:method:delivery:max">-&mvt:method:delivery:max;</mvt:if> business day(s)<br> Should Arrive: &mvt:method:estimated:min_day; &mvt:method:estimated:min;<mvt:if expr="l.settings:method:delivery:min NE l.settings:method:delivery:max"> to &mvt:method:estimated:max_day; &mvt:method:estimated:max;</mvt:if> </p> </mvt:foreach> <hr> </mvt:foreach>
 

Basket #898

Note: This does not work yet.
Created: 1429560729
View "Basket #898"
<mvt:assign name="g.xml" value="'<Product_Update code=\"sample-product\"><Price>200</Price></Product_Update>'" /> <mvt:do file="g.module_feature_prv_ad" name="g.provision_result" value="PRV_Action_ProvisionStringData( g.xml )" /> &mvte:global:mvdo_error; &mvte:global:xml; <hr> &mvt:global:provision_result;
 

Basket #474

[Documentation](http://www.miva.com/template-language/miva_template_language/entities_&_encoding.html) [Video Tutorial](http://www.miva.com/videos/web_developers/output-encoding)
Created: 1427727106
View "Basket #474"
<mvt:assign name="g.test" value="1+1"/> &mvt:global:test;
 

Snippet: 1427689534 - v1

[Documentation](http://www.miva.com/template-language/miva_template_language/entities_&_encoding.html) [Video Tutorial](http://www.miva.com/videos/web_developers/output-encoding)
Created: 1427689534
View "Snippet: 1427689534 - v1"
<mvt:while expr="g.counter LT 10"> <mvt:assign name="g.counter" value="g.counter + 1" /> &mvte:global:counter;<br> </mvt:while><mvt:while expr="g.counter LT 10"> <mvt:assign name="g.counter" value="g.counter + 1" /> &mvte:global:counter;<br> </mvt:while><mvt:eval expr="2 + 2" /><mvt:assign name="l.settings:sample" value="'<i>Hello World.</i>'" /> <h2>No Encoding</h2> &mvt:sample; <h2>Entity Encoding </h2> <p><small>Can help prevent cross side scripiting</small></p> &mvte:sample; <h2>Attribute Encoding </h2> <p><small>Great for URLs</small></p> &mvta:sample; <mvt:comment> <!-- Click the Result's "View Source" Button for more details. --> </mvt:comment> <mvt:while expr="g.counter LT 10"> <mvt:assign name="g.counter" value="g.counter + 1" /> &mvte:global:counter;<br> </mvt:while><mvt:while expr="g.counter LT 10"> <mvt:assign name="g.counter" value="g.counter + 1" /> &mvte:global:counter;<br> </mvt:while><mvt:while expr="g.counter LT 10"> <mvt:assign name="g.counter" value="g.counter + 1" /> &mvte:global:counter;<br> </mvt:while>
 

Output Encoding

[Documentation](http://www.miva.com/template-language/miva_template_language/entities_&_encoding.html) [Video Tutorial](http://www.miva.com/videos/web_developers/output-encoding)
Created: 1427238108
View "Output Encoding"
<mvt:assign name="l.settings:sample" value="'<i>Hello World.</i>'" /> <h2>No Encoding</h2> &mvt:sample; <h2>Entity Encoding </h2> <p><small>Can help prevent cross side scripiting</small></p> &mvte:sample; <h2>Attribute Encoding </h2> <p><small>Great for URLs</small></p> &mvta:sample; <h2>JavaScript Encoding</h2> &mvtj:sample; <h2>Sluggified Encoding</h2> &mvts:sample; <mvt:comment> <!-- Click the Result's "View Source" Button for more details. --> </mvt:comment>