Jump to content

Clientdetails array problem


Recommended Posts

Hi,

 

I'm working on a custom module, and having a problem understanding how to retrieve clients information from clientsdata and configarray arrays :

 

function wapple_ConfigOptions() {

# Should return an array of the module options for each product - maximum of 24

$configarray = array(

"Package ID" => array( "Type" => "dropdown", "Options" => "20,29,30,31"),

);

return $configarray;

}

 

$plan_id = $configarray["Type"];

 

--- This doesn't seem to be working ---

 

and

 

$clientsdetails = $params["clientsdetails"]; # Array of clients details - firstname, lastname, email, country, etc...

 

 

$myfirstname = $clientsdetails['firstname'],

$mylastname = $clientsdetails['lastname'],

$myemail = $clientsdetails['email'],

 

 

-- These also don't have a values---

 

However if I retrieve from a variable and NOT array, I don't have a problem :

 

$myserverusername = $serverusername = $params["serverusername"];

 

-- This one works just fine --

 

Could you guys help me out here, what am I doing wrong?

 

Thank you in advance,

Link to comment
Share on other sites

  • 7 months later...
Hi,

 

I'm working on a custom module, and having a problem understanding how to retrieve clients information from clientsdata and configarray arrays :

 

function wapple_ConfigOptions() {

# Should return an array of the module options for each product - maximum of 24

$configarray = array(

"Package ID" => array( "Type" => "dropdown", "Options" => "20,29,30,31"),

);

return $configarray;

}

 

$plan_id = $configarray["Type"];

 

--- This doesn't seem to be working ---

 

and

 

$clientsdetails = $params["clientsdetails"]; # Array of clients details - firstname, lastname, email, country, etc...

 

 

$myfirstname = $clientsdetails['firstname'],

$mylastname = $clientsdetails['lastname'],

$myemail = $clientsdetails['email'],

 

 

-- These also don't have a values---

 

However if I retrieve from a variable and NOT array, I don't have a problem :

 

$myserverusername = $serverusername = $params["serverusername"];

 

-- This one works just fine --

 

Could you guys help me out here, what am I doing wrong?

 

Thank you in advance,

 

Hi,

At the end of this line

$mylastname = $clientsdetails['lastname'],

 

Your using a command instead of a semicolon.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated