I am trying to use a text element with two attribute expressions. I want the URL field in the pop-up to hyperlink to the URL, but have it display "Click here for more info." I can get it to hyperlink to where I want it to go, but it is showing the full URL, not the alias I am looking for. Currently, this is what it shows.
Brian_McLeer_0-1724450493731.png
1st expression {expression/expr0}
var annexYear = $feature.ANNEX_YEAR;
var annexDate = $feature.ANNEX_DATE;
var acres = $feature.ACRES;
var name = $feature.ANNEX_NAME;
var annexationDate = Text($feature.AnnexationDate, "MMMM D, YYYY");
return "Annex Year: " + annexYear + "\n" +
"Annex Date: " + annexDate + "\n" +
"Acres: " + acres + "\n" +
"Name: " + name + "\n" +
"Annexation Date: " + annexationDate + "\n";2nd expression {expression/expr1}
var link = 'https://server.domain.com/maps/' + UrlEncode($feature.URL);
return linkText element:
{expression/expr0} URL: {expression/expr1}
Solved! Go to Solution.
I think I answered my own question. You can edit the HTML in the text element, but the OK button gets greyed out. You have to exit the HTML mode then click ok.
Brian_McLeer_0-1724450910390.png
Brian_McLeer_1-1724450941054.png
Brian_McLeer_2-1724450951859.png
I think I answered my own question. You can edit the HTML in the text element, but the OK button gets greyed out. You have to exit the HTML mode then click ok.
Brian_McLeer_0-1724450910390.png
Brian_McLeer_1-1724450941054.png
Brian_McLeer_2-1724450951859.png