cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

How to locate the tags that contain blanks at the start of the tag content using an ACL fucntion

SOLVED
Highlighted
Garnet

How to locate the tags that contain blanks at the start of the tag content using an ACL fucntion

Hello,

I'm looking for a way to locate the tags that contain blanks at the start of the tag content. What is the best way using an ACL function ?

Best regards

David

Tags (1)
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Re: How to locate the tags that contain blanks at the start of the tag content using an ACL fucntion

I would say the easiest way to do this is using XPath, something like this:

function fixSpaces() {
  local oids[], o;
  xpath_nodeset(oids, "//*[starts-with(text(),' ')]");
  for (o in oids) {
    # do something with oids[o]...
  }
}

View solution in original post

2 REPLIES 2
Highlighted

Re: How to locate the tags that contain blanks at the start of the tag content using an ACL fucntion

I would say the easiest way to do this is using XPath, something like this:

function fixSpaces() {
  local oids[], o;
  xpath_nodeset(oids, "//*[starts-with(text(),' ')]");
  for (o in oids) {
    # do something with oids[o]...
  }
}

View solution in original post

Re: How to locate the tags that contain blanks at the start of the tag content using an ACL fucntion

Hi Clay,

Thanks for your help.

David

Announcements