 
This is a reference for the functions defined by eCart
[url=http://www.webassist.com/community/tutorials/view_tutorial.php?tid=200#section1]GetContent[/url]
 Index
Index
 GetContent
GetContent
GetContent()
Initialize the cart contents. should be used on nay page that includes the eCart object after the require_once line
<?php
//WA eCart Include
require_once("WA_eCart/eCart1_PHP.php");
?>
<?php
$eCart1->GetContent();
?> SaveCart
SaveCart
SaveCart()
Save the cart contents
$eCart1->SaveCart(); BOF
BOF
BOF()
Returns true if the pointer is on the first line item, else returns false
$eCart1->BOF(); ClearCart
ClearCart
ClearCart()
Remove all items from the cart
$eCart1->ClearCart(); ResetAll
ResetAll
ResetAll()
Reset the Cart
$eCart1->ResetAll(); DeleteFromCart
DeleteFromCart
DeleteFromCart($index, $reIndex)
$index - array index of the item to remove
$reIndex - true or false to reindex the cart.
$eCart1->DeleteFromCart(1, true); DisplayInfo
DisplayInfo
DisplayInfo($ItemProperty)
Used to display a cart column value on the page:
echo($eCart1->DisplayInfo("Name")); EOF()
EOF()
EOF()
$eCart1->EOF() RulesInformation
RulesInformation
RulesInformation($theSet)
Returns an array of the rules defined for theSet parameter.
Parameters:
$theSet - can be "Charges", "Discounts", "tax", "Shipping"
$eCart1->RulesInformation("Discounts") Rules_EOF
Rules_EOF
Rules_EOF($theSet)
Returns true if the pointer is on the last rule for the selected set.
Parameters:
$theSet - can be "Charges", "Discounts", "Tax", "Shipping"
$eCart1->Rules_EOF("Tax"); GetInfo
GetInfo
GetInfo($ItemID, $ItemProperty)
Returns the Item property for the Item ID that is passed.
Parameters:
$ItemID - ID for the item in the cart
$ItemProperty - name of the cart column value to return
$eCart1->GetInfo(3, "Quantity"); GetItem
GetItem
GetItem($ItemID)
returns an array of the properties for the specified item
Parameters:
$ItemID - The ID of the Item in the cart
$eCart1->GetItem(5); InCart
InCart
InCart($itemID) 
returns true if the ID passed is in the cart, false if not
Parameters:
$itemID - ID for the Item to look for
$eCart1->InCart(3); IsEmpty
IsEmpty
IsEmpty()
returns true if the cart is empty, false if there are items in the cart;
$eCart1->IsEmpty(); Move
Move
Move($modifier)
Move the cart pointer the specified number in the list of line items
Parameters:
$modifier - number of line item to move the pointer
$eCart1->Move(3); MoveFirst
MoveFirst
MoveFirst()
move the cart pointer to the first item.
$eCart1->MoveFirst(); MoveLast
MoveLast
MoveLast()
move the cart pointer to the last item:
$eCart1->MoveLast(); MoveNext
MoveNext
MoveNext()
move the cart pointer to the next item:
$eCart1->MoveNext(); MovePrevious
MovePrevious
MovePrevious()
move the cart pointer to the previous item
$eCart1->MovePrevious() Rules_MoveNext
Rules_MoveNext
Rules_MoveNext($theSet)
move the cart pointer to the next rule in the specified set
Parameters:
$theSet - can be "Discounts, "Shipping", Tax", "Charges"
$eCart1->Rules_MoveNext("Shipping") Rules_MoveFirst
Rules_MoveFirst
Rules_MoveFirst($theSet)
move the cart pointer to the First rule in the specified set
Parameters:
$theSet - can be "Discounts, "Shipping", Tax", "Charges"
$eCart1->Rules_MoveFirst("Discounts") ReIndexContent()
ReIndexContent()
ReIndexContent()
Recreate the cart index
$eCart->ReIndexContent(); TotalColumn
TotalColumn
TotalColumn($ColumnName)
Returns the SubTotal of cart column for all items in the cart, used for total quantity as an example:
Parameters:
$ColumnName - the name of the column to calcualte subtotal for.
$eCart1->TotalColumn("Quantity") GetCharges
GetCharges
GetCharges()
Returns the Subtotal of all active Charges:
$eCart1->GetCharges(); GetDiscounts
GetDiscounts
GetDiscounts()
$eCart1->GetDiscounts(); GetTax
GetTax
GetTax()
$eCart1->GetTax(); GetShipping
GetShipping
GetShipping()
$eCart1->GetShipping(); TotalRuleset
TotalRuleset
TotalRuleset($theSet)
Parameters:
$theSet - can be "Discounts", "Shipping", Tax", "Charges"
$eCart1->TotalRuleset("Discounts"); GetRuleValueByName
GetRuleValueByName
GetRuleValueByName($theSet, $theName)
Parameters:
$theSet - can be "Discounts", "Shipping", Tax", "Charges"
$eCart1->GetRuleValueByName($theSet, $theName); RuleLooperName
RuleLooperName
RuleLooperName($theSet)
Parameters:
$theSet - can be "Discounts", "Shipping", Tax", "Charges"
$eCart1->RuleLooperName("Shipping"); RuleLooperValue
RuleLooperValue
RuleLooperValue($theSet)
Parameters:
$theSet - can be "Discounts", "Shipping", Tax", "Charges"
$eCart1->RuleLooperValue("Charges"); ConditionalTotal
ConditionalTotal
ConditionalTotal($ColumnName, $ConditionalColumn, $ConditionalValue)
$eCart1->ConditionalTotal("Quantity", "Name", "Widget A"); GetTaxableTotal
GetTaxableTotal
GetTaxableTotal()
$eCart1->GetTaxableTotal(); GetTaxedSubtotal
GetTaxedSubtotal
GetTaxedSubtotal()
$eCart1->GetTaxedSubtotal(); GrandTotal
GrandTotal
GrandTotal()
$eCart1->GrandTotal(); DeleteZeroQuantity
DeleteZeroQuantity
DeleteZeroQuantity()
$eCart1->DeleteZeroQuantity(); Session_SaveCart
Session_SaveCart
Session_SaveCart()
$eCart1->Session_SaveCart(); Session_GetContent
Session_GetContent
Session_GetContent()
$eCart1->Session_GetContent(); Cookie_SaveCart
Cookie_SaveCart
Cookie_SaveCart()
$eCart1->Cookie_SaveCart(); Cookie_GetContent
Cookie_GetContent
Cookie_GetContent()
$eCart1->Cookie_GetContent(); WA_eCart_WeightConversion
WA_eCart_WeightConversion
WA_eCart_WeightConversion($theWeight, $startUnits, $endUnits)
$eCart1->WA_eCart_WeightConversion($theWeight, $startUnits, $endUnits); WA_eCart_GetWeightFromPounds
WA_eCart_GetWeightFromPounds
WA_eCart_GetWeightFromPounds($lbsWeight, $endUnits)
$eCart1->WA_eCart_GetWeightFromPounds($lbsWeight, $endUnits); WA_eCart_GetGroupDecimalChars
WA_eCart_GetGroupDecimalChars
WA_eCart_GetGroupDecimalChars($numDisplay)
$eCart1->WA_eCart_GetGroupDecimalChars($numDisplay); WA_eCart_DisplayMoney
WA_eCart_DisplayMoney
WA_eCart_DisplayMoney($theObject, $theAmount)
WA_eCart_DisplayMoney(eCart1, "12.99") WA_eCart_DisplayWeight
WA_eCart_DisplayWeight
WA_eCart_DisplayWeight($theObject, $theWeight)
$eCart1->IsEmpty(); WA_eCart_DisplayNumber
WA_eCart_DisplayNumber
WA_eCart_DisplayNumber($theObject, $theNumber)
$eCart1->IsEmpty(); WA_eCart_MaskOutput
WA_eCart_MaskOutput
WA_eCart_MaskOutput($tValue, $tMaskType, $tMaskArguments)
$eCart1->IsEmpty(); WA_eCart_MaskNumber
WA_eCart_MaskNumber
WA_eCart_MaskNumber($theNumStr, $groupChar, $decimalChar, $forceDec, $numDec)
$eCart1->IsEmpty(); WA_eCart_MaskWeightMoney
WA_eCart_MaskWeightMoney
WA_eCart_MaskWeightMoney($theNumStr, $symbolStr, $leftOrRight, $groupChar, $decimalChar, $forceDec, $numDec)
$eCart1->IsEmpty(); WA_eCart_MaskDate
WA_eCart_MaskDate
WA_eCart_MaskDate($dateVar, $dateFormat, $timeFormat)
$eCart1->IsEmpty(); WA_eCart_FormatNumber
WA_eCart_FormatNumber
WA_eCart_FormatNumber($theNumStr, $forceDec, $numDec)
$eCart1->IsEmpty(); WA_RoundToDecimals
WA_RoundToDecimals
WA_RoundToDecimals($theNum, $theDecimals)
$eCart1->IsEmpty(); WA_GetCountryName
WA_GetCountryName
WA_GetCountryName($countryCode)
$eCart1->IsEmpty(); WAEC_findRecordMySQL
WAEC_findRecordMySQL
WAEC_findRecordMySQL($theRS, $theCol, $theVal)
$eCart1->IsEmpty(); WA_isValidPayPal
WA_isValidPayPal
WA_isValidPayPal()
$eCart1->IsEmpty(); WAEC_getTimestamp
WAEC_getTimestamp
WAEC_getTimestamp()
$eCart1->IsEmpty(); siteToPageRel
siteToPageRel
siteToPageRel($theSite)
$eCart1->IsEmpty(); Reviews and comments
Reviews and commentsComments will be sent to the author of this tutorial and may not be answered immediately. For general help from WebAssist, please visit technical support.
Sign in to add commentsYour friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.
These out-of-the-box solutions provide you proven, tested applications that can be up and running now. Build a store, a gallery, or a web-based email solution.