Location: PHPKode > scripts > WH Social > wh_social/modules/news.inc.php
<?php

    echo '<div class="content_left">
    <div id="breadcrumb">
        <ul class="crumbs">
            <li class="first"><a href="index.php" style="z-index:9;"><span></span>' . $lang['index'] . '</a></li>
            <li><a href="news.php" style="z-index:8;">' . $lang['news'] . '</a></li>
        </ul>
    </div>
    </div>

    <div class="content_right">';

        include('modules/search.inc.php');
    echo '</div>

    <div class="clear_long"></div>';

    $ret = 1;

    echo '<div class="main_menu">';

        $ret = include 'framework/templates/'.$main_content['menu'];
    echo '<div id="line"></div>';

        $ret = include 'framework/templates/'.$main_content['infos'];
    echo '</div>';

    echo '<div class="main_content">';

    echo '<table width="97%" align="center" cellpadding="0" cellspacing="0">
    <tr><td>';

    echo '<h1 class="p_space">' . $lang['news'] . '</h1>';

    $count = mysql_query("SELECT id FROM news WHERE `check` = '1'");
	$news = mysql_num_rows($count);

	echo '<p align="right">' . $news . ' ' . $lang['articles'] . '<a href="framework/feeds/articles.php" target="_blank"><img src="style/buttons/rss.png" alt="Feeds" hspace="5" border="0"></a></p>';

    echo '</td></tr></table>';

	$path  = $_SERVER["PHP_SELF"];
	$query = mysql_query("SELECT id FROM news WHERE `check` = '1'");
	$total = mysql_num_rows($query);
	$allsites = ceil($total / $entries);

	include('framework/functions/pagination.php');

	$sql = "SELECT
     			id,
				author,
    			title,
    			text,
    			date
			FROM
  				news
			WHERE
           		`check` = '1'
			ORDER BY
				id DESC
			LIMIT
   				$start,$entries";

	$result = mysql_query($sql) OR die(mysql_error());

    if(!$result) {

	echo '<p class="false">' . $lang['no_articles'] . '</p>' . mysql_error();

		}else{

		if(intval(mysql_num_rows($result)) == 0) {

		echo '<p class="false">' . $lang['no_articles'] . '</p>' . mysql_error();

	}else{

    echo '<div id="container">';

    echo '<div class="timeline_container">
    <div class="timeline">
    <div class="plus"></div>
    </div>
    </div>';

    echo '<table width="100%" cellpadding="0" cellspacing="0">
    <tr><td>';

	while($row = mysql_fetch_assoc($result)) {

		echo '<div class="item">
        <a href="#" class="deletebox">X</a>
        <div>
            <a href="mailto:' . $webmaster . '">' . htmlentities($row['author'], ENT_QUOTES) . '</a>&nbsp;&nbsp;&nbsp;<small>' . date('d.m.Y - H:i', strtotime($row['date'])) . '</small><br><br>
            <p class="p_news">' . htmlentities($row['title'], ENT_QUOTES) . '</p>
            ' . nl2br(stripslashes($row['text'])) . '
        </div>
        </div>';
        }

    echo '</td></tr>
    </table>';

    echo '</div>';

    echo '<div class="clear_long"></div>';

    echo '<table width="97%" align="center" cellpadding="0" cellspacing="0">
    <tr><td>';

    echo '<span class="pages">Seite ' . $page . ' von ' . $allsites . '</span>';
	echo $link_string;

    echo '</td></tr>
    </table>';

	echo '<div class="clear"></div>';
	}
	}

?>
Return current item: WH Social