Bläddra i källkod

Styled schedule sections in the home page.

Iñigo Valentin 9 år sedan
förälder
incheckning
5ae51898bb
2 ändrade filer med 144 tillägg och 104 borttagningar
  1. 33 9
      www/css/index.css
  2. 111 95
      www/index.php

+ 33 - 9
www/css/index.css

@@ -26,7 +26,7 @@ table.festival_section_table tr td div#festivals_summary{
 }
 
 table.festival_section_table tr td div#festivals_summary img{*/
-div#festivals img{
+div#festivals div#festivals_summary img{
 	display:		inline-block;
 	max-width:		40%;
 	max-height:		15em;
@@ -62,24 +62,48 @@ div#festivals div#festivals_schedule_table div#festivals_schedule_row div.festiv
 	margin: 0.4em 0.4em 0.4em 0.2em;
 }
 
-div.festival_event{
+div#festivals div#festivals_schedule_table div#festivals_schedule_row div.festivals_schedule_cell div.festival_event{
 	margin:			1em;
-	padding:		0.3em 0.3em 0.3em 1em;
-	border-left:	0.em solid black;
+	padding:		0.3em 0.3em 0.3em 0.5em;
 }
 
-div.festival_event span.title{
+div#festivals div#festivals_schedule_table div#festivals_schedule_row div.festivals_schedule_cell div.festival_event h4{
+	margin:			1em 0.2em 0.2em 0em;
 	font-weight:	bold;
-	margin:			0.5em;
+	color:			#444444;
 }
 
-div.festival_event span.description{
+div#festivals div#festivals_schedule_table div#festivals_schedule_row div.festivals_schedule_cell div.festival_event div.schedule_content{
+	border-left:	0.1em dotted black;
+	margin-left:	0.5em;
+}
+
+div#festivals div#festivals_schedule_table div#festivals_schedule_row div.festivals_schedule_cell div.festival_event span.title{
 	font-weight:	bold;
-	margin:			0.2em 1em 1em 1em;
+	font-size:		120%;
+	color:			#275573;
+	margin:			1em 0.5em 0.7em 0.2em;
+}
+
+div#festivals div#festivals_schedule_table div#festivals_schedule_row div.festivals_schedule_cell div.festival_event p.description{
+	margin:	0.2em 1em 1em 1em;
 }
 
-div.festival_event table.location{
+div#festivals div#festivals_schedule_table div#festivals_schedule_row div.festivals_schedule_cell div.festival_event table.location{
 	margin:		0.3em 1em 0.3em 1.6em;
+	font-size:	90%;
+	color:		#222222;
+}
+
+div#festivals div#festivals_schedule_table div#festivals_schedule_row div.festivals_schedule_cell div.festival_event table.location img{
+	max-width:	1.3em;
+	max-hieght:	1.5em;
+}
+
+div#festivals div#festivals_schedule_table div#festivals_schedule_row div.festivals_schedule_cell div.festival_event table.location span.address{
+	font-size:	80%;
+	font-style:	italic;
+	color:		#444444;
 }
 
 

+ 111 - 95
www/index.php

@@ -136,45 +136,48 @@
 												<meta itemprop='startDate' content='<?=$r_sch_curr['isostart']?>'/>
 												<span class='hidden' itemprop='location' itemscope itemtype='http://schema.org/Place'>
 													<meta itemprop='address' content='Vitoria-Gasteiz'/>
-												<span>
+												</span>
 <?php
 												if (strlen($r_sch_curr['isoend']) > 0){
 													echo("<meta itemprop='endDate' content='$r_sch_curr[isoend]'/>\n");
 												}
 ?>
-												<span class='title'><?=$r_sch_curr['title']?></span>
+												<div class='schedule_content'>
+													<span class='title'><?=$r_sch_curr['title']?></span>
 <?php
