Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Easy Populate - Serious help needed


Guest

Recommended Posts

I uploaded a clean version of oscommerce to my webserver and added Easy Populate to it. When trying to upload "complete tab-delimited.txt " file , the same file as was downloaded this is the error I get.

Warning: move_uploaded_file(/home/pcpulse/public_html/catalog/catalog/temp/EP2003Dec28-1111.txt): failed to open stream: No such file or directory in /home/pcpulse/public_html/catalog/admin/easypopulate_functions.php on line 32

Warning: move_uploaded_file(): Unable to move '/tmp/phplijxYg' to '/home/pcpulse/public_html/catalog/catalog/temp/EP2003Dec28-1111.txt' in /home/pcpulse/public_html/catalog/admin/easypopulate_functions.php on line 32

File uploaded.
Temporary filename: /tmp/phplijxYg
User filename: EP2003Dec28-1111.txt
Size: 80020

Warning: file(/home/pcpulse/public_html/catalog/catalog/temp/EP2003Dec28-1111.txt): failed to open stream: No such file or directory in /home/pcpulse/public_html/catalog/admin/easypopulate.php on line 644

Warning: Invalid argument supplied for foreach() in /home/pcpulse/public_html/catalog/admin/easypopulate.php on line 667

 

I have looked at the line numbers and can't see anything

  // get the entire file into an array
 $readed = file(DIR_FS_DOCUMENT_ROOT . $tempdir . $usrfl_name);
}
if ($localfile){
 // move the file to where we can work with it
 $file = tep_get_uploaded_file('usrfl'); 	 $attribute_options_query = "select distinct products_options_id from " . TABLE_PRODUCTS_OPTIONS . " order by products_options_id";

	 $attribute_options_values = tep_db_query($attribute_options_query);

	 $attribute_options_count = 1;
	 //while ($attribute_options = tep_db_fetch_array($attribute_options_values)){
 if (is_uploaded_file($file['tmp_name'])) {
	 tep_copy_uploaded_file($file, DIR_FS_DOCUMENT_ROOT . $tempdir);
 }

 echo "<p class=smallText>";
 echo "Filename: " . $localfile . "<br>";

 // get the entire file into an array
 $readed = file(DIR_FS_DOCUMENT_ROOT . $tempdir . $localfile);
}

// now we string the entire thing together in case there were carriage returns in the data
$newreaded = "";
foreach ($readed as $read){
 $newreaded .= $read;
}

 

// 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);
}

 

Any help would be great

 

Thanks

Rich

Link to comment
Share on other sites

Thanks , I have done that but still get these errors. ???

Warning: move_uploaded_file(/home/pcpulse/public_html/catalog/catalog/temp/EP2003Dec28-1111.txt): failed to open stream: No such file or directory in /home/pcpulse/public_html/catalog/admin/easypopulate_functions.php on line 32

Warning: move_uploaded_file(): Unable to move '/tmp/phpFmh9Fj' to '/home/pcpulse/public_html/catalog/catalog/temp/EP2003Dec28-1111.txt' in /home/pcpulse/public_html/catalog/admin/easypopulate_functions.php on line 32

File uploaded.
Temporary filename: /tmp/phpFmh9Fj
User filename: EP2003Dec28-1111.txt
Size: 80020

Warning: file(/home/pcpulse/public_html/catalog/catalog/temp/EP2003Dec28-1111.txt): failed to open stream: No such file or directory in /home/pcpulse/public_html/catalog/admin/easypopulate.php on line 644

Warning: Invalid argument supplied for foreach() in /home/pcpulse/public_html/catalog/admin/easypopulate.php on line 667

 

 

I have looked at the lines there's eroes on , but can't find any.

 

Rich

Link to comment
Share on other sites

Look for the line where it sets the temp directory and change '/catalog/temp/' to '/temp/' or '/catalog/temp' to '/temp' (depending on what's on that line).

 

Hth,

Matt

Link to comment
Share on other sites

You have an extra 'catalog' in the path:

 

/home/pcpulse/public_html/catalog/catalog/temp/EP2003Dec28-1111.txt

 

This is a file system path, so look at these - in both your configuration file and the contribution.

 

Matti

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...