HikaShop: image link

  • Posts: 51
  • Thank you received: 0
12 years 1 month ago #69374

Hello
i want to take tha product images from a url instead of storing them locally
how can i do that ????

Please Log in or Create an account to join the conversation.

  • Posts: 12953
  • Thank you received: 1778
12 years 1 month ago #69501

Hi,

I think that you'll have to use CSV import and directly put the URL of your images in the "images" column then HikaShop will download them automatically to your website in order to attach them to your products.

Hope this will help you.

Last edit: 12 years 1 month ago by Mohamed Thelji.
The following user(s) said Thank You: gili

Please Log in or Create an account to join the conversation.

  • Posts: 51
  • Thank you received: 0
12 years 1 month ago #69572

i cant use csv import cause i must import everything from another DB to another server so i need a workaround to this
plus i DONT want the files to be stored locally. i want to take them from the other server directly

Please Log in or Create an account to join the conversation.

  • Posts: 82818
  • Thank you received: 13361
  • MODERATOR
12 years 1 month ago #69575

That's not possible. HikaShop HAS to download the images in order to create thumbnails for them and store the thumbnails locally. You won't be able to have the product images on another server or you will have to customize the views of hikaShop for that and not have any thumbnails.

The following user(s) said Thank You: gili

Please Log in or Create an account to join the conversation.

  • Posts: 51
  • Thank you received: 0
12 years 1 month ago #69578

ok so i need two solutions from you
1. how to take the products from the other db and DL them locally
2. how to do what you said.. how to customize the views of hikashop ????
or how can i modify the program to take one foto and show it in two sizes without resizing it ???

Please Log in or Create an account to join the conversation.

  • Posts: 82818
  • Thank you received: 13361
  • MODERATOR
12 years 1 month ago #69731

1. Mohamed already replied to you about that

I think that you'll have to use CSV import and directly put the URL of your images in the "images" column then HikaShop will download them automatically to your website in order to attach them to your products.


2. You would have to create first a custom field of the table "product" in order to enter the URL of the image for each product.
Then, you would have to edit each view file of the view "product" via the menu Display->Views and replace the image displaying block of code by some simple code like that:
echo '<img src="'.$this->row->custom_field_column_name.'" />';
Where custom_field_column_name is the column name of your custom field. Of course, you can add a width/height in that img tag to force the size of the image in order to suits your needs.

Here is an example of such code that you want to replace:
echo $this->image->display(@$this->row->file_path,false,$this->escape($this->row->file_name), '' , '' , $this->image->main_thumbnail_x, $this->image->main_thumbnail_y);

That's taken from the listing_img_title view file.

The following user(s) said Thank You: gili

Please Log in or Create an account to join the conversation.

  • Posts: 51
  • Thank you received: 0
12 years 2 weeks ago #72400

so, we have managed to display the images in the product details, but the only problem is that where the thumbnails are supposed to be, it shows the regular (not resized) image. Any idea about how to also show the thumbs using url path? Thank you so much in advance.

Please Log in or Create an account to join the conversation.

  • Posts: 51
  • Thank you received: 0
12 years 2 weeks ago #72704

anyone ????????

Please Log in or Create an account to join the conversation.

  • Posts: 82818
  • Thank you received: 13361
  • MODERATOR
12 years 2 weeks ago #72708

Please provide a link so that we can see that as well with a screenshot explaining what is not right.

The following user(s) said Thank You: gili

Please Log in or Create an account to join the conversation.

  • Posts: 51
  • Thank you received: 0
12 years 2 weeks ago #72714

ubook.igrouphost.com/index.php?option=co...t=listing&Itemid=300
go to the second page
and check the book that has the title "Limnos"
it has a thumbnail but its not actually thumb but the image itself ...
so what i need now is another command that takes the distant thumbnail image and uses it here
for the image i used the command u told me before and worked fine :)

Please Log in or Create an account to join the conversation.

  • Posts: 51
  • Thank you received: 0
12 years 2 weeks ago #72754

well?????

Please Log in or Create an account to join the conversation.

  • Posts: 51
  • Thank you received: 0
12 years 2 weeks ago #73021

helloooo !!!! anyone ?!?!??!?!?

Please Log in or Create an account to join the conversation.

  • Posts: 82818
  • Thank you received: 13361
  • MODERATOR
12 years 2 weeks ago #73229

Hi,

You need to add such CSS code in the frontend CSS file of Hikashop that you can edit via the Display tab of the configuration :
.hikashop_products img{
height : 100px;
}

Note that each time you bump a thread, it goes up at the top of the list so you have to wait longer for us to see it which goes against what you want. You would already have had a reply yesterday would you not have bumped it twice.

The following user(s) said Thank You: gili

Please Log in or Create an account to join the conversation.

  • Posts: 51
  • Thank you received: 0
12 years 2 weeks ago #73387

Hello
the option of adding css is the one thought i already had !!!! :)
but i d like to know if there is a way to call a second image from the remote server to put in the place of the thumbnail !!!
could u please help me with that ??

Please Log in or Create an account to join the conversation.

  • Posts: 82818
  • Thank you received: 13361
  • MODERATOR
12 years 2 weeks ago #73616

Hi,

I'm not following you.

The code I gave you :
echo '<img src="'.$this->row->custom_field_column_name.'" />';
Display an image.
If you want to display two images, then just have that code twice.
If you want to have a smaller image, then just upload a smaller image and use that small image instead of the big one.

The following user(s) said Thank You: gili

Please Log in or Create an account to join the conversation.

  • Posts: 51
  • Thank you received: 0
12 years 2 weeks ago #73737

Exactly I want to display 2 images one big one small . The small at the position of the thumbnail and the big at the position of the normal image

Please Log in or Create an account to join the conversation.

  • Posts: 82818
  • Thank you received: 13361
  • MODERATOR
12 years 1 week ago #74013

What is, in your case, the position of the big image and the small image ?
I can see that you were first talking about the products listing page. But it sounds that you are not talking about the product page ?

You want to small image on the listing and the big on the product page ?

In that case, for the small image add the code displaying the first custom field of the small image in the listing_img_title file and then, for the big image, add the code displaying the second custom field of the big image in the show_default file via the menu Display->Views.

The following user(s) said Thank You: gili

Please Log in or Create an account to join the conversation.

  • Posts: 51
  • Thank you received: 0
12 years 1 day ago #76499

thank you for your help ..

Please Log in or Create an account to join the conversation.

Time to create page: 0.093 seconds
Powered by Kunena Forum