Jump to content

Punk Rock Geek

Members
  • Posts

    49
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

Punk Rock Geek's Achievements

Member

Member (2/5)

0

Reputation

  1. Cool, thanks, that worked. But is there any way I can call "/home/*****/public_html/" without typing it out? I'm going to be using this on different servers, and I want everything to be automatically defined.
  2. For simpicity's sake, I have been changing it to "upload" in this topic. (I just forgot to change it that time.) The name of the actual directory is videos. And yes, it exists in my root folder, and it is CHMOD'd to 777. $target_path = "videos/"; uploads correctly. And $target_path = $_SERVER["DOCUMENT_ROOT"] . "videos/"; returns the error in my previous post.
  3. Got these errors when I turned on all PHP errors: Warning: move_uploaded_file(/var/www/html/upload/homepage01.gif) [function.move-uploaded-file]: failed to open stream: No such file or directory in /home/*****/public_html/modules/add_file.php on line 94 Warning: move_uploaded_file() [function.move-uploaded-file]: Unable to move '/tmp/phpVUAjh7' to '/var/www/html/upload/homepage01.gif' in /home/*****/public_html/modules/add_file.php on line 94 (***** kept blank for privacy reasons.)
  4. Okay, thanks, I changed target path to $target_path = $_SERVER["DOCUMENT_ROOT"] . "upload/"; I removed the extra / as well. When I echo it, I get: /var/www/html/upload/ However, the file is still not uploading.
  5. Hmm, echoing $target_path when$ target_path= "$_SERVER["DOCUMENT_ROOT"]/upload/"; returns absolutely nothing. Even the "/upload/" part is missing.
  6. The form works when I put the upload folder inside of the same directory as the php file. So: $target_path = "upload/"; Works. However, if the upload folder is in a parent directory, it does not work. I have tried: $target_path = "$_SERVER["DOCUMENT_ROOT"]/upload/"; And $target_path = "../upload/"; Help?
  7. Awesome, thanks! It worked! What would I need to change if I wanted every option in the select box (NOT just the options selected) to be returned in the javascript?
  8. I have a form containing a multiple select box, as follows: Please assume that I already have knowledge of how basic AJAX is structured. I only need to know how the above particular example will differ from basic ones. (For example, if I have an empty name field, and I fill in the name and press submit, my code already successfully adds that name to the database and shows the new name on the page without a refresh.) I am not able to replicate this with multiple options at once however. Specifically, how can I get every option that is selected, to be transferred to the "my_javascript" function? Furthermore, after I send those options from the javascript to the PHP (I assume this step will be identical to "basic" AJAX implementations?), then how do I add each option to the database in my PHP file? Thanks!
  9. With the code: include ($_SERVER['DOCUMENT_ROOT'] . 'plugins/content/jumi/originals/language/file.php'); I am getting no errors. The only error that shows up is this: And that's only because the language variables within file.php are not being included. I used: error_reporting(E_ALL); ini_set('display_errors', '1'); To report the errors.
  10. The variable isn't empty. It just isn't including anything. I don't know what else to add.
  11. The URL of the file I'm trying to include is: http://www.mydomain.com/plugins/content/jumi/originals/language/file.php
  12. I changed include ($_SERVER['DOCUMENT_ROOT'] . '/directory/file.php'); to include ($_SERVER['DOCUMENT_ROOT'] . 'directory/file.php'); And it got rid of the double slash. Still doesn't work though.
  13. Hmm, nope. I'll need access to the functions and variables still.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.