View Full Version : editing files problem
bmroyer
12-06-2004, 09:49 PM
i installed this portal successfully, but I edited the files wrong I think. I get all these errors. I can get into the admin cp though. Check it out www.unknownwriters.net click on the forums and other stuff. I got something screwed up. If the files are edited wrong then im screwed, I dont understand how to edit them/copy/paste
Brian
12-06-2004, 10:03 PM
The error means that the changes to your forum/includes/functions_calendar.php file were done incorrectly. Try getting a fresh, un-hacked version of that file and reapply the changes.
bmroyer
12-06-2004, 10:49 PM
I changed it to what it said to do, and its still messed up.
Says Find:
function construct_calendar_output($today, $usertoday, $calendarinfo, $fullcalendar = 0, $weekrange = '')
{
global $birthdaycache, $eventcache, $bbuserinfo, $vbphrase, $stylevar, $show, $offset, $colspan, $days, $months, $show;
Replace With:
function construct_calendar_output($today, $usertoday, $calendarinfo, $fullcalendar = 0, $weekrange = '')
{
global $birthdaycache, $eventcache, $bbuserinfo, $vbphrase, $stylevar, $show, $offset, $colspan, $days, $months, $vba_options, $vboptions;
you wanna fix it?
Brian
12-06-2004, 10:52 PM
What do you have about 5 lines above and 5 lines below the code you posted?
bmroyer
12-06-2004, 10:56 PM
what do you mean?
bmroyer
12-06-2004, 11:01 PM
heres a clean part of the code I need to edit.
// ###################### Start getcalendarbits #######################
function construct_calendar_output($today, $usertoday, $calendarinfo, $fullcalendar = 0, $weekrange = '')
{
global $birthdaycache, $eventcache, $bbuserinfo, $vbphrase, $stylevar, $show, $offset, $colspan, $days, $months;
$calendarid = $calendarinfo['calendarid'];
$month = $usertoday['month'];
$year = $usertoday['year'];
$calendardaybits = '';
$calendarweekbits = '';
if ($calendarinfo['showweekends'])
{
$weeklength = 7;
$colspan = 8;
$daywidth = '14%';
$linkwidth = '2%';
}
else
{
$weeklength = 5;
$colspan = 6;
$daywidth = '19%';
$linkwidth = '5%';
}
bmroyer
12-07-2004, 11:38 AM
anymore suggestions
Brian
12-07-2004, 12:37 PM
Posting the un-modified code doesn't help at all. If you will post the code that you modified and about 5 lines above it and 5 lines below it then I should be able to tell you what the problem is.
bmroyer
12-07-2004, 07:35 PM
I got that problem solved now, this is the other error I get when I click on the index piece.
Fatal error: Call to undefined function: print_portal_output() in /home/kid69sta/public_html/cmps_index.php on line 27
bmroyer
12-07-2004, 08:15 PM
I looked through the faqs and download the info.php file and uploaded it. I click on it and it doesnt load nothing in the page.
bmroyer
12-07-2004, 08:42 PM
I looked over everything. The global file looks like its correctly edited, I have all the vbadv files uploaded..triple checked. It has to be my cmps_index file.
Heres what it looks like: (colored where the editing starts and ends)
// ============================================
// Enter the full path to your forum here
// Example: /home/vbadvanced/public_html/forum
// ============================================
chdir('/home/kid69sta/public_html/forums/');
And here is my global code:
// Start functions
if (DB_QUERIES)
{
// start functions parse timer
echo "Parsing functions.php\n";
$pageendtime = microtime();
$starttime = explode(' ', $pagestarttime);
$endtime = explode(' ', $pageendtime);
$beforetime = $endtime[0] - $starttime[0] + $endtime[1] - $starttime[1];
echo "Time before: $beforetime\n";
if (function_exists('memory_get_usage'))
{
echo "Memory Before: " . number_format((memory_get_usage() / 1024)) . 'KB' . " \n";
}
}
if (defined('VBA_PORTAL'))
{
$phrasegroups = array_merge($phrasegroups,
array(
'calendar',
'adv_portal',
'postbit'
)
);
$specialtemplates = array_merge($specialtemplates,
array(
'adv_modules',
'adv_portal_opts',
'attachmentcache',
'bbcodecache',
'birthdaycache',
'eventcache',
'iconcache',
'maxloggedin',
'smiliecache',
'userstats'
)
);
$globaltemplates = array_merge($globaltemplates,
array(
'adv_portal',
'adv_portal_footer'
)
);
}
require_once('./includes/functions.php');
if (DB_QUERIES)
{
// end functions parse timer
$pageendtime = microtime();
$starttime = explode(' ', $pagestarttime);
$endtime = explode(' ', $pageendtime);
$aftertime = $endtime[0] - $starttime[0] + $endtime[1] - $starttime[1];
echo "Time after: $aftertime\n";
echo "Time taken: " . ($aftertime - $beforetime) . "\n";
if (function_exists('memory_get_usage'))
{
echo "Memory After: " . number_format((memory_get_usage() / 1024)) . 'KB' . " \n";
}
echo "\n<hr />\n\n";
}
Brian
12-08-2004, 01:26 AM
Your global.php file is not modified correctly. Get a fresh, un-hacked version of the file and follow the instructions closely.
vBulletin® v3.8.4, Copyright ©2000-2012, Jelsoft Enterprises Ltd.