How to run User Criteria on the basis of URL
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-07-2023 04:46 AM
I just want to restrict the visibility of catalog item on the basis of URL, so for that I wrote one Not Available User Criteria Script which is not working. Below is the script
var url = top.location.href;
if (url.indexOf('now/hr/agent') > -1){
answer=true;
}
Please correct me if I am going wrong, or is there any other workaround for this?
Your answer will be helpful for me.
1 REPLY 1

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-08-2023 11:59 PM
Hi @Harsh Ahuja,
I believe user criteria are evaluated server side. So it won't be possible to use the URL.
Help others to find a correct solution by marking the appropriate response as accepted solution and helpful.