How to save Data and fetch it?
Posted: Mon Aug 04, 2008 11:47 pm
http://www.dhtmlgoodies.com/scripts/arr ... demo2.html
I've been looking for something like this for so long and i was glad and happy i found this website. How ever Im running into a little problem.
I have a social website where everyone has a profile. In each profile there are 5 tables i would like each user to Arrange. Only the owner of the profile will be able to arrange these tables. I came with the code to let each user arrange their profile (only the owner of its profile). When saving the arrangement, i would like it to save in the DB on the same row as a profile. I just need to know how to save it and fetch it. I was trying a code like this:
function save_arrange($id) {
global $lang, $session_logged;
if ($session_logged == 'true') {
$fetch_profile = sql_query("SELECT * FROM profiles WHERE profile_id = '".$_GET['id']."'
AND profile_owner = '".$_COOKIE['session_username']."' LIMIT 1");
if (mysql_num_rows($fetch_video) != 0) {
$profile = mysql_fetch_array($fetch_profile);
sql_query("INSERT INTO profiles (HELP!) VALUES (HELP!)");
return message_status('done', $lang['profile_arranged']);
} } }
Thanks in advanced