hi every1.
im wrtting a chat system!,the problem i dont no how to insert the value of a variable into the db(mysql)

i no connection and insertion, but only data, nat variable, plz help

? sorry can you rephrase that as i have no idea what you mean. if you know insertion and connection why cant you do it ?

Are you talking about getting the data from the user in the webpage? If you are, then you can use a form. Depending on the method of the form wether it is post or get, Just set the action to the php script that will enter into the database and use the $HTTP_POST_VARS or $_POST if it is post method or you can use $HTTP_GET_VARS or $_GET to extract the variables if the form was sent to the script by the get method
The html for the form looks somewhat like

<form action="processingScript.php" method="post">
<input type="text" name="theVarInQuestion" />
<br>
<input type="submit" value="Send The Variable" />
</form>

and the script to get the variable is anything like
processingScript.php :

/* regular html code  and open body */
<?php
echo "The variable was $HTTP_POST_VARS['theVarInQuestion']"
?>
/* end body and html */

Well, hope this helps.......

This question has already been answered. Start a new discussion instead.