Well to be honest it seems simpler doing it the way I've done it. I'm trying to avoid using third party stuff on the main site, and wanted to code as much of it as I could myself. And learning simpleXML to code this myself is going to be awkward, and I can't find a decent tutorial. What I've done to get the news on www.blackvine-animation.co.uk from www.community.blackvine-animation.co.uk is this:
<?php
include 'config.php';
include 'opendb.php';
$query = "SELECT news_subject FROM fusion_news ORDER BY news_datestamp DESC LIMIT 0,10";
$result = mysql_query($query);
if($row = mysql_fetch_array($result, MYSQL_ASSOC))
$subjects = nl2br("{$row['news_subject']}<br>" );
echo stripslashes($subjects);
?>
</div>
<div id="imageplace"></div>
<p>
<?php
include 'config.php';
include 'opendb.php';
$query = "SELECT * FROM fusion_news ORDER BY news_datestamp DESC LIMIT 0,10";
$result = mysql_query($query);
if($row = mysql_fetch_array($result, MYSQL_ASSOC))
$news = nl2br("{$row['news_news']} <br>") .
nl2br("{$row['news_extended']} <br><br>");
{
echo stripslashes($news);
}
include 'closedb.php';
?>
That just takes the news and subject from the database entry that php-fusion makes when news is entered via the form on there. What I want is to get the user name on there aswell. In the fusion_news table, it identifies the user who made the post by news_name, which is entered as a numeric value.
In the table fusion_users, there is user_name and user_id. User_name is there name in text, user_id is numeric value. I need to make it take the news_name numeric value, then make that equal user_id, then make that find the user_name, but don't know how. Any idea how to do this? Even just pointing me in the right direction as in like a name of a function or something that I can research and learn myself would be great.