Well, I got 2 files from the author of the site I first showed you. He said these will make it like his. If I posted the files, could someone please explain how to make this work?
THANKS!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
The First file is called catalog.php and includes:
<?php
/************************************************************************
index.php
-------------------
begin : Saturday, Feb 13, 2001
copyright : (C) 2001 The phpBB Group
email : support@phpbb.com
$Id: index.php,v 1.99.2.3 2004/07/11 16:46:15 acydburn Exp $
*************************************************************************/
/************************************************************************
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
************************************************************************/
define('IN_PHPBB', true);
$phpbb_root_path = './';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.'.$phpEx);
include($phpbb_root_path . 'catdata.'.$phpEx);
//
// Start session management
//
$userdata = session_pagestart($user_ip, PAGE_INDEX);
init_userprefs($userdata);
//
// End session management
//
$page_title = 'Available Free Items';
include($phpbb_root_path . 'includes/page_header.'.$phpEx);
$offers = '';
$offers .= '<table border="0" width="100%" cellspacing="0" cellpadding="0">
<tr>
<td colspan="3"><center><span class="genmed">' . $overview . '</span></center><br /><br /></td>
</tr>
';
//$useroffersid = encodeuid($userdata['user_id']);
$useroffersid = $userdata['user_id'];
foreach ($name as $key => $value) {
// if ($imgurl[$key] != '' && $linkurl[$key] != '') {
$offers .= " <tr>
<td width=\"20%\" align=\"right\"><a href=\"" . $linkurl[$key] . $useroffersid . "\" target=\"_blank\"><img src=\"$imgurl[$key]\"></a></td>
<td width=\"0\"> </td>
<td width=\"80%\"><span class=\"genmed\"><p align=\"center\"><b>$name[$key] - $referrals[$key] Referrals</b></p><br />$description[$key]</span></td>
</tr>
<tr><td width=\"100%\" colspan=\"3\"><hr></td></tr>
";
// }
}
$offers .= '
</table>';
$template->set_filenames(array(
'message_body' => 'message_body.tpl')
);
$template->assign_vars(array(
'MESSAGE_TITLE' => $page_title,
'MESSAGE_TEXT' => $offers)
);
$template->pparse('message_body');
include($phpbb_root_path . 'includes/page_tail.'.$phpEx);
?>
THE SECOND FILE IS CALLED Referral_view.php and is:
<?php
/************************************************************************
referral_view.php
-------------------
begin : Friday, June 20, 2002
copyright : (C) 2001 The phpBB Group
email : support@phpbb.com
created by : John B. Abela <abela@phpbb.com>
edited by : Verfaillie Steven <rancisis@pandora.be>
**************************************************************************/
/************************************************************************
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
************************************************************************/
/***********************************************************************
This file will be used for displaying the referrals log publicaly, within a users profile.
File initially created by John B. Abela, edited by Verfaillie Steven to create new feature,
re-edited by John B. Abela to streamline code and setup for distribution with main package.
************************************************************************/
define('IN_PHPBB', true);
$phpbb_root_path = './';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.'.$phpEx);
if ( !empty($board_config['default_lang']) )
{
include($phpbb_root_path . 'language/lang_' . $board_config['default_lang'] . '/lang_referral.'.$phpEx);
}
else
{
include($phpbb_root_path . 'language/lang_english/lang_referral.'.$phpEx);
}
//
// Start session management
//
$userdata = session_pagestart($user_ip, PAGE_INDEX);
init_userprefs($userdata);
//
// End session management
//
$page_title = 'Status';
$template->set_filenames(array(
'body' => 'referral_view_body.tpl')
);
if ( !empty($HTTP_GET_VARS['ruid']) )
{
$ruid = $HTTP_GET_VARS['ruid'];
}
elseif ( !empty($HTTP_GET_VARS['ruid']) )
{
$ruid = $HTTP_GET_VARS['ruid'];
}
else
{
$ruid = $board_config['referral_id'];
}
$ruid = intval($ruid);
$viewdata = get_userdata($ruid);
$offcompl = $viewdata['user_offer'];
if ($offcompl == '1') {
$offcompl = '<font color="#00FF00">Congratulations! Your offer has been completed!</font>';
} elseif ($offcompl == '2') {
$offcompl = '<font color="#00FF00">Congratulations! Your item has been SENT!!!!!</font>';
} else {
$offcompl = '<font color="#FFFF00">Please complete an offer!</font>';
}
//
// Generate SQL
//
$sql = "SELECT *
FROM " . REFERRAL_TABLE . "
WHERE ruid = '" . $ruid . "'";
if( !$result = $db->sql_query($sql) )
{
message_die(GENERAL_ERROR, "Could not query referral table", $lang['Error'], LINE, FILE, $sql);
}
$referral_rows = $db->sql_fetchrowset($result);
$referral_count = count($referral_rows);
$reflink = '<a href="'. real_path('portal.'.$phpEx.'?ref=' . $ruid) . '"><i>' . real_path('portal.'.$phpEx.'?ref=' . $ruid);
if ($userdata['user_id'] == $ruid && $viewdata['user_street'] != '' && $viewdata['user_city'] != '' && $viewdata['user_state'] != '' && $viewdata['user_zip'] != '' || $userdata['user_level'] == '1') {
$offcompl .= '<br /><br />Your address<br /><br />' . $viewdata['user_street'] . '<br />' . $viewdata['user_city'] . ',' . $viewdata['user_state'] . '<br />' . $viewdata['user_zip'];
} elseif ($userdata['user_id'] == $ruid) {
$offcompl .= '<br /><br /><font color="#FFFF00">You must fill in your address from your profile before your item is shipped.</font>';
} elseif ($userdata['user_id'] != $ruid) {
$offcompl .= '<br /><br /><font color="#FFFF00">You cannot see the address on another account.</font>';
}
$template->assign_vars(array(
"L_REFERRAL_N_NAME" => $lang['Referral_Admin_New_Name'],
"L_REFERRAL_DATETIME" => $lang['Referral_Admin_DateTime'],
"ROW_CLASS_BOTTOM" => $theme['td_class1'],
"REF_LINK" => $offcompl . '<br /><br />To refer more friends use this link ' . $reflink
)
);
for($i = 0; $i < $referral_count; $i++)
{
//
// GET NEW USER DATA
$nuid = $referral_rows[$i]['nuid'];
settype($nuid, "integer");
//
$new_userdata = get_userdata($nuid);
if( !$new_userdata )
{
$new_username = $lang['Referral_Admin_User_Delete'];
}
else
{
$temp_url = append_sid("profile.$phpEx?mode=viewprofile&" . POST_USERS_URL . "=".$new_userdata['user_id']."");
$new_username = '<a href="' . $temp_url . '">' . $new_userdata['username'] . '</a>';
}
$status = $new_userdata['user_offer'];
if ($status == '1') {
$status = '<font color="#00FF00">Offer Completed</font>';
} elseif ($status == '2') {
$status = '<font color="#00FF00">Item Sent(Offer Completed)</font>';
} else {
$status = '<font color="#FFFF00">Offer NOT Completed</font>';
}
if ($new_userdata['user_active'] != '1' && $new_userdata['user_actkey'] != '') {
$status = '<font color="#FF0000">Email not verified</font>';
} elseif ($new_userdata['user_active'] != '1' && $new_userdata['user_actkey'] == '') {
$status = '<font color="#FF0000">User on <b>HOLD</b>!</font>';
}
$referral_date = create_date($board_config['default_dateformat'], $referral_rows[$i]['referral_time'], $board_config['board_timezone']);
$row_color = ( !($i % 2) ) ? $theme['td_color1'] : $theme['td_color2'];
$row_class = ( !($i % 2) ) ? $theme['td_class1'] : $theme['td_class2'];
$template->assign_block_vars("referrers", array(
"ROW_COLOR" => "#" . $row_color,
"ROW_CLASS" => $row_class,
"NEW_USER" => $new_username,
"REPLACEMENT" => $referral_date,
"STATUS" => $status
)
);
}
//$gen_simple_header = TRUE;
include($phpbb_root_path . 'includes/page_header.' . $phpEx);
$template->pparse('body');
include($phpbb_root_path . 'includes/page_tail.' . $phpEx);
?>
ONCE AGAIN, THANK YOU FOR YOUR HELP!