4 require
'../../../_src/_config.php';
7 $tx =
'<!DOCTYPE HTML>';
10 $tx .=
'<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css">';
11 $tx .=
'<meta name="viewport" content="width=device-width">';
13 $tx .=
'<h3>immagine responsiva <span id="dimensions"></span></h3>';
14 $tx .=
'<picture style="width: 100%;">';
15 foreach(
$ct[
'img'][
'formats'][
'l'] as
$w =>
$h ) {
16 $tx .=
'<source srcset="../../../var/immagini/' .
$w .
'l/slide03.jpg" media="(orientation: landscape) and (max-width: ' .
$w .
'px)">';
18 foreach(
$ct[
'img'][
'formats'][
'p'] as
$w =>
$h ) {
19 $tx .=
'<source srcset="../../../var/immagini/' .
$w .
'p/slide03.jpg" media="(orientation: portrait) and (max-width: ' .
$w .
'px)">';
21 $tx .=
'<img class="img-fluid" src="../../../var/immagini/slide03.jpg" alt="prova slide 03">';
24 $tx .=
'window.onresize = displayWindowSize;';
25 $tx .=
'window.onload = displayWindowSize;';
26 $tx .=
'function displayWindowSize() {';
27 $tx .=
'myWidth = window.innerWidth;';
28 $tx .=
'myHeight = window.innerHeight;';
29 $tx .=
' document.getElementById("dimensions").innerHTML = myWidth + "x" + myHeight;';
if(isset( $cx['contatti'])) if(isset( $cf['site']['contatti'])) $ct['contatti']