Author Topic: Adding Excel File Upload option to product_csv module  (Read 306249 times)

jtruelson

  • Beginner
  • *
  • Posts: 12
Re: Adding Excel File Upload option to product_csv module
« Reply #30 on: June 16, 2007, 08:32:03 am »
This worked beautifully until I applied the VM 1.0.11 patch.  Is there a fix? Would I dare reinstall the current hack?

Joseph Kwan

  • Advanced
  • Full Member
  • *****
  • Posts: 2344
Re: Adding Excel File Upload option to product_csv module
« Reply #31 on: June 16, 2007, 09:05:20 am »
Can you report detail of the problem? By comparing the files, I don't see any problem.
Joseph
Joomla/VM Upgrade Services. Problems with your migration? We can help.
Custom extensions to VM. Performance Tuning. Template modifications and advices.
Pay service to make VM work according to your needs. Your Joomla/VM solutions are just a PM away.

jtruelson

  • Beginner
  • *
  • Posts: 12
Re: Adding Excel File Upload option to product_csv module
« Reply #32 on: June 16, 2007, 20:54:17 pm »
Solved! ;D VM was throwing a file extension not allowed error.  I re-copied xls hack over the upgraded VM installation and it seems okay now.  Thanks for the quick reply, I much prefer to not restore from my most recent VM 1.0.10 backup.

I agree with an earlier post:  This option truly deserves to be part of the VM core.

Joseph Kwan

  • Advanced
  • Full Member
  • *****
  • Posts: 2344
Re: Adding Excel File Upload option to product_csv module
« Reply #33 on: June 16, 2007, 23:20:17 pm »
Yes, if you just apply the 1.0.10 to 1.0.11 patch without recopying the hack file, the ps_csv.php will be overwritten and the hack will have problem. I've updated the download with a new version that should work for both 1.0.10 and 1.0.11.

Edited June 18: That means, if you want to upgrade to 1.0.11, you have to re-apply the hack after the patch. The updated version added the changes in version 1.0.11 and it should have no problem working with 1.0.10.

Joseph
Joomla/VM Upgrade Services. Problems with your migration? We can help.
Custom extensions to VM. Performance Tuning. Template modifications and advices.
Pay service to make VM work according to your needs. Your Joomla/VM solutions are just a PM away.

Nero

  • Beginner
  • *
  • Posts: 13
Re: Adding Excel File Upload option to product_csv module
« Reply #34 on: June 18, 2007, 20:45:15 pm »
God, my Nightmares are over, thank u  20 000 times Sir Kwan. This is the first time i manage to upload files into virtue mart, none of the CSV methode i try, for weeks and weeks did work. My compliments and yes, this should be implanted in the future update of VM !! Thanks a lot !!!

THANK U THANK U THANK U !!!!!!

lipmat

  • Beginner
  • *
  • Posts: 45
Re: Adding Excel File Upload option to product_csv module
« Reply #35 on: June 23, 2007, 08:21:59 am »
hi,

after commenting out the duplicated items in language file, it drops this:

Quote
Parse error: syntax error, unexpected T_CLASS, expecting T_FUNCTION ... administrator\components\com_virtuemart\languages\english.php on line 1901

Joseph Kwan

  • Advanced
  • Full Member
  • *****
  • Posts: 2344
Re: Adding Excel File Upload option to product_csv module
« Reply #36 on: June 23, 2007, 08:34:12 am »
Usually this problem is due to a missing ';'. Please post the line you have commented out in case you can't solve your problem.
Joseph
Joomla/VM Upgrade Services. Problems with your migration? We can help.
Custom extensions to VM. Performance Tuning. Template modifications and advices.
Pay service to make VM work according to your needs. Your Joomla/VM solutions are just a PM away.

lipmat

  • Beginner
  • *
  • Posts: 45
Re: Adding Excel File Upload option to product_csv module
« Reply #37 on: June 23, 2007, 09:42:22 am »
Code: [Select]
var $_PHPSHOP_PRODUCT_DISPLAY_UPDATE_ITEM_LBL = 'Item Update Results';
// var $_PHPSHOP_PRODUCT_CSV_UPLOAD = 'Use CSV upload';
var $_PHPSHOP_PRODUCT_FOLDERS = 'Product Folders';
...
var $_PHPSHOP_PRODUCT_CLONE = 'Clone Product';
//var $_PHPSHOP_CSV_SETTINGS = 'Settings';
var $_PHPSHOP_CSV_DELIMITER = 'Delimiter';
var $_PHPSHOP_CSV_ENCLOSURE = 'Field Enclosure Char';
//var $_PHPSHOP_CSV_UPLOAD_FILE = 'Upload a CSV File';
var $_PHPSHOP_CSV_UPLOAD_XLS_FILE = 'Upload an EXCEL File';
//var $_PHPSHOP_CSV_SUBMIT_FILE = 'Submit CSV File';
//var $_PHPSHOP_CSV_FROM_DIRECTORY = 'Load from directory';
//var $_PHPSHOP_CSV_FROM_SERVER = 'Load CSV File from Server';
//var $_PHPSHOP_CSV_EXPORT_TO_FILE = 'Export to CSV File';
var $_PHPSHOP_CSV_SELECT_FIELD_ORDERING = 'Choose Field Ordering Type';
var $_PHPSHOP_CSV_DEFAULT_ORDERING = 'Default Ordering';
var $_PHPSHOP_CSV_CUSTOMIZED_ORDERING = 'My customized Ordering';
//var $_PHPSHOP_CSV_SUBMIT_EXPORT = 'Export all Products to CSV File';
//var $_PHPSHOP_CSV_CONFIGURATION_HEADER = 'CSV Import / Export Configuration';
var $_PHPSHOP_CSV_SAVE_CHANGES = 'Save Changes';
...

