I'm trying to add URL's to an online document that will scroll to a specific page of the document depending on the feature selected. This is all based on building zones, for example, if an 'R1' Zone is selected, clicking on the URL in the pop-up will scroll to page 108, if the 'CC' Zone it will scroll to page 152, and so on.
I know that it's possible to put in a single URL using the method in the image below:
But that doesn't allow for URL variation depending on the zone. For example: '<baseurl>' + '#page=108'
When I attempt to create an Arcade expression to allow for this, it just adds the URL as text, instead of being a clickable link. I also am unable to use HTML code in Arcade, so I can't figure out how to make it a word (Ex. Click Here) instead of the entire URL.
Below is a really simple test expression I wrote to see if the link would work and the result in the pop-up.
Does anyone have a work-around for this? Am I missing some built-in functionality?
Any help is appreciated!
Solved! Go to Solution.
I think I ran into a situation like this before with one of my projects. I would create a separate Arcade Expression (Expression01) to create the URL link and then, in your popup, reference Expression01 as the source of your hyperlink. I think this way the "on the fly" link is actually constructed before it is presented as a URL link in the pop up.
Steve
I think I ran into a situation like this before with one of my projects. I would create a separate Arcade Expression (Expression01) to create the URL link and then, in your popup, reference Expression01 as the source of your hyperlink. I think this way the "on the fly" link is actually constructed before it is presented as a URL link in the pop up.
Steve
It looks like this works! Thank you, I was hoping it would be something simple that I was just missing!
Have a great day!
I have the exact same problem as Caitlin. Can you elaborate a little more? Do I create a separate Attribute Expression with just the URL link? What do I do with the conditional If - Else Statement?
I am using Map Viewer.
You need to create a new expression that contains your if else and any other code you're using, this expression includes your URL.
and then you add {expression/expr0} to wherever you wanted to put the URL in your pop-up.
@Caitlin, I am having the same issue. Is there any way you can post your attribute expression and how you inserted it into the text element?