[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] paths



At 5:05 PM -0500 6/28/99, ken towry wrote:
>Hi All,
>
>----------perl-------
>
>I've parsed my html doc. (which a form resides in) with a couple of sub
>routines, returned the form data back to the doc. between special tags.
>
>I'm left with the doc. now in the cgi-bin not properly referencing it's
>original graphics in javascript and html.
>
>require "parsehtm.pl";
>require "handler.pl";
>
>$htmdir =
>"/custs/home/a/abc1111/public_html/guaranty/pages/mtg_comparejs/images";
>$output = &parseHtml("$htmdir/dirsub_p.htm");
>
>print "Content-type: text/html\n\n";
>print "<BASE
>
>#I can resolve the html with a print statement like this, but it looks
>way wrong#
>HREF=\"http://www.website.net/guaranty/pages/mtg_comparejs/images/\">";

You could use a different quoting mechanism for this, so you wouldn't have
to escape your "'s.  :-)

Look in your standard documentation for HERE docs.  A lot of people use
here docs to print HTML.  It makes things somewhat easier to write and to
read.

>print $output;
>
>1;
>
>----------javascript------------

If the problem starts anywhere after this line, you should ask for help in
a javascript forum.  This is a perl forum.

>
>
>Has anybody got ideas on how I can do this correctly?

It seems, at a very quick glance, like your parsehtm.pl script may be
munging your paths.  You might try running that script on a simple test to
see if it causes the changes you are seeing.

Also, I'm not sure that you shouldn't be posting these questions about perl
on unix to the MacPerl - Any Perl list?  Am I not remembering things right?

-Jeff Lowrey



===== Want to unsubscribe from this list?
===== Send mail with body "unsubscribe" to macperl-request@macperl.org