-												if (strlen($r_sch_curr["description"]) > 0 && $r_sch_curr["description"] != $r_sch_curr["title"]){
-													echo("<br/><p class='description'>$r_sch_curr[description]</p>\n");
-													echo("<meta itemprop='description' content='$r_sch_curr[description]'/>\n");
-												}
+													if (strlen($r_sch_curr["description"]) > 0 && $r_sch_curr["description"] != $r_sch_curr["title"]){
+														echo("<br/><p class='description'>$r_sch_curr[description]</p>\n");
+														echo("<meta itemprop='description' content='$r_sch_curr[description]'/>\n");
+													}
 ?>
-												<table class='location'>
-													<tr>
-														<td>
-															<a target='_blank' href='http://maps.google.com/maps?q=<?=$r_sch_curr[lat]?>,<?=$r_sch_curr[lon]?>+(My+Point)&z=14&ll=<?=$r_sch_curr[lat]?>,<?=$r_sch_curr[lon]?>'>
-																<img alt=' ' src='<?=$proto?><?=$http_host?>/img/misc/pinpoint.png'/>
-															</a>
-														</td>
-														<td>
+													<table class='location'>
+														<tr>
+															<td>
+																<a target='_blank' href='http://maps.google.com/maps?q=<?=$r_sch_curr[lat]?>,<?=$r_sch_curr[lon]?>+(My+Point)&z=14&ll=<?=$r_sch_curr[lat]?>,<?=$r_sch_curr[lon]?>'>
+																	<img alt=' ' src='<?=$proto?><?=$http_host?>/img/misc/pinpoint.png'/>
+																</a>
+															</td>
+															<td>
 <?php
-															//If name and address are the same, show only name
-															if ($r_sch_curr['place'] == $r_sch_curr['address']){
-																echo("$r_sch_curr[place]\n");
-															}
-															else{
-																echo("$r_sch_curr[place] <span class='address'>- $r_sch_curr[address]</span>\n");
-															}
+																//If name and address are the same, show only name
+																if ($r_sch_curr['place'] == $r_sch_curr['address']){
+																	echo("$r_sch_curr[place]\n");
+																}
+																else{
+																	echo("$r_sch_curr[place] <br/><span class='address'> $r_sch_curr[address]</span>\n");
+																}
 ?>
-														</td>
-													</tr>
-												</table>
+															</td>
+														</tr>
+													</table>
+												</div> <!--.schedule_content  -->
 											</div> <!-- festival-event -->
 <?php
 										} // if (mysqli_num_rows($q_sch_curr) > 0)
 										if (mysqli_num_rows($q_sch_next) > 0){
 											$r_sch_next = mysqli_fetch_array($q_sch_next);
 ?>
+											
 											<div class='festival_event' itemprop='subEvent' itemscope itemtype='http://schema.org/Event'>
 												<h4><?=$lng['index_festivals_schedule_next']?></h4>
 												<meta itemprop='inLanguage' content='<?=$lang?>'/>
@@ -183,36 +186,40 @@
 												<span class='hidden' itemprop='location' itemscope itemtype='http://schema.org/Place'>
 													<meta itemprop='address' itemprop='name'>Vitoria-Gasteiz</meta>
 												</span>
-												<span class='title'><?=$r_sch_next['title']?> - <?=$r_sch_next['st']?></span>
 <?php
 												if (strlen($r_sch_curr['isoend']) > 0){
-													echo "<meta itemprop='endDate' content='$r_sch_next[isoend]'/>\n";
-												}
-												if (strlen($r_sch_next["description"]) > 0 && $r_sch_next["description"] != $r_sch_next["title"]){
-													echo "<br/><p class='description'>$r_sch_next[description]</p>\n";
-													echo "<meta itemprclass='entry'op='description' content='$r_sch_next[description]'/>\n";
+													echo("<meta itemprop='endDate' content='$r_sch_next[isoend]'/>\n");
 												}
 ?>
-												<table class='location'>
-													<tr>
-														<td>
-															<a target='_blank' href='http://maps.google.com/maps?q=<?=$r_sch_next[lat]?>,<?=$r_sch_next[lon]?>+(My+Point)&z=14&ll=<?=$r_sch_next[lat]?>,<?=$r_sch_next[lon]?>'>
-																<img alt=' ' src='<?=$proto?><?=$http_host?>/img/misc/pinpoint.png'/>
-															</a>
-														</td>
-														<td>
+												<div class='schedule_content'>
+													<span class='title'><?=$r_sch_next['title']?> - <?=$r_sch_next['st']?></span>
 <?php
-															//If name and address are the same, show only name
-															if ($r_sch_next['place'] == $r_sch_next['address']){
-																echo("$r_sch_next[place]\n");
-															}
-															else{
-																echo("$r_sch_next[place] <span class='address'>- $r_sch_next[address]</span>\n");
-															}
+													if (strlen($r_sch_next["description"]) > 0 && $r_sch_next["description"] != $r_sch_next["title"]){
+														echo("<br/><p class='description'>$r_sch_next[description]</p>\n");
+														echo("<meta itemprclass='entry'op='description' content='$r_sch_next[description]'/>\n");
+													}
 ?>
-														</td>
-													</tr>
-												</table>
+													<table class='location'>
+														<tr>
+															<td>
+																<a target='_blank' href='http://maps.google.com/maps?q=<?=$r_sch_next[lat]?>,<?=$r_sch_next[lon]?>+(My+Point)&z=14&ll=<?=$r_sch_next[lat]?>,<?=$r_sch_next[lon]?>'>
+																	<img alt=' ' src='<?=$proto?><?=$http_host?>/img/misc/pinpoint.png'/>
+																</a>
+															</td>
+															<td>
+<?php
+																//If name and address are the same, show only name
+																if ($r_sch_next['place'] == $r_sch_next['address']){
+																	echo("$r_sch_next[place]\n");
+																}
+																else{
+																	echo("$r_sch_next[place] </br><span class='address'> $r_sch_next[address]</span>\n");
+																}
+?>
+															</td>
+														</tr>
+													</table>
+												</div> <!--.schedule_content  -->
 											</div> <!-- festival-event -->
 <?php
 										}
