Browse Source

Still fixing styles

Xen 1 year ago
parent
commit
afd1b0de35
2 changed files with 11 additions and 15 deletions
  1. 2 2
      www/article.php
  2. 9 13
      www/index.php

+ 2 - 2
www/article.php

@@ -75,7 +75,7 @@ function clean_str($str) {
         <span class="newsfeed">NewsFeed</span>
         <?php echo $loc ?> front page
     </a></small>
-    <h1 class="newsfeed"><?php echo clean_str($readability->getTitle());?></h1>
+    <h1><?php echo clean_str($readability->getTitle());?></h1>
     <p><small><a href="<?php echo $article_url ?>" target="_blank">Original source</a> (on modern site) <?php
         $img_num = 0;
         $imgline_html = "| Article images:";
@@ -91,7 +91,7 @@ function clean_str($str) {
         }
     ?></small></p>
     <?php if($error_text) { echo "<p><font color='red'>" . $error_text . "</font></p>"; } ?>
-    <p><?php echo $readable_article;?></font></p>
+    <p><?php echo $readable_article;?></p>
     <small><a href="/index.php?loc=<?php echo $loc ?>">< Back to <span class="brand">NewsFeed</span> <?php echo $loc ?> front page</a></small>
 </body>
  </html>

+ 9 - 13
www/index.php

@@ -63,7 +63,7 @@ function clean_str($str) {
 		<i>NewsFeed.FYI</i>
 	</h1>
 	<hr>
-	<span style="text-align: center; font-size: small;">
+	<p style="text-align: center; font-size: small;">
 		Basic HTML Google News Feed. Based on 
 		<a href="https://github.com/ActionRetro/68k-news" target="_blank">
 			<b>source</b>
@@ -77,16 +77,14 @@ function clean_str($str) {
 			<b>Action Retro</b>
 		</a>
 		.
-	</span>
+	</p>
 	<?php
 	if($section) {
 		$section_title = explode(" - ", strtoupper($feed->get_title()));
-		echo "<center><h2>" . $section_title[0]  . " NEWS</h2></center>";
+		echo "<h2 syle='text-align: center;'>" . $section_title[0]  . " NEWS</h2>";
 	}
 	?>
-	<small>
-	<p>
-	<center>
+	<p style="text-align: center; font-size: small;">
 		<a href="index.php?loc=<?php echo $loc ?>">TOP</a>
 		<a href="index.php?section=world&loc=<?php echo strtoupper($loc) ?>">WORLD</a>
 		<a href="index.php?section=nation&loc=<?php echo strtoupper($loc) ?>">NATION</a>
@@ -96,13 +94,11 @@ function clean_str($str) {
 		<a href="index.php?section=science&loc=<?php echo strtoupper($loc) ?>">SCIENCE</a>
 		<a href="index.php?section=health&loc=<?php echo strtoupper($loc) ?>">HEALTH</a>
 		<br>
-		<span class="brandname" style="size: 1;">-=-=-=-=-=-=-=-=-=-=-=-=-=-</span>
+		<span class="newsfeed" style="size: 1;">-=-=-=-=-=-=-=-=-=-=-=-=-=-</span>
 		<br>
 		<?php echo strtoupper($loc) ?> Edition
 		<a href="choose_edition.php">(Change)</a>
-	</center>
 	</p>
-	</small>
 	<?php
 	/*
 	Here, we'll loop through all of the items in the feed, and $item represents the current item in the loop.
@@ -110,8 +106,8 @@ function clean_str($str) {
 	foreach ($feed->get_items() as $item):
 	?>
  
-			<h3><font size="5"><a href="<?php echo 'article.php?loc=' . $loc . '&a=' . $item->get_permalink(); ?>"><?php echo clean_str($item->get_title()); ?></a></font></h3>
-			<p><font size="4"><?php 
+			<h3 style="font-size: 5;"><a href="<?php echo 'article.php?loc=' . $loc . '&a=' . $item->get_permalink(); ?>"><?php echo clean_str($item->get_title()); ?></a></h3>
+			<p style="font-size: 4;"><?php 
             $subheadlines = clean_str($item->get_description());
             $remove_google_link = explode("<li><strong>", $subheadlines);
             $no_blank = str_replace('target="_blank"', "", $remove_google_link[0]) . "</li></ol></font></p>"; 
@@ -122,9 +118,9 @@ function clean_str($str) {
 			$cleaned_links = str_replace( "View Full Coverage on Google News", "", $cleaned_links);
             echo $cleaned_links;
             ?></p>
-			<p><small>Posted on <?php echo $item->get_date('j F Y | g:i a'); ?></small></p>
+			<p style="text-align: center; font-size: small;">Posted on <?php echo $item->get_date('j F Y | g:i a'); ?></p>
  
 	<?php endforeach; ?>
-	<p><center><small>v1.0 Powered by Mozilla Readability (Andres Rey PHP Port) and SimplePie</small><center></p>
+	<p style="text-align: center; font-size: small;">v1.0 Powered by Mozilla Readability (Andres Rey PHP Port) and SimplePie</p>
 </body>
 </html>