Browse Source

fixed foreach error

Eddie Machado 13 năm trước cách đây
mục cha
commit
6139d5d43b
1 tập tin đã thay đổi với 2 bổ sung2 xóa
  1. 2 2
      library/admin.php

+ 2 - 2
library/admin.php

@@ -60,7 +60,7 @@ function bones_rss_dashboard_widget() {
 		$items = $feed->get_items(0, $limit);                      // create an array of items
 	}
 	if ($limit == 0) echo '<div>The RSS Feed is either empty or unavailable.</div>';   // fallback message
-	else foreach ($items as $item) : ?>
+	else foreach ($items as $item) { ?>
 
 	<h4 style="margin-bottom: 0;">
 		<a href="<?php echo $item->get_permalink(); ?>" title="<?php echo mysql2date(__('j F Y @ g:i a', 'bonestheme'), $item->get_date('Y-m-d H:i:s')); ?>" target="_blank">
@@ -70,7 +70,7 @@ function bones_rss_dashboard_widget() {
 	<p style="margin-top: 0.5em;">
 		<?php echo substr($item->get_description(), 0, 200); ?>
 	</p>
-	<?php endforeach;
+	<?php }
 }
 
 // calling all custom dashboard widgets