diff --git a/private/bin/importOldData.php b/private/bin/importOldData.php index 2f6d260..4ded4af 100644 --- a/private/bin/importOldData.php +++ b/private/bin/importOldData.php @@ -31,10 +31,13 @@ else { GlobalVariables::get("dao")->save($admin); } +$count = 0; $imgDir = "/home/r.didato/mediaimg/notizie"; -$statement = $pdo->query("select * from notizia order by id desc limit 0,100"); +$statement = $pdo->query("select * from notizia order by id desc limit $count,100"); $dati = $statement->fetchALL(PDO::FETCH_CLASS,"stdClass"); -// while (is_array($dati) && sizeof($dati)==0){ + +while (is_array($dati) && sizeof($dati)>0){ + foreach ($dati as $ele){ $notizia = new stdClass(); $notizia->status = NotiziaModel::STATUS_ACCEPTED; @@ -129,7 +132,10 @@ $dati = $statement->fetchALL(PDO::FETCH_CLASS,"stdClass"); // } // } + $count+=100; + $statement = $pdo->query("select * from notizia order by id desc limit $count,100"); + $dati = $statement->fetchALL(PDO::FETCH_CLASS,"stdClass"); } -// } +} ?> \ No newline at end of file diff --git a/public/style/admin.css b/public/style/admin.css index 557cc5e..fee7656 100644 --- a/public/style/admin.css +++ b/public/style/admin.css @@ -120,7 +120,7 @@ div.commentoAcceptance > .buttons a.red:hover{background-color:#FF8DA6;} div.commentoAcceptance > .buttons a.yellow:hover{background-color:#FF8DA6;} div.commentoBlock{border: 4px solid #CFCFCF;border-radius: 15px;padding: 12px 5px 5px 20px;margin: 5px 0px;background-color: #E6E6E6;} - +.commentiBlock ul {list-style: none;} /* ____ _ _ _ _ _ _____ ____ | __ ) / \ | \ | | \ | | ____| _ \