Hello Community,
I need some help with this code since I am new to coding.
I have created a custom pop-up that allows me to gather information through intersecting.
Now I wanted to get to the next level-creating links with intersecting. I created two separate arcade expressions;
One for the intersection:
var intersectLayer =Intersects(FeaturesetbyName($map, "landrecords - Parcel Map"), $feature)
var results = ""
var baseweb ="http://pw.lacounty.gov/sur/nas/landrecords/parcel/PM"
for (var f in intersectLayer){
if (results ==""){
results = f.Reference;
} else{
results += ", " + f.Reference;
}
}
return results
One for the hyperlink:
The result is circled in blue, however the links both send you to the same document.
Any help would be appreciated.
Thank you.
-Matthew
Hi @Anonymous User ,
A couple of comments/questions on what you are trying to achieve:
Xander,
Yes the first comment/question is correct.
The reason why I want a loop is because there are several resources/polygons stacked on one another. I want to return all of them that are within a click. I'm not sure if that answers the second statement correctly. I will try the first function and see what I come up with.
Yes, that is the correct URL I am looking for.
Hi @Anonymous User ,
Thanks for clarifying!
You mention that you want to retrieve multiple hyperlinks since there can be multiple resources stacked on one another. A couple of things to keep in mind:
On the other hand, you mentioned earlier that you obtain the same URL for different features. I don't see a reason for this in the Arcade expression and I would first look at the data and try some different URL's manually in the browser to see what happens and that there is no redirect causing this behavior.