View Full Version : Passing params from one page to another

02-23-2003, 06:12 AM
I need a little help with a problem I can't get working. Here's the situation:

I have a photo gallery of approx 2200+ pics, they are in 8 separate galleries and use 11 pages for each gallery to display them. That's 88 pages. I want to cut them down to only 11 pages. The photos in each gallery will be named the same (IE: gallery01 - pic01, pic02,.., gallery02 - pic01, pic02,...) and so on. In order for this to work I need to pass params between pages so it know which gallery to goto to display the pages. On my main gallery page I have 1 button for each gallery (8 buttons total). When I click on button I want it to pass the param of that gallery number to the next page so it will know which gallery to display. Ihave tried this: <a href="photos.htm?gallery_num=1" but the page photos.htm doesn't recognize that number. How do I get it to recognize that number.

Within photos.htm I have a call made to an external .JS file. This file is what is used to display the photos when the cursor is placed over the number for that photo. (IE: when the cursor is placed over the number 3, pic03.jpg is displayed, when the cursor is placed over pic0102.jpg then that photo is displayed, ect...)


02-23-2003, 06:55 PM
How come you don't name the destination pages photos1.htm photos.htm.....photos11.htm???

02-23-2003, 08:04 PM
the pages are named as follows:


the photos will be named the same as they are in separate directories, so the filenames wont matter.

each page displays 27 photos except for the last and it displays 30 photos. Here is what I need:

<td width="5%" align="center" bgcolor="gold" class="dhtmlbutton"
onMouseup="upeffect(this)" onMousedown="downeffect(this)"
onmouseover="upeffect(this)" onmousedown="normaleffect(this)">
<img name="pic1" SRC="../miscgraphics/blank.gif" width="10" height="10" border="0"><br>
<a href="goldbergphotos01.htm?gallery_num=1"
onMouseOver="changeIt('img2', 'http://www.fortunecity.com/millennium/rosieandjim/428/goldberg/goldberggallery01/goldberg0001.jpg')"
<img src="../buttons/goldberggallerybuttonnumber01.jpg" width="50" height="30" border="0" class="opacity1"
onMouseOver="imgover(pic1) ;playSound(8) ;this.className='opacity2';"
onMouseOut="imgout(pic1) ;stopSound(8) ;this.className='opacity1';"
alt="Goldberg Gallery number 1"></a><br>
<strong><font color="#FF0000">0001</font></strong><br>
<strong><font color="#FF0000">to</font></strong><br>
<strong><font color="#FF0000">0300</font></strong></td>

When the above button is clicked I need it to pass the param gallery_num to goldbergphotos01.htm. So the photos can be viewed.

With in goldbergphotos01.htm there is a call to an external file goldbergdispic.js, this is how the photos are displayed.

switch (gallery_num)
case 1 : gallery_dir = "../goldberggallery01/"; break;
case 2 : gallery_dir = "../goldberggallery02/"; break;
case 3 : gallery_dir = "../goldberggallery03/"; break;
case 4 : gallery_dir = "../goldberggallery04/"; break;
case 5 : gallery_dir = "../goldberggallery05/"; break;
case 6 : gallery_dir = "../goldberggallery06/"; break;
case 7 : gallery_dir = "../goldberggallery07/"; break;
case 8 : gallery_dir = "../goldberggallery08/"; break;

document.write('<img src="' + gallery_dir + 'goldberg0001.jpg" NAME="img2" border="0" width="248" height="236" onmouseover="playSound(6)" onmouseout="stopSound(6)">');

how can i do this? and wirk properly? This is the problem i need to solve?


to view the gallery so you can get an understanding what im trying to do: