<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>
<title>Question2Answer Q&amp;A - Recent questions tagged cometchat</title>
<link>https://www.question2answer.org/qa/tag/cometchat</link>
<description>Powered by Question2Answer</description>
<item>
<title>I want to add the cometchat with question2answer</title>
<link>https://www.question2answer.org/qa/49242/i-want-to-add-the-cometchat-with-question2answer</link>
<description>

&lt;p&gt;&lt;strong&gt;I've done the following steps:-&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&amp;nbsp;&lt;/p&gt;

&lt;table border=&quot;1&quot; cellpadding=&quot;1&quot; style=&quot;width:500px; border-spacing: 1px;&quot;&gt;

&lt;tbody&gt;

&lt;tr&gt;

&lt;td&gt;

&lt;p&gt;Introduction&lt;/p&gt;

&lt;p&gt;This guide will help you through the installation process and get CometChat running on your site.&lt;/p&gt;

&lt;p&gt;Installation is very straight forward, only taking about 30 minutes from uploading the files to viewing the CometChat bar on your site.&lt;/p&gt;

&lt;p&gt;Before you begin, you will need an FTP client, if you do not have one, some popular solutions include&amp;nbsp;&lt;a rel=&quot;nofollow&quot; href=&quot;http://filezilla-project.org/&quot;&gt;FileZilla&lt;/a&gt;&amp;nbsp;(free) or&amp;nbsp;&lt;a rel=&quot;nofollow&quot; href=&quot;http://www.globalscape.com/products/ftp_clients.aspx&quot;&gt;CuteFTP&lt;/a&gt;&amp;nbsp;(trial).&lt;/p&gt;

&lt;p&gt;This guide assumes that you have successfully downloaded the latest release of CometChat and have the zip file “unzipped” and ready to go. If not, you can download the package from your client area.&lt;/p&gt;

&lt;p&gt;The instructions will term the zip file you downloaded as&amp;nbsp;&lt;strong&gt;cometchat.zip&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Uploading&lt;/p&gt;

&lt;p&gt;At this point, you should have the zip archive cometchat.zip and find a single folder- “cometchat”.&lt;/p&gt;

&lt;p&gt;If you access your site via ‘http://www.domain.com’, then look for the webroot directory.&lt;/p&gt;

&lt;p&gt;The “webroot” directory is usually ‘public_html’ or ‘www’, but this varies from server to server so if you’re unsure, contact your hosting provider.&lt;/p&gt;

&lt;p&gt;Using your FTP client, copy the cometchat folder to your webroot directory. e.g. http://www.domain.com/cometchat&lt;/p&gt;

&lt;p&gt;Configuration&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Switch on development mode&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Edit config.php and search for the tag:&lt;/p&gt;

&lt;pre&gt;/* ADVANCED */&lt;/pre&gt;

&lt;p&gt;Set&amp;nbsp;&lt;strong&gt;DEV_MODE&lt;/strong&gt;&amp;nbsp;to 1,&amp;nbsp;&lt;strong&gt;ERROR_LOGGING&lt;/strong&gt;&amp;nbsp;to 1 and&amp;nbsp;&lt;strong&gt;CACHING&lt;/strong&gt;&amp;nbsp;to 0. After integration, you can set it to default.&lt;/p&gt;

&lt;pre&gt;define('DEV_MODE','1');
define('ERROR_LOGGING','1');
define('MEMCACHE','0'); 
&lt;/pre&gt;

&lt;p&gt;&lt;strong&gt;Add your database information&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Edit&amp;nbsp;&lt;strong&gt;integration.php&lt;/strong&gt;&amp;nbsp;and update the DATABASE details.&lt;/p&gt;

&lt;p&gt;/* DATABASE */&lt;/p&gt;

&lt;pre&gt;define('DB_SERVER','localhost');
define('DB_PORT','3306');
define('DB_USERNAME','root');
define('DB_PASSWORD','password');
define('DB_NAME','databasename');
define('TABLE_PREFIX','');
define('DB_USERTABLE','users');
define('DB_USERTABLE_NAME','username');
define('DB_USERTABLE_USERID','userid');
define('DB_AVATARTABLE',&quot; &quot;);
define('DB_AVATARFIELD','users.avatar');
&lt;/pre&gt;

&lt;p&gt;The first 5 lines are used to access the database. You must access your existing site’s database and not create a separate database for CometChat.&lt;/p&gt;

&lt;p&gt;The next 6 lines specify details about your database schema.&lt;/p&gt;

&lt;p&gt;* If all your tables use a prefix, for example tableprefix_, then specify the&amp;nbsp;&lt;strong&gt;TABLE_PREFIX&lt;/strong&gt;&amp;nbsp;as tableprefix_ or you can leave it empty and mention complete table name while defining&amp;nbsp;&lt;strong&gt;DB_USERTABLE&lt;/strong&gt;
&lt;br&gt;*&amp;nbsp;&lt;strong&gt;DB_USERTABLE&lt;/strong&gt;&amp;nbsp;specifies the name of the table in which your user information is stored.
&lt;br&gt;*&amp;nbsp;&lt;strong&gt;DB_USERTABLE_NAME&lt;/strong&gt;&amp;nbsp;specifies the name of the field from users table in which the user’s name/display name is stored.
&lt;br&gt;*&amp;nbsp;&lt;strong&gt;DB_USERTABLE_USERID&lt;/strong&gt;&amp;nbsp;specifies the name of the field from users table in which the user’s id is stored (usually id or userid or user_id or member_id). This field must be of integer type.
&lt;br&gt;*&amp;nbsp;&lt;strong&gt;DB_AVATARTABLE&lt;/strong&gt;&amp;nbsp;specifies join of users table with avatar table. If avatar is stored in the users table then leave this field blank.
&lt;br&gt;*&amp;nbsp;&lt;strong&gt;DB_AVATARFIELD&lt;/strong&gt;&amp;nbsp;is the user ID by default. You can change this if your site stores avatar in users or avatars table.&lt;/p&gt;

&lt;p&gt;The code will look like:&lt;/p&gt;

&lt;pre&gt;define('TABLE_PREFIX','');
define('DB_USERTABLE','users');
define('DB_USERTABLE_NAME','username');
define('DB_USERTABLE_USERID','userid');
define('DB_AVATARTABLE',&quot; &quot;);
define('DB_AVATARFIELD','users.avatar');&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;

&lt;p&gt;&amp;nbsp;&lt;/p&gt;

&lt;p&gt;&lt;span style=&quot;color:rgb(255, 255, 255)&quot;&gt;&lt;span style=&quot;background-color:rgb(255, 0, 0)&quot;&gt;I don't know what to do after this which is mentioned in this article -&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;a target=&quot;_blank&quot; rel=&quot;nofollow&quot; href=&quot;https://support.cometchat.com/documentation/php/installing-cometchat/custom-coded-site/php-site/&quot;&gt;https://support.cometchat.com/documentation/php/installing-cometchat/custom-coded-site/php-site/​&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&amp;nbsp;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;span style=&quot;color:rgb(0, 128, 0)&quot;&gt;&lt;em&gt;They have easy install option for like 50 CMS but&amp;nbsp;question2answer CMS is not in the list and so I have to install manual only :(&lt;/em&gt;&lt;/span&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description>
<category>Q2A Core</category>
<guid isPermaLink="true">https://www.question2answer.org/qa/49242/i-want-to-add-the-cometchat-with-question2answer</guid>
<pubDate>Mon, 07 Dec 2015 16:44:02 +0000</pubDate>
</item>
</channel>
</rss>