Author Topic: Pop-Up an Bildgrösse anpassen  (Read 10845 times)

0 Members and 1 Guest are viewing this topic.

Offline thomas10

  • Newbie
  • *
  • Posts: 19
    • View Profile
Pop-Up an Bildgrösse anpassen
« on: March 06, 2006, 02:18:18 PM »
Kann sich jemand meine Seite ansehen und mir dabei helfen?

http://www.galerie-jumpy.de

Danke erstmal und Grüsse,

Thomas

Offline thomas10

  • Newbie
  • *
  • Posts: 19
    • View Profile
Re: Pop-Up an Bildgrösse anpassen
« Reply #1 on: March 06, 2006, 04:37:28 PM »
Bitte helft mir!!!!!!!!!!!!!!

Meine Details sieht jetzt so aus, allerdings stimmt die Grösse immer noch nicht:

Code: [Select]
<BODY style="MARGIN: 0px" bottomMargin=0 leftMargin=0 topMargin=0 rightMargin=0 marginheight="0" marginwidth="0">
{header}
<p>&nbsp;</p>
<

                                <table style="line-height:100%; background-color:white; margin-top:0; margin-bottom:0;" cellpadding="3" cellspacing="0" align="center">
                                    <tr>
                                        <td>
                                            <p>{image}</p>
                                        </td>
                                    </tr>
                                </table>
<script language="JavaScript">
var id=0;
function control()
{
if (document.images[0].complete)
{
var x=document.images[0].width;
var y=document.images[0].height;
window.resizeTo(x,y);
window.clearInterval(id);
}

}
id=window.setInterval("control()",100);

</script>

Offline mawenzi

  • 4images Moderator
  • 4images Guru
  • *****
  • Posts: 4.500
    • View Profile
Re: Pop-Up an Bildgrösse anpassen
« Reply #2 on: March 06, 2006, 06:09:10 PM »
hallo thomas10,

die Werte 'width' und 'height' werden vom Bild in deinem Fenster ja schon richtig übernommen. Doch ist dein details.html-Template, was im  Fenster geladen wird, ja größer als das Bild. Es gibt also 2 Möglichkeiten ...

1. Du passt deine details.html genau deinem Fenster an, d.h. also ohne jeglichen Rand. Z.B. muss das auch raus ...
Code: [Select]
<p>&nbsp;</p>
<

2. Oder du machst dein Fenster per J-Script größer ... sagen wir mal Breite + 50 px und Höhe + 50 px. Z.B. so ...
Code: [Select]
var x=document.images[0].width + 50;
var y=document.images[0].height + 50;
Das Script würde ich auch gleich an den Anfang der details.html setzen, auf alle Fälle aber vor {image} ...

mawenzi
Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

Offline thomas10

  • Newbie
  • *
  • Posts: 19
    • View Profile
Re: Pop-Up an Bildgrösse anpassen
« Reply #3 on: March 06, 2006, 07:28:27 PM »
Hi!

Vielen Dank! Endlich hilft mir jemand  :D

Ich möchte die erste Version haben.
Wie passe ich das Fenster denn genau meinem Bild an?
Wie entferne ich die Scrollbalken?
Wie richte ich es auf dem Bildschirm mittig aus?

Sorry, aber ich kenne mich nur etwas mit Html aus.

Gruss, Thomas

Offline thomas10

  • Newbie
  • *
  • Posts: 19
    • View Profile
Re: Pop-Up an Bildgrösse anpassen
« Reply #4 on: March 06, 2006, 09:40:24 PM »
Ok Scrollbalken sind weg und die Breite passt auch.
Allerdings bekomme ich die Höhe nicht hin.

Quote
<BODY style="MARGIN: 0px" bottomMargin=0 leftMargin=0 topMargin=0 rightMargin=0 marginheight="0" marginwidth="0" scroll="no">
{header}

<

                                <table style="line-height:100%; background-color:white; margin-top:0; margin-bottom:0;" cellpadding="3" cellspacing="0" align="center">
                                    <tr>
                                        <td>
                                            <p>{image}</p>
                                        </td>
                                    </tr>
                                </table>
<script language="JavaScript">
var id=0;
function control()
{
   if (document.images[0].complete)
   {
      var x=document.images[0].width +50;
      var y=document.images[0].height +50;
      window.resizeTo(x,y);
      window.clearInterval(id);
   }

}
id=window.setInterval("control()",100);

</script>


Woran lilegt das?

Bei height kann ich eingeben was ich will.

Gruss, Thomas

Offline mawenzi

  • 4images Moderator
  • 4images Guru
  • *****
  • Posts: 4.500
    • View Profile
