Skip to content

classes_modules_payment_shoporderaddress.class

Daniel Spors edited this page Dec 19, 2023 · 2 revisions

Classes in file modules/payment/shoporderaddress.class.php

class ShopOrderAddress

Prototype of an Address Model. Your own address class must inherit from this. Usually this data is stored alongside the order itself so a typical IShopOrder::GetAddress method would just create a new ShopOrderAddress object and assign all properties from itself.

class MyShopOrder implements IShopOrder	
{	
public function GetAddress()	
{	
$res = new ShopOrderAddress();	
$res->Firstname = $this->fname;	
$res->Lastname = $this->lname;	
$res->Address1 = $this->street;	
$res->Zip = $this->zip;	
$res->City = $this->city;	
$res->Email = $this->email;	
return $res;	
}	
	
// more methods	
}	

Clone this wiki locally