Example #1
0
        if ($conectado === TRUE) {
            $content_download = $video->downloadContent($ftpCon);
            foreach ($content_download as $formato => $bajado) {
                $todos = $todos && $bajado;
                if (!$bajado) {
                    echo "<font color=\"red\">No se pudo bajar el video de formato {$formato}<br />";
                } else {
                    $alguno = true;
                }
            }
        } else {
            echo "ERROR: no se puede loguear al ftp\n";
        }
        if ($alguno === TRUE) {
            $xmlContent = $video->genXML();
            $arrayMuestra[] = $video->getArraySubForm();
            $total++;
            $written = file_put_contents($video->getDirToWrite() . "/" . $xmlFile, $xmlContent);
        } else {
            $log .= " ";
        }
    } catch (Exception $e) {
        $log .= "genXML: " . $e->getMessage() . "\n";
    }
}
// genero nombre para el zip
$i = 0;
$existe = TRUE;
while ($existe === TRUE) {
    if (file_exists(ZIP_DIR . "/{$zipFile}")) {
        $i++;