Compare commits

..

No commits in common. "87c95fc7c12c5447348e615ac9cc6654372cb513" and "a169a5d66e938a128955804a2ac386b49387479c" have entirely different histories.

4 changed files with 349 additions and 388 deletions

View file

@ -709,10 +709,9 @@ img.minilogo {
margin-top: 0px; margin-top: 0px;
text-align: left; text-align: left;
font-family: 'titilliumlight'; font-family: 'titilliumlight';
font-size: 1.8em; font-size: 2em;
text-transform: uppercase; text-transform: uppercase;
color: #c53f33; color: #c53f33;
margin-bottom: 0.4em;
} }
p.elements{margin:0px 1.5em !important; p.elements{margin:0px 1.5em !important;
padding: 0em; padding: 0em;
@ -1139,13 +1138,6 @@ width: 150px;}
.ui-content{margin-top: 1em !important;} .ui-content{margin-top: 1em !important;}
.panel_logo {
height: 20vh;
margin: 0 50% 10%;
transform: translate(-50%, 0);
-webkit-transform: translate(-50%, 0);
-moz-transform: translate(-50%, 0);
}
/*footer*/ /*footer*/
@ -1157,30 +1149,6 @@ width: 150px;}
max-width: 797px; max-width: 797px;
margin-left: -1px; margin-left: -1px;
} }
#navheader {
padding-top: 0;
top: 0;
}
#nav2 {
background-color: orange;
max-height: 70px;
}
.rwd {
/*max-width: auto;*/
max-height: 30px;
}
.my-new-list li {
border-bottom: 1px solid gray;
}
#outside, .ui-body-a, .ui-page-theme-a .ui-body-inherit, html .ui-bar-a .ui-body-inherit, html .ui-body-a .ui-body-inherit, html body .ui-group-theme-a .ui-body-inherit, html .ui-panel-page-container-a {
background-color: purple !important;
}
/*BLOCCO DI TUTTO A MAX WIDTH:(800) /*BLOCCO DI TUTTO A MAX WIDTH:(800)
.ui-mobile .ui-page, body { .ui-mobile .ui-page, body {

View file

@ -46,18 +46,89 @@
<script type="text/javascript" src="cordova.js"></script> <script type="text/javascript" src="cordova.js"></script>
<script type="text/javascript" src="js/push.js"></script> <script type="text/javascript" src="js/push.js"></script>
<script type="text/javascript" src="js/share.js"></script> <script type="text/javascript" src="js/share.js"></script>
<script type="text/javascript">
$(document).on("mobileinit", function () {
$("body").pagecontainer({
defaults: true
});
$(".ui-loader").loader({
defaults: true
});
$("input").button();
});
$(document).on("pagecontainerchange", function () {    
var current = $(".ui-page-active").prop("id");     // Remove active class from nav buttons
    
console.log("current" + current);
$("[data-role='navbar'] a.ui-btn-active").removeClass("ui-btn-active");     // Add active class to current nav button
    
$("[data-role='navbar'] a").each(function () {
var href = $(this).prop("href");        
if (href.indexOf(current, href.length - current.length) !== -1) {            
$(this).addClass("ui-btn-active");        
}    
});
});
$(document).on("pagecreate", function () {
$("body > [data-role='panel']").panel();
$("body > [data-role='panel'] [data-role='listview']").listview();
$("body > [data-role='header']").toolbar();
$("body > [data-role='footer']").toolbar();
$("body > [data-role='navbar']").navbar();
$("#navfooter").navbar();
postInList();
});
/*per inizio navigazione*/
var Site = function () {
this.homepage = "#index"; // the default page that is loaded
this.init();
};
Site.prototype.init = function () {
var self = this;
$(document).ready(function () {
// default page if no hash given
// this changes the hash, so the event is fired
// no need to call self.navigate
window.location.hash = self.homepage;
});
};
// On document ready
$(function () {
intercettaUrl();
new Site();
$(".minibox").click(function () {
});
});
</script>
</head> </head>
<body> <body>
<!--panel --> <!--panel -->
<div data-role="panel" data-position="right" id="outside" data-theme="a" data-position-fixed="true" data-display="overlay" data-swipe-close="true"> <div data-role="panel" data-position="right" id="outside" data-theme="a" data-position-fixed="true" data-display="overlay" data-swipe-close="true">
<p><img src="image/ilovexm24_puzzle-300x300.jpg" class="panel_logo" /></p> <p><img src="image/xm-logo.png" class="rwd" /></p>
<ul data-role="listview"> <ul data-role="listview">
<li><a class="nav" href="#info">Info</a></li>
<li><a class="nav" href="#ilove">I love XM24</a></li> <li><a class="nav" href="#ilove">I love XM24</a></li>
<li><a class="nav" href="#events">Events</a></li> <li><a class="nav" href="#info">Info</a></li>
<li><a class="nav" href="#about">About</a></li>
<li> <li>
<input type="text" class="cerca" value="" placeholder="Cerca" data-clear-btn="true" /> <input type="text" class="cerca" value="" placeholder="Cerca" data-clear-btn="true" />
</li> </li>
@ -80,20 +151,18 @@
</div> </div>
<!--/navbar --> <!--/navbar -->
<div data-role="header" data-position="fixed" id="navheader"> <div data-role="header" data-position="fixed" id="navheader" class="hide">
<div data-role="navbar" id="nav2" data-iconpos="left" data-theme="a"> <div data-role="navbar" id="nav2" data-iconpos="left" data-theme="a">
<ul class="downnav"> <ul class="downnav">
<li><a class="ui-mini" href="#outside" data-icon="bars"> <li><a class="ui-mini nav" href="#index">Home</a> </li>
<img src="image/xm-logo.png" class="rwd" /> <li><a class="ui-mini" href="#outside">Menù</a> </li>
</a>
</li>
</ul> </ul>
</div> </div>
</div> </div>
<!-- /header --> <!-- /header -->
<!-- Home page --> <!-- Home page -->
<!-- <div data-role="page" id="index" data-dom-cache="true" data-theme="a" class="ui-page"> <div data-role="page" id="index" data-dom-cache="true" data-theme="a" class="ui-page">
<center><p><img src="image/xm-logo.png" class="rwd" /></p> <center><p><img src="image/xm-logo.png" class="rwd" /></p>
<ul data-role="listview" data-inset="true"> <ul data-role="listview" data-inset="true">
<li> <li>
@ -101,7 +170,7 @@
<img src="./image/ilovexm24_puzzle-300x300.jpg" class="ui-li-thumb"> <img src="./image/ilovexm24_puzzle-300x300.jpg" class="ui-li-thumb">
<h2>I love XM24</h2> <h2>I love XM24</h2>
<p>Bla blabla</p> <p>Bla blabla</p>
<!-p class="ui-li-aside">iOS</p-=> <!--p class="ui-li-aside">iOS</p-->
</a> </a>
</li> </li>
<li> <li>
@ -109,7 +178,7 @@
<img src="./image/xm24-particolare2.jpeg" class="ui-li-thumb"> <img src="./image/xm24-particolare2.jpeg" class="ui-li-thumb">
<h2>Info e comunicati</h2> <h2>Info e comunicati</h2>
<p>Bla Bla blabla</p> <p>Bla Bla blabla</p>
<!--p class="ui-li-aside">BlackBerry</p-=> <!--p class="ui-li-aside">BlackBerry</p-->
</a> </a>
</li> </li>
<li> <li>
@ -121,11 +190,11 @@
</li> </li>
</ul> </ul>
</center> </center>
<!=-a class="minibox orange nav" href="#eventi"> Eventi</a> <!--a class="minibox orange nav" href="#eventi"> Eventi</a>
<a class="minibox green nav" href="#lab"> Laboratori</a> <a class="minibox green nav" href="#lab"> Laboratori</a>
<a class="minibox green nav" href="#ultime"> News</a> <a class="minibox green nav" href="#ultime"> News</a>
<a class="minibox green nav" href="#tag"> Tag</a> <a class="minibox green nav" href="#tag"> Tag</a>
<a class="minibox blue nav" href="#quotidiano"> Un post a caso</a ==> <a class="minibox blue nav" href="#quotidiano"> Un post a caso</a-->
<br/ style="clear:both;"> <br/ style="clear:both;">
<div id="aggiornahome">Aggiorna i contenuti dal sito XM24 di tanto in tanto. <div id="aggiornahome">Aggiorna i contenuti dal sito XM24 di tanto in tanto.
@ -156,21 +225,8 @@
<input type="button" value="OK" onclick='$("#benvenuta").popup("close");alterContent(#info);' /> <input type="button" value="OK" onclick='$("#benvenuta").popup("close");alterContent(#info);' />
</div> </div>
</div> --> </div>
<div data-role="page" id="info" data-prev="index" data-next="" data-dom-cache="true" data-theme="a" class="ui-page">
<div role="main" class="ui-content">
<!-- <center><p><img src="image/xm-logo.png" class="rwd" /></p></center> -->
<div class="ui-body">
<p class="introlettera">Info e comunicati</p>
<p id="mostralistainfo" class="listatovirgole listevoci">
<img class="gifloader" src="./image/ajax_loader_red_512.gif" />
</p>
</div>
<!-- chiude body-->
</div>
<!--chiude content -->
</div>
</div> </div>
<div data-role="page" id="events" data-prev="index" data-next="" data-dom-cache="true" data-theme="a" class="ui-page"> <div data-role="page" id="events" data-prev="index" data-next="" data-dom-cache="true" data-theme="a" class="ui-page">
@ -200,7 +256,20 @@
<!--chiude content --> <!--chiude content -->
</div> </div>
<!-- chiude pagina --> <!-- chiude pagina -->
<div data-role="page" id="info" data-prev="index" data-next="" data-dom-cache="true" data-theme="a" class="ui-page">
<div role="main" class="ui-content">
<div class="ui-body">
<p class="introlettera">Info e comunicati</p>
<p id="mostralistainfo" class="listatovirgole listevoci">
<img class="gifloader" src="./image/ajax_loader_red_512.gif" />
</p>
</div>
<!-- chiude body-->
</div>
<!--chiude content -->
</div>
<!-- chiude pagina --> <!-- chiude pagina -->
<div data-role="page" id="quotidiano" data-transition="slide" data-prev="index" data-next="" data-dom-cache="true" data-theme="a" class="ui-page"> <div data-role="page" id="quotidiano" data-transition="slide" data-prev="index" data-next="" data-dom-cache="true" data-theme="a" class="ui-page">
<div role="main" class="ui-content"> <div role="main" class="ui-content">

