FreiChat related discussions
help with chat

Hi
First of all thanks for nice work.
i have been struggling to make frei up and running.i m not integrating frei to anything but just want to test with localhost.i m able to access an dloging server/login.php and login succesfully.when i try access client/main.php i get page full of errors which start with


User parameters wrong line 121 in drivers/JCB.php/*-----------------------Definitions--------------------------------------------*/ var freidefines = { url:'http://localhost:8080/FreiChat/', theme:'pattern_blue', ses_status:'1', fonload:'show', reidfroh

can some one help me with this.also i am surprised why JCB.php is called even if i use customised option.in my opinion costom.php should be called.any ways i m not an expert so need ur help.

ok now i made a simple index.php and i guess i am suppose to add some code there and when i wd call index.php the chat wd appear.but i m unable to know what codes to be added and where.its not clear from the vid.

Br
Tulip

Hi First of all thanks for nice work. i have been struggling to make frei up and running.i m not integrating frei to anything but just want to test with localhost.i m able to access an dloging server/login.php and login succesfully.when i try access client/main.php i get page full of errors which start with User parameters wrong line 121 in drivers/JCB.php/*-----------------------Definitions--------------------------------------------*/ var freidefines = { url:'http://localhost:8080/FreiChat/', theme:'pattern_blue', ses_status:'1', fonload:'show', reidfroh can some one help me with this.also i am surprised why JCB.php is called even if i use customised option.in my opinion costom.php should be called.any ways i m not an expert so need ur help. ok now i made a simple index.php and i guess i am suppose to add some code there and when i wd call index.php the chat wd appear.but i m unable to know what codes to be added and where.its not clear from the vid. Br Tulip

The custom driver cannot be installed easily in current version of FreiChatX
because its not yet added in the installation process.

It will be added in the next version that would be released within two days.

But if you cannot wait till then there is manual installation,

So do you want to know how to do it manually?
And anyway in both installations the time taken would be almost the same.

The custom driver cannot be installed easily in current version of FreiChatX because its not yet added in the installation process. It will be added in the next version that would be released within two days. But if you cannot wait till then there is manual installation, So do you want to know how to do it manually? And anyway in both installations the time taken would be almost the same.
Necessity is the mother of all inventions!

Hi
Thanks a lot for ur mail.
yes i m interested to know how i can do that manually.pls share with me.i can not wait to see the beauty of ur work for 2 days more.hope u understand.

Br
tulip

Hi Thanks a lot for ur mail. yes i m interested to know how i can do that manually.pls share with me.i can not wait to see the beauty of ur work for 2 days more.hope u understand. Br tulip

Hi
to make it simple, lets say i have a file called index.php in htdocs folder.how can i integrate ur works to index.php

Br
tulip

Hi to make it simple, lets say i have a file called index.php in htdocs folder.how can i integrate ur works to index.php Br tulip

add the following code inside the 'head' tag

<script type="text/javascript" language="javascipt" src="http://localhost/freichat/client/main.php?id=0"></script> 
<link rel="stylesheet" href="http://localhost/freichat/client/jquery/freichat_themes/freichatcss.php" type="text/css">


and this in the 'body' tag
<div class="freichathtml" id="freichathtml"> </div>

make sure you change the path in the code with respect to your environment.

but make sure your arg.php has correct parameters. (try selecting the driver as 'drupal' during installation then enter the correct database details, but dont copy-paste the generated code, then edit arg.php accordingly)

add the following code inside the &#039;head&#039; tag &amp;lt;code&amp;gt; &amp;lt;script type=&amp;quot;text/javascript&amp;quot; language=&amp;quot;javascipt&amp;quot; src=&amp;quot;http://localhost/freichat/client/main.php?id=0&amp;quot;&amp;gt;&amp;lt;/script&amp;gt; &amp;lt;link rel=&amp;quot;stylesheet&amp;quot; href=&amp;quot;http://localhost/freichat/client/jquery/freichat_themes/freichatcss.php&amp;quot; type=&amp;quot;text/css&amp;quot;&amp;gt; &amp;lt;/code&amp;gt; and this in the &#039;body&#039; tag &amp;lt;code&amp;gt; &amp;lt;div class=&amp;quot;freichathtml&amp;quot; id=&amp;quot;freichathtml&amp;quot;&amp;gt; &amp;lt;/div&amp;gt; &amp;lt;/code&amp;gt; make sure you change the path in the code with respect to your environment. but make sure your arg.php has correct parameters. (try selecting the driver as &#039;drupal&#039; during installation then enter the correct database details, but dont copy-paste the generated code, then edit arg.php accordingly)

Hi Abinash,
thanks a lot.it did work but i see no user is online.where i can add user and test this with 2 users from different PC.so that they can chat.

Br
Tulip

Hi Abinash, thanks a lot.it did work but i see no user is online.where i can add user and test this with 2 users from different PC.so that they can chat. Br Tulip

Hi
When in user mode i see the message "Please LogIn to chat!".
so where do i login and may be my friends so that we can chat with this.

Br
tulip

Hi When in user mode i see the message &quot;Please LogIn to chat!&quot;. so where do i login and may be my friends so that we can chat with this. Br tulip

Hi Avinash,
any help or pointers?
it would help me a lot.

Br
tulip

Hi Avinash, any help or pointers? it would help me a lot. Br tulip

in the arg.php set $show_name='guest'
open two different browsers and you should be able to chat as guests.

if it works, then we can talk about the integration part (connecting logged in users to FreiChatX)

NOTE: please don't double post, there is an option to edit your posts

in the arg.php set $show_name=&#039;guest&#039; open two different browsers and you should be able to chat as guests. if it works, then we can talk about the integration part (connecting logged in users to FreiChatX) NOTE: please don&#039;t double post, there is an option to edit your posts

Hi Avinash,
thanks for ur mail.
i tried with 2 different windows and both display "No One Is Online".where i m wrong?i will take care of double post. thanks for pointing.
Br
tulip

Hi Avinash, thanks for ur mail. i tried with 2 different windows and both display &quot;No One Is Online&quot;.where i m wrong?i will take care of double post. thanks for pointing. Br tulip

did you set $show_name='guest' ?????

after editing,paste the arg.php code here so that i can have a look at it. (dont mention any passwords)

did you set $show_name=&#039;guest&#039; ????? after editing,paste the arg.php code here so that i can have a look at it. (dont mention any passwords)

Hi Avinash,
thanks again for quick response.yes i did set.
here it goes.
br
tulip



<?php /* FreiChatX parameters */

if(!defined('RDIR'))
{
define('RDIR', dirname(__FILE__));
define('PARENTDIR',dirname(RDIR));
}

$admin_pswd='adminpass';
$url="http://".$_SERVER["HTTP_HOST"].$_SERVER['SCRIPT_NAME'];
$show_name='guest'; //you can have guest or user
$show_module='visible'; //you can have'visible' or'hidden'
$chatspeed='5000'; //Do not change this value
$fxval='true'; //Set it to true if you do not want animations
$draggable='enable';
$conflict=''; //Jquery Conflicts 'true' or ''
$msgSendSpeed='1000'; //Message are sent after 1 second of post, reducing it will increase FreiChatX message sending speed but also will send more requests to the server! NOTE:: Do not decrease it below 1000
$show_avatar='block';

$debug=true; //option for debugging ,default is false
$freichat_theme='ce_green';
$css=$freichat_theme; //background color
$color=$css; //colour for chatbuttons
$lang='english'; //Language please do not include .php here only file name

$load='show'; //chatbox
$dyncss='disable'; //template patch
$evnixpower='visible'; //powered by evnix
$show_chatbox='';
$time='36000'; //In seconds

/*FreiChatX plugin parameters*/
// File sending
$show_file_sending_plugin='true';
$file_size_limit=2000; //In Kilobytes
$expirytime=3000; //In minutes
$valid_exts='image/jpeg,image/png,image/jpg,image/gif,application/zip'; //valid extensions separated by commas

/* Data base details */
$con='mysql';
$username='root';
$password='sql';
$client_db_name='frei';
$host='127.0.0.1';
$driver='Drupal';
$db_prefix='';
$uid='1299078356';


/* NOTE:= Below setting only applies to users using custom driver*/

//Tell FreiChatX what to use { Pure session } OR { Session and database }
/*
* Psession -> Pure sessions
* Sdatabase -> Session with database
*/

$freiuse="Sdatabase"; //can have value as Psession or Sdatabase

/* If you are using only sessions to store User details */
//Please use only the index of session variable

//The default value in user name or user id session when user is a guest
$default_ses=null; //If you dont make any checks leave it null

$ses_username='root'; /* Username stored in session*/ //Only index value
$ses_userid='loginid'; /* Userid stored in session */ //Only index value

/* OR */

/* if you are using database table to store User details */
$usertable='login'; //specifies the name of the table in which your user information is stored.
$row_username='root'; //specifies the name of the field in which the user's name/display name is stored.
$row_userid='loginid'; //specifies the name of the field in which the user's id is stored (usually id or userid)
?>

Hi Avinash, thanks again for quick response.yes i did set. here it goes. br tulip &amp;lt;?php /* FreiChatX parameters */ if(!defined(&#039;RDIR&#039;)) { define(&#039;RDIR&#039;, dirname(__FILE__)); define(&#039;PARENTDIR&#039;,dirname(RDIR)); } $admin_pswd=&#039;adminpass&#039;; $url=&quot;http://&quot;.$_SERVER[&quot;HTTP_HOST&quot;].$_SERVER[&#039;SCRIPT_NAME&#039;]; $show_name=&#039;guest&#039;; //you can have guest or user $show_module=&#039;visible&#039;; //you can have&#039;visible&#039; or&#039;hidden&#039; $chatspeed=&#039;5000&#039;; //Do not change this value $fxval=&#039;true&#039;; //Set it to true if you do not want animations $draggable=&#039;enable&#039;; $conflict=&#039;&#039;; //Jquery Conflicts &#039;true&#039; or &#039;&#039; $msgSendSpeed=&#039;1000&#039;; //Message are sent after 1 second of post, reducing it will increase FreiChatX message sending speed but also will send more requests to the server! NOTE:: Do not decrease it below 1000 $show_avatar=&#039;block&#039;; $debug=true; //option for debugging ,default is false $freichat_theme=&#039;ce_green&#039;; $css=$freichat_theme; //background color $color=$css; //colour for chatbuttons $lang=&#039;english&#039;; //Language please do not include .php here only file name $load=&#039;show&#039;; //chatbox $dyncss=&#039;disable&#039;; //template patch $evnixpower=&#039;visible&#039;; //powered by evnix $show_chatbox=&#039;&#039;; $time=&#039;36000&#039;; //In seconds /*FreiChatX plugin parameters*/ // File sending $show_file_sending_plugin=&#039;true&#039;; $file_size_limit=2000; //In Kilobytes $expirytime=3000; //In minutes $valid_exts=&#039;image/jpeg,image/png,image/jpg,image/gif,application/zip&#039;; //valid extensions separated by commas /* Data base details */ $con=&#039;mysql&#039;; $username=&#039;root&#039;; $password=&#039;sql&#039;; $client_db_name=&#039;frei&#039;; $host=&#039;127.0.0.1&#039;; $driver=&#039;Drupal&#039;; $db_prefix=&#039;&#039;; $uid=&#039;1299078356&#039;; /* NOTE:= Below setting only applies to users using custom driver*/ //Tell FreiChatX what to use { Pure session } OR { Session and database } /* * Psession -&amp;gt; Pure sessions * Sdatabase -&amp;gt; Session with database */ $freiuse=&quot;Sdatabase&quot;; //can have value as Psession or Sdatabase /* If you are using only sessions to store User details */ //Please use only the index of session variable //The default value in user name or user id session when user is a guest $default_ses=null; //If you dont make any checks leave it null $ses_username=&#039;root&#039;; /* Username stored in session*/ //Only index value $ses_userid=&#039;loginid&#039;; /* Userid stored in session */ //Only index value /* OR */ /* if you are using database table to store User details */ $usertable=&#039;login&#039;; //specifies the name of the table in which your user information is stored. $row_username=&#039;root&#039;; //specifies the name of the field in which the user&#039;s name/display name is stored. $row_userid=&#039;loginid&#039;; //specifies the name of the field in which the user&#039;s id is stored (usually id or userid) ?&amp;gt;

you forgot to set the $driver parameter in arg.php
set

$driver='Custom';


and tell me what happens!!

you forgot to set the $driver parameter in arg.php set &amp;lt;code&amp;gt; $driver=&#039;Custom&#039;; &amp;lt;/code&amp;gt; and tell me what happens!!

thnaks again Avinash,
i did not set it bocz we were heading for drupal,so i set it to Custom.
i did set it to Custom and no changes in output.

Br
tulip

thnaks again Avinash, i did not set it bocz we were heading for drupal,so i set it to Custom. i did set it to Custom and no changes in output. Br tulip

did it work? if yes then we can move on to the next step i.e integration

now suppose this is your login code

if(USERNAME_AND_PASSWORD_MATCHES)
{
$_SESSION['username']='some_user_name';
$_SESSION['id']='some_user_id';
}

in the above example 'username' & 'id' are indexes used to store the values into session.

now modify arg.php as follows
$freiuse="Psession";
$ses_username='username'; //'username' is the index
$ses_userid='id'; //'id' is the index


NOTE: always clear your browser cookies before every test
and don't forget to mention the result!

did it work? if yes then we can move on to the next step i.e integration now suppose this is your login code &amp;lt;code&amp;gt; if(USERNAME_AND_PASSWORD_MATCHES) { $_SESSION[&#039;username&#039;]=&#039;some_user_name&#039;; $_SESSION[&#039;id&#039;]=&#039;some_user_id&#039;; } &amp;lt;/code&amp;gt; in the above example &#039;username&#039; &amp; &#039;id&#039; are indexes used to store the values into session. now modify arg.php as follows &amp;lt;code&amp;gt; $freiuse=&quot;Psession&quot;; $ses_username=&#039;username&#039;; //&#039;username&#039; is the index $ses_userid=&#039;id&#039;; //&#039;id&#039; is the index &amp;lt;/code&amp;gt; NOTE: always clear your browser cookies before every test and don&#039;t forget to mention the result!

Hi Avinash,
i m sorry but i was unable to make with guest account.
any suggestions.i updated $show_name='guest'; and opened the link with 2 browser but still it shows fetching ..userlist and and next it displays no one is online.any suggestions.i know i m annoying much but still i expect help from u.

br
tulip

Hi Avinash, i m sorry but i was unable to make with guest account. any suggestions.i updated $show_name=&#039;guest&#039;; and opened the link with 2 browser but still it shows fetching ..userlist and and next it displays no one is online.any suggestions.i know i m annoying much but still i expect help from u. br tulip

it looks like there is an issue,
you have set debug to true, that means there must be a file created named 'freixlog.log' in freichat directory.
Check if you have any error messages such as 'unable to connect to database' or similar ones

it looks like there is an issue, you have set debug to true, that means there must be a file created named &#039;freixlog.log&#039; in freichat directory. Check if you have any error messages such as &#039;unable to connect to database&#039; or similar ones

Hi avinash,
thanks again for ur time
in log file i see only 2 kind of msg
main.php loaded
connected to database successfully
and this i see repeatedly.
hope i m not disturbing u.

Br
tulip

Hi avinash, thanks again for ur time in log file i see only 2 kind of msg main.php loaded connected to database successfully and this i see repeatedly. hope i m not disturbing u. Br tulip

now go to your database , check if 'frei_chat' and 'frei_session' tables exists;
if yes, then tell me what records are present(very imp.)
then empty both the tables.
Clear the cache and cookies of both the browsers.
close both the browsers and restart them again.

don't forget to mention the result.

now go to your database , check if &#039;frei_chat&#039; and &#039;frei_session&#039; tables exists; if yes, then tell me what records are present(very imp.) then empty both the tables. Clear the cache and cookies of both the browsers. close both the browsers and restart them again. don&#039;t forget to mention the result.

hi
thanks for ur operation.
cleared both tables.
Cleared the cache and cookies of both the browsers.
closed both the browsers and restart them again.
still no result.

Br
tulip

hi thanks for ur operation. cleared both tables. Cleared the cache and cookies of both the browsers. closed both the browsers and restart them again. still no result. Br tulip
12
219
29
0
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