Logic Machine Forum
Mosaic custom widget image url - Printable Version

+- Logic Machine Forum (https://forum.logicmachine.net)
+-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1)
+--- Forum: Visualization (https://forum.logicmachine.net/forumdisplay.php?fid=9)
+--- Thread: Mosaic custom widget image url (/showthread.php?tid=765)



Mosaic custom widget image url - Anton Voskresenskiy - 02.05.2017

Hi,

Have got another problem...

When I add a custom widget with images, its content is stored with a very strange path:
/apps/data/mosaic20/widgets/u/2/images/walllamp.png
Where /u/2/ corresponds to user defined widget number TWO !!! "Number TWO" means that this widget was added second to number ONE...

So.. to access images inside widgets you have to decide beforehand load sequence and put the correspondent link inside script.js If you change the sequence of widget loading to the system - all images will be broken Sad((

Why not to use /u/myname/ where "myname" is the name of a custom widget, that is not dependent on the load sequence?

Has anyone used custom widgets with images yet? Is there work around ? May be adding images to custom theme will solve the problem? Any ideas?


A.


RE: Mosaic custom widget image url - Anton Voskresenskiy - 02.05.2017

Have got a solution using css. Inside css images are accessed in a correct way not depending on a full widget url.