Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > How to find surplus unlinked images

Reply
Thread Tools

How to find surplus unlinked images

 
 
KiwiBrian
Guest
Posts: n/a
 
      08-18-2008
Assume that I have a html file that has internal links to 100 images which
are in a daughter folder.
This daughter folder has an extra 500 unrequired images.
How could I make a list of the filenames of the unrequired, or the required,
images.


 
Reply With Quote
 
 
 
 
Sherm Pendley
Guest
Posts: n/a
 
      08-18-2008
"KiwiBrian" <(E-Mail Removed)> writes:

> Assume that I have a html file that has internal links to 100 images which
> are in a daughter folder.
> This daughter folder has an extra 500 unrequired images.
> How could I make a list of the filenames of the unrequired, or the required,
> images.


Sounds like a job for Perl to me. To be fair, Ruby or Python could do
the job just as well, but I know Perl a lot better.

First, parse the HTML and walk through it, keeping a list of all the
images it references. Then, walk through a directory listing of the
child directory; for each of the images, check to see if its in the
list of images you built in the first step.

sherm--

--
My blog: http://shermspace.blogspot.com
Cocoa programming in Perl: http://camelbones.sourceforge.net
 
Reply With Quote
 
 
 
 
Nico Schuyt
Guest
Posts: n/a
 
      08-18-2008
KiwiBrian wrote:
> Assume that I have a html file that has internal links to 100 images
> which are in a daughter folder.
> This daughter folder has an extra 500 unrequired images.
> How could I make a list of the filenames of the unrequired, or the
> required, images.


I did that a couple of days ago:
1. Move all images to another directory
2. Open the page in FireFox and activate 'Display image paths' in the web
developer toolbar (plugin)
3. Open Explorer next to Firefox
4. Drag the missing images to the image directory

Alternative: run Xenu (http://home.snafu.de/tilman/xenulink.html) after step
one to get a list of the necessary images

--
Nico


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: How include a large array? Edward A. Falk C Programming 1 04-04-2013 08:07 PM
We buy & sell Networking Hardware, New/Surplus & Used networkinghardware.net Cisco 0 06-30-2007 01:33 AM
ASP.NET 2.0 events rapidly unlinked in repeater control content hs.dreamer@gmail.com ASP .Net 0 03-15-2006 02:32 PM
Win32 Recovery of 'unlinked' File DavidLopes213@hotmail.com Perl Misc 2 01-03-2006 04:02 PM
www: security in unlinked directories Henning Meyer Computer Security 3 07-13-2003 08:02 PM



Advertisments