View file

@ -108,7 +108,6 @@ function getParameterByName(name, url) {
function display_results(contenitore, messaggio) { function display_results(contenitore, messaggio) {
$(contenitore).text(messaggio); $(contenitore).text(messaggio);
}; };
$(function () { $(function () {
$("form").submit(function () { $("form").submit(function () {
return false; return false;
@ -136,98 +135,23 @@ function setFirstRun() {
} }
} }
}; };
/*per link in browser di default */ /*per link in browser di default */
document.addEventListener("deviceready", onDeviceReady, false); document.addEventListener("deviceready", onDeviceReady, false);
//le cose all'inizio //le cose all'inizio
$(document).on("mobileinit", function () {
$("body").pagecontainer({
defaults: true
});
$(".ui-loader").loader({
defaults: true
});
$("input").button();
});
$(document).on("pagecontainerchange", function () {    
var current = $(".ui-page-active").prop("id");     // Remove active class from nav buttons
    
console.log("current" + current);
$("[data-role='navbar'] a.ui-btn-active").removeClass("ui-btn-active");     // Add active class to current nav button
    
$("[data-role='navbar'] a").each(function () {
var href = $(this).prop("href");        
if (href.indexOf(current, href.length - current.length) !== -1) {            
$(this).addClass("ui-btn-active");        
}    
});
});
$(document).on("pagecreate", function () {
$("body > [data-role='panel']").panel();
$("body > [data-role='panel'] [data-role='listview']").listview();
$("body > [data-role='header']").toolbar();
$("body > [data-role='footer']").toolbar();
$("body > [data-role='navbar']").navbar();
$("#navfooter").navbar();
postInList();
});
/*per inizio navigazione*/
var Site = function () {
this.homepage = "#index"; // the default page that is loaded
this.init();
};
Site.prototype.init = function () {
var self = this;
$(document).ready(function () {
// default page if no hash given
// this changes the hash, so the event is fired
// no need to call self.navigate
window.location.hash = self.homepage;
});
};
// On document ready
$(function () {
// intercettaUrl();
// new Site();
// $(".minibox").click(function () {});
});
function onDeviceReady() { function onDeviceReady() {
// console.log('deviceready'); // console.log('deviceready');
createDB(); createDB();
setFirstRun(); setFirstRun();
$("#navheader").addClass("hide");
$("#navfooter").addClass("hide");
$("a.nav").on("click", function (event) { $("a.nav").on("click", function (event) {
// Prevent the usual navigation behavior // Prevent the usual navigation behavior
event.preventDefault(); event.preventDefault();
hrefseguente = $(this).attr("href"); hrefseguente = $(this).attr("href");
alterContent(hrefseguente); alterContent(hrefseguente);
}); });
// eliminare le due righe:
$("body > [data-role='header']").toolbar();
$("[data-role='navbar']").navbar();
alterContent("#info");
}; };
function overlayblock() { function overlayblock() {
$(".overlaynero").toggleClass("hide"); $(".overlaynero").toggleClass("hide");
} }
@ -573,9 +497,9 @@ function cercaMe() {
var dTime = new Date(time); var dTime = new Date(time);
if (dTime.getTime() <= lastUpdateDate) { if (dTime.getTime() <= lastUpdateDate) {
//key mi dice l'indice' //key mi dice l'indice'
items.push("<li><a href='#singleQpost' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small></li>"); items.push("<li><a href='#singleQpost' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small>|</li>");
} else { } else {
items.push("<p><a href='#' onclick='aggiornaora();' style='color:#666;' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small></p>"); items.push("<p><a href='#' onclick='aggiornaora();' style='color:#666;' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small>|</p>");
} }
}); });
$("<ul/>", { $("<ul/>", {

View file

@ -22,10 +22,10 @@ function myJsonCategory(Qcategory, div, addTagCategory) {
} }
}); });
//key mi dice l'indice' //key mi dice l'indice'
items.push("<li class='"+ cattag +"'><a href='#singleQpost' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small><span>" + tag + "</span>|</li>"); items.push("<li class='"+ cattag +"'><a href='#singleQpost' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small>|<span>" + tag + "</span>|</li>");
} }
else {*/ else {*/
items.push("<li><a href='#singleQpost' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small></li>"); items.push("<li><a href='#singleQpost' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small>|</li>");
} }
$("<ul/>", { $("<ul/>", {
@ -56,7 +56,7 @@ function myJsonLastPage(div) {
var splitTime = time.split("T"); var splitTime = time.split("T");
var cleanTime = splitTime[0]; var cleanTime = splitTime[0];
//key mi dice l'indice' //key mi dice l'indice'
items.push("<li><a href='#singleQpost' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small>"); items.push("<li><a href='#singleQpost' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small>|");
} }
$("<ul/>", { $("<ul/>", {
"class": "my-new-list" "class": "my-new-list"
@ -92,7 +92,7 @@ function myJsonCategoryPaginated(Qcategory, div, pageNumber) {
var splitTime = time.split("T"); var splitTime = time.split("T");
var cleanTime = splitTime[0]; var cleanTime = splitTime[0];
//key mi dice l'indice' //key mi dice l'indice'
items.push("<li><a href='#singleQpost' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small></li>"); items.push("<li><a href='#singleQpost' data-post='" + id + "'>" + title + "</a><br/><small>" + cleanTime + "</small>|</li>");
} }
$("<ul/>", { $("<ul/>", {
"class": "my-new-list" "class": "my-new-list"