|
|||||||
![]() |
|
|
Thread Tools | Search this Thread |
|
#1
|
|||
|
|||
|
1) Script Title: PHP Photo Album script
2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...photoalbum.htm 3) Describe problem: I want to be able to do several things and as i am a complete newbie with php i need some sage advice... This is the site i'm testing it out on http://elvisontour.co.uk/test/newgallery.htm 1. I would like to control the background colour of the popup page. 2. I would like to remove the path and title bar if possible. Managed to change the colors of the links without too much trouble but i am struggling with this. BTW, thats not me in the Elvis outfit!! Cheers All Kev |
|
#2
|
||||
|
||||
|
Although this script uses PHP to gather the images it displays from a directory, the rest of the script is coded in javascript. There is no pop up page, that is the image itself you are viewing. Virtually all modern browsers do not permit displaying a pop up without the title bar, and if the address bar is not displayed, the path is displayed either in the title bar (most browsers) or in a proprietary information bar (Opera, perhaps others).
Modifications can be made to the javascript to pop up something other than the image itself, even something other than a pop up window.
__________________
WWWWWWWWWWWW - John________________________ Really Show Your Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate |
|
#3
|
|||
|
|||
|
Ok cheers, what about chaning the bacground colour and fixing margins?
Kev |
|
#4
|
||||
|
||||
|
The background color of what? The margins of what? An image displayed by itself in a browser pop up window has neither of these.
A popular modification to this script is to use it with lightbox 2.03: http://www.dynamicdrive.com/dynamici...box2/index.htm To do so, install the lightbox files as instructed on the demo page. Then add this to the PHP Photo Album script (additions red): Code:
if (gsortorder=="asc" || gsortorder=="desc")
galleryarray.sort(sortbydate)
function buildbox(){
for (var i = 0; i < galleryarray.length; i++){
var imagecompletepath=(targetlinkdir!="")? targetlinkdir+galleryarray[i][0] : imagepath+galleryarray[i][0];
document.write('<a style="display:none;" title="Elvis Detail" href="'+imagecompletepath+'" rel="lightbox[joe]"><\/a>')
}
}
buildbox();
var totalslots=dimension.split("x")[0]*dimension.split("x")[1]
function buildimage(i){
var imagecompletepath=(targetlinkdir!="")? targetlinkdir+galleryarray[i][0] : imagepath+galleryarray[i][0]
var tempcontainer='<a href="'+imagecompletepath+'" target="'+href_target+'" rel="lightbox[joe]" onClick="return popuplinkfunc(this)">'
tempcontainer+='<img src="'+imagepath+galleryarray[i][0]+'" title="'+galleryarray[i][0]+' ['+galleryarray[i][1]+']" />'
tempcontainer+='</a><br />'
tempcontainer+=(descriptionprefix[0]==1)? descriptionprefix[1]+(i+1) : ""
return tempcontainer
}
Code:
function popuplinkfunc(imgsrc){
if (popupsetting[0]==1){
var popwin=open(imgsrc.href, "popwin", popupsetting[1])
popwin.focus()
return false
}
else
return true
}
Code:
function popuplinkfunc(imgsrc){
myLightbox.start(imgsrc); return false;
}
__________________
WWWWWWWWWWWW - John________________________ Really Show Your Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
|
|