PDA

View Full Version : Defualt to No Show Photo Data


jgrove
20th of March 2005 (Sun), 07:52
Hi,

I want the option of the hide/show photo data, but by defualt i dont want it shown. So when the page loads they have to select the show info to see it.

How can i do this,

Many Thanks in advance,

Pekka
20th of March 2005 (Sun), 10:45
Two changes:

In fetchsettings.php change (line 264-266)


if ($s_show_photopage_detail == "0") {
$s_show_photopage_detail_switch = "0";
}


to


//if ($s_show_photopage_detail == "0") {
//$s_show_photopage_detail_switch = "0";
//}


and in photo.php (about line 2350)


ob_start();
if ($s_show_photopage_detail == "1") {
if ($hidedetail == "0") {
include("photodetails.php");
}
}
$detail_string = ob_get_contents();
ob_end_clean();


to


ob_start();
//if ($s_show_photopage_detail == "1") {
if ($hidedetail == "0") {
include("photodetails.php");
}
//}
$detail_string = ob_get_contents();
ob_end_clean();


After those changes misc settings' settings:

Display photo detail: OFF
Display "show/hide photo detail" -switch: ON

will set the photodetail off by default and enable the switch that will reveal the details.

Display photo detail: ON
Display "show/hide photo detail" -switch: ON

will set the photodetail show by default and enable the switch that will hide the details.

Display photo detail: OFF
Display "show/hide photo detail" -switch: OFF

will set the photodetail off (no switch).

Display photo detail: ON
Display "show/hide photo detail" -switch: OFF

will set the photodetail on (no switch).

This is the way it should have been from the start :)

jgrove
21st of March 2005 (Mon), 02:32
Works a treat, Thanks Pekka, i really cannot wait for V1.5 keep up the good work.