Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

munckee

macrumors 65816
Original poster
Oct 27, 2005
1,219
1
I've designed one or two personal sites in dreamweaver. Nothing special, but they work.

I'm now in the process of updating (ie rebuilding from scratch) and I have a couple of questions:

1. I want to create a link such that when you click on a picture on my site, it pops up a new window AT A SPECIFIC SIZE. I can get a new window to pop up, but I can't figure out where to specify the size of that window so it doesn't expand to fill the user's screen. How do I do that?

2. How do I set it so that when I do click on the picture and pop up the new link, the original page doesn't bounce back up to the origin?

Thanks for the help. Sorry for the newb questions, but website implementation isn't my forte.
 
munckee said:
I've designed one or two personal sites in dreamweaver. Nothing special, but they work.

I'm now in the process of updating (ie rebuilding from scratch) and I have a couple of questions:

1. I want to create a link such that when you click on a picture on my site, it pops up a new window AT A SPECIFIC SIZE. I can get a new window to pop up, but I can't figure out where to specify the size of that window so it doesn't expand to fill the user's screen. How do I do that?

2. How do I set it so that when I do click on the picture and pop up the new link, the original page doesn't bounce back up to the origin?

Thanks for the help. Sorry for the newb questions, but website implementation isn't my forte.

not sure what you mean by #2, but for #1 you'll need some basic javascript. here's the code i use:

in the head:
Code:
<SCRIPT LANGUAGE="JAVASCRIPT" TYPE="TEXT/JAVASCRIPT">
function newwindow(flashwin) {
	flashwindow = window.open(flashwin, "newwin", "width=800, height=543, toolbar=0, menubar=0, location=0, scrollbars=0, resizable=0, margin=0, padding=0")
	flashwindow.focus()
}
</SCRIPT>
and obviously modify teh paramaters to suit your needs. 0=no, 1=yes


in the body:
Code:
<a href="javascript:newwindow('#')"
<image src="your image here"></a>
 
homerjward said:
not sure what you mean by #2, but for #1 you'll need some basic javascript. here's the code i use:

in the head:
Code:
<SCRIPT LANGUAGE="JAVASCRIPT" TYPE="TEXT/JAVASCRIPT">
function newwindow(flashwin) {
	flashwindow = window.open(flashwin, "newwin", "width=800, height=543, toolbar=0, menubar=0, location=0, scrollbars=0, resizable=0, margin=0, padding=0")
	flashwindow.focus()
}
</SCRIPT>
and obviously modify teh paramaters to suit your needs. 0=no, 1=yes


in the body:
Code:
<a href="javascript:newwindow('#')"
<image src="your image here"></a>

Thanks. I guess I should specify, I know basically NOTHING about html. I do my layouts with the design tools in dreamweaver; never even look at the code. Could you help me out with where I need to insert that code and how it should look?

By number two I mean that I've seen a lot of sites where you scroll down the page and when you click a link, it pops up the linked page in a new window, but the window behind it (the original) jumps back to the top of the page as well. I'd like to avoid that.
 
Ok, I took a look at the code (talk about confusing) and noted that the head section currently reads:

<head>

<title>DannyNathan.com</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="JavaScript" type="text/JavaScript">
<!--
function MM_reloadPage(init) { //reloads the window if Nav4 resized
if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}

MM_reloadPage(true);
//-->
</script>
<style type="text/css">
<!--
.style1 {
font-family: Arial, Helvetica, sans-serif;
font-size: 12px;
}
-->
</style></head>

I tried replacing your code or just adding it in with no luck. Any help?
 
I found a "behavior" that works perfectly for what I was trying to do. It can be found here:

www.dreamweaverfever.com/grow/

and it's the one called "smart link".

On a related note, I now have a couple of behaviors that I downloaded and they're on my desktop. I assume I can/should move them into a macromedia folder; can anyone tell me which one they belong in?
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.