Upload System
Posted: Wed Aug 14, 2013 6:16 am
Hello, I am currently creating an upload system, and I am trying to get a variable into the upload directory.How could I do this?
As you can see below, I have tried several ways, and none seem to be working.Once I remove the variable and replace it with normal text, it works.I have three or four sections, so I don't really want to be creating one for each when I could get it in one, so how could I get it to work?
NOTE: The variable $data_name is the name of my database.The user is asked to select their category via a dropdown box, and then the selected one sends it to that specific table in the database.All the variables do definetly work, as I have tried them.Many many times...
Once I replace either of these ways with the following, it works.
Initially, I tried this, but then soon realised that it wasn't going to work.
As you can see below, I have tried several ways, and none seem to be working.Once I remove the variable and replace it with normal text, it works.I have three or four sections, so I don't really want to be creating one for each when I could get it in one, so how could I get it to work?
NOTE: The variable $data_name is the name of my database.The user is asked to select their category via a dropdown box, and then the selected one sends it to that specific table in the database.All the variables do definetly work, as I have tried them.Many many times...
Code: Select all
$minimap_uploadLocation = "c:/wamp/www/strongholdcrusader/downloads/categories/$data_name/pages/minimaps/\\";Code: Select all
$minimap_uploadLocation = "c:/wamp/www/strongholdcrusader/downloads/categories/".$data_name."/pages/minimaps/\\";Code: Select all
$minimap_uploadLocation = "c:/wamp/www/strongholdcrusader/downloads/categories/shc_cbuploads/pages/minimaps/\\";Code: Select all
$minimap_uploadLocation = "../categories/".$data_name."pages/minimaps/\\";