Friends,
Here's the latest - I was uploading to my heart's content, until... I don't have A CLUE what happened.. I have tried reuploading the original files from a fresh osC MS2max install and it isn't fixing.. Any ideas? Is it possible that there error is due to the content in the txt file I am trying to upload? (I'm uploading a .txt file from local.)
__________________________________________________ _______
Easy Populate 2.61-MS2 - Default Language : English(1)
Warning: move_uploaded_file(/home/cafeprod/public_html//temp/Upload_withnoDecimals-Weight.txt): failed to open stream: Permission denied in /home/cafeprod/public_html/admin/easypopulate_functions.php on line 32
Warning: move_uploaded_file(): Unable to move '/var/tmp/phplUDUez' to '/home/cafeprod/public_html//temp/Upload_withnoDecimals-Weight.txt' in /home/cafeprod/public_html/admin/easypopulate_functions.php on line 32
File uploaded.
Temporary filename: /var/tmp/phplUDUez
User filename: Upload_withnoDecimals-Weight.txt
Size: 1360399
Warning: file(/home/cafeprod/public_html//temp/Upload_withnoDecimals-Weight.txt): failed to open stream: No such file or directory in /home/cafeprod/public_html/admin/easypopulate.php on line 720
Warning: Invalid argument supplied for foreach() in /home/cafeprod/public_html/admin/easypopulate.php on line 738
Upload EP File
Any ideas are most appreciated...
__________________________________________________
My easypopulate_functions.php file (at public_html/admin)
<?php
function tep_get_uploaded_file($filename) {
if (isset($_FILES[$filename])) {
$uploaded_file = array('name' => $_FILES[$filename]['name'],
'type' => $_FILES[$filename]['type'],
'size' => $_FILES[$filename]['size'],
'tmp_name' => $_FILES[$filename]['tmp_name']);
} elseif (isset($GLOBALS['HTTP_POST_FILES'][$filename])) {
global $HTTP_POST_FILES;
$uploaded_file = array('name' => $HTTP_POST_FILES[$filename]['name'],
'type' => $HTTP_POST_FILES[$filename]['type'],
'size' => $HTTP_POST_FILES[$filename]['size'],
'tmp_name' => $HTTP_POST_FILES[$filename]['tmp_name']);
} else {
$uploaded_file = array('name' => $GLOBALS[$filename . '_name'],
'type' => $GLOBALS[$filename . '_type'],
'size' => $GLOBALS[$filename . '_size'],
'tmp_name' => $GLOBALS[$filename]);
}
return $uploaded_file;
}
// the $filename parameter is an array with the following elements:
// name, type, size, tmp_name
function tep_copy_uploaded_file($filename, $target) {
if (substr($target, -1) != '/') $target .= '/';
$target .= $filename['name'];
move_uploaded_file($filename['tmp_name'], $target);
}
__________________________________________________ _________
Now.. line 738 from the easypopulate.php file at public_html/admin
// now we string the entire thing together in case there were carriage returns in the data
737~ $newreaded = "";
738~ foreach ($readed as $read){
739~ $newreaded .= $read;
}
// now newreaded has the entire file together without the carriage returns.
// if for some reason excel put qoutes around our EOREOR, remove them then split into rows
$newreaded = str_replace('"EOREOR"', 'EOREOR', $newreaded);
$readed = explode( $separator . 'EOREOR',$newreaded);
OH.. and also, I have set permissions on both of these files as well as the easypopulate.php found at root/easypopulate/EP_v2_74_MS2/catalog/admin/easypopulate.php to 777.
Thanks - will await your brilliance and continue to absorb![]()





LinkBack URL
About LinkBacks











Bookmarks