title: How to get the ID of a mysql row before INSERT
body: <p>I can get the ID just after INSERT by mysql_insert_id(); but I want to save an image in the form of ID-image_name.jpg and save it in a column named Image_Name. How can I save the image with forthcoming ID? Or it is better to save the image file after INSERT process?</p>