John and Scott (and Rick),

I have a sample ExtendScript that uses the Socket object, called
"NETWORK_-_Retrieve_text_over_network.jsx". It retrieves text from a
webpage and sticks it into a document. It could be easily modified to
just look for the 200 OK message. All in all, this would be a very short
and generally simple script for an experienced developer. A great idea
for a script, really. I should add it to the group. I could use it



Message: 16
Date: Wed, 30 Apr 2014 09:46:55 -0700
From: Scott Prentice <>
To:, framers 
Subject: Re: URL Checker
Message-ID: <>
Content-Type: text/plain; charset="iso-8859-1"; Format="flowed"

You got me thinking about this. Here's some really basic ExtendScript 
code that will iterate over all markers and check the text of "message 
URL" Hypertext markers to see if they are valid files (on the local file

system). This would need to be cleaned up a bit to make it useful, but 
definitely doable ..

var doc = app.ActiveDoc;
var marker = doc.FirstMarkerInDoc;
while ( {
 if (marker.MarkerTypeId.Name == "Hypertext") {
 var markerText = marker.MarkerText;
 if (markerText.substr(0,11) == "message URL") {
 var target = markerText.substr(12);
 // tests for local files
 var file = File(target);
 if (file.exists) {
 Console("GOOD ["+target+"]");
 } else {
 Console("BAD ["+target+"]");
 marker = marker.NextMarkerInDoc;

It turns out that you can test for remote (web-based) URLs using the 
Socket object.




You are currently subscribed to framers as

Send list messages to

To unsubscribe send a blank email to
or visit

Send administrative questions to Visit for more resources and info.

Reply via email to