Menu
Guide
Reference
Cookbook
Try
Buy
Search
Reference
Options
Config options
Hooks
Translations
Site methods
Field methods
Classes
Cart
ListItem
ListItems
Logger
Merx
OrderPage
PaymentDetails
Price
PricingRule
PricingRules
ProductList
ProductPage
Tax
TaxRule
TaxRules
API Reference
Models
Routes
Panel blueprints
Fields
Layouts
Pages
Tabs
Releases
Merx 2
new Merx()
Initializes cart and gateways
Merx::calculateTax()
Calculates tax amount from gross price and tax rate
$merx->cart()
Returns visitors cart.
$merx->createOrder()
Stores order page to file system
Merx::currency()
Currency of the pricing rule
Merx::exceptionDetails()
Diagnostic details of an exception, for use in `Exception::$details`
Merx::filterOrderData()
Removes the fields Merx sets itself from client submitted order data
Merx::formatCurrency()
Formats a currency number E.g. 1045.12 → € 1,045.12 Similar to I18n::formatNumber()
Merx::formatIBAN()
Helper method to format IBAN
Merx::formatPercent()
Formats a float to percent E.g. 0.19 → 19 % Similar to I18n::formatNumber()
$merx->initializeOrder()
Creates virtual OrderPage and validates it. Runs the payment gateway’s `initializePayment` function. Saves virtual OrderPage in the customer’s session.
Merx::pricingRule()
Gets a pricing rule by its key, or finds the one that applies to the current context
Merx::pricingRules()
Gets all pricing rules defined by pricing rule option
Merx::returnUrl()
Url to be used to complete the payment
Merx::taxRule()
Gets the tax rule by its key
Merx::taxRules()
Gets all tax rules defined by tax rule option
new Merx()
Initializes cart and gateways
src/Merx.php#L79
new Merx()
Parent class
Wagnerwagner\Merx\Merx