Image upload - determine folder


Posted on 16th Feb 2014 07:03 pm by admin

I have an upload script that may be accessed from different directories. Problem is, the script is made with "../images/uploads" as the folder place for uploaded images. Which means that if the script is accessed from the main home folder of the site, it won't work. I'd like a more dynamic solution. I seen somebody give an example of this a while back. I know that I'll have to use one of the $_SERVER variables. Just not sure which one exactly and how to go about doing it.

No comments posted yet

Your Answer:

Login to answer
319 Like 36 Dislike
Previous forums Next forums
Other forums

Which practice of iteration through containers is preferred
In the "real world" what kind of loop do most people use to iterate through a container like a vecto

php file erros / need help please
Hello

Someone decoded a zend file for me.. after uploaded it on ftp i get some errors, i trye

LIMIT $start, 10... how to pass last value queried into next page with GET??
Ok I know how to display the first or last 10 results of a query...

$result = mysql_query(&q

function not returning the correct value
I have a program that needs to return a value from a function. I have an output statement inside the

Hits this week counter
I have a counter on my site that tracks hits, IP's, etc. into a mySQL database. It also includes the

Get to know your fellow coder
I think it's time we got personal around here. There's a lot of code swapping and a few members kno

Receive Rosettanet Message to SAP 4.6c
Dear all ,

My customer will send the PO details by rosettanet message , Is it

Batch update record with Pagination
Hoping someone can help me with this issue I'm having, im trying to batch update records from a resu

Using real time in php
I'm very average at PHP and im looking to introduce time to something on my site.
Its a sports si

Parse error: syntax error, unexpected $end in
hello,
i receive the error :Parse error: syntax error, unexpected $end in C:xamppxampphtdocsh

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash