Re: coger html de otra web - Choring Script 2.0

From: Date: Wed, 04 Jun 2003 12:38:26 +0000
Subject: Re: coger html de otra web - Choring Script 2.0
References: 1 2 3  Groups: php.general.es 
Request: Send a blank email to general-es+get-36996@lists.php.net to get a copy of this message
Hola esta es mi linda y simple creacion que te permite sacar codigo desde otra web, y mostrarlo como si fuera tuyo, va con ejemplo y todo. Pd Seguro a alguien le sirve :D <?php $container=implode("",file("http://www.meteofa.mil.ar/pronos/pronos.htm")); $container=str_replace("><",">\n<",$container); $lineas=explode("\n",$container); function scanPage($theFile,$startTag,$endTag){ $tmp=array(); for ($linea=0; $linea<count($theFile); $linea++){ if(strtolower(substr(trim($theFile[$linea]),0,strlen($startTag)))==strtolowe r($startTag)) { for ($l2=$linea+1;$l2<count($theFile);$l2++){ if (strtolower(substr(trim($theFile[$l2]),0,strlen($endTag)))==strtolower($endT ag)) { return $tmp; } else $tmp[]=$theFile[$l2]; } } } } function scanTag($theFile,$startTag){ for ($linea=0; $linea<count($theFile); $linea++){ if (strtolower(substr($theFile[$linea],0,strlen($startTag)))==strtolower($start Tag)) { return $theFile[$linea]; } } } $laPage=scanPage($lineas,"<!-------------------- Fin Hora -------------------------------->","<HR width=600>"); $laPage=implode("\n",$laPage); echo $laPage; ?> ---------------------------------------------- Alberto Ferrer albertof@barrahome.org http://www.barrahome.org ---------------------------------------------- Syntax Error in KITCHEN.H: COFFEE not found. ----- Original Message ----- From: "Marcelo O.Olcese" <molcese@ancal.com.ar> To: <lista@phpes.com> Sent: Wednesday, June 04, 2003 8:58 AM Subject: Re: [PHP-ES] coger html de otra web > Aca en Argentina, tratamos de no coger a las paginas HTML..... > Pero bueno, sobre gustos.... > > jajajja > MArcelo (Arg) > > ----- Original Message ----- > From: "Manuel Rodriguez Morales" <manu@sevillaconsulting.com> > To: <lista@phpes.com> > Sent: Wednesday, June 04, 2003 8:53 AM > Subject: Re: [PHP-ES] coger html de otra web > > > > Si, tengo permiso. > > Gracias > > ----- Original Message ----- > > From: "Serguei Vicario Manjón" <svicario@comunet.es> > > To: <lista@phpes.com> > > Sent: Wednesday, June 04, 2003 1:44 PM > > Subject: Re: [PHP-ES] coger html de otra web > > > > > > > Hola, > > > > > > revisa las funciones Fopen y File. > > > > > > Un saludo > > > Serguei > > > > > > PD: Supongo que tienes permiso del propietario de la web para tomar la > > > informacion. > > > > > > > > > > > > At 4/6/03 13.36, you wrote: > > > >a ver, necesito meter en la web de mi empresa unas cositas que hay en > la > > > >web de uno de las webs asociadas a nosotros con algunas modificaciones. > > > >como seria para recuperar el html de una url ??? > > > > > > > > > --------------------------------------------------------------------- > > > Archivo On-line: http://www.phpes.com/ > > > via news: news://news.phpes.com/ > > > Manual PHP en español: http://www.php.net/manual/es/ > > > Para dar de baja la suscripción, mande un mensaje a: > > > lista-unsubscribe@phpes.com > > > > > > > > > > > > > > > > > --------------------------------------------------------------------- > > Archivo On-line: http://www.phpes.com/ > > via news: news://news.phpes.com/ > > Manual PHP en español: http://www.php.net/manual/es/ > > Para dar de baja la suscripción, mande un mensaje a: > > lista-unsubscribe@phpes.com > > > > --------------------------------------------------------------------- > Archivo On-line: http://www.phpes.com/ > via news: news://news.phpes.com/ > Manual PHP en español: http://www.php.net/manual/es/ > Para dar de baja la suscripción, mande un mensaje a: > lista-unsubscribe@phpes.com > > > >

« previous php.general.es (#36996) next »