오픈 소스 PHP 래퍼를 편집하여 XML을 내보내려고합니다.XML에서 PHP 로의 배열?
원본 :이처럼 될 수 있도록
$new_invoice = array(
array(
"Type"=>"ACCREC",
"Contact" => array(
"ContactID" => "[contact id]"
),
"Date" => "2010-04-08",
"DueDate" => "2010-04-30",
"Status" => "SUBMITTED",
"LineAmountTypes" => "Exclusive",
"LineItems"=> array(
"LineItem" => array(
array(
"Description" => "Just another test invoice",
"Quantity" => "2.0000",
"UnitAmount" => "250.00",
"AccountCode" => "200"
)
)
)
)
);
내가 다른 LineItem을 추가했습니다
$new_invoice = array(
array(
"Type"=>"ACCREC",
"Contact" => array(
"ContactID" => "7937FF1D-B135-4BD0-A219-4B621EA3808C"
),
"Date" => "2010-04-08",
"DueDate" => "2010-04-30",
"Status" => "DRAFT",
"LineAmountTypes" => "Exclusive",
"LineItems"=> array(
"LineItem" => array(
array(
"Description" => "Just another test invoice",
"Quantity" => "2.0000",
"UnitAmount" => "250.00",
"AccountCode" => "200"
)
)
"LineItem" => array(
array(
"Description" => "Just another test invoice2",
"Quantity" => "2.0000",
"UnitAmount" => "250.00",
"AccountCode" => "200"
)
)
)
)
);
을하지만 닫는 브래킷을 기대 "라고 오류가있어) 이 보인다 모든 괄호가 있으므로 혼란 스럽습니다.