Static-X    Static-X.infopop.cc  Hop To Forum Categories  Static-X Open Discussion  Hop To Forums  Open Discussion    the geek thread
Page 1 2 
Go
New
Find
Notify
Tools
Reply
  
  Login/Join 
Picture of hardkoretom
Posted
I can't think of anything clever to say other than this thread is for programming or graphic design talk or any other highly nerdy subjects.

ok, so I am writing this function in php where the user enters in a name for a folder that will be created by the function and uploads a file to the folder that was just created. Ok, so i am able to make the folder but the file wont move into the folder, it just stays in the root program directory. I have been pondering over this for awhile and havent been able to get it to work yet. Here is a link to the files with my script. any suggestions?


 
Posts: 2754 | Location: Anaheim, CA | Las Vegas, NV | Registered: Sat July 15 2006Reply With QuoteEdit or Delete Message

Picture of Lorazepam
Posted Hide Post
Is the uploads folder also chmodded 0777?

Also are you really using PHP4? I'm so sorry if you are.


---

 
Posts: 286 | Registered: Tue February 12 2008Reply With QuoteEdit or Delete Message
Picture of hardkoretom
Posted Hide Post
Well, the code I am using is straight from php.net/filesystem, and I am using InstantRails version 2 so there might be a chance it could be php4.

I thought the chmod was running with the mkdir function

mkdir("uploads/" . $jobName, "0777");

but I will try running chmod on that folder before I move the uploaded file.


edit, I just reread what you posted and I didnt chmod the folder. I guess that will be the first thing I will try out.


thanks.


 
Posts: 2754 | Location: Anaheim, CA | Las Vegas, NV | Registered: Sat July 15 2006Reply With QuoteEdit or Delete Message
Gaz
Mr Personality of the fucking year
Picture of Gaz
Posted Hide Post
You might as well of written that in French, since it makes no sense to me.


Ima gonna go play warcraft or something that I do understand.
 
Posts: 5046 | Location: Wales.UK | Registered: Sat October 04 2003Reply With QuoteEdit or Delete Message





Picture of "Resurrected"
Posted Hide Post






 
Posts: 72 | Registered: Sat September 06 2008Reply With QuoteEdit or Delete Message
Posted Hide Post
quote:
Originally posted by hardkoretom:
...mkdir...chmod...


i think those two words are from the linux command line, monumental waste of time

quote:
Originally posted by hardkoretom:
...or graphic design talk...


since when graphic design is nerdy ?


 
Posts: 770 | Location: behind your father's eyes | Registered: Tue March 15 2005Reply With QuoteEdit or Delete Message
Picture of hardkoretom
Posted Hide Post
quote:
Originally posted by Oblivion:
quote:
Originally posted by hardkoretom:
...mkdir...chmod...


i think those two words are from the linux command line, monumental waste of time

quote:
Originally posted by hardkoretom:
...or graphic design talk...


since when graphic design is nerdy ?


Graphic design is a very nerdy subject especially if you are talking about vectors, pantones/hex color codes, or doing some of the special features in photoshop/illustrator/gimp. it is something that a normal joe cannot do without alot of studying or reading guides.


 
Posts: 2754 | Location: Anaheim, CA | Las Vegas, NV | Registered: Sat July 15 2006Reply With QuoteEdit or Delete Message

Picture of Lorazepam
Posted Hide Post
quote:
Originally posted by Oblivion:
quote:
Originally posted by hardkoretom:
...mkdir...chmod...


i think those two words are from the linux command line, monumental waste of time


They're Unix tools, and they're found in pretty much every decent operating system. Windows users can even use them via Cygwin.

As for Linux or Unix being a waste of time, try telling that to IBM, Sun, or Apple; better yet, try running a web server with more than two weeks of uptime.


---

 
Posts: 286 | Registered: Tue February 12 2008Reply With QuoteEdit or Delete Message
Picture of hardkoretom
Posted Hide Post
I tried throwing in a chmod 777 on the root folder of the script and it didnt help.

would it be easier to have the browse box just copy the file and place it in the new folder?


 
Posts: 2754 | Location: Anaheim, CA | Las Vegas, NV | Registered: Sat July 15 2006Reply With QuoteEdit or Delete Message
Posted Hide Post
quote:
Originally posted by hardkoretom:
Graphic design is a very nerdy subject especially if you are talking about vectors, pantones/hex color codes...


well maybe it's not very nerdy to me 'casue i understand it a little bit but still the art part of grafic design takes the edge off from the nerdy part