var $_PHPSHOP_CSV_AVAILABLE_FIELDS = 'Available Fields';
//var $_PHPSHOP_CSV_OUTPUT_CSV_UPLOAD_MESSAGES = 'CSV upload messages:';
var $_PHPSHOP_CSV_OUTPUT_COUNT = 'Count';
var $_PHPSHOP_CSV_OUTPUT_TOTAL = 'Total';
//var $_PHPSHOP_CSV_OUTPUT_FILE_IMPORTED = 'CSV File Imported';
var $_PHPSHOP_CSV_OUTPUT_UPDATED = 'Updated';

I've commented all the vars that can be found beneath Customized language for XLS upload coz they're duplicated

Joseph Kwan

  • Advanced
  • Full Member
  • *****
  • Posts: 2344
Re: Adding Excel File Upload option to product_csv module
« Reply #38 on: June 24, 2007, 00:17:17 am »
Don't see any problem with your file. You may try using the original file from the latest version and see if that works. The customization of the language are just for easier understanding. If that works, you can then copy back the custom language element one by one.

Joseph
Joomla/VM Upgrade Services. Problems with your migration? We can help.
Custom extensions to VM. Performance Tuning. Template modifications and advices.
Pay service to make VM work according to your needs. Your Joomla/VM solutions are just a PM away.

lipmat

  • Beginner
  • *
  • Posts: 45
Re: Adding Excel File Upload option to product_csv module
« Reply #39 on: June 24, 2007, 19:11:59 pm »
The problem was that the vars were ended with this:
Quote
class phpShopLanguage extends vmLanguage {}
but there should have been only a } sign.
thanks for your help


Joseph Kwan

  • Advanced
  • Full Member
  • *****
  • Posts: 2344
Re: Adding Excel File Upload option to product_csv module
« Reply #40 on: June 25, 2007, 07:25:39 am »
Good to know you find the problem. Is it a problem with the download? Other people doesn't seem to have problem.
Joseph
Joomla/VM Upgrade Services. Problems with your migration? We can help.
Custom extensions to VM. Performance Tuning. Template modifications and advices.
Pay service to make VM work according to your needs. Your Joomla/VM solutions are just a PM away.

lipmat

  • Beginner
  • *
  • Posts: 45
Re: Adding Excel File Upload option to product_csv module
« Reply #41 on: June 25, 2007, 08:30:45 am »
Yes, I've simply extracted the hack_Virtuemart_xls_upload.zip and there it is, in the language file. The modifications I had to make are commenting out the duplicated vars and in line 1902 the class phpShopLanguage extends vmLanguage {} had to be rewritten to a simple }

Joseph Kwan

  • Advanced
  • Full Member
  • *****
  • Posts: 2344
Re: Adding Excel File Upload option to product_csv module
« Reply #42 on: June 25, 2007, 08:46:57 am »
That's interesting. Do you have a brace } at line 1901? The class definition should have been ended with this brace.
Line 1902 is there for compatibility purpose. If you are using virtuemart, line 1902 can be deleted.
Joseph
Joomla/VM Upgrade Services. Problems with your migration? We can help.
Custom extensions to VM. Performance Tuning. Template modifications and advices.
Pay service to make VM work according to your needs. Your Joomla/VM solutions are just a PM away.

lipmat

  • Beginner
  • *
  • Posts: 45
Re: Adding Excel File Upload option to product_csv module
« Reply #43 on: June 25, 2007, 08:50:19 am »
ok, thank you

erick monfredo

  • Beginner
  • *
  • Posts: 5
Re: Adding Excel File Upload option to product_csv module
« Reply #44 on: June 25, 2007, 19:32:54 pm »
Thanks this tools is exactly what i need...but i got this error :

Fatal error: Cannot redeclare vmLanguage::$_PHPSHOP_PRODUCT_CSV_UPLOAD in /var/www/vhosts/xxxxxxxxx/httpdocs/site/administrator/components/com_virtuemart/languages/english.php on line 1887

Saw ther's  alreday same problem on first page seems to be fixed..but tryed to comment line   and still same error ...

that's the original english.php file, i didn't touched anything :

Code: [Select]
Customized language for XLS upload
*/
var $_PHPSHOP_PRODUCT_CSV_UPLOAD = 'CSV/Excel File upload';
var $_PHPSHOP_CSV_FILE_FORMAT = 'File Upload Format';
var $_PHPSHOP_CSV_FORMAT_CSV = 'CSV File';
var $_PHPSHOP_CSV_FORMAT_XLS = 'EXCEL File';
var $_PHPSHOP_CSV_SETTINGS = 'CSV Settings';
var $_PHPSHOP_CSV_UPLOAD_FILE = 'Upload File';
var $_PHPSHOP_CSV_SUBMIT_FILE = 'Submit File';
var $_PHPSHOP_CSV_FROM_DIRECTORY = 'Load from directory';
var $_PHPSHOP_CSV_FROM_SERVER = 'Load File from Server';
var $_PHPSHOP_CSV_EXPORT_TO_FILE = 'Export to CSV File';
var $_PHPSHOP_CSV_SUBMIT_EXPORT = 'Export all Products to CSV File';
var $_PHPSHOP_CSV_CONFIGURATION_HEADER = 'FILE Import / Export Configuration';
var $_PHPSHOP_CSV_OUTPUT_CSV_UPLOAD_MESSAGES = 'File upload messages:';
var $_PHPSHOP_CSV_OUTPUT_FILE_IMPORTED = 'File Imported';
}

Please can u tell me what is the problem ???

Thanks

Erick