Cool Comments

Ajax Comment System


Please, reed you this section carefully. 

Please, read you this section carefully. 
 
In this section, you learn how to install and to use the application in your web.
 
- For to install: you have all information about the installation in the section INSTALLATION.
 
- For to insert the form for the comments in your website, you go to /admin-comment/containers/index.php
 
  1.  Here, you select the link "new". 
  2. You will view a new window. 
  3. In this window, you write the name of container.
  4. You copy of the section code.
  5. You click in the button "Save" and the container be saved.
  6. Finally, you go to your website and where you want to see the comments and the form for to insert a new comment, you paste the code that you copied before. 

Remember: In the default installation, the buttons: Active comments, active plugin facebook and response notification are disabled.  

1. Unzip folder

2. Rename the admin-comment/includes/example_config.php file to config.php

3. Open config.php and set your database configuration

Use the following code to connect the database in config.php

 

$host="localhost";                //localhost

/*---------------------------------------------------------------------
----------------------- NAME OF USER  ---------------------------------     
-----------------------------------------------------------------------
---------here, you have to write your name of user of your database----
-----------------------------------------------------------------------*/

$user="your_user";    

/*----------------------------------------------------------------------
------------------------ PASSWORSD -------------------------------------
------------------------------------------------------------------------
------------here, you have to write the password of your database-------
------------------------------------------------------------------------*/

$pass="your_password";  


/*--------------------------------------------------------------------------------------------------------------------------------------------------
------------------------------------------------- NAME OF DATABASE -------------------------------------------------------------------
----------------------------------------------------------------------------------------------------------------------------------------------------
---------------- here, you have to write the name of your database --------- -------------------------------------------------------
----------------------------------------------------------------------------------------------------------------------------------------------------*/

$db="your_database"

/*---------------------------------------------------------------------------------------------------------------------------------------------------
----------------------------------------------------------- ROOT PATH ------------------------------------------------------------------------
------------------------------------------------------------------------------------------------------------------------------------------------------
-------------------------------------Include the path if the folder is not in the root directory. ------------------ --------------------
-----------------------------------------------------------------------------------------------------------------------------------------------------

* For exemple: * In my server, the folder is:     domain.com/directory_one/cool-comment
*
 * In the define, I would write:
 *
 * define("PATH", "directory_one/cool-cool-comment"); */

define("PATH", "ROOT_PATH");


/*----------------------------------------------------------------------------------*/
/*------------------------------------------------------------------------------------
---------------------------- PHP MAILER ----------------------------------------------
--------------------------------------------------------------------------------------
------------------------------------------------------------------------------------*/

//Set the hostname of the mail server

define("HOST_SMTP", "mail.com");

//Username to use for SMTP authentication

define("USER_SMTP", "smtp@mail.com");

//Password to use for SMTP authentication

define("PASS_SMTP", "password");

//Set the SMTP port number - likely to be 25, 465 or 587

define("PORT_SMTP", "25");

//Set the encryption system to use - ssl (deprecated) or tls

define("SECURITY_SMTP", "");

//Example: Hotmail:  


host:smtp.live.com          port: 587                  Security: tls

/*---------------------------------------------------------------------------------*/

For more information about phpMailer: https://github.com/PHPMailer/PHPMailer

 

4. Upload the content of folder in your host root

5. You execute http://www.your-domain/admin-comment, and you will view the page of installation. For example: http://www.myweb.com/admin-comment.

In this page, You have to insert your Email and password twice.

6. Finally, you have finished the installlation.  

 

For to go to the administrattion of comments, you will execute:
 
http://your-domain/path/admin-comment , Here you log for to access.
 
In the administration, you have sections diferents:
 
1. Dashboard

This is the homepage, when you enter in the aplicattion, after you write your login and password, you see is page.

In the page have three elements, there are Settings, Comments and Containers.

In the setting, you configure the count of administrator, you have custom settings and you can design the options of comments.

In the Comments you can to see the comments of user and you can to configure options of comments.

In the containers. you can to create and to see containers.

 
2. Settings
               2.1  - User System

Execute /admin-comment/settings/index.php for change your settings

1., You can set a new username for entry in your administration

2. You can set a new password

               2.2 - Customization

Execute /admin-comment/settings/index.php for change your settings

1. You can active the alert at your email. When the user add a new comment you receive notice for email. This way help you for approve of disapprove news comments.

2. You can change the name of email for send your mail. you can select your adress email for send notice at the users that leave comments.

3. You can add of modify you alias email. The users receive you email like name your alias email.

4. Active the input url. Everobody can add his website that leave a comment.

5. Active Antispan security code. Before send message, the user need insert the security code.

6. Active alert user for response. The user receive a notice everytime somebody reply his comment

7. You can disable all comments no approved when you still approved a new comment in /admin-comment/comments/index.php

8. Plugin facebook. If you click in this checkbox, you desactive the option of login for user. The other manner you have activated the option of login

9.Timezone:Here, you can to select the timezone for the comments.

               2.3 - Design

Execute /admin-comment/settings/index.php for change your settings

1. You can set your css color on send post button.

2. You can set your css hover color on send post button.

3. You can set a default user image if don`t take a facebook image or gravater image. For this operattion, you need set of write permission of writer on the folder "admin-comment/images

4. You can set your css color line on every page.

5. You can set your css color background on every page.

6. You can set your css text color on every page.

7. You can set your css color inside comment on every page.

3. Comments

Execute /admin-comment/comments/index.php for to see all comments.

1. You can to see all comments, the comments approved. The comments pending and the comments spam.

2. Section cancel: You can delete the comment if you use the bin.

3. You can active the comments: The comments can`t to see in the web if the user don`t active.

4. Date: This secetion show us the date of comments have been written.

5. User: Here, You can see the name and email of user.

6. Submitted on: this section shoe the content of comments.

7.  Container: this section show  the container belong to comments.

8. Replies: Here, there are a number of answer of comment.

 
4. Containers

Execute /admin-comments/containers/index.php and you can see the containers that you have created. Also, you have the option to create a new container for other website.

Sections:

1. New comment:

       1.1 Name: name of container.

       1.2 Code: This is the code that need copy and paste in your website, Whre you want to see the form of comments.

2. Cancel: The icons of bin is for delete the container.

3. Created: here, you can see when the containers have been created.

4. Containers: the name of container.

5. Comments: number of comments of container

 

This is the homepage, when you enter in the aplicattion, after you write your login and password, you see is page.

In the page have three elements, there are Settings, Comments and Containers.

In the setting, you configure the count of administrator, you have custom settings and you can design the options of comments.

In the Comments you can to see the comments of user and you can to configure options of comments.

In the containers. you can to create and to see containers.

 

Execute /admin-comment/settings/index.php for change your settings

1., You can set a new username for entry in your administration

2. You can set a new password

Execute /admin-comment/settings/index.php for change your settings

1. You can active the alert at your email. When the user add a new comment you receive notice for email. This way help you for approve of disapprove news comments.

2. You can change the name of email for send your mail. you can select your adress email for send notice at the users that leave comments.

3. You can add of modify you alias email. The users receive you email like name your alias email.

4. Active the input url. Everobody can add his website that leave a comment.

5. Active Antispan security code. Before send message, the user need insert the security code.

6. Active alert user for response. The user receive a notice everytime somebody reply his comment

7. You can disable all comments no approved when you still approved a new comment in                                            /admin-comment/comments/index.php

8. Plugin facebook. If you click in this checkbox, you desactive the option of login for user. The other manner you have activated the option of login

9.Timezone:Here, you can to select the timezone for the comments.

Execute /admin-comment/settings/index.php for change your settings

1. You can set your css color on send post button.

2. You can set your css hover color on send post button.

3. You can set a default user image if don`t take a facebook image or gravater image. For this operattion, you need set of write permission of writer on the folder "admin-comment/images

4. You can set your css color line on every page.

5. You can set your css color background on every page.

6. You can set your css text color on every page.

7. You can set your css color inside comment on every page.

Execute /admin-comment/comments/index.php for to see all comments.

1. You can to see all comments, the comments approved. The comments pending and the comments spam.

2. Section cancel: You can delete the comment if you use the bin.

3. You can active the comments: The comments can`t to see in the web if the user don`t active.

4. Date: This secetion show us the date of comments have been written.

5. User: Here, You can see the name and email of user.

6. Submitted on: this section shoe the content of comments.

7.  Container: this section show  the container belong to comments.

8. Replies: Here, there are a number of answer of comment.

 

 

Execute /admin-comments/containers/index.php and you can see the containers that you have created. Also, you have the option to create a new container for other website.

Sections:

1. New comment:

       1.1 Name: name of container.

       1.2 Code: This is the code that need copy and paste in your website, Whre you want to see the form of comments.

2. Cancel: The icons of bin is for delete the container.

3. Created: here, you can see when the containers have been created.

4. Containers: the name of container.

5. Comments: number of comments of container

In this section, we explain how you can to make that the button of login facebook is active.

1. You go to http://developers.facebook.com . Here you log in with your account of facebook.

2. You are identified in facebook. Then you go to http://developers.facebook.com and click in "Apps"-> "Created new app".

3. After, you have created your app facebook, now, you go to your App and click in "Settings".

4. In Settomg. you click in "add Platform" and click in "Website".

    4.1 Now, you have to insert in the text box "Site url" the url of your web, for example, http://yourweb.es

    4.2 In rhe text box, "App Domains", you have to insert the url of your web, for example, yourwerb.es

    4.3 In the text box, "Contact Email", You have to insert your Email

    4.4 You make click in "Save settings".

5. You make click in "Status & Review"

    5.1 In the question "Do you want to make this app all its live features available to the general public?" , you change the            option "no" for "yes".

6. Now, you go yo Dashboard and you copy the text box of "App ID".

7. You go to /admin-comment/js/cool-comments.js and in the line six, you delete the number of appID and you paste your appID

// JavaScript Document 
/**************Function active upload*******/
/*facebook api*/
window.fbAsyncInit = function() {
FB.init({
appId      : '1467775626793581',
status     : true, // check login status
cookie     : true, // enable cookies to allow the server to access the session
 xfbml      : true  // parse XFBML

8. Finally, You save and upload the file in your server

In this section, we explain how, you can to create a file for you insert the language than you want.

1. You go to the directory /admin-comments/strings/

2. In this directory, you create a file named "string_language.xml".

In the word language you have to write the code of ISO 639-1. This rule is 204 codes of two letters, This codes are user for identify the language in the world. 
You can to identify your code if you visit the website http://es.wikipedia.org/wiki/ISO_639-1
for example, "string_en.xml"  ,   "string_es.xml"   ,    "string_fr.xml"

3. Next, you go to /admin-comments/string_en.xml , You copy all text and you go to your file and you paste the text.

4. Now, you should to go write in the field "valor" the translated word in your language.

for example:

<traduccion>
<clave>post_your_comment</clave>
<valor>HERE, you have to write the translated word</valor>
</traduccion>

5. You translate all words and you save.

6. Finally, You go to /admin-comments/settings/index.php , and, in the section "Language" you can to choose your language.

Here, we go to explain how we have to change the permissions of the images directory (write permissions). This permissions have to change because if you change the icon of user, the directory images need permissions of write.

1. You go to de directory images /admin-comments/images , you click width the right buttom about the folder, and you select the options "permissions of file".

2. You click the options "write" and save.