quote:
Originally posted by Lorazepam:
try running a web server with more than two weeks of uptime


you know what ? i don't need more than two weeks of uptime, i am able to plan my life ahead and i might be able to survive such a tragedy


 
Posts: 770 | Location: behind your father's eyes | Registered: Tue March 15 2005Reply With QuoteEdit or Delete Message

Picture of Lorazepam
Posted Hide Post
quote:
Originally posted by Oblivion:
you know what ? i don't need more than two weeks of uptime, i am able to plan my life ahead and i might be able to survive such a tragedy


Look at how stupid you are


---

 
Posts: 286 | Registered: Tue February 12 2008Reply With QuoteEdit or Delete Message

Picture of Lorazepam
Posted Hide Post
quote:
Originally posted by hardkoretom:
I tried throwing in a chmod 777 on the root folder of the script and it didnt help.

would it be easier to have the browse box just copy the file and place it in the new folder?


Try changing $HTTP_POST_FILES to just $_FILES, register_globals might be turned off.


---

 
Posts: 286 | Registered: Tue February 12 2008Reply With QuoteEdit or Delete Message
Posted Hide Post
quote:
Originally posted by Lorazepam:

Look at how stupid you are


it's actually amuzing seeing how important those things seem to you


 
Posts: 770 | Location: behind your father's eyes | Registered: Tue March 15 2005Reply With QuoteEdit or Delete Message

Picture of Lorazepam
Posted Hide Post
quote:
Originally posted by Oblivion:
quote:
Originally posted by Lorazepam:

Look at how stupid you are


it's actually amuzing seeing how important those things seem to you


Computer scientists care about stable and secure operating systems? This is such a shocking revelation


---

 
Posts: 286 | Registered: Tue February 12 2008Reply With QuoteEdit or Delete Message

Picture of Lorazepam
Posted Hide Post
Hey guys I see you're talking about programming and stuff, I just want to let you know that computers are gay and I like dicks in my mouf


---

 
Posts: 286 | Registered: Tue February 12 2008Reply With QuoteEdit or Delete Message
Picture of hardkoretom
Posted Hide Post
I got it to work. I didnt echo my variables to see what was being stored. I can't believe I never thought to do that. my target path was uploads/testFile.txt instead of uploads/$jobName/testFile.txt. Now I need to figure out what I want my program to do next. thanks


 
Posts: 2754 | Location: Anaheim, CA | Las Vegas, NV | Registered: Sat July 15 2006Reply With QuoteEdit or Delete Message
Like salt to old wounds...
Picture of Kriss
Posted Hide Post
What are you programming, Tom?



__________________________




Crash! Let's do it!Photobucket

Kriss's DeviantArt
 
Posts: 2864 | Location: Dee! | Registered: Sat December 04 2004Reply With QuoteEdit or Delete Message
Picture of hardkoretom
Posted Hide Post
I work for a printing company and I am writing a program that will format the files we use for the printing presses automatically.Its kinda hard cause I am just starting out and I am relearning some languages.


 
Posts: 2754 | Location: Anaheim, CA | Las Vegas, NV | Registered: Sat July 15 2006Reply With QuoteEdit or Delete Message
Like salt to old wounds...
Picture of Kriss
Posted Hide Post
Sounds like you know quite a bit about it already, though. You all might as well be speaking Russian to me.



__________________________




Crash! Let's do it!Photobucket

Kriss's DeviantArt
 
Posts: 2864 | Location: Dee! | Registered: Sat December 04 2004Reply With QuoteEdit or Delete Message
Picture of hardkoretom
Posted Hide Post
quote:
Originally posted by Kriss:
Sounds like you know quite a bit about it already, though. You all might as well be speaking Russian to me.


Ironically enough, the guy whom I replaced was in fact russian.

well, my deal is that I have only been doing theoretical and havent done anything in the real world other than my own websites. My last job promised that I would be given a chance at doing that and my coworker was extremely willing to give me some work and go thru it with me until I got the hang of it, but my boss didnt want to spend the money for me to learn it. He just had me out doing work he didnt hire me to do.

What kind of work do you do again? was it a game tester?


 
Posts: 2754 | Location: Anaheim, CA | Las Vegas, NV | Registered: Sat July 15 2006Reply With QuoteEdit or Delete Message
 Previous Topic | Next Topic powered by eve community Page 1 2  
 

Static-X    Static-X.infopop.cc  Hop To Forum Categories  Static-X Open Discussion  Hop To Forums  Open Discussion    the geek thread