Hi I have installed freichat as per instructions but i'm stuck at the end

at this step unclear what to put, my unsers are un the database as uni_users, plus i dont know were to place this after.

if(USER_IS_LOGGED_IN)
{
$ses = LOGGED_IN_USERID; //tell freichat the userid of the current user

setcookie("freichat_user", "LOGGED_IN", time()+3600, "/"); // *do not change -> freichat code

}
else {

$ses = null; //tell freichat that the current user is a guest

setcookie("freichat_user", null, time()+3600, "/"); // *do not change -> freichat code

}

also.....when i pu the code intothe script i get this at the top of the page....please view picture...thank you

5896391d25d5d.png

Hi I have installed freichat as per instructions but i'm stuck at the end at this step unclear what to put, my unsers are un the database as uni_users, plus i dont know were to place this after. if(USER_IS_LOGGED_IN) { $ses = LOGGED_IN_USERID; //tell freichat the userid of the current user setcookie("freichat_user", "LOGGED_IN", time()+3600, "/"); // *do not change -> freichat code } else { $ses = null; //tell freichat that the current user is a guest setcookie("freichat_user", null, time()+3600, "/"); // *do not change -> freichat code } also.....when i pu the code intothe script i get this at the top of the page....please view picture...thank you ![5896391d25d5d.png](serve/attachment&path=5896391d25d5d.png)
 
0
reply

Hi,

You need to put that code in any .php file which loads on every page

Also, the code should be edited properly for eg, if your site uses PHP SESSION to store users in in $_SESSION['user_id'], then
LOGGED_IN_USERID will become $_SESSION['user_id']

Hi, You need to put that code in any .php file which loads on every page Also, the code should be edited properly for eg, if your site uses PHP SESSION to store users in in $_SESSION['user_id'], then LOGGED_IN_USERID will become $_SESSION['user_id']
 
0
reply
82
views
1
replies
3
followers
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft