chat script small tip needed -- 2
$10-30 USD
Maksettu toimituksen yhteydessä
Hi,
i am writing a simple chat box but im stuck because i want to choose, depends on who's message do it comes, the field color should change.
for example if the text is sent by me, it should be blue, else it should be green.
ok i have :
mysql_query("SELECT * FROM task where chat_id ='$id'ORDER BY time_created ASC")or die(mysql_error());
and i have:
$chatbox .= '
<b class="alert-info"> . $message .'</b>';
i want each message depending who its coming from be green or blue.
i wrote this code: but cant fit it in:
if ($from == $logged_user)
{
$color_code = 'blue';
} else {
$color_code = 'green';
}
if you can help me fix it and with a low cost, let me know soon
Projektin tunnus: #32215814
Tietoa projektista
Myönnetty käyttäjälle:
sir message me i will help you i am php expert ... sir message me i will help you i am php expert ...
10 freelanceria on tarjonnut keskimäärin $23 tähän työhön
Hello Sir, I have read your job description carefully start your project right now and able to lead your project to success asap. My Strong Experiences as follow: - PHP Framework Like Laravel & CodeIgniter (3+ years) Lisää
PHP,PDO, Core-php, CakePHP, CodeIgniter, Laravel, Mysql, HTML, HTML5, CSS, JavaScript, jquery, AJax, And BUG FIXING etc. When we work for clients really feel happy because we like to work for clients to give them Lisää
What is the $logged_user and $from variables? I need to know so I can help debug, have you tried to var_dump them both to see if they’re the same?
Hello Client. I check your code. Now understand that you have some mistake. I can fix it in 10mins. if you select me,I will try in my best Thank you.
Hi, How are you? Here is your good partner. I have read your job description and am very interested in your task. I am very familiar with Php and Sql, So I can do very well in a few hours for you. please hire me, I wil Lisää