We're Hiring!

Is it possible to use URL hyperlinks in Key-Value pairs?

General user discussion about using the OMERO platform to its fullest. Please ask new questions at https://forum.image.sc/tags/omero
Please note:
Historical discussions about OMERO. Please look for and ask new questions at https://forum.image.sc/tags/omero

There are workflow guides for various OMERO functions on our help site - http://help.openmicroscopy.org

You should find answers to any basic questions about using the clients there.

Is it possible to use URL hyperlinks in Key-Value pairs?

Postby Kouichi_C_Nakamura » Thu Dec 06, 2018 4:39 pm

Is it possible to use URL hyperlinks in Key-Value pairs (MapAnnotation)?

I could not, but the readme file of OMERO.mapr shows apparent hyperlinks (text in blue), so I wonder if it's possible or not. https://github.com/ome/omero-mapr
Kouichi_C_Nakamura
 
Posts: 165
Joined: Thu Oct 19, 2017 1:35 pm

Re: Is it possible to use URL hyperlinks in Key-Value pairs?

Postby manics » Thu Dec 06, 2018 5:48 pm

Mapr overrides one of the webclient templates to make hyperlinks into links: https://github.com/ome/omero-mapr/blob/ ... al.js.html
It's not part of the standard OMERO.web. If you've got a test system you could try installing mapr even if you don't need most of the functionality?

Simon
User avatar
manics
Team Member
 
Posts: 261
Joined: Mon Oct 08, 2012 11:01 am
Location: Dundee

Re: Is it possible to use URL hyperlinks in Key-Value pairs?

Postby Kouichi_C_Nakamura » Mon Dec 10, 2018 11:49 am

Thanks. We discussed the installation of OMERO.mapr before for other purposes, but this adds another advantage of using it.

I've noticed that, with standard OMERO.web, HTML tag like `<a href="https://www.ncbi.nlm.nih.gov/gene/14415">14415</a>` does not work. However, if I use an URL like "https://www.ncbi.nlm.nih.gov/gene/14415" as a value, it does look blue and allows us to jump to the destination page.

Image001.png
Image001.png (3.42 KiB) Viewed 1255 times
Kouichi_C_Nakamura
 
Posts: 165
Joined: Thu Oct 19, 2017 1:35 pm

Re: Is it possible to use URL hyperlinks in Key-Value pairs?

Postby mtbc » Wed Dec 12, 2018 10:54 am

Dear Kouichi,

Thank you, an interesting observation. We'll have a think about this one: I can see that it would be useful to recognize simple cases more usefully but we may shy from having users expect arbitrary HTML to be supported!

Cheers,
Mark
User avatar
mtbc
Team Member
 
Posts: 282
Joined: Tue Oct 23, 2012 10:59 am
Location: Dundee, Scotland

Re: Is it possible to use URL hyperlinks in Key-Value pairs?

Postby Kouichi_C_Nakamura » Thu Dec 13, 2018 12:05 pm

I agree. What to be supported and what to be not.

Thinking of the appearance of MapAnootation on OMERO.web, just supporting the HTML <a> tag makes sense to me. You probably don't want <b> or <i> or anything more complicated than that.

Does that (supporting <a> alone) accidentally convert a literal text to a hyperlink? Quite unlikely, but not guaranteed.
Kouichi_C_Nakamura
 
Posts: 165
Joined: Thu Oct 19, 2017 1:35 pm

Re: Is it possible to use URL hyperlinks in Key-Value pairs?

Postby manics » Thu Dec 13, 2018 12:50 pm

If it's just hyperlinks we could auto-link anything matching
Code: Select all
protocol://<non-space-characters>
and not bother with parsing html or any other markup?
User avatar
manics
Team Member
 
Posts: 261
Joined: Mon Oct 08, 2012 11:01 am
Location: Dundee

Re: Is it possible to use URL hyperlinks in Key-Value pairs?

Postby Kouichi_C_Nakamura » Thu Dec 13, 2018 1:35 pm

Thanks.

protocol://<non-space-characters>


Looking at the screenshot I uploaded above (the Gene ID value), this I think is perhaps already working?

Maybe, it's good as it is, then? Just ask people to give up using <a> and instead ask to use full URLs?

Best,
Kouichi
Kouichi_C_Nakamura
 
Posts: 165
Joined: Thu Oct 19, 2017 1:35 pm

Re: Is it possible to use URL hyperlinks in Key-Value pairs?

Postby manics » Thu Dec 13, 2018 3:32 pm

You're right! It looks like if you add a URL to a map-annotation in OMERO.web it only becomes hyperlinked after a refresh, this is why I thought it wasn't implemented, so I think using the full URL is the best option. We'll certainly consider adding limited formatting (e.g. limited HTML tags, or markdown) in future though.
User avatar
manics
Team Member
 
Posts: 261
Joined: Mon Oct 08, 2012 11:01 am
Location: Dundee


Return to User Discussion

Who is online

Users browsing this forum: No registered users and 1 guest