I'm using wordpress to post tips for my community of indie filmmakers. I'd like to put the tips under password to be available only to registered filmmakers. User accesses are stored in my database, and I have objects & functions designed to access that info.
I've altered the index.php file in the default theme thus:
<?php define("SITE_ROOT", '[my site root]'); ?>
<?php require_once SITE_ROOT . '/include/app_top.php'; ?> //this opens the db connection
<?php require_once SITE_ROOT . '/include/config.inc.php'; ?> // this has various defined vars
<?php require_once SITE_ROOT . '/business_objects/bo_user.php'; ?> // this contains the IsFilmmakerAuthenticated() function
<?php $mBoUser = new BoUser(); ?>
<?php if ($mBoUser.IsFilmmakerAuthenticated()) : ?>
...
and then I continue with the main code.
I'm getting these two errors:
Warning: session_start() [function.session-start]: Cannot send session cache limiter - headers already sent (output started at /.../public_html/blog/wp-content/themes/default/header.php:2) in /.../public_html/include/app_top.php on line 5
Fatal error: Call to undefined function isfilmmakerauthenticated() in /.../public_html/blog/wp-content/themes/default/index.php on line 9
Is there an easy fix?
Thanks a lot for your help!