Web Link Field has new unexplained behavior

Hey there,
A few days ago, a weblink field in our database started doing something strange.
The weblink CONewTab OSU is meant to make the link to the CO record linked to a collecting event by constructing the URL with the collectionCode and catalog number of related records using the /bycatalog/ pathway.

It did this flawlessly until a few days ago, when it started combining the URL of the current page with the link. I don’t know how or why this started happening.

See below screenshot, where instead of the expected link:
invertebrates.osu.edu/specify/bycatalog/IZB/000074985, the button links to

https://invertebrates.osu.edu/specify/view/collectingevent/315643/invertebrates.osu.edu/specify/bycatalog/IZB/000074985
which is the URL of the page of the CE record + the expected formatted weblink to the CO table.

Notice as well that when we expanded the grid view, and click on the “link” button on the right, the correct URL appears on mouseover and is linked when clicked.

Any ideas as to what’s causing this? Seems like a bug, because I’ve deleted and recreated the weblink and signed out and in, and the problem persists.

Hi @nfshoobs

I believe this is being caused by the link you have in the weblink being treated as a relative link. In your weblink setup, is there a reason not to include the scheme (https://) in the first url part argument? I think this may solve the issue.

1 Like

Also, it seems to be working for me if I am correctly understanding the flow. If I go to https://invertebrates.osu.edu/specify/view/collectingevent/315643/ and click on the CO weblink within the Collection objects section, regardless of whether it is in table view or grid view, the collection object https://invertebrates.osu.edu/specify/view/collectionobject/597550/ will open. The system is redirecting from the bycatalog/collectionCode/catalogNumber path to the view path with the table and id.

I am on Firefox 133.0.3, and have also tested and it works on microsoft edge.

@markp You are right on the money. The link needs the https://, any weblink without that in the URL part will have problems!
And the reason it was immediately working for you is that I had manually changed the link to another version that worked (because it had a URL part with this https:// part already). I’ve fixed both though!

1 Like