php - How to make Table from API Array of Data
Get the solution ↓↓↓So this is what I got from the API:
Array
(
[data] => Array
(
[items] => Array
(
[0] => Array
(
[alexa_info] => Array
(
[rank] =>
)
[alexa_rank_updated_at] =>
[cert_summary] => Array
(
[issuer_dn] => Array
(
[C] => US
[CN] => DigiCert SHA2 Extended Validation Server CA
[L] =>
[O] => DigiCert Inc
[OU] => www.digicert.com
[ST] =>
[emailAddress] =>
[raw] => C=US, O=DigiCert Inc, OU=www.digicert.com, CN=DigiCert SHA2 Extended Validation Server CA
)
[subject_dn] => Array
(
[C] => US
[CN] => www.apple.com`
Code:
echo '<table cellpadding="5" cellspacing="0" border="1">'; foreach ($data['items'] as $key => $value) { echo "<tr>"; foreach ($value as $info) echo "<td>".$info."</td>"; echo "</tr>"; } echo "</table>";
Share solution ↓
Additional Information:
Link To Answer People are also looking for solutions of the problem: to enable extensions, verify that they are enabled in your .ini files
Didn't find the answer?
Our community is visited by hundreds of web development professionals every day. Ask your question and get a quick answer for free.
Similar questions
Find the answer in similar questions on our website.
Write quick answer
Do you know the answer to this question? Write a quick response to it. With your help, we will make our community stronger.