How to make the mod work for digital download product?
I think some modification would be required to set download location, file type etc
Thanks in advanced
Printable View
How to make the mod work for digital download product?
I think some modification would be required to set download location, file type etc
Thanks in advanced
Way beyond me. I suggest search the forum for object_array or post in the general questions area.PHP Code:
reset($object_array);
while (list($key, $value) = each($object_array))
I have no experience with digital product, but I have found that if you have moderate programming skills, you could add any fields you need to EP. The core logic is there for updating most files associated with products.
The upload code doesn't begin until pretty far down in the program, but each section has some notes that proved helpfull along with reading the code logic.
Jeff
Great module! Two questions though:
1. How to I import images hosted on a third party site? In my upload text file, I set the v_products_image to something like: http://www.othersite.com/image.jpg. However, when it imports it into my store, I believe it's saving that long string as the actual image name, so that in my store, it tries to load: http://www.MyStore.com/images/http:/....com/image.jpg
I use Image Handler 2, by the way. So I would like to know if EP can import the image from this other site and save it directory into my Images folder, stripping off the URL and only storing the image name in the database so that Image Handler can pick it up?
2. How can I modify the EP php file so that it won't import a product if the v_products_model value matches ANY PART of an existing record? For example, let's say that I have an existing record called "ITEM123 - A" and in my import file, I have a new item called "ITEM123". I do not want to import this new record. Where can I edit in the EP php file to see if any part of the string matches, to simply skip it and don't import it?
[QUOTE=Jeff G;616661]PHP Code:
reset($object_array);
while (list($key, $value) = each($object_array))
Well Line 28 had // in front of if (!is_array($object_array)) return;
i deleted the // and i am not getting the errors - however, when i click to edit the product all of the feilds are BLANK, even though i see the products listed on the front page.. :eek:
everything goes back to normal when i change the product id back to 1.
not sure how to fix it, i'll keep looking. i'm thinking i might just use product id 1 as a workaround then run the sql patch to update things to music product.
Would anyone please let me know what the appropriate "v_products..." would be for "record company" and "music genre" so i can add these 2 fields to the EP file?
For the record, I was able to address this issue:
The way I did that was to do the following:Quote:
2. How can I modify the EP php file so that it won't import a product if the v_products_model value matches ANY PART of an existing record? For example, let's say that I have an existing record called "ITEM123 - A" and in my import file, I have a new item called "ITEM123". I do not want to import this new record. Where can I edit in the EP php file to see if any part of the string matches, to simply skip it and don't import it?
1. Line 1877 - CHANGE:
$result = ep_query("SELECT products_id FROM ".TABLE_PRODUCTS." WHERE (products_model = '" . zen_db_input($v_products_model) . "')");
TO THIS:
$result = ep_query("SELECT products_id FROM ".TABLE_PRODUCTS." WHERE (products_model LIKE '%" . zen_db_input($v_products_model) . "%')");
Then I commented out Line 1941 to Line 1978, which is the block of code that updates existing orders. The reason I have this need is because I am not planning to update anything, but rather, ADD new items only.
I still need some help with this one outstanding issue though:
ok think i found the right 1 but when i upload my products it comes up with this error::
Warning: move_uploaded_file(/home/truliebl/public_html/temp/export_attributes_20080920.xls) [function.move-uploaded-file]: failed to open stream: Permission denied in /home/truliebl/public_html/admin/includes/functions/extra_functions/easypopulate_functions.php on line 57
Warning: move_uploaded_file() [function.move-uploaded-file]: Unable to move '/tmp/phpnL3RVf' to '/home/truliebl/public_html/temp/export_attributes_20080920.xls' in /home/truliebl/public_html/admin/includes/functions/extra_functions/easypopulate_functions.php on line 57
Warning: file(/home/truliebl/public_html/temp/export_attributes_20080920.xls) [function.file]: failed to open stream: No such file or directory in /home/truliebl/public_html/admin/easypopulate.php on line 1201
Warning: Invalid argument supplied for foreach() in /home/truliebl/public_html/admin/easypopulate.php on line 1301
Help any1?:no:
credenscel,
From your post it sounds like you changed the default of products_id, not products_type. Products_id should not be in the EP file. It is either found by EP when updating, or assigned automatically for new product.
Give that a check.
Jeff