For Programmers: Free Programming Magazines  


Home > Archive > PHP Language > May 2004 > web functions?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author web functions?
aaron

2004-05-20, 3:30 pm


Hi,

I'd like to post some news content on my web page from another website. Are
there built in php functions that will allow me to do this?

Thanks,
Aaron


Janwillem Borleffs

2004-05-20, 4:31 pm

aaron wrote:
> I'd like to post some news content on my web page from another
> website. Are there built in php functions that will allow me to do
> this?
>


Yes there are, but do you have permission from the other website to publish
the content?


JW



Janwillem Borleffs

2004-05-20, 5:30 pm

aaron wrote:
> I'd like to post some news content on my web page from another
> website. Are there built in php functions that will allow me to do
> this?
>


You are cross-posting (sending the post seperately to multiple
newsgroups). Don't do that. Reply in alt.comp.lang.php.

JW



Michael Vilain

2004-05-20, 5:30 pm

In article <c8itlp$16cg$1@nntp1.u.washington.edu>,
"aaron" <atdawgie@yahoo.com> wrote:

> I'd like to post some news content on my web page from another website. Are
> there built in php functions that will allow me to do this?


Do you mean can php open up a network socket to another site's port 80
and read that page to a file? I've not tried this. Perl has a lot more
library modules you can install to do this, even HTML parsing code. I
do this for my e-commerce electronic billing. Check out Perl and
various CPAN modules.

--
DeeDee, don't press that button! DeeDee! NO! Dee...



aaron

2004-05-21, 4:31 pm

It's copyrighted material, no problem, what are the functions?


"Janwillem Borleffs" <jw@jwscripts.com> wrote in message
news:40ad0d7b$0$67519$ee9da40f@news.wanadoo.nl...
> aaron wrote:
>
> Yes there are, but do you have permission from the other website to

publish
> the content?
>
>
> JW
>
>
>



Janwillem Borleffs

2004-05-21, 4:31 pm

aaron wrote:
> It's copyrighted material, no problem, what are the functions?
>


fopen
fsockopen with fputs/fgets
file/file_get_contents

to mention a couple...

Most basic example:

// Get the Google home page and print it
print file_get_contents("http://www.google.nl/");

See www.php.net for details.


JW



Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com