<?php
(
0 => null,
1 => 'Fye Flourigh',
2 => '+5521888',
3 => null,
4 => null,
5 => null,
6 => null
);
for($i=0;$i < count($data_content);$i++) { // Faz um loop para pegar todos os elemento da array $data_content. if($data_content[$i] != null) { // Se o valor do elemento da array for diferente de vazio ele continua
if($i == 1) { // Se o valor do elemento da array for um(contacts_form_name)
echo "Nome do contato:" . $data_content[$i] . "\n";
}
if($i == 2) { // Se o valor do elemento da array ser dois(whatsapp)
echo "Whatsapp do contato:" . $data_content[$i] . "\n";
}
if($i == 3) { // Se o valor do elemento da array ser três(email)
echo "Email do contato:" . $data_content[$i] . "\n";
}
if($i == 4) { // Se o valor do elemento da array ser quatro(site)
echo "Site do contato:" . $data_content[$i] . "\n";
}
if($i == 5) { // Se o valor do elemento da array ser cinco(facebook)
echo "Facebook do contato:" . $data_content[$i] . "\n";
}
if($i == 6) { // Se o valor do elemento da array ser igual a seis(messenger)
echo "Messenger do contato:" . $data_content[$i] . "\n";
}
}
}
PD9waHAgCgokZGF0YV9jb250ZW50ID0gQXJyYXkKKAogICAgMCA9PiBudWxsLAogICAgMSA9PiAnRnllIEZsb3VyaWdoJywKICAgIDIgPT4gJys1NTIxODg4JywKICAgIDMgPT4gbnVsbCwKICAgIDQgPT4gbnVsbCwKICAgIDUgPT4gbnVsbCwKICAgIDYgPT4gbnVsbAopOwoKZm9yKCRpPTA7JGkgPCBjb3VudCgkZGF0YV9jb250ZW50KTskaSsrKSB7IC8vIEZheiB1bSBsb29wIHBhcmEgcGVnYXIgdG9kb3Mgb3MgZWxlbWVudG8gZGEgYXJyYXkgJGRhdGFfY29udGVudC4KICBpZigkZGF0YV9jb250ZW50WyRpXSAhPSBudWxsKSB7IC8vIFNlIG8gdmFsb3IgZG8gZWxlbWVudG8gZGEgYXJyYXkgZm9yIGRpZmVyZW50ZSBkZSB2YXppbyBlbGUgY29udGludWEKICAgIGlmKCRpID09IDEpIHsgLy8gU2UgbyB2YWxvciBkbyBlbGVtZW50byBkYSBhcnJheSBm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