Object ohne "Rahmen" und Scrollbalken!
hotspot
- html
Hi!
Ich versuche eine *.pl Datei als object in eine Seite einzubinden - klappt soweit ja auch ganz gut, aber:
Warum sehe ich bei Mozilla garnix? und
Wieso ist bei border=0 immer noch soetwas randähnliches zu sehen?
Geht das irgendwie weg?
Diesen Pseudoscrollbalken hätte ich eigentlich auch ganz gern nur bei Bedarf.
Axo ... es MUSS mit object passieren !!
(iframe ect. geht prima, kann ich aber nicht benutzen)
Bsp.:
http://www.indexstand.de/test3a.html
Hallo!
Warum sehe ich bei Mozilla garnix?
gute Frage, keine Ahnung, aber mit opera7 gehts.
Wieso ist bei border=0 immer noch soetwas randähnliches zu sehen?
Geht das irgendwie weg?
Das ist aber nur beim MSIE. Der geht weg, wenn Du in die eingebettete Datei body {border:0} schreibst.
Diesen Pseudoscrollbalken hätte ich eigentlich auch ganz gern nur bei Bedarf.
Hast Dus mal mit overflow:hidden probiert? Ich denke, daß auch im Archiv die Lösung steht.
tschüs, jürgen
Hallo!
Warum sehe ich bei Mozilla garnix? gute Frage, keine Ahnung, aber mit opera7 gehts.
Wieso ist bei border=0 immer noch soetwas randähnliches zu sehen? Geht das irgendwie weg? Das ist aber nur beim MSIE. Der geht weg, wenn Du in die eingebettete Datei body {border:0} schreibst.
In die *.pl Datei?
an welcher Stelle?
#!/usr/bin/perl use LWP::UserAgent; use LWP::Simple; use CGI::Carp qw(fatalsToBrowser);
#####################################################################
#####################################################################
#####################################################################
######################################################################
##############################################
##############################################
$pathtemplate = "template/template.htm";
$beforegroup[0] = ''; $startstring[0] = '<html>'; $endstring[0] = '</html>'; $maxblocks[0] = 50; $between[0] = ''; $aftergroup[0] = '';
#@filter1 = ("");
#@filter2 = ("Text", "Text");
#$urlscript = "http://localhost/cgi-bin/grabnpaste/grabnpaste.pl";
#$alternativedomain = "www.spacerforalternativedomain.de";
%replace = ( '' => '' );
$printhtml = 1;
#$cache = "cache/cache.htm";
#$cacheoutput = 1;
#$cachetimeout = 3600;
#$usesimple = 1;
$useflock = 1;
##############################################
##############################################
##############################################
@urlref = ("BACKGROUND=", "HREF=", "SRC=", "ACTION=", "CODEBASE=");
@protocol = ("HTTP://", "FTP://", "MAILTO:", "GOPHER://", "NEWS://", "WAIS://", "HTTPS://", "JAVASCRIPT:");
@filetypes = ("HTML", "HTM", "SHTM", "SHTML", "JHTML", "JSP", "PHP", "PHP3", "PHP4", "PHP5", "PHTML", "PL", "CGI", "ASP");
##############################################
if($ENV{'REQUEST_METHOD'} eq 'GET') { $query = $ENV{'QUERY_STRING'}; } elsif($ENV{'REQUEST_METHOD'} eq 'POST') { binmode STDIN; read(STDIN, $query, $ENV{'CONTENT_LENGTH'}); }
@pairs = split(/&/, $query); foreach $pair (@pairs) { ($key, $value) = split(/=/, $pair); $value =~ tr/+/ /; $value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg; $key =~ tr/+/ /; $key =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg; $form{$key} = $value; }
if(($ENV{'REQUEST_METHOD'} eq 'POST') && !$form{'gnp_form-url'}) { die "Content-type: text/html\n\nGnP: Method Post without URL. Check configuration and insert a gnp_form_url"; }
if ($form{'gnp_form-url'}) { $sourceurl = $form{'gnp_form-url'}; } else { ($sourceurl, @query) = split (/?/, $query); $query = join("",@query); }
##############################################
@domain = split (///, $sourceurl); $domain = $domain[0]."//".$domain[2]."/"; if (@domain > 4) { $folder = join("/", @domain[3..(@domain-2)])."/"; }
##############################################
if ($cachetimeout && $cacheoutput) { if (-e $cache) { $cache_modtime = (stat $cache)[9]; } if ($cache_modtime + $cachetimeout < time()) { $file = getnewfile($sourceurl,$query); } } else { $file = getnewfile($sourceurl,$query); }
if (!defined($file)) { if ($cacheoutput && $printhtml) { open(CACHE, "<$cache") || die "Content-type: text/html\n\nGnP: Read error at $cache!"; @file=<CACHE>; close(CACHE); $file = join("", @file); $cache_age = time() - $cache_modtime; print "Content-type: text/html\n\n"; print $file; print "<!-- cache-age = $cache_age seconds -->"; exit; } elsif ($printhtml) { print "Content-type: text/html\n\n"; print "GnP: Source is unreachable!\n\n"; exit; } else { exit; } }
##############################################
if ($pathtemplate) { open(TEMPLATE, "<$pathtemplate") || die "Content-type: text/html\n\nGnP: Read error at $pathtemplate!"; @template=<TEMPLATE>; close(TEMPLATE); @template = split (/<GRABBER>/, join("", @template)); }
##############################################
$filemem = $file; $file = ""; for ($j=0;$j<@startstring;$j++) { if ($endstring[$j]) { @parts = split (/$startstring[$j]/si, $filemem); # Delete attribut "i" to search case sensitive and "s" to detect newlines if ($parts[1]) {$file = $file.$beforegroup[$j]} $blockstart = 0; for ($i=1;$i<@parts;$i++) { $parts[$i] = $startstring[$j].$parts[$i]; ($parts[$i], $trash) = split (/$endstring[$j]/si, $parts[$i]); # Delete attribut "i" to search case sensitive and "s" to detect newlines $take = 1; if (@filter1) { foreach (@filter1) { if ($parts[$i] =~ /$_/si) { # Delete attribut "i" to search case sensitive and "s" to detect newlines $take = 0; } } } if ($take && $maxblocks[$j]) { if ($blockstart) {$file = $file.$between[$j]} $file = $file.$parts[$i].$endstring[$j]; $maxblocks[$j]--; $blockstart = 1; } } if ($parts[1]) {$file = $file.$aftergroup[$j]} } }
##############################################
@file = split (/\n/, $file); $file = ""; foreach $line (@file) { $take = 1; if (@filter2) { foreach (@filter2) { if ($line =~ /$_/si) {$take = 0} # Delete attribut "i" to search case sensitive and "s" to detect newlines } } if ($take) {$file = $file.$line."\n"} }
##############################################
if ($alternativedomain eq "") {$alternativedomain = "not defined"} for ($i=0;$i<@urlref;$i++) { $copy = uc($file); $position = 1; $oldpos = length($copy); while ($position != -1) { $position = rindex($copy,$urlref[$i],$oldpos); $oldpos = $position - 1; if ($position != -1) { $position = $position + length($urlref[$i]); $quotation = substr($copy,$position,1); if (($quotation eq " ") || ($quotation eq """) || ($quotation eq "'")) {$position++} $complete = 1; foreach (@protocol) { $protocol = substr($copy,$position,length($)); if ($protocol eq $) {$complete = 0} } if (substr($copy,$position,1) eq "#") {$complete = 0} if ($complete && (substr($copy,$position,1) ne "/")) {substr($file,$position,0,$domain.$folder)} elsif (substr($copy,$position,1) eq "/") {substr($file,$position,1,$domain)} $file =~ s|/[^/]*?/../|/|; # if (($urlscript) && (($urlref[$i] eq "HREF=") || ($urlref[$i] eq "ACTION="))) { $protocol = substr($file,$position,7); $domainindex = index($file,"/",$position+7); $filetypeindex = index($file,".",$domainindex)+1; $urlend = index($file," ",$domainindex); if ($urlend > $filetypeindex) { $complete = 0; foreach (@filetypes) { $filetype = uc(substr($file,$filetypeindex,length($))); if ($filetype eq $) {$complete = 1;} } if ((uc($protocol) eq "HTTP://") && ((uc(substr($file,$position,$domainindex-$position)) =~ uc($domain[2])) || (uc(substr($file,$position,$domainindex-$position)) =~ uc($alternativedomain))) && $complete) { substr($file,$position,0,$urlscript."?") } } } } } }
##############################################
foreach (keys(%replace)) { $file =~ s/($)/$replace{$}/sig; # Delete attribut "i" to search case sensitive and "s" to detect newlines }
##############################################
$file = $template[0]."<!-- Grab'n'Paste (www.skriptoase.de) -->\n".$file."\n<!-- Grab'n'Paste -- End -->\n".$template[1];
if ($cache) { open(CACHE, ">$cache") || die "Content-type: text/html\n\nGnP: Write error at $cache!"; flock(CACHE, 1) unless (!$useflock); print CACHE $file; flock(CACHE, 8) unless (!$useflock); close(CACHE); $cachestatus = "<!-- GnP: Caching was o.k.! -->"; }
##############################################
print "Content-type: text/html\n\n"; if ($printhtml) { print $file; } print $cachestatus;
exit;
##############################################
sub getnewfile { my $sourceurl = shift; my $query = shift;
if ($usesimple) { if ($query) {$sourceurl = $sourceurl."?".$query} return get($sourceurl); } else { my $ua = new LWP::UserAgent; $ua->agent("AgentName/0.1 " . $ua->agent); my $req = new HTTP::Request POST => $sourceurl; $req->content_type('application/x-www-form-urlencoded'); $req->content($query); my $res = $ua->request($req); if ($res->is_success) { return $res->content; } else { return; } } }
Diesen Pseudoscrollbalken hätte ich eigentlich auch ganz gern nur bei Bedarf. Hast Dus mal mit overflow:hidden probiert? Ich denke, daß auch im Archiv die Lösung steht.
Als css des objects? werde ich mal machen.
tschüs, jürgen
Besten Dank!
Hallöle,
Das ist aber nur beim MSIE. Der geht weg, wenn Du in die eingebettete Datei body {border:0} schreibst.
In die *.pl Datei?
an welcher Stelle?
[...]
$pathtemplate = "template/template.htm";
Wahrscheinlich und vermutlich in deine Vorlage namens template.htm.
Viele Grüße
Torsten
Hallöle,
Das ist aber nur beim MSIE. Der geht weg, wenn Du in die eingebettete Datei body {border:0} schreibst.
In die *.pl Datei?
an welcher Stelle?
[...]
$pathtemplate = "template/template.htm";Wahrscheinlich und vermutlich in deine Vorlage namens template.htm.
Viele Grüße
Torsten
Als css?
hi,
Das ist aber nur beim MSIE. Der geht weg, wenn Du in die eingebettete Datei body {border:0} schreibst.
Wahrscheinlich und vermutlich in deine Vorlage namens template.htm.
Als css?
wonach sieht body {border:0} denn aus?
(tipp: nein, html ist es nicht.)
gruss,
wahsaga