SimplePortal
Customization => Custom Coding => Topic started by: Mick. on December 27, 2009, 11:28:11 AM
-
Can anyone clean this code for me? This for the latest pics from SMF gallery media.
I keep getting this error:
Use of undefined constant Owner - assumed 'Owner'
global $sourcedir, $user_info, $ID_MEMBER, $context, $txt, $galurl, $galurl2, $scripturl, $settings, $db_prefix;
require_once($sourcedir . '/Subs-MGallery.php');
loadMGal_Settings();
if(loadlanguage('MGallery') == false)
loadLanguage('MGallery', 'english');
$items = getMediaItems(0, 5, 'm.id_media DESC');
echo '
<table border="0" width="100%" cellspacing="1" cellpadding="4">
<br />
';
foreach($items as $item)
echo '
<td class="windowbg2">
<div class="smalltext" style=" line-height: 1.4em; border: 0px #000000 solid; padding: 5px;">
<a href="',$galurl,'sa=item;id=',$item['id'],'"><img alt="" src="',$galurl,'sa=media;id=',$item['id'],';thumb" alt="" /></a><br />
',Owner,': <a href="',$scripturl,'?action=profile;u=',$item['poster_id'],'">',$item['poster_name'],'</a><br />
</div>
</td>';
echo '
</tr>
</table>';
-
Find:
',Owner,': <a href="',$scripturl,'?action=profile;u=',$item['poster_id'],'">',$item['poster_name'],'</a><br />
Replace with:
Owner: <a href="',$scripturl,'?action=profile;u=',$item['poster_id'],'">',$item['poster_name'],'</a><br />
-
Thanx, ill tru it out ;)