Hi,

I need help you php master to solve a problem with this code to open new window when someone click.

<!--RSS FEED-->
<?php if(function_exists('fetch_feed')) {

	include_once(ABSPATH.WPINC.'/feed.php');
	$feed = fetch_feed('http://feeds.com/');

	$limit = $feed->get_item_quantity(20); // specify number of items
	$items = $feed->get_items(0, $limit); // create an array of items

}
if ($limit == 0) echo '<div>XXXXXX</div>';
else foreach ($items as $item) : ?>

<div>
	<a href="<?php echo $item->get_permalink(); ?>"
	  title="<?php echo $item->get_date('j F Y @ g:i a'); ?>">
		<?php echo $item->get_title(); ?>
	</a>
</div>
<div>
	<?php echo substr($item->get_description(), 0, 0); ?>
	<span></span>
</div>

<?php endforeach; ?>

:D

Sorry I have just let target blank like this below and works well

<!--RSS FEED-->
<?php if(function_exists('fetch_feed')) {

	include_once(ABSPATH.WPINC.'/feed.php');
	$feed = fetch_feed('http://feeds.com/');

	$limit = $feed->get_item_quantity(20); // specify number of items
	$items = $feed->get_items(0, $limit); // create an array of items

}
if ($limit == 0) echo '<div>Powered by SportPicks.WS</div>';
else foreach ($items as $item) : ?>

<div>
	<a href="<?php echo $item->get_permalink(); ?>
	  title="<?php echo $item->get_date('j F Y @ g:i a'); ?>" target="_blank">
		<?php echo $item->get_title(); ?>
	</a>
</div>
<div>
	<?php echo substr($item->get_description(), 0, 0); ?>
	<span></span>
</div>

<?php endforeach; ?>

SoLVED

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.