From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

Example Code

'Mapping' a Webpage using LabVIEW

Products and Environment

This section reflects the products and operating system used to create the example.

To download NI software, including the products shown below, visit ni.com/downloads.

    Software

  • LabVIEW

Code and Documents

Attachment

Overview

Use this VI to programmatically discover http links contained in a web page.

 
Description

This example program uses the URL Get Document VI to return the HTML content of a webpage as a string. It then searches in the HTML content to return all the links it contained in an array.

 

Requirements

  • LabVIEW 2012 (or compatible)

 
Steps to Implement or Execute Code

1. Insert the URL
2. Run VI
3. Indicators show HTML contents and Links founded

 

Additional Information or References
VI Block Diagram

Web page Mapper LV2012 NI verified.png

 

 **This document has been updated to meet the current required format for the NI Code Exchange.**

 

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.

Comments
engwei
Member
Member
on

by the way .. what for ?

Nate.H
Active Participant
Active Participant
on

Mostly to demonstrate string parsing. A little because it was just fun. A little more because it was a start on creating a useful tool for showing a webpage's relation to other pages within a large online space such as ni.com. With a core structure similar to this VI, you can create a relational hierarchy that looks similar to the VI hierarchy and helps with content placement for products, content linking for relevant searches and support, etc...

engwei
Member
Member
on

hmm. yeah .. cool