WPCF7_ConstantContact_ContactPostRequest::add_street_address() public CF7 1.0
{} Это метод класса: WPCF7_ConstantContact_ContactPostRequest{}
Хуков нет.
Возвращает
Null. Ничего.
Использование
$WPCF7_ConstantContact_ContactPostRequest = new WPCF7_ConstantContact_ContactPostRequest(); $WPCF7_ConstantContact_ContactPostRequest->add_street_address( $street, $city, $state, $postal_code, $country, $kind );
Код WPCF7_ConstantContact_ContactPostRequest::add_street_address() WPCF7 ConstantContact ContactPostRequest::add street address CF7 5.3.2
public function add_street_address( $street, $city, $state, $postal_code, $country, $kind = 'home' ) {
$street = trim( $street );
$city = trim( $city );
$state = trim( $state );
$postal_code = trim( $postal_code );
$country = trim( $country );
if ( ! ( $street || $city || $state || $postal_code || $country )
or 1 <= count( $this->street_addresses )
or ! in_array( $kind, array( 'home', 'work', 'other' ) )
or 255 < $this->strlen( $street )
or 50 < $this->strlen( $city )
or 50 < $this->strlen( $state )
or 50 < $this->strlen( $postal_code )
or 50 < $this->strlen( $country ) ) {
return false;
}
return $this->street_addresses[] = array(
'kind' => $kind,
'street' => $street,
'city' => $city,
'state' => $state,
'postal_code' => $postal_code,
'country' => $country,
);
}