Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function change_profile_image($user_id, $file_temp, $file_extn){
- $file_path = 'image/profile/' . substr(md5(time()), 0, 10) . '.' . $file_extn;
- move_uploaded_file($file_temp, $file_path);
- //echo $file_path;;
- mysql_query("UPDATE `user` SET `profile`= '". mysql_real_escape_string($file_path)."' WHERE `user_id` = " . (int)$user_id);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement