[Skip to main content](#vessel-content)

#   CSV import, avoid product images get stored locally.

##

- **[river](/forum/user/9591-river "View river's Profile")**
- [![river's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar9591.gif)](/forum/user/9591-river "View river's Profile") Topic Author
- [ Offline](/forum/user/9591-river)

Less More

- Posts: 344
- Thank you received: 3
-
-

9 years 1 month ago -  9 years 1 month ago [\#279883](#279883) by [river](/forum/user/9591-river "View river's Profile")  *[CSV import, avoid product images get stored locally.](/forum/37-import-export-csv-xls/892238-csv-import-avoid-product-images-get-stored-locally#279883 "-- HikaShop version -- : 3.2 -- Joomla version -- : 3.8 -- PHP version -- : 7  Hikashop 3.2  So Im importing products from a CSV file and this works fine.  But I &quot;dont&quot; want the product image to be &quot;stored locally&quot;. Under &quot;new product&quot;&gt;In Enter image path&gt; Store locally=NO  But when Import the products from the CSV file the image is automatically stored locally.  Here is a screenshot from a part of my csv file:  How can I avoid this. Can I do some change in the CSV file so that the image is not stored locally, or do I need to change some code in the hikashop import settings.  Any advice...  Tnx.")* was created by *[river](/forum/user/9591-river "View river's Profile")*

-- HikaShop version -- : 3.2
-- Joomla version -- : 3.8
-- PHP version -- : 7

Hikashop 3.2

So Im importing products from a CSV file and this works fine.

But I "dont" want the product image to be "stored locally".
Under "new product"&gt;In Enter image path&gt; Store locally=NO

But when Import the products from the CSV file the image is automatically stored locally.

Here is a screenshot from a part of my csv file:
[ ![hika&#95;csv.png](/forum/attachment/40736) ](/forum/attachment/40736 "hika&#95;csv.png")

How can I avoid this.
Can I do some change in the CSV file so that the image is not stored locally, or do I need to change some code in the hikashop import settings.

Any advice...

Tnx.

- [ ![hika&#95;csv.png](/forum/attachment/40736) ](/forum/attachment/40736 "hika&#95;csv.png") [ ](/forum/attachment/40736?download=1 "hika&#95;csv.png")

Last edit: 9 years 1 month ago by [river](/forum/user/9591-river "View river's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM3LWltcG9ydC1leHBvcnQtY3N2LXhscy84OTIyMzgtY3N2LWltcG9ydC1hdm9pZC1wcm9kdWN0LWltYWdlcy1nZXQtc3RvcmVkLWxvY2FsbHk/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86584
- Thank you received: 14325
-
-

9 years 1 month ago [\#279895](#279895) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[CSV import, avoid product images get stored locally.](/forum/37-import-export-csv-xls/892238-csv-import-avoid-product-images-get-stored-locally#279895 "-- HikaShop version -- : 3.2 -- Joomla version -- : 3.8 -- PHP version -- : 7  Hikashop 3.2  So Im importing products from a CSV file and this works fine.  But I &quot;dont&quot; want the product image to be &quot;stored locally&quot;. Under &quot;new product&quot;&gt;In Enter image path&gt; Store locally=NO  But when Import the products from the CSV file the image is automatically stored locally.  Here is a screenshot from a part of my csv file:  How can I avoid this. Can I do some change in the CSV file so that the image is not stored locally, or do I need to change some code in the hikashop import settings.  Any advice...  Tnx.")*

Hi,

There are no options for that yet. We'll have such options for the import in the next version of HikaShop.
In the mean time, you would have to modify the code in administrator/components/com_hikashop/helpers/import.php to handle that.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM3LWltcG9ydC1leHBvcnQtY3N2LXhscy84OTIyMzgtY3N2LWltcG9ydC1hdm9pZC1wcm9kdWN0LWltYWdlcy1nZXQtc3RvcmVkLWxvY2FsbHk/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[river](/forum/user/9591-river "View river's Profile")**
- [![river's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar9591.gif)](/forum/user/9591-river "View river's Profile") Topic Author
- [ Offline](/forum/user/9591-river)

Less More

- Posts: 344
- Thank you received: 3
-
-

9 years 1 month ago [\#279944](#279944) by [river](/forum/user/9591-river "View river's Profile")  Replied by *[river](/forum/user/9591-river "View river's Profile")* on topic *[CSV import, avoid product images get stored locally.](/forum/37-import-export-csv-xls/892238-csv-import-avoid-product-images-get-stored-locally#279944 "-- HikaShop version -- : 3.2 -- Joomla version -- : 3.8 -- PHP version -- : 7  Hikashop 3.2  So Im importing products from a CSV file and this works fine.  But I &quot;dont&quot; want the product image to be &quot;stored locally&quot;. Under &quot;new product&quot;&gt;In Enter image path&gt; Store locally=NO  But when Import the products from the CSV file the image is automatically stored locally.  Here is a screenshot from a part of my csv file:  How can I avoid this. Can I do some change in the CSV file so that the image is not stored locally, or do I need to change some code in the hikashop import settings.  Any advice...  Tnx.")*

Ok tnx for reply
This is good news, Looking foreward to next update.

Anyway. I looked trough the file:
administrator/components/com_hikashop/helpers/import.php

And it containts 2000 lines of code:cheer:

Any advice on what I need to change in the file in order to deactivate the CSV-row "Images" so it only link and doesn't import the image ?

Tnx

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM3LWltcG9ydC1leHBvcnQtY3N2LXhscy84OTIyMzgtY3N2LWltcG9ydC1hdm9pZC1wcm9kdWN0LWltYWdlcy1nZXQtc3RvcmVkLWxvY2FsbHk/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86584
- Thank you received: 14325
-
-

9 years 1 month ago [\#279953](#279953) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[CSV import, avoid product images get stored locally.](/forum/37-import-export-csv-xls/892238-csv-import-avoid-product-images-get-stored-locally#279953 "-- HikaShop version -- : 3.2 -- Joomla version -- : 3.8 -- PHP version -- : 7  Hikashop 3.2  So Im importing products from a CSV file and this works fine.  But I &quot;dont&quot; want the product image to be &quot;stored locally&quot;. Under &quot;new product&quot;&gt;In Enter image path&gt; Store locally=NO  But when Import the products from the CSV file the image is automatically stored locally.  Here is a screenshot from a part of my csv file:  How can I avoid this. Can I do some change in the CSV file so that the image is not stored locally, or do I need to change some code in the hikashop import settings.  Any advice...  Tnx.")*

Deleting that piece should help: Code:

if(substr($image,0,7)=='http://'&#124;&#124;substr($image,0,8)=='https://'){ $parts = explode('/',$image); $name = array_pop($parts); $name = explode('?',$name); $name = array_shift($name); $name = urldecode($name); if(!file_exists($this-&gt;uploadFolder.$name)){ $content = file_get_contents($image); JFile::write($this-&gt;uploadFolder.$name,$content); }else{ $size = $this-&gt;getSizeFile($image); if($size!=filesize($this-&gt;uploadFolder.$name)){ $name=$size.'_'.$name; if(!file_exists($this-&gt;uploadFolder.$name)){ $content = file_get_contents($image); JFile::write($this-&gt;uploadFolder.$name,$content); } } } if(file_exists($this-&gt;uploadFolder.$name) &amp;&amp; (filesize($this-&gt;uploadFolder.$name) &gt; 0 &#124;&#124; filesize($this-&gt;uploadFolder.$name) === false)){ $product-&gt;images[$k] = $name; }else{ $unset[]=$k; } }

The following user(s) said Thank You: [river](/forum/user/9591-river "View river's Profile")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM3LWltcG9ydC1leHBvcnQtY3N2LXhscy84OTIyMzgtY3N2LWltcG9ydC1hdm9pZC1wcm9kdWN0LWltYWdlcy1nZXQtc3RvcmVkLWxvY2FsbHk/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[river](/forum/user/9591-river "View river's Profile")**
- [![river's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar9591.gif)](/forum/user/9591-river "View river's Profile") Topic Author
- [ Offline](/forum/user/9591-river)

Less More

- Posts: 344
- Thank you received: 3
-
-

9 years 1 month ago [\#279997](#279997) by [river](/forum/user/9591-river "View river's Profile")  Replied by *[river](/forum/user/9591-river "View river's Profile")* on topic *[CSV import, avoid product images get stored locally.](/forum/37-import-export-csv-xls/892238-csv-import-avoid-product-images-get-stored-locally#279997 "-- HikaShop version -- : 3.2 -- Joomla version -- : 3.8 -- PHP version -- : 7  Hikashop 3.2  So Im importing products from a CSV file and this works fine.  But I &quot;dont&quot; want the product image to be &quot;stored locally&quot;. Under &quot;new product&quot;&gt;In Enter image path&gt; Store locally=NO  But when Import the products from the CSV file the image is automatically stored locally.  Here is a screenshot from a part of my csv file:  How can I avoid this. Can I do some change in the CSV file so that the image is not stored locally, or do I need to change some code in the hikashop import settings.  Any advice...  Tnx.")*

Excellent. It works.

Tnx a lot.

Looking forward to get this function as a part of Hikashop. ![:)](/media/kunena/emoticons/3.png ":)") ![:)](/media/kunena/emoticons/3.png ":)")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzM3LWltcG9ydC1leHBvcnQtY3N2LXhscy84OTIyMzgtY3N2LWltcG9ydC1hdm9pZC1wcm9kdWN0LWltYWdlcy1nZXQtc3RvcmVkLWxvY2FsbHk/dG1wbD1tYXJrZG93bg==) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.079 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
