Declanworld 08:49 27 Apr 2007

Please click on one of the thumbnails and tell me if it's possible to get the larger image to open in the centre of the screen instead of the top left which I get. I'm using Dreamweaver 8: click here

  Declanworld 01:03 28 Apr 2007

I've postponed looking at alternatives for long enough.

  Eric10 20:25 28 Apr 2007

Please note that while working on this problem I have removed all spaces from your paths and filenames because spaces are bad practise so take this into consideration when referring to them.

The simplest way to reposition the pictures is to add a 'top' and a 'left' to the javascript that calls the picture.
e.g. onclick="MM_openBrWindow('../album_image_pages/poison/poison012.htm',','width=334,height=370,top=250,left=250')"

A more refined way to do it would be to add variables for top and left to the javascript function in the head section.
e.g. function MM_openBrWindow(theURL,winName,features) { //v2.0
var wint = 250;
var winl = 250;,winName,features+',top='+wint+',left='+winl);

Using this latter method you can change the position of all the images by changing the values of 'wint' and 'winl' in this one place while leaving the rest of the code alone.

It doesn't center the images but you should be able to get a better look than you have now. It should also be possible to set the variables with a calculated value to take account of screen size but that is best left to someone who understands javascript better than I do.

  Declanworld 20:54 28 Apr 2007

Many thanks Eric for your precious time. I'm going to get at this ASAP. Thanks also for the spaces tip.


  Eric10 21:16 28 Apr 2007

I forgot to mention that your first thumbnail actually opens the wrong picture. It shows poison26.jpg instead of poison003.jpg. The correct page is loaded (poison003.htm) but that page has the wrong title and refers to the wrong image.

  Declanworld 00:16 29 Apr 2007

Eeks! I've embarrassed myself, Eric. I'm indebted to you.


This thread is now locked and can not be replied to.

Elsewhere on IDG sites

OnePlus 5 review

Alice Saey's mesmerising animation for Dutch singer Mark Lotterman

iPad Pro 10.5in (2017) review

Comment booster votre iPhone ?