Homepage selbermachen 7.851 Themen, 35.616 Beiträge

Frameset automatisch mitladen

Cully / 5 Antworten / Flachansicht Nickles

Hallo...


ich möchte gerne, daß wenn eine Seite aus meinem Frameset über eine Suchmaschiene aufgerufen wird, das gesamte Frameset (also die gefundene Seite im MainFrame und das dazugehörige Menü außenrum) geladen und angezeigt wird.


Kann mir jemand sagen wie das funktioniert?


Danke

bei Antwort benachrichtigen
HADU Cully „Frameset automatisch mitladen“
Optionen

Hi,
hier ein Beispiel für ein Javascript, dass so etwas macht

<script language="JavaScript">
<!---
function is_msie() {
return (navigator.appName == "Microsoft Internet Explorer");}
function Framing(){
if (this.document == top.document ||
top.location.host != this.location.host) {
var pathprefix = location.protocol + '//'
+ location.host
+ location.pathname.substring(0,
location.pathname.lastIndexOf('/')+1);
var doctitle = document.title;
document.clear();
document.open("text/html");
document.writeln('<html>\n<head><title>' +doctitle+
'</title></head>');
document.writeln('<frameset cols="150,*" framespacing="0" border="false" frameborder="0" noresize>'+
'<frame src="'+pathprefix+'inhalt2.htm" name=inhalt scrolling="no" noresize>'+
'<frame src="'+top.location.href+'" name=Hauptframe >'+
'</frameset></html>');
document.close();
return true;
}
return false;
}
function msieFraming() {
if (is_msie()) {
if (Framing()) {
window.setTimeout('top.frames["Hauptframe"].location.href = '+
'"'+top.location.href+'";',10);
}}}
function netscFraming() {
if (!is_msie()) Framing();
}
msieFraming();
// --->
</script>



Du musst es natürlich an Deine Befürfnisse anpassen

bei Antwort benachrichtigen