Re: Problems

Bryan Lowery (BLowery@oklahoman.com)
Wed, 20 Oct 1999 12:12:35 -0500


------_=_NextPart_000_01BF1B1E.4F44D9B0
Content-Type: text/plain

Perl Gods-
	Can you please try to assist me with an issue I'm having? Here's my
problem.....

Say we have an HTML tag....<hl>. Now <hl> in this case can stand for hot
link. There are two types of hot link tags...
	1. <hl>mailto:you@isp.com
	2. <hl>http:\\www.homepage.com
Now our server (unix) is sent HTML files all of the time. As of right now,
we are having to open these HTML pages up,...look for the <hl> tag,...then
change the href to it's correct form. What I need from Perl is a script that
will automate this entire process server side <<consing.pl>> .

IS THIS POSSIBLE?

	I have written and attached a starting script. This script should
identify the <title> tag,...read it and then print it out onto a new html
document. The script compiles with no errors...but I cant get it to work.I
must be placing it incorrectly on the server or the test html page or
something. My experience with Perl and CGI is limited....so in put on
de-bugging scripts would be helpful too.

Advise will be greatly appreciated.

Reagrds-

Bryan Lowery

------_=_NextPart_000_01BF1B1E.4F44D9B0
Content-Type: application/octet-stream;
	name="consing.pl"
Content-Disposition: attachment;
	filename="consing.pl"
Content-Location: ATT-0-5E5DA78D0187D311980300805FBB8011-C
	ONSING.PL


#Single tag only

sub parse_title{
#parse and output page title
$parser=HTML::TokeParser->new(\$webPage);
$parser->get_tag("title");
print "<p><h2>Page title</h2> ".
      $parser->get_trimmed_text."</p>";
}

------_=_NextPart_000_01BF1B1E.4F44D9B0--