New Ranks & Badges For The Community!
Notice something different? The ranks and associated badges have gone "Star Fleet". See what they all mean HERE
Commodore
Commodore
260 views

Regular Expression to find Data Content match on a webpage

Hello Team, we have our first request to try to configure a URL monitor to search for a corresponding line then a value on a webpage.  We then will configure the alert based on whether the value returned is greater than 200. 

Goal is to locate the line on the webpage starting with /output. (Example below).   We need to capture the last value ('3' in the example).  This value could change everytime monitor runs. 

We are testing with the basic URL Monitor.  Should we use one of the others such as URL Sequence or Content?

For the REGEX, can we simply use the actual output displayed or must we use the 'source page' view where the page is displayed with all the HTML tags? 

If anyone could advise or provide suggestions as to best way to configure the REGEX or an example we can use to get started, we would gladly appreciate it. 

Please let me know if you need any further information or have any questions. 

Thank you so much. Frank

 

url.PNG

 

0 Likes
1 Reply
Highlighted
Micro Focus Expert
Micro Focus Expert

You must use the raw HTML code of the page to build a correct regex to capture what you want.

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.