Solved

Extract list of jpg files

Posted on 2014-01-05
1
269 Views
Last Modified: 2014-01-05
I am trying to get a list of all jpg files in a html file. The html file is complex, and not formatted clearly. (at least not to a human) I have tried to add blank lines around the image tags, but that is not helping to split up the results enough. I imagine there has to be an easy way to get a list of files?

<img src="directory/test.jpg" alt="" width="200" height="250">

becomes:
directory/test.jpg
0
Comment
Question by:stakor
1 Comment
 
LVL 84

Accepted Solution

by:
ozo earned 500 total points
Comment Utility
perl -lne 'print for /src="(.*?)"/g'
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Perl 101 11 68
Union rows in array that have common elements 2 79
SQL query to extract a portion of a field 6 68
Need some Regex Help 3 35
by Batuhan Cetin Regular expression is a language that we use to edit a string or retrieve sub-strings that meets specific rules from a text. A regular expression can be applied to a set of string variables. There are many RegEx engines for u…
I have been reconstructing a PHP-based application that has grown into a full blown interface system over the last ten years by a developer that has now gone into business for himself building websites. I am not incredibly fond of writing PHP code o…
Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now