
Goldc0der
Novice
Nov 22, 2005, 6:48 AM
Post #18 of 21
(9216 views)
|
Re: [davorg] Write text Between Two Tags
[In reply to]
|
Can't Post
|
|
Ahh.. finally something... Ok... i did one thing. I put the code: <!--#exec cgi="cgi-bin/novidades.cgi"--> ... on "captura.shtml" file. I trade <!--#include virtual="cgi-bin/novidades.pl" --> by <!--#exec cgi="cgi-bin/novidades.cgi"--> then, i rename "novidades.pl" to "novidades.cgi" I also trade the marks of "novidades.htm" from: [START] -> xiniciox (Begin mark) [END] -> xfimx (End mark) The file "novidades.cgi" as the code: #!/usr/bin/perl use CGI::Carp 'fatalsToBrowser'; $ficheiro="../novidades.htm"; open(LISTA, '<', $ficheiro) or die "Can't open $fichero: $!"; my $retorno = do {undef $/; <LISTA>}; close(LISTA); $retorno =~ s/^.*xiniciox//is; $retorno =~ s/xfimx.*$//is; print $retorno; ______________________________________________________ Now, when i run the script in the web browser there´s no erros, but dont give anu results either. It´s seems, that .cgi file dont find any text between xiniciox and xfimx word. DAMN Help plz!
|