Searching for element name substrings in ACL
‎Feb 15, 2010
03:04 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
‎Feb 15, 2010
03:04 PM
Searching for element name substrings in ACL
Maybe I am mistaken and don't know what I am doing (a good possibility), but it seems like wild cards (*) in substr don't work very well when searching for element names. I am trying to search for any elements that contain a given substring in their name, such as "-xyz". What is the correct syntax to use for this in ACL?
For instance, if I were looking for any element that contained the substring "-xyz" in the element name, how would that oid_find_children(), or whatever, function read?
As I have stated before, I am no ACL expert, nor do I play one on TV.
________________________________
For instance, if I were looking for any element that contained the substring "-xyz" in the element name, how would that oid_find_children(), or whatever, function read?
As I have stated before, I am no ACL expert, nor do I play one on TV.
________________________________
2 REPLIES 2
‎Feb 15, 2010
03:17 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
‎Feb 15, 2010
03:17 PM
Hey, Ed...
Try something like this:
oid_find_children(oid, arr, ".*-xyz.*", 😎
The value 8 for the "flags" argument specifies that the "tag" argument
is a regular expression. The "." matches any character and the "*"
matches zero or more of whatever is right before it.
-Brandon 🙂
Try something like this:
oid_find_children(oid, arr, ".*-xyz.*", 😎
The value 8 for the "flags" argument specifies that the "tag" argument
is a regular expression. The "." matches any character and the "*"
matches zero or more of whatever is right before it.
-Brandon 🙂
‎Feb 15, 2010
03:27 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
‎Feb 15, 2010
03:27 PM
Thanks, Brandon.