Re: Pop-Up an Bildgrösse anpassen
« Reply #5 on: March 06, 2006, 09:51:07 PM »
für die Höhenanpassung würde ich noch folgendes ändern ...
1.
Code: [Select]
topMargin="10"

2.
Code: [Select]
var y=document.images[0].height +60;

mawenzi
Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

Offline thomas10

  • Newbie
  • *
  • Posts: 19
    • View Profile
Re: Pop-Up an Bildgrösse anpassen
« Reply #6 on: March 06, 2006, 10:01:13 PM »
Hi!

topMargin... im Body-Tag ändern?

Ich habe es versucht, leider ohne Ergebniss.
Meine Fensterhöhe ist irgenwie begrenzt.

Kann dies vielleicht an einer PHP-Datei liegen?

Gruss, Thomas

Offline mawenzi

  • 4images Moderator
  • 4images Guru
  • *****
  • Posts: 4.500
    • View Profile
Re: Pop-Up an Bildgrösse anpassen
« Reply #7 on: March 06, 2006, 11:45:23 PM »
hallo thomas10,

das sieht doch jetzt bestens aus ! ... gleichmäßiger Rand, ... bei jedem Bild, ... egal welches Format !
Sind da jetzt noch Fragen offen ... ?

mawenzi
Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

Offline thomas10

  • Newbie
  • *
  • Posts: 19
    • View Profile
Re: Pop-Up an Bildgrösse anpassen
« Reply #8 on: March 07, 2006, 06:54:28 AM »
Ja!  :(

Klick doch auf der Startseite mal auf die Ente links oben.
Das Bild ist eigentlich höher wie das Popup!

Irgendetwas begrenzt meine Fensterhöhe.

Gruss, Thomas

Offline mawenzi

  • 4images Moderator
  • 4images Guru
  • *****
  • Posts: 4.500
    • View Profile
Re: Pop-Up an Bildgrösse anpassen
« Reply #9 on: March 07, 2006, 09:42:54 AM »
Also ich kann mich nur wiederholen ! Bei mir läuft es bestens. Auch "Ente gut ... die Zweite" wird exakt in dem Hochformat incl. gleichmäßig umlaufenden Rand angezeigt. Das muss an deinem Browser liegen ... leere mal deine Cache bzw. aktualisiere (mit dem Button) mal deine Seite.

mawenzi
Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...

Offline thomas10

  • Newbie
  • *
  • Posts: 19
    • View Profile
Re: Pop-Up an Bildgrösse anpassen
« Reply #10 on: March 07, 2006, 03:18:31 PM »
Ok, ich will hier ja niemanden nerven  8O

Mein Popup passt sich soweit der Bildgrösse an.
Nun hätte ich es gerne noch mittig auf dem Desktop.

Ich habe diesen Code gefunden, weiss allerdings nicht wie bzw. wo ich ihn einbinden muss:

Quote
Popup in der Mitte des Desktop

Interessiert vielleicht auch einige von Euch ;)
Bei diesem Script wird bei einem Klick auf einem Link, ein Popup auf der Bildschirmmitte angezeigt.

Beispiel (http://www.webmasterbiz.de/scripte/popup_center/center.html)

<html>
<head>
<title>popup-center</title>
<script type=text/javascript>
var win= null;
function NewWindow(mypage,myname,w,h,scroll){
var winl = (screen.width-w)/2;
var wint = (screen.height-h)/2;
var settings ='height='+h+',';
settings +='width='+w+',';
settings +='top='+wint+',';
settings +='left='+winl+',';
settings +='scrollbars='+scroll+',';
settings +='resizable=yes';
win=window.open(mypage,myname,settings);
if(parseInt(navigator.appVersion) >= 4){win.window.focus();}
}
</script>
</head>
<body text="#993300" bgcolor="#AFAFAF"link="#FF0000" alink="#FF0000" vlink="#FF0000">
<a href="http://webmasterbiz.de/vbindex.php" onclick="NewWindow(this.href,'name','600','500','yes');retu rn false">
Klicke hier um ein Popup in der Mitte des Desktops zu öffnen!
</a>

</body>
</html>

stormi

Offline thomas10

  • Newbie
  • *
  • Posts: 19
    • View Profile
Re: Pop-Up an Bildgrösse anpassen
« Reply #11 on: March 08, 2006, 10:46:41 AM »
Mir fehlt irgendwo die Verbindung von Objekt und Fenster....
Kann mir denn das niemand etwas näherbringen?

BIIIIIIIIIIIIIIIIIIIIIIIIIIIIIIITE :roll: