diff --git a/private/lib/gui/GUIHandlerMobile.php b/private/lib/gui/GUIHandlerMobile.php
index 26447a5..4f473ed 100644
--- a/private/lib/gui/GUIHandlerMobile.php
+++ b/private/lib/gui/GUIHandlerMobile.php
@@ -201,7 +201,16 @@ class GUIHandlerMobile {
+
+
+
+
+
+
Selezionate una data per la ricerca, e premere il tasto Invia.
+ titolo) > 103) ? substr($notizia->titolo,0,100).'...' : $notizia->titolo;
+ $stringSottotitolo = (strlen($notizia->sottotitolo) > 73) ? substr($notizia->sottotitolo,0,70).'...' : $notizia->sottotitolo;
+ $stringTesto = (strlen($notizia->testo) > 33) ? substr($notizia->testo,0,30).'...' : $notizia->testo;
+ $media = DaoMediaHandler::getMainMediaFromModel($notizia);
+ ?>
+
+
renderMedia(array("size"=>MediaRenderer::SIZE_SMALL)):"" ;?>
+
+
+
+
+
+
+
+
+ 1){
+ ?>
+
+ Inizio
+
+
...
+
+ $numPages){
+// $j=page-2;
+ if($page +1 == $numPages){
+ $last = $page+1;;
+ }
+ else{
+ $last = $page;
+ }
+ }
+
+ for($j;$j<=$last;$j++){
+ if($j == $page){
+ ?>
+
+
+
+
+
+
+
+
+
+
...
+
+ Ultima ()
+
+
+
+
+
+
+
+
Nessun articolo trovato nella data selezionata.
+
+
+
+
+
\ No newline at end of file
diff --git a/public/mobile/categorySummary.php b/public/mobile/categorySummary.php
new file mode 100644
index 0000000..0b38d4f
--- /dev/null
+++ b/public/mobile/categorySummary.php
@@ -0,0 +1,77 @@
+NotiziaModel::$NOTIZIE_CATEGORY[$_GET["category"]]["label"]));
+
+ $category = "";
+ if(array_key_exists("category", $_GET) && strcmp($_GET["category"], "")!=0){
+
+// var_dump(NotiziaModel::$NOTIZIE_CATEGORY[intval($_GET["category"])]["hidden"]);
+ if(NotiziaModel::$NOTIZIE_CATEGORY[$_GET["category"]]["hidden"]){
+ GUIHandlerMobile::redirect("index.php");
+ }
+ $category = $_GET["category"];
+
+// $category = NotiziaModel::CATEGORY_CRONACA;
+
+ $category = intval($category);
+
+ $notizie = GlobalVariables::get("dao")->query("NotiziaModel",
+ array("status"=>NotiziaModel::STATUS_ACCEPTED,"category"=>$category,"about.data"=>array('$lte'=>new MongoDate())),
+ array("sort"=>array("about.data"=>-1),"limit"=>10)
+ );
+
+ if (sizeof($notizie)>0){
+ $notizie = array_map(function($ele){$ele->testo = strip_tags($ele->testo);$ele->sottotitolo = strip_tags($ele->sottotitolo); return $ele; }, $notizie);
+ }
+ }
+ else{
+ GUIHandlerMobile::redirect("index.php");
+ }
+
+
+}catch(GUIException $ex){
+ $error = $ex->getMessage();
+}catch (Exception $exec){
+ $msg = LogModel::fromException($exec);
+ GlobalVariables::get("dao")->save($msg);
+
+ GUIHandlerMobile::redirect("index.php");
+}
+?>
+
+
+
+ titolo) > 103) ? substr($notizia->titolo,0,100).'...' : $notizia->titolo;
+ $stringSottotitolo = (strlen($notizia->sottotitolo) > 73) ? substr($notizia->sottotitolo,0,70).'...' : $notizia->sottotitolo;
+ $stringTesto = (strlen($notizia->testo) > 33) ? substr($notizia->testo,0,30).'...' : $notizia->testo;
+ $media = DaoMediaHandler::getMainMediaFromModel($notizia);
+ ?>
+
+
renderMedia(array("size"=>MediaRenderer::SIZE_SMALL)):"" ;?>
+
+
+
+
+
+
+
+
+
+
+
diff --git a/public/mobile/images/blueBalls.png b/public/mobile/images/blueBalls.png
new file mode 100644
index 0000000..f6b4b17
Binary files /dev/null and b/public/mobile/images/blueBalls.png differ
diff --git a/public/mobile/js/functions.js b/public/mobile/js/functions.js
new file mode 100644
index 0000000..c916538
--- /dev/null
+++ b/public/mobile/js/functions.js
@@ -0,0 +1,79 @@
+function openPagePost(page, request, blank){
+ var blank = typeof blank !== 'undefined' ? blank : false;
+ var inputs = '';
+ request.forEach(function(element, index, array){
+ inputs += '
+
Inserisci i tuoi dati per accedere
+
+
+
+
+
+
\ No newline at end of file
diff --git a/public/mobile/logoutMobile.php b/public/mobile/logoutMobile.php
new file mode 100644
index 0000000..bedd079
--- /dev/null
+++ b/public/mobile/logoutMobile.php
@@ -0,0 +1,13 @@
+
\ No newline at end of file
diff --git a/public/mobile/passwordForgotMobile.php b/public/mobile/passwordForgotMobile.php
new file mode 100644
index 0000000..1c4f28f
--- /dev/null
+++ b/public/mobile/passwordForgotMobile.php
@@ -0,0 +1,98 @@
+getFirst("UserModel",array("email"=>$email)); // WTF!?!?!
+
+ if (is_null($user)){
+ $msg = "Email non valida";
+ }
+ else {
+ $sent = true;
+
+ $oldOne = GlobalVariables::get("dao")->getFirst("PasswordRecoveryRequestModel",array("target.class"=>"UserModel","target.id"=>$user->id));
+ if (!is_null($oldOne)){
+ GlobalVariables::get("dao")->delete($oldOne);
+ }
+ $request = PasswordRecoveryRequestModel::fromModel($user);
+ GlobalVariables::get("dao")->save($request);
+
+// $mail = FDN_MailHelper::getUserPasswordResetMail($user);
+// GlobalVariables::get("dao")->save($mail);
+ }
+
+ }
+
+}catch(GUIException $ex){
+ $msg = $ex->getMessage();
+ $err = true;
+}catch (Exception $exec){
+ $model = LogModel::fromException($exec);
+ GlobalVariables::get("dao")->save($model);
+ $msg = "Si è verificato un errore inatteso durante l'operazione. Se il problema persiste contattaci comunicandoci il seguente codice
+
Inserisci la tua email per recuperare i dati
+
+
+
+
+
\ No newline at end of file
diff --git a/public/mobile/redazione.php b/public/mobile/redazione.php
new file mode 100644
index 0000000..84eb029
--- /dev/null
+++ b/public/mobile/redazione.php
@@ -0,0 +1,42 @@
+getMessage();
+ }catch (Exception $exec){
+ $msg = LogModel::fromException($exec);
+ GlobalVariables::get("dao")->save($msg);
+
+ GUIHandlerMobile::redirect("index.php");
+ }
+?>
+
+
+
La tua registrazione è quasi completa!
+
A breve riceverai un'email all'indirizzo
email;?>
per completare la registrazione
+
+
+
+
+
\ No newline at end of file
diff --git a/public/mobile/searchResults.php b/public/mobile/searchResults.php
new file mode 100644
index 0000000..1f42a3f
--- /dev/null
+++ b/public/mobile/searchResults.php
@@ -0,0 +1,206 @@
+id);
+ AnalyticsHelper::logPageImpression();
+
+ GUIHandlerMobile::generateHtmlHeaders();
+ $searchParameters = "";
+ if(array_key_exists("search", $_POST) && strcmp($_POST["search"], "")!=0){
+
+// var_dump($_POST["search"]);
+ $searchParameters = strip_tags(PostHandler::get("search"));
+
+
+ $found = false;
+ $limit=10;
+ $page = 1;
+ $numPages = 1;
+
+ if(array_key_exists("page", $_POST)){
+ $page = intval($_POST["page"]);
+ }
+
+ $skip =($page - 1) * $limit;
+
+ $notizieAll = GlobalVariables::get("dao")->searchCount("NotiziaModel",$searchParameters,
+ array("status"=>NotiziaModel::STATUS_ACCEPTED)
+ );
+
+// $notizieAll = GlobalVariables::get("dao")->query("NotiziaModel",
+// array("status"=>NotiziaModel::STATUS_ACCEPTED)
+// );
+
+ if($notizieAll>0){
+// $dim = count($notizieAll);
+ $numPages = ceil($notizieAll/$limit);
+ $found = true;
+ }
+ else{
+ $found = false;
+ }
+
+ $notizie = GlobalVariables::get("dao")->search("NotiziaModel",$searchParameters,
+ array("status"=>NotiziaModel::STATUS_ACCEPTED),
+ array("sort"=>array("about.data"=>-1),"limit"=>$limit,"skip"=>$skip)
+ );
+
+// $notizie = GlobalVariables::get("dao")->query("NotiziaModel",
+// array("status"=>NotiziaModel::STATUS_ACCEPTED),
+// array("sort"=>array("about.data"=>-1),"skip"=>$skip,"limit"=>$limit)
+// );
+
+ if (sizeof($notizie)>0){
+ $found=true;
+ $notizie = array_map(function($ele){$ele->testo = strip_tags($ele->testo);$ele->sottotitolo = strip_tags($ele->sottotitolo); return $ele; }, $notizie);
+ }
+
+ }
+ else{
+ GUIHandlerMobile::redirect("index.php");
+ }
+
+
+}catch(GUIException $ex){
+ $error = $ex->getMessage();
+}catch (Exception $exec){
+ $msg = LogModel::fromException($exec);
+ GlobalVariables::get("dao")->save($msg);
+
+// GUIHandlerMobile::redirect("index.php");
+}
+?>
+
+
+
+
+
+ titolo) > 103) ? substr($notizia->titolo,0,100).'...' : $notizia->titolo;
+ $stringSottotitolo = (strlen($notizia->sottotitolo) > 73) ? substr($notizia->sottotitolo,0,70).'...' : $notizia->sottotitolo;
+ $stringTesto = (strlen($notizia->testo) > 33) ? substr($notizia->testo,0,30).'...' : $notizia->testo;
+ $media = DaoMediaHandler::getMainMediaFromModel($notizia);
+ ?>
+
+
renderMedia(array("size"=>MediaRenderer::SIZE_SMALL)):"" ;?>
+
+
+
+
+
+
+
+
+
+
Nessun articolo trovato con questi parametri di ricerca.
+
+
+
+
diff --git a/public/mobile/style/public.css b/public/mobile/style/public.css
index 702a7d0..85920ed 100644
--- a/public/mobile/style/public.css
+++ b/public/mobile/style/public.css
@@ -22,10 +22,12 @@ body{font-family:lato, arial;}
.bottomBar #loginMobile{border:0px;margin-left:1vw;}
.bottomBar img{width:2.2em;display:inline-block;}
-.menuContainer{width:100vw;height:215vh;position:fixed;margin-left:-100vw;background-color:#333;z-index:100;overflow:scroll;top:0;}
+.menuContainer{width:100vw;height:115vh;position:fixed;margin-left:-100vw;background-color:#333;z-index:100;overflow:scroll;top:0;}
+.loginContainer{width:100vw;height:100vh;position:fixed;margin-left:100vw;background-color:#333;z-index:100;overflow:auto;top:0;}
.menuHead{text-align:right;overflow:auto;}
-#closeMenu{height:2em;float:right;margin:0.3em 0.3em 0.3em 10px;}
+#closeLogin,#closeMenu{height:2em;float:right;margin:0.3em 0.3em 0.3em 10px;}
+#closeLogin{float:left;}
.searchBar{overflow:auto;height:2em;margin:0.3em 10px;}
.searchBar > div{font-size:14pt;position:relative;}
@@ -47,8 +49,9 @@ body{font-family:lato, arial;}
right: 0.3em;
}
-.menuBar{font-weight:bold;color:white;/* background-color:#0069a3 */;height:200vh;padding-bottom:15vh;}
-.menuTab{
+.loginReg,.menuBar{font-weight:bold;color:white;/* background-color:#0069a3 */;}
+.menuBar{height:100%;}
+.menuTab{
font-size: 14pt;
font-family: "Bebas Neue";
border-radius: 5px 0px 0px 5px;
@@ -61,6 +64,26 @@ body{font-family:lato, arial;}
.menuTab > ul{margin:0;}
.menuTab > ul > li{width:60%;}
+.loginData{
+ font-size: 14pt;
+ font-family: "Bebas Neue";
+ /* margin: 0px 5px 2px 10px; */
+
+ background-color: #222;
+ /* border-left: 5px solid #0069a3; */
+ padding:5px;
+ margin-top:5vh;
+ text-align:center;
+}
+.loginData a{color:white;}
+.loginData .modalBody{padding:0 0 15px;}
+.loginData .modalBody .title{padding:5px;}
+.loginData .modalBody form div{padding:5px;}
+.loginData .modalBody form input{padding:5px;}
+.loginData .modalBody form div.btn{padding:0px;}
+.loginData .modalBody form a.btn{padding:5px 15px;border:1px solid; border-radius:5px;display:inline-block;}
+
+
.footer{background-color:/* #095a87 */black;text-align:center;width:100vw;font-size:8pt;color:white;overflow:hidden;}
.footer .footerButton{text-align:center;margin-bottom:2vw;}
@@ -169,3 +192,66 @@ body{font-family:lato, arial;}
.newCommento div{padding:5px 0px;}
.newCommento textarea{}
.newCommento input{padding:5px 10px;}
+
+/**
+
+CATEGORY SUMMARY
+
+*/
+.notiziaContainer{padding:0 10px;}
+.notiziaContainer div{display:inline-block;}
+.notiziaContainer a{color:black;vertical-align:middle;display:inline-block;}
+.notiziaContainer a div{display:block;}
+
+
+.searchResultsContainer, .archivioResults, .categorySummaryContainer{width:100%;padding:5px 2vw 5px 0px;box-sizing:border-box;}
+.searchResultsContainer > .notiziaContainer, .archivioResults > .notiziaContainer,
+.categorySummaryContainer > .notiziaContainer{border:solid #d6d6d6 1px;margin-bottom:5px;padding:1vw;}
+.notiziaContainer > .notiziaImage{display:inline-block;vertical-align:middle;text-align:center;max-width:40vw;}
+.notiziaContainer .notiziaImage.mediaContent img{max-width:40vw;}
+.notiziaContainer > .notiziaInfo{
+ display:inline-block;
+ width:50vw;
+ padding:2vw;
+ vertical-align:middle;
+ cursor:pointer;
+ text-decoration:none;
+ color:black;
+ font-size:10pt;
+}
+.notiziaInfo > .notiziaTitolo{font-weight:bold;padding:5px;}
+.notiziaInfo > .notiziaSottotitolo{padding:5px;}
+.notiziaInfo > .notiziaTesto{padding:5px;color:#1a9ee9;font-weight:bold;}
+
+
+.archivioDate{padding:5px 0px;font-size:10pt;}
+.archivioDate select, .archivioDate input{padding:2px 10px; margin:5px 5px 0px; border:solid #1a9ee9 1px;}
+
+/*
+ ____ _ _ _
+| _ \ __ _ __ _(_)_ __ __ _| |_(_) ___ _ __
+| |_) / _` |/ _` | | '_ \ / _` | __| |/ _ \| '_ \
+| __/ (_| | (_| | | | | | (_| | |_| | (_) | | | |
+|_| \__,_|\__, |_|_| |_|\__,_|\__|_|\___/|_| |_|
+ |___/
+*/
+
+.paging {padding:5px 0px;font-size:10pt;}
+.paging .page{margin:0px 5px 0px 5px;display:inline-block;padding:5px 5px;background-color:#B7B7B7;cursor:pointer;}
+.paging .page.noSelection{cursor:default;}
+.paging .page.noSelection:hover{background-color:#B7B7B7;}
+.paging .page.current{font-weight:bold;cursor:default;background-color:#d3d3d3;}
+.paging .page:hover{background-color:#939393;}
+.paging .page.current:hover{background-color:#d3d3d3;}
+
+/*
+ ____ _ _
+| _ \ ___ __| | __ _ ___(_) ___ _ __ ___
+| |_) / _ \/ _` |/ _` |_ / |/ _ \| '_ \ / _ \
+| _ < __/ (_| | (_| |/ /| | (_) | | | | __/
+|_| \_\___|\__,_|\__,_/___|_|\___/|_| |_|\___|
+
+*/
+
+.contattiRedazione{text-align:center;font-size:14pt;padding:10px 5px;color:#199fe6;}
+.contattiRedazione a{color:black;}
diff --git a/public/searchResults.php b/public/searchResults.php
index bccd228..15d319f 100644
--- a/public/searchResults.php
+++ b/public/searchResults.php
@@ -91,19 +91,12 @@ try {
?>