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

Calander layout
Hi i know this sounds like a simple question but i cant find the answer to it anywhere i have added

GIS appliction help
I found some tutorials in the internet to develop a map application I don't want to use google maps

Open browser page depending on XML results
Hello,

I have some PHP code that sends webbased from data to an external url ( in the form of

Page not Loading After Test
Hey All

It seemed that an inlcude statement wasn't working for some reason, so I tried a more

Sessions Value Not Saved
Hi,

Im making a login form and im using this code:
Code: if($login=="true"){

phpmailer class & pop.gmail.com?
Code: <?php
$mail->IsSMTP();
$mail->Host = "pop.gmail.com";

Linkage between two scripts
Okay say I have this for a link in a script:

Code: <li><a href="#&q

Limiting uploaded file type
I am working on a simple upload script, and I need it to limit the allowed file type that is uploade

Delete all from a table
I can not get the following code to work. If I run the sql statement in the db it will delete all t

update 2 columns by doing inner 2-column query
Hi,
is something like this possible?

update contract_all set col1,col2 =
(

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