Re: how to post a question?
| From: | Ryan A | Date: | Fri, 22 Jul 2005 16:41:59 +0000 |
| Subject: | Re: how to post a question? | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-219230@lists.php.net to get a copy of this message | ||
Hey,
The problem might be with your php settings,
run phpinfo() and see if allow_url_fopen is set to ON
heres where i uploaded what i did so far, little more needs to be done
so that the mouseover images work:
http://php-php.com/a2ztips/test.php
The way I did it is in a *very very very dirty way*, I suggest you dump my
code and use a RegEx there (am too lazy to write one) instead of the
multiple
str_replace calls but my code should give you a good starting point.
<?php
$filename =
file_get_contents('http://www.dtcc.com/ThoughtLeadership/menu.htm');
$filename= str_replace("../dtcc.css","http://www.dtcc.com/dtcc.css",
$filename);
$filename= str_replace("images/","http://www.dtcc.com/images/", $filename);
$filename= str_replace("/http:","http:", $filename);
$filename= str_replace("..http:","http:", $filename);
echo $filename;
?>
Cheers,
Ryan
On 7/22/2005 6:11:27 PM, Chirantan Ghosh (cghosh@primarywave.com) wrote:
> Hi Ryan,
>
> I tried that first & also after you wrote with no avail. ( This should be
>
> very elemental)
> =========
> <?php
> $filename =
>
> file_get_contents('http://www.dtcc.com/ThoughtLeadership/menu.htm');
> echo $filename;
> ?>
> =========
>
> I am trying this html in a local machine. I preview it Internet Explorer
> (which has access to net).
> Does it matter if the HTML file is not residing in a domain?( I
> didn't think
> so but no harm asking)
>
> Thanks a bunch for taking interest,
> Chirantan
>
> ----- Original Message -----
> From: "Ryan A" <ryan@coinpass.com>
> To: <cghosh@primarywave.com>
> Cc: "php" <php-general@lists.php.net>
> Sent: Friday, July 22, 2005 12:10 PM
> Subject: Re: [PHP] how to post a question?
>
>
> > Hey,
> > Getting the code from the remote site is easy enough, you just gotto
find
> > the images now, but heres something
> > that should get you the basic code including the javascript:
> >
> > <?php
> > $filename =
> > file_get_contents('http://www.
> dtcc.com/ThoughtLeadership/menu.htm');
> > echo $filename;
> > ?>
> >
> > once you have the code, start convert