• Register
Plug-in Tutorial Build an EC-CUBE plug-in

Top Commentators

114

1

EC Mike

SHOGUNSHOGUN

32

2

hrbabu

SAMURAISAMURAI

29

3

Sumant Jha

SAMURAISAMURAI

29

4

justcubed

SAMURAISAMURAI

21

5

Ashok Kafle

SAMURAISAMURAI

21

6

shahith

SAMURAISAMURAI

14

7

Jeemusu

KABUKIKABUKI

14

8

Yangsin

KABUKIKABUKI

9

9

Zaw Hlaing Bwar

GEISYAGEISYA

8

10

Fei Liu

GEISYAGEISYA

Ranking Key

  • FUJISANFUJISAN1,000+ posts
  • SAKURASAKURA500+ posts
  • SHOGUNSHOGUN100+ posts
  • NINJYANINJYA50+ posts
  • SAMURAISAMURAI20+ posts
  • KABUKIKABUKI10+ posts
  • GEISYAGEISYALess than 10 posts

how to update/edit delivery address?

0 votes

I would like to create a page that edit the delivery address of the customer and the function that return all info of the customer passing the customer_id.

 

//connect to database
  function init() {
        parent::init();
        $masterData         = new SC_DB_MasterData_Ex();
        $this->arrPref      = $masterData->getMasterData('mtb_pref');
        $this->httpCacheControl('nocache');
    }
 
action(){
//what should i do here?
}
asked 2013-10-10 by krishfran (320 points) KABUKIKABUKI

1 Answer

0 votes
Hello Krishfran,

I would take a look at  SC_Helper_Address.php. Call the functions from your page or at the very least copy them and adapt them to work on your new page:

Use the function getAddress or getList to obtain the delivery addresses.

Then when you want to write back to the db (insert or update) use the function registAddress.

I hope that helps. Let me know if you have any other questions.

Thank you,

Mike
answered 2013-10-10 by EC Mike (6,360 points) SHOGUNSHOGUN
...