VL-Web: Images from different sites

This Q&A forum allows users to post and respond to "How Do I Do ....." questions. Please do not use to report (suspected) errors - you must use your regional help desk for this. The information contained in this forum has not been validated by LANSA and, as such, LANSA cannot guarantee the accuracy of the information.
Post Reply
René Houba
Posts: 220
Joined: Thu Nov 26, 2015 7:03 am

VL-Web: Images from different sites

Post by René Houba »

Hi,

I was wondering if someting like this is possible:

We are going to make a website for a prospect. They are in the food industry. This site shows several pictures of articles.

The prospect has several Suppliers.
The pictures to show are not pictures of our prospect, they are pictures of their suppliers and are also located on the site of the supplier.

It could be that the supplier decides to change one of their pictures. They do that in their own environment and the website of our prospect should pick up this changed picture immediately.

To have this work is very important for our prospect. They have so many suppliers and they made each supplier responsible for their own pictures.


So in this scenario, the picture is not located in the LANSA IMAGES folder at all.


Kind regards,
René
dannyoorburg
Posts: 177
Joined: Mon Jan 04, 2016 9:50 am
Location: Australia

Re: VL-Web: Images from different sites

Post by dannyoorburg »

Hi René,

PRIM_IMAG.Filename takes URLs as well.

Cheers,
Danny
René Houba
Posts: 220
Joined: Thu Nov 26, 2015 7:03 am

Re: VL-Web: Images from different sites

Post by René Houba »

Hi Danny,

That's great. Is there a specific syntax for this or is it just like this:
#Image.filename := ('http://www.lansa.com/PoC/en_ALL/images/logo.gif')


Kind regards,
René
JamesDuignan
Posts: 85
Joined: Thu Nov 26, 2015 1:43 pm

Re: VL-Web: Images from different sites

Post by JamesDuignan »

Hi Rene,

Yep, as simple as that, as long as the image exists ;)

Code: Select all

Begin_Com Role(*EXTENDS #PRIM_WEB)

Define_Com Class(#PRIM_IMAG) Name(#gImage) Displayposition(1) Parent(#COM_OWNER) Height(313) Width(569) Tabposition(1) Left(32) Top(8)

Evtroutine Handling(#Com_owner.Initialize)

#gImage.FileName := ('http://www.lansa.com/img/products/visual-lansa-web-development-responsive.png')

Endroutine

End_Com
René Houba
Posts: 220
Joined: Thu Nov 26, 2015 7:03 am

Re: VL-Web: Images from different sites

Post by René Houba »

THANKS James :)
Post Reply