clanstyles Posted June 29, 2007 Author Share Posted June 29, 2007 I don't get it how do you get the image number mysql? You mean the auto_increment id? Quote Link to comment Share on other sites More sharing options...
cooldude832 Posted June 29, 2007 Share Posted June 29, 2007 What are you using these images for? Quote Link to comment Share on other sites More sharing options...
clanstyles Posted June 30, 2007 Author Share Posted June 30, 2007 Its a site to sell what you want at and they take pics ( upto 3 of an item ). Then its dislpayed nicely on the page. Quote Link to comment Share on other sites More sharing options...
cooldude832 Posted June 30, 2007 Share Posted June 30, 2007 yeah for sure you will want to use a mysql association otherwise you will never be able to retrieve those images, unless you store their urls in the table and thats just a waste of good table space. Quote Link to comment Share on other sites More sharing options...
clanstyles Posted June 30, 2007 Author Share Posted June 30, 2007 How do u do that? Quote Link to comment Share on other sites More sharing options...
clanstyles Posted June 30, 2007 Author Share Posted June 30, 2007 dump Quote Link to comment Share on other sites More sharing options...
clanstyles Posted June 30, 2007 Author Share Posted June 30, 2007 I ment **BUMP** rofl Quote Link to comment Share on other sites More sharing options...
clanstyles Posted July 1, 2007 Author Share Posted July 1, 2007 ** BUMP ** :-( Quote Link to comment Share on other sites More sharing options...
redarrow Posted July 1, 2007 Share Posted July 1, 2007 why keep bumping show some code please. Quote Link to comment Share on other sites More sharing options...
clanstyles Posted July 1, 2007 Author Share Posted July 1, 2007 Well its up there but ive changed some things.. Sorry. I bump because i need this and the rules say I can every few hours if nobody responds. $i=1; while ($i < 3) { if ($_FILES['image'.$i]['type'] == "image/jpeg" || $_FILES['image'.$i]['type'] == "image/jpg" || $_FILES['image'.$i]['type'] == "image/pjpeg" || $_FILES['image'.$i]['type'] == "image/gif"){ $count++; $file_name = ""; $file_name .= "temp."; $file_name .= str_replace(".jpg","",str_replace("/","",str_replace("image","",$_FILES['imagefile'.$i]['type']))); //Replaces to lowercase only .jpg files $ext = ".jpg"; $random_digit = rand(1, 999); //Lets make a new name $new_file_name=$random_digit.$us.$count.$ext; //Lets Path it $path[$count]= "uploadimages/".$new_file_name; if(copy($_FILES['imagefile'.$i]['tmp_name'], $path[$count])){ echo "It Copied!!!<br/>"; } else{ echo "copy Failed<br/>"; } } $i++; } What I need though is for it to implode the images at the end. All the names I mean. What I really need is somthing that allows others to upload images. Like up to 3. I have three fields allready setup. image1 image2 image3. I need it so they can submit, gifs, jpgs, jpegs, pngs ect.. what ever they require. Then it stores it with a random name lik 12312.gif to a dir uploadedimages/. implodes the name for each image with a | seperating it. Later i have an explode that puts the image sout ( have that all done. ) Thank You Quote Link to comment Share on other sites More sharing options...
clanstyles Posted July 1, 2007 Author Share Posted July 1, 2007 dump to the BUMP ;p idk lol Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.