@@ -244,36 +251,41 @@
 												<span class='hidden' itemprop='location' itemscope itemtype='http://schema.org/Place'>
 													<meta itemprop='address' itemprop='name'>Vitoria-Gasteiz</meta>
 												</span>
-												<span class='title'><?=$r_sch_curr['title']?></span>
 <?php
 												if (strlen($r_sch_curr['isoend']) > 0){
-													echo "<meta itemprop='endDate' content='$r_sch_curr[isoend]'/>\n";
-												}
-												if (strlen($r_sch_curr["description"]) > 0 && $r_sch_curr["description"] != $r_sch_curr["title"]){
-													echo "<br/><p class='description'>$r_sch_curr[description]</p>\n";
-													echo "<meta itemprop='description' content='$r_sch_curr[description]'/>\n";
+													echo("<meta itemprop='endDate' content='$r_sch_curr[isoend]'/>\n");
 												}
 ?>
-												<table class='location'>
-													<tr>
-														<td>
-															<a target='_blank' href='http://maps.google.com/maps?q=<?=$r_sch_curr[lat]?>,<?=$r_sch_curr[lon]?>+(My+Point)&z=14&ll=<?=$r_sch_curr[lat]?>,<?=$r_sch_curr[lon]?>'>
-																<img alt=' ' src='<?=$proto?><?=$http_host?>/img/misc/pinpoint.png'/>
-															</a>
-														</td>
-														<td>
+												<div class='schedule_content'>
+													<span class='title'><?=$r_sch_curr['title']?></span>
+<?php
+
+													if (strlen($r_sch_curr["description"]) > 0 && $r_sch_curr["description"] != $r_sch_curr["title"]){
+														echo("<br/><p class='description'>$r_sch_curr[description]</p>\n");
+														echo("<meta itemprop='description' content='$r_sch_curr[description]'/>\n");
+													}
+?>
+													<table class='location'>
+														<tr>
+															<td>
+																<a target='_blank' href='http://maps.google.com/maps?q=<?=$r_sch_curr[lat]?>,<?=$r_sch_curr[lon]?>+(My+Point)&z=14&ll=<?=$r_sch_curr[lat]?>,<?=$r_sch_curr[lon]?>'>
+																	<img alt=' ' src='<?=$proto?><?=$http_host?>/img/misc/pinpoint.png'/>
+																</a>
+															</td>
+															<td>
 <?php
-															//If name and address are the same, show only name
-															if ($r_sch_curr['place'] == $r_sch_curr['address']){
-																echo("$r_sch_curr[place]\n");
-															}
-															else{
-																echo("$r_sch_curr[place] <span class='address'>- $r_sch_curr[address]</span>\n");
-															}
+																//If name and address are the same, show only name
+																if ($r_sch_curr['place'] == $r_sch_curr['address']){
+																	echo("$r_sch_curr[place]\n");
+																}
+																else{
+																	echo("$r_sch_curr[place] <br/><span class='address'> $r_sch_curr[address]</span>\n");
+																}
 ?>
-														</td>
-													</tr>
-												</table>
+															</td>
+														</tr>
+													</table>
+												</div> <!--.schedule_content  -->
 											</div> <!-- festival-event -->
 <?php
 										}
@@ -290,36 +302,40 @@
 												<span class='hidden' itemprop='location' itemscope itemtype='http://schema.org/Place'>
 													<meta itemprop='address' itemprop='name'>Vitoria-Gasteiz</meta>
 												</span>
-												<span class='title'><?=$r_sch_next['title']?> - (<?=$r_sch_next['st']?>)</span>
 <?php
 												if (strlen($r_sch_curr['isoend']) > 0){
 													echo "<meta itemprop='endDate' content='$r_sch_next[isoend]'/>\n";
 												}
-												if (strlen($r_sch_next["description"]) > 0 && $r_sch_next["description"] != $r_sch_next["title"]){
-													echo "<br/><p class='description'>$r_sch_next[description]</p>\n";
-													echo "<meta itemprop='description' content='$r_sch_next[description]'/>\n";
-												}
 ?>
-												<table class='location'>
-													<tr>
-														<td>
-															<a target='_blank' href='http://maps.google.com/maps?q=<?=$r_sch_next[lat]?>,<?=$r_sch_next[lon]?>+(My+Point)&z=14&ll=<?=$r_sch_next[lat]?>,<?=$r_sch_next[lon]?>'>
-																<img alt=' ' src='<?=$proto?><?=$http_host?>/img/misc/pinpoint.png'/>
-															</a>
-														</td>
-														<td>
+												<div class='schedule_content'>
+													<span class='title'><?=$r_sch_next['title']?> - <?=$r_sch_next['st']?></span>
+<?php
+													if (strlen($r_sch_next["description"]) > 0 && $r_sch_next["description"] != $r_sch_next["title"]){
+														echo "<br/><p class='description'>$r_sch_next[description]</p>\n";
+														echo "<meta itemprop='description' content='$r_sch_next[description]'/>\n";
+													}
+?>
+													<table class='location'>
+														<tr>
+															<td>
+																<a target='_blank' href='http://maps.google.com/maps?q=<?=$r_sch_next[lat]?>,<?=$r_sch_next[lon]?>+(My+Point)&z=14&ll=<?=$r_sch_next[lat]?>,<?=$r_sch_next[lon]?>'>
+																	<img alt=' ' src='<?=$proto?><?=$http_host?>/img/misc/pinpoint.png'/>
+																</a>
+															</td>
+															<td>
 <?php
-															//If name and address are the same, show only name
-															if ($r_sch_next['place'] == $r_sch_next['address']){
-																echo("$r_sch_next[place]\n");
-															}
-															else{
-																echo("$r_sch_next[place] <span class='address'>- $r_sch_next[address]</span>\n");
-															}
+																//If name and address are the same, show only name
+																if ($r_sch_next['place'] == $r_sch_next['address']){
+																	echo("$r_sch_next[place]\n");
+																}
+																else{
+																	echo("$r_sch_next[place] <br/><span class='address'> $r_sch_next[address]</span>\n");
+																}
 ?>
-														</td>
-													</tr>
-												</table>
+															</td>
+														</tr>
+													</table>
+												</div> <!--.schedule_content  -->
 											</div> <!-- festival-event -->
 <?php
 										}