ERROR

You installed the standalone Coppermine into your Nuke portal.
". "Please download and install a CPG Port: CPG for PostNuke OR CPG for PHPnuke
gay adoption well being

gay adoption well being

set mature brabusters

mature brabusters

play kiss the sky yacht

kiss the sky yacht

oxygen gay gangsta porn

gay gangsta porn

more trade mpg adult

trade mpg adult

twenty matthew mcconaughey nude

matthew mcconaughey nude

read ftee lesbian sex videos

ftee lesbian sex videos

ear hana azoulay nude

hana azoulay nude

support farrah the fuck puppet

farrah the fuck puppet

hit illinos sex offender

illinos sex offender

two nude india pussy

nude india pussy

famous plastic hershey s kiss

plastic hershey s kiss

though naked girls bib boobs

naked girls bib boobs

band hot chicks belly

hot chicks belly

during christian counseling nyc

christian counseling nyc

drive bang bang kill kill

bang bang kill kill

one bondage accessories

bondage accessories

search damien olivers other passions

damien olivers other passions

blood nude pics of antonella

nude pics of antonella

wrote fucked up stars

fucked up stars

art naked gie

naked gie

space erotic female humiliation pics

erotic female humiliation pics

thank adult spanking pictures stories

adult spanking pictures stories

song nude women athlete pics

nude women athlete pics

free nasty videoes

nasty videoes

time marlin monroe sex scene

marlin monroe sex scene

condition spanking game free flash

spanking game free flash

stood xxx amateur inturnal cumshots

xxx amateur inturnal cumshots

seed james buchanan sex

james buchanan sex

fall lohan nude flash

lohan nude flash

special breast cancer primary source

breast cancer primary source

people hot naked muscular men

hot naked muscular men

sat relationship with christ

relationship with christ

double breast conserving surgery

breast conserving surgery

road slutty porn

slutty porn

example asian cowgirl sex positions

asian cowgirl sex positions

above teen milf video

teen milf video

been jamaican fuck clips

jamaican fuck clips

smell tips on erotic positions

tips on erotic positions

small double fuck teen

double fuck teen

separate sex fantasia

sex fantasia

receive jades nude celebities

jades nude celebities

air femdom torture

femdom torture

enough diagram of womans vagina

diagram of womans vagina

plant marcia brady lesbian

marcia brady lesbian

car cherry middle eastern escort

cherry middle eastern escort

moon quality tits

quality tits

provide nude photos vanesa hudgnes

nude photos vanesa hudgnes

continent evista research breast cancer

evista research breast cancer

sing bellydance topless

bellydance topless

iron the most xxx site

the most xxx site

coast megan qt naked gallerys

megan qt naked gallerys

kill gay journalists

gay journalists

duck czech index amateurs

czech index amateurs

fear mrs steele porn

mrs steele porn

bar nude sunbathing north carolina

nude sunbathing north carolina

capital horny gay boy fuck

horny gay boy fuck

bird porn with guys

porn with guys

sugar fart fetish

fart fetish

dress amateur black girl

amateur black girl

center chicks innocently naked

chicks innocently naked

division sperm receptacles 2

sperm receptacles 2

are sexy videos women licking

sexy videos women licking

mark lipstick fetish gallery

lipstick fetish gallery

safe asia schoolgirls sex

asia schoolgirls sex

fell non nude young model

non nude young model

night gay belgium boys

gay belgium boys

final gurnee teen center

gurnee teen center

distant nude marti gas

nude marti gas

hill gillian chung nude video

gillian chung nude video

about passion and prudence

passion and prudence

surface hardcore vibrating dildos

hardcore vibrating dildos

son anal sac carcinomas

anal sac carcinomas

bed mature nude female

mature nude female

way sub shop bondage

sub shop bondage

share tiffany walker mpg

tiffany walker mpg

ask incredibles nude pictures

incredibles nude pictures

sentence absolute ebony

absolute ebony

ice gay in portland oregon

gay in portland oregon

kill porn dames

porn dames

brown young celebrities vibrator

young celebrities vibrator

inch jenn air knobs

jenn air knobs

set shannon florida escort 610

shannon florida escort 610

true . mother daughter team sex

mother daughter team sex

crop miss outstanding teen pageants

miss outstanding teen pageants

very upskirt de famosas gratis

upskirt de famosas gratis

finger dick butkus highlight film

dick butkus highlight film

meet avant making good love

avant making good love

death young blowjob video

young blowjob video

practice babes showing boobs

babes showing boobs

ride eminem topless

eminem topless

point tiffany pollard pattersons tits

tiffany pollard pattersons tits

brother chode licking

chode licking

do voyeur photo pictures free

voyeur photo pictures free

shine passwords adult xxx free

passwords adult xxx free

to sleeping beauty porn

sleeping beauty porn

white real sex with whore

real sex with whore

problem xotic xtreme babes nude

xotic xtreme babes nude

sign her first anal van

her first anal van

prepare sailor moon diana hentia

sailor moon diana hentia

cloud chris pontius poses nude

chris pontius poses nude

object lyrics groovy kinda love

lyrics groovy kinda love

self lovely vietnamese nudes

lovely vietnamese nudes

all carreer counseling

carreer counseling

symbol xxx asian streetmeat ladyboys

xxx asian streetmeat ladyboys

mass big cock sucking whore

big cock sucking whore

from single catholic personals

single catholic personals

mountain reagons daughter nude

reagons daughter nude

north breast mass in baby

breast mass in baby

favor gay sex apparell

gay sex apparell

sign pussy and tity

pussy and tity

dress redheads preveiw

redheads preveiw

fire dree sex games

dree sex games

sense little boys nudes

little boys nudes

deal dick chaney s responsibilities

dick chaney s responsibilities

teach metacafe topless dancer

metacafe topless dancer

season gay sex pictures redhat

gay sex pictures redhat

swim nipple exercises

nipple exercises

mount adult twins sex stories

adult twins sex stories

she teen sex fourms

teen sex fourms

summer teen masturbation dvd

teen masturbation dvd

two petite russians sex

petite russians sex

again runescape aquatic nasties

runescape aquatic nasties

now nudist chicks

nudist chicks

south hanging pussy lips

hanging pussy lips

matter miconazole vaginal suppositories

miconazole vaginal suppositories

story nadias pink porn

nadias pink porn

determine jeanne triplehorn naked

jeanne triplehorn naked

rest antionella naked pictures

antionella naked pictures

thank nelson mandela three wives

nelson mandela three wives

produce j edger hoover transvestite

j edger hoover transvestite

state teens reasons to vote

teens reasons to vote

corner mr hot chicks

mr hot chicks

beat male orgasm movies

male orgasm movies

tie gay dom

gay dom

basic tgp hot

tgp hot

when nasty porn free video

nasty porn free video

told rocky roads and xxx

rocky roads and xxx

vowel alternative hairstyles for teens

alternative hairstyles for teens

usual famous celebs nude pics

famous celebs nude pics

their daytona beach fl escorts

daytona beach fl escorts

sail metacafe make love fuck

metacafe make love fuck

single nudism vids

nudism vids

son porn free torents

porn free torents

ask tyler singles

tyler singles

thus private nude pages

private nude pages

visit mandy bright sucks

mandy bright sucks

make spanking humiliate stories wife

spanking humiliate stories wife

substance tiny clips xxx

tiny clips xxx

red sperm chocolate velvet rose

sperm chocolate velvet rose

after boarding schoolgirl

boarding schoolgirl

sheet sissy juice

sissy juice

atom blonde chick pussy

blonde chick pussy

middle love poems for valentines

love poems for valentines

press erotic literature for seniors

erotic literature for seniors

weather share porn peer

share porn peer

move edmonton gay pride

edmonton gay pride

look teen baisis

teen baisis

through tall girls fetish

tall girls fetish

idea india online sex video

india online sex video

beauty keria knightely nude

keria knightely nude

after mature singles in tulsa

mature singles in tulsa

length hillary sucks clinton

hillary sucks clinton

quiet all gay wallpaper

all gay wallpaper

guide hentai video game

hentai video game

forward prince kiss music video

prince kiss music video

finish search nylons retro

search nylons retro

sheet neopets hentai fire faerie

neopets hentai fire faerie

summer gay bar traps

gay bar traps

ice hardcore miltary sex videos

hardcore miltary sex videos

beat large girth cocks

large girth cocks

decimal peinus masturbation pleasure

peinus masturbation pleasure

anger bart simpson nudity

bart simpson nudity

black shooting orgasm movies

shooting orgasm movies

separate butt sex thumbs

butt sex thumbs

yard anal fisting girls

anal fisting girls

country fine xxx women pics

fine xxx women pics

lone geek beauty reunion marry

geek beauty reunion marry

seed mature sucking thumbnails

mature sucking thumbnails

drink mistress betty boo

mistress betty boo

loud jacobs ladder webcam

jacobs ladder webcam

well fanfiction forever knight spanking

fanfiction forever knight spanking

organ vaginal polyps symptoms

vaginal polyps symptoms

finish lesbians eating each other

lesbians eating each other

numeral xxx pokemon stories

xxx pokemon stories

fish celeberaties sex tapes

celeberaties sex tapes

sound website mississippi escort

website mississippi escort

describe connecticut striped bass

connecticut striped bass

area nude celebreties list

nude celebreties list

near lesbian p

lesbian p

any bian love stories

bian love stories

finish exgirlfriend nudes

exgirlfriend nudes

crease webcam strippers

webcam strippers

process amatur daily chix

amatur daily chix

day oldest naked woman gag

oldest naked woman gag

tool scab film gay vampires

scab film gay vampires

could gay personal ads ireland

gay personal ads ireland

boat sex at wedings

sex at wedings

also horse cum shot cocks

horse cum shot cocks

dictionary movie big breast thumbs

movie big breast thumbs

decide inability to express love

inability to express love

place sex work caught pasadena

sex work caught pasadena

feet university of boston sucks

university of boston sucks

band cute redhead throat fuck

cute redhead throat fuck

top mistress free galleries

mistress free galleries

straight gay intergenerational

gay intergenerational

support mulatto horny

mulatto horny

are zolo love quizzes

zolo love quizzes

die partner sex toys

partner sex toys

fat play daddy gay men

play daddy gay men

soft lactating lesbian video

lactating lesbian video

finish terra patrick nude

terra patrick nude

find crazy college sex parties

crazy college sex parties

both sydnee steele nude

sydnee steele nude

shoulder naughty escorts

naughty escorts

print cum on pussy pictores

cum on pussy pictores

system tantric music maverick

tantric music maverick

young shemale yum 10th annaversay

shemale yum 10th annaversay

touch voyeur girls jersey change

voyeur girls jersey change

bright bare pussy flat chested

bare pussy flat chested

capital butt fuck free trailer

butt fuck free trailer

dead sleeping teenager sex

sleeping teenager sex

bit cheap lesbian dvds

cheap lesbian dvds

it flexible naked girls videos

flexible naked girls videos

block roberts strip light

roberts strip light

planet bobbie russian teen model

bobbie russian teen model

pay stealth upskirt

stealth upskirt

appear hot fucking blonde

hot fucking blonde

sat amature porn sites

amature porn sites

if shinobu bondage fanfic

shinobu bondage fanfic

tell sex tape amateur

sex tape amateur

teeth anal tech

anal tech

start love korean letters

love korean letters

total canda amature videos

canda amature videos

cry vivian hsu free nude

vivian hsu free nude

block just plain sex

just plain sex

caught bakunyu hentai

bakunyu hentai

store ebony croydon

ebony croydon

ice hentai bam

hentai bam

force breast implant scars

breast implant scars

trip dick ground

dick ground

thing teen on panty

teen on panty

valley marilyn nash nude

marilyn nash nude

her love myspace grpahics

love myspace grpahics

ever pay per minute gay

pay per minute gay

parent playmate shannon stewart nude

playmate shannon stewart nude

place secret teen amateur

secret teen amateur

continue young child pix nude

young child pix nude

left interracial dating afro

interracial dating afro

grew the condom spot

the condom spot

search real naked army women

real naked army women

engine gay parenting argument

gay parenting argument

metal nude women butt

nude women butt

war university girl sex

university girl sex

log men in cock cages

men in cock cages

thin ebony masterbation clips

ebony masterbation clips

general alein sex game

alein sex game

rest dick drain

dick drain

job amatures goe wild

amatures goe wild

leg son sister fuck

son sister fuck

arrive michelle bass nude

michelle bass nude

when lesbian birthday

lesbian birthday

hunt pull chain light knobs

pull chain light knobs

hair full fashion nylon tgp

full fashion nylon tgp

equate escort in sofia bulgaria

escort in sofia bulgaria

sand blue beauty space

blue beauty space

tree gay gossip porn

gay gossip porn

some pussy piercing procedures

pussy piercing procedures

half sensual shoes

sensual shoes

friend britney pictures underwear

britney pictures underwear

industry anita cannibal blonde

anita cannibal blonde

many ats condom products

ats condom products

since amy fisher hardcore video

amy fisher hardcore video

value erotic picturs of bjork

erotic picturs of bjork

home tween harajuku costume

tween harajuku costume

crop pakistan india relationship

pakistan india relationship

language husbands foot fetish

husbands foot fetish

rule mature group videos

mature group videos

track squrting breasts

squrting breasts

wife thigh high xxx

thigh high xxx

for porn moves deep throat

porn moves deep throat

major latifa nude

latifa nude

sail redhead pussy eating

redhead pussy eating

big abnormally large cock

abnormally large cock

ride live9 bach nude

live9 bach nude

usual girls forst to fuck

girls forst to fuck

log gay saunas florida

gay saunas florida

ocean shemales hdv

shemales hdv

am java swing grid

java swing grid

law womens masturbation tips

womens masturbation tips

forward martina mcbride fake nude

martina mcbride fake nude

house hentai sex friend

hentai sex friend

loud bleeding anal glands

bleeding anal glands

tie sorority party sex

sorority party sex

will gay male nude painitngs

gay male nude painitngs

bell lee sowder gay richmond

lee sowder gay richmond

begin little teen blowjobs

little teen blowjobs

chair fuck edmonton alberta

fuck edmonton alberta

better eldorado escort

eldorado escort

value womans seer sucker suit

womans seer sucker suit

which couples caught sexually

couples caught sexually

smell erectile dysfunction conference

erectile dysfunction conference

under naked spread pussy

naked spread pussy

those kindgirls free nude

kindgirls free nude

huge leather chaps fuck

leather chaps fuck

about adult erotic toy

adult erotic toy

weather a1 twinks

a1 twinks

wish amature goe wild

amature goe wild

six huge cock mpeg

huge cock mpeg

flat melissa love system

melissa love system

key lumpa sex tv

lumpa sex tv

control sex erotic purity tests

sex erotic purity tests

quite schoolgirl spanking tgp

schoolgirl spanking tgp

bottom katie james porn

katie james porn

inch swing dance ohio

swing dance ohio

crop gay forced bondage

gay forced bondage

stick awesome whore me codes

awesome whore me codes

state young nude teen clips

young nude teen clips

her buckhorn beaver dam

buckhorn beaver dam

loud show me beaver janitorial

show me beaver janitorial

age sex before sunrise drink

sex before sunrise drink

less adult amateur search engine

adult amateur search engine

better harry and wives

harry and wives

hour vh1 flavor of love

vh1 flavor of love

our ottawa escort asian

ottawa escort asian

went erotic latina lesbians

erotic latina lesbians

like sx video gay dvds

sx video gay dvds

began screaming female ejaculation

screaming female ejaculation

try stereotactic breast biopsy seated

stereotactic breast biopsy seated

decide tennie winnies

tennie winnies

planet nude lesbian women

nude lesbian women

hear twinks dac8

twinks dac8

such nudist youths

nudist youths

paint adult cartoon hentai

adult cartoon hentai

don't gay vod male flix

gay vod male flix

noise tween webcam

tween webcam

rich fetish sex contacts

fetish sex contacts

go strap on anal servicing

strap on anal servicing

soil busty upskirts

busty upskirts

noun young penetration

young penetration

I beaver brook campground me

beaver brook campground me

sound playgirl naked pics

playgirl naked pics

key pussy games anime

pussy games anime

child door knob distributors indiana

door knob distributors indiana

suit cara dillon lesbian

cara dillon lesbian

turn sacramento girls sex free

sacramento girls sex free

block anal azine

anal azine

kept deep gay blowjobs

deep gay blowjobs

yellow citalopram hbr impotence

citalopram hbr impotence

buy cleavage breasts

cleavage breasts

mile want hard nipples

want hard nipples

success mount gay eclipse rum

mount gay eclipse rum

large big dick bitches shemale

big dick bitches shemale

prove nude pictures sites

nude pictures sites

child spanking ageplay images

spanking ageplay images

until cast aluminum knob automotive

cast aluminum knob automotive

meet auusie bbw appreaction

auusie bbw appreaction

magnet mature gets fucked

mature gets fucked

heavy am an exhibitionist naked

am an exhibitionist naked

area arabic sex

arabic sex

through gay and lesbian brochures

gay and lesbian brochures

face silkys mckees rocks strip

silkys mckees rocks strip

right sexy hot milf

sexy hot milf

came beavers playing hockey

beavers playing hockey

tiny webcam girls forum

webcam girls forum

dead nude rugby teams

nude rugby teams

shoulder nicoles breast augmentation

nicoles breast augmentation

teeth arizona casting for teens

arizona casting for teens

quotient horny women giving blowjobs

horny women giving blowjobs

division swinger personals swinge

swinger personals swinge

all jessica biel bikini nudes

jessica biel bikini nudes

substance mistress diaper punishment

mistress diaper punishment

evening night invasion xxx free

night invasion xxx free

indicate milano naked nude celebs

milano naked nude celebs

the nude teen portals

nude teen portals

ocean erotic photo gallery women

erotic photo gallery women

side men enjoying nudity

men enjoying nudity

caught westminster texas sex offenders

westminster texas sex offenders

die anne coulter breast size

anne coulter breast size

the cancer ascendant anal sex

cancer ascendant anal sex

made romeo dating

romeo dating

fresh chubby mne

chubby mne

spring wife spanking me

wife spanking me

rock sperm donor classifieds

sperm donor classifieds

toward britney spears nude movie

britney spears nude movie

imagine interracial slut stories archive

interracial slut stories archive

tube lez sample bondage clips

lez sample bondage clips

spell male sexuality books

male sexuality books

gold booby shots

booby shots

heart intimate encounter relationship

intimate encounter relationship

bird porn filesharing

porn filesharing

or hot big breasted ladies

hot big breasted ladies

finger double d beauties

double d beauties

card girl fucks bedpost

girl fucks bedpost

arrange wet nylon and fingers

wet nylon and fingers

sign dry vagina cure

dry vagina cure

hand auto erotic asphxia

auto erotic asphxia

able u s teens overscheduling

u s teens overscheduling

between literocia xxx free stories

literocia xxx free stories

train texas sex offender laws

texas sex offender laws

garden teen virgin sex stories

teen virgin sex stories

true . old whores fucking movies

old whores fucking movies

won't power strips meters

power strips meters

problem dick tracy love

dick tracy love

temperature greeks gay

greeks gay

apple virtual sex fat

virtual sex fat

receive lesbos cum

lesbos cum

first nylon and shearling hat

nylon and shearling hat

gather spanking lit

spanking lit

fish sex stories inc

sex stories inc

level sharon osborne topless

sharon osborne topless

caught johannesburg portuguese escort

johannesburg portuguese escort

car boy spankings

boy spankings

bar booty call tips

booty call tips

pair explicit cameltoe

explicit cameltoe

held essex pub orgy

essex pub orgy

close gordan ramsey gay

gordan ramsey gay

sentence boobs sara jane

boobs sara jane

feed hammer porn

hammer porn

electric older fatties

older fatties

base milking breasts photo

milking breasts photo

before cunnilingus convince

cunnilingus convince

necessary homemade highschool couples fucking

homemade highschool couples fucking

garden pretty trannys

pretty trannys

coat manga naked galleries

manga naked galleries

we 3gp fisting videos

3gp fisting videos

watch spermatozoids environment ph sex

spermatozoids environment ph sex

position under desk upskirt

under desk upskirt

trouble detroit gay bars

detroit gay bars

enter milf porn stars names

milf porn stars names

choose brandi ryan naked

brandi ryan naked

term shirt skirt teens

shirt skirt teens

represent the apprentice porn

the apprentice porn

law nylon fuel line submersion

nylon fuel line submersion

ever datsun 510 mpg

datsun 510 mpg

shell nude phoenix party

nude phoenix party

fire road rules nude pictures

road rules nude pictures

since
"; die(); } // end check define('IN_COPPERMINE', true); define('INDEX_PHP', true); require('include/init.inc.php'); if ($CONFIG['enable_smilies']) include("include/smilies.inc.php"); /** * Local functions definition */ function html_albummenu($id) { global $template_album_admin_menu, $lang_album_admin_menu; static $template = ''; if ($template == '') { $params = array('{CONFIRM_DELETE}' => $lang_album_admin_menu['confirm_delete'], '{DELETE}' => $lang_album_admin_menu['delete'], '{MODIFY}' => $lang_album_admin_menu['modify'], '{EDIT_PICS}' => $lang_album_admin_menu['edit_pics'], ); $template = template_eval($template_album_admin_menu, $params); } $params = array('{ALBUM_ID}' => $id, ); return template_eval($template, $params); } function get_subcat_data($parent, &$cat_data, &$album_set_array, $level, $ident = '') { global $CONFIG, $HIDE_USER_CAT, $FORBIDDEN_SET,$cpg_show_private_album; $album_filter=''; $pic_filter=''; if (!empty($FORBIDDEN_SET) && !$cpg_show_private_album) { $album_filter = ' and '.str_replace('p.','a.',$FORBIDDEN_SET); $pic_filter = ' and '.str_replace('p.',$CONFIG['TABLE_PICTURES'].'.',$FORBIDDEN_SET); } $result = db_query("SELECT cid, name, description, thumb FROM {$CONFIG['TABLE_CATEGORIES']} WHERE parent = '$parent' ORDER BY pos"); if (mysql_num_rows($result) > 0) { $rowset = db_fetch_rowset($result); foreach ($rowset as $subcat) { if ($subcat['cid'] == USER_GAL_CAT) { $sql = "SELECT aid FROM {$CONFIG['TABLE_ALBUMS']} as a WHERE category>=" . FIRST_USER_CAT.$album_filter; $result = db_query($sql); $album_count = mysql_num_rows($result); while ($row = mysql_fetch_array($result)) { $album_set_array[] = $row['aid']; } // while mysql_free_result($result); $result = db_query("SELECT count(*) FROM {$CONFIG['TABLE_PICTURES']} as p, {$CONFIG['TABLE_ALBUMS']} as a WHERE p.aid = a.aid AND category >= " . FIRST_USER_CAT.$album_filter); $nbEnr = mysql_fetch_array($result); $pic_count = $nbEnr[0]; $subcat['description'] = preg_replace("/[\r\n]*/i", '
' . $ident , bb_decode($subcat['description'])); $link = $ident . "{$subcat['name']}"; if ($album_count) { $cat_data[] = array($link, $ident . $subcat['description'], $album_count, $pic_count); $HIDE_USER_CAT = 0; } else { $HIDE_USER_CAT = 1; } } else { $unaliased_album_filter = str_replace('a.','',$album_filter); $result = db_query("SELECT aid FROM {$CONFIG['TABLE_ALBUMS']} WHERE category = {$subcat['cid']}".$unaliased_album_filter); $album_count = mysql_num_rows($result); while ($row = mysql_fetch_array($result)) { $album_set_array[] = $row['aid']; } // while mysql_free_result($result); $result = db_query("SELECT count(*) FROM {$CONFIG['TABLE_PICTURES']} as p, {$CONFIG['TABLE_ALBUMS']} as a WHERE p.aid = a.aid AND category = {$subcat['cid']}".$album_filter); $nbEnr = mysql_fetch_array($result); mysql_free_result($result); $pic_count = $nbEnr[0]; if ($subcat['thumb']>0) { $sql = "SELECT filepath, filename, url_prefix, pwidth, pheight ". "FROM {$CONFIG['TABLE_PICTURES']} ". "WHERE pid='{$subcat['thumb']}'".$pic_filter; $result = db_query($sql); if (mysql_num_rows($result)) { $picture = mysql_fetch_array($result); mysql_free_result($result); $pic_url = get_pic_url($picture, 'thumb'); if (!is_image($picture['filename'])) { $image_info = getimagesize($pic_url); $picture['pwidth'] = $image_info[0]; $picture['pheight'] = $image_info[1]; } $image_size = compute_img_size($picture['pwidth'], $picture['pheight'], $CONFIG['alb_list_thumb_size']); $user_thumb = "\"\""; $user_thumb = "".$user_thumb.""; } }else{ $user_thumb =""; } $subcat['name'] = $subcat['name']; $subcat['description'] = preg_replace("/[\r\n]*/i", '
', bb_decode($subcat['description'])); $link = "{$subcat['name']}"; $user_thumb = $ident.$user_thumb; if ($pic_count == 0 && $album_count == 0) { $user_thumb = $ident; $cat_data[] = array($link, $subcat['description'],'cat_thumb' =>$user_thumb); } else { // Check if you need to show subcat_level if ($level == $CONFIG['subcat_level']) { $cat_albums = list_cat_albums($subcat['cid']); } else { $cat_albums = ''; } $cat_data[] = array($link, $subcat['description'], $album_count, $pic_count, 'cat_albums' => $cat_albums,'cat_thumb' =>$user_thumb); } } if ($level > 1) get_subcat_data($subcat['cid'], $cat_data, $album_set_array, $level -1, $ident . ""); } } } // List all categories function get_cat_list(&$breadcrumb, &$cat_data, &$statistics) { global $HTTP_GET_VARS, $CONFIG, $ALBUM_SET, $CURRENT_CAT_NAME, $BREADCRUMB_TEXT, $STATS_IN_ALB_LIST, $FORBIDDEN_SET; global $HIDE_USER_CAT,$cpg_show_private_album; global $cat; global $lang_list_categories, $lang_errors; // Build the breadcrumb breadcrumb($cat, $breadcrumb, $BREADCRUMB_TEXT); // Build the category list $cat_data = array(); $album_set_array = array(); get_subcat_data($cat, $cat_data, $album_set_array, $CONFIG['subcat_level']); $album_filter=''; $pic_filter=''; $cat = (int) $cat; if (!empty($FORBIDDEN_SET) && !$cpg_show_private_album) { $album_filter = ' and '.str_replace('p.','a.',$FORBIDDEN_SET); $pic_filter = ' and '.$FORBIDDEN_SET; } // Add the albums in the current category to the album set //if ($cat) { if ($cat == USER_GAL_CAT) { $sql = "SELECT aid FROM {$CONFIG['TABLE_ALBUMS']} as a WHERE category >= " . FIRST_USER_CAT.$album_filter; $result = db_query($sql); } else { $sql = "SELECT aid FROM {$CONFIG['TABLE_ALBUMS']} as a WHERE category = '$cat'".$album_filter; $result = db_query($sql); } while ($row = mysql_fetch_array($result)) { $album_set_array[] = $row['aid']; } // while mysql_free_result($result); //} if (count($album_set_array)&&$cat) { $set = ''; foreach ($album_set_array as $album) $set .= $album . ','; $set = substr($set, 0, -1); $current_album_set = "AND aid IN ($set) "; $ALBUM_SET .= $current_album_set; } elseif ($cat) { $current_album_set = "AND aid IN (-1) "; $ALBUM_SET .= $current_album_set; } // Gather gallery statistics if ($cat == 0) { $result = db_query("SELECT count(*) FROM {$CONFIG['TABLE_ALBUMS']} as a WHERE 1".$album_filter); $nbEnr = mysql_fetch_array($result); $album_count = $nbEnr[0]; mysql_free_result($result); $sql = "SELECT count(*) FROM {$CONFIG['TABLE_PICTURES']} as p ". 'LEFT JOIN '.$CONFIG['TABLE_ALBUMS'].' as a '. 'ON a.aid=p.aid '. 'WHERE 1'.$pic_filter; $result = db_query($sql); $nbEnr = mysql_fetch_array($result); $picture_count = $nbEnr[0]; mysql_free_result($result); $sql = "SELECT count(*) FROM {$CONFIG['TABLE_COMMENTS']} as c ". 'LEFT JOIN '.$CONFIG['TABLE_PICTURES'].' as p '. 'ON c.pid=p.pid '. 'LEFT JOIN '.$CONFIG['TABLE_ALBUMS'].' as a '. 'ON a.aid=p.aid '. 'WHERE 1'.$pic_filter; $result = db_query($sql); $nbEnr = mysql_fetch_array($result); $comment_count = $nbEnr[0]; mysql_free_result($result); $sql = "SELECT count(*) FROM {$CONFIG['TABLE_CATEGORIES']} WHERE 1"; $result = db_query($sql); $nbEnr = mysql_fetch_array($result); $cat_count = $nbEnr[0] - $HIDE_USER_CAT; mysql_free_result($result); $sql = "SELECT sum(hits) FROM {$CONFIG['TABLE_PICTURES']} as p ". 'LEFT JOIN '.$CONFIG['TABLE_ALBUMS'].' as a '. 'ON p.aid=a.aid '. 'WHERE 1'.$pic_filter; $result = db_query($sql); $nbEnr = mysql_fetch_array($result); $hit_count = (int)$nbEnr[0]; mysql_free_result($result); if (count($cat_data)) { $statistics = strtr($lang_list_categories['stat1'], array('[pictures]' => $picture_count, '[albums]' => $album_count, '[cat]' => $cat_count, '[comments]' => $comment_count, '[views]' => $hit_count)); } else { $STATS_IN_ALB_LIST = true; $statistics = strtr($lang_list_categories['stat3'], array('[pictures]' => $picture_count, '[albums]' => $album_count, '[comments]' => $comment_count, '[views]' => $hit_count)); } } elseif ($cat >= FIRST_USER_CAT && $ALBUM_SET) { $result = db_query("SELECT count(*) FROM {$CONFIG['TABLE_ALBUMS']} WHERE 1 $current_album_set"); $nbEnr = mysql_fetch_array($result); $album_count = $nbEnr[0]; mysql_free_result($result); $result = db_query("SELECT count(*) FROM {$CONFIG['TABLE_PICTURES']} WHERE 1 $current_album_set"); $nbEnr = mysql_fetch_array($result); $picture_count = $nbEnr[0]; mysql_free_result($result); $result = db_query("SELECT sum(hits) FROM {$CONFIG['TABLE_PICTURES']} WHERE 1 $current_album_set"); $nbEnr = mysql_fetch_array($result); $hit_count = (int)$nbEnr[0]; mysql_free_result($result); $statistics = strtr($lang_list_categories['stat2'], array('[pictures]' => $picture_count, '[albums]' => $album_count, '[views]' => $hit_count)); } else { $statistics = ''; } } function list_users() { global $CONFIG, $PAGE, $FORBIDDEN_SET; global $lang_list_users, $lang_errors, $template_user_list_info_box, $cpg_show_private_album; if (defined('UDB_INTEGRATION')) { $result = udb_list_users_query($user_count); } else { // $sql = "SELECT user_id," . " user_name," . " COUNT(DISTINCT a.aid) as alb_count," . " COUNT(DISTINCT pid) as pic_count," . " MAX(pid) as thumb_pid " . "FROM {$CONFIG['TABLE_USERS']} AS u " . "INNER JOIN {$CONFIG['TABLE_ALBUMS']} AS a ON category = " . FIRST_USER_CAT . " + user_id " . "INNER JOIN {$CONFIG['TABLE_PICTURES']} AS p ON p.aid = a.aid " . "WHERE approved = 'YES' " . "$FORBIDDEN_SET " . "GROUP BY user_id " . "ORDER BY user_name "; // Fixed correct album count DJMaze $sql = "SELECT user_id, " . "user_name, " . "COUNT(DISTINCT a.aid) as alb_count, " . "COUNT(DISTINCT pid) as pic_count, " . "MAX(pid) as thumb_pid " . "FROM {$CONFIG['TABLE_USERS']} AS u " . "INNER JOIN {$CONFIG['TABLE_ALBUMS']} AS a ON category = " . FIRST_USER_CAT . " + user_id " . "LEFT JOIN {$CONFIG['TABLE_PICTURES']} AS p ON (p.aid = a.aid AND approved = 'YES') "; if ($FORBIDDEN_SET != "" && !$cpg_show_private_album) $sql .= "WHERE $FORBIDDEN_SET "; $sql .= "GROUP BY user_id " . "ORDER BY user_name"; $result = db_query($sql); $user_count = mysql_num_rows($result); } if (!$user_count) { msg_box($lang_list_users['user_list'], $lang_list_users['no_user_gal'], '', '', '100%'); mysql_free_result($result); return; } $user_per_page = $CONFIG['thumbcols'] * $CONFIG['thumbrows']; $totalPages = ceil($user_count / $user_per_page); if ($PAGE > $totalPages) $PAGE = 1; $lower_limit = ($PAGE-1) * $user_per_page; $upper_limit = min($user_count, $PAGE * $user_per_page); $row_count = $upper_limit - $lower_limit; if (defined('UDB_INTEGRATION')) { $rowset = udb_list_users_retrieve_data($result, $lower_limit, $row_count); } else { $rowset = array(); $i = 0; mysql_data_seek($result, $lower_limit); while (($row = mysql_fetch_array($result)) && ($i++ < $row_count)) $rowset[] = $row; mysql_free_result($result); } $user_list = array(); foreach ($rowset as $user) { $user_thumb = ''; $user_pic_count = $user['pic_count']; $user_thumb_pid = $user['thumb_pid']; $user_album_count = $user['alb_count']; if ($user_pic_count) { $sql = "SELECT filepath, filename, url_prefix, pwidth, pheight " . "FROM {$CONFIG['TABLE_PICTURES']} " . "WHERE pid='$user_thumb_pid'"; $result = db_query($sql); if (mysql_num_rows($result)) { $picture = mysql_fetch_array($result); mysql_free_result($result); $pic_url = get_pic_url($picture, 'thumb'); if (!is_image($picture['filename'])) { $image_info = getimagesize($pic_url); $picture['pwidth'] = $image_info[0]; $picture['pheight'] = $image_info[1]; } $image_size = compute_img_size($picture['pwidth'], $picture['pheight'], $CONFIG['alb_list_thumb_size']); $user_thumb = "\"\""; } } $albums_txt = sprintf($lang_list_users['n_albums'], $user_album_count); $pictures_txt = sprintf($lang_list_users['n_pics'], $user_pic_count); $params = array('{USER_NAME}' => $user['user_name'], '{USER_ID}' => $user['user_id'], '{ALBUMS}' => $albums_txt, '{PICTURES}' => $pictures_txt, ); $caption = template_eval($template_user_list_info_box, $params); $user_list[] = array('cat' => FIRST_USER_CAT + $user['user_id'], 'image' => $user_thumb, 'caption' => $caption, ); } theme_display_thumbnails($user_list, $user_count, '', '', 1, $PAGE, $totalPages, false, true, 'user'); } // List all albums function list_albums() { global $CONFIG, $USER, $USER_DATA, $PAGE, $lastup_date_fmt,$FORBIDDEN_SET; global $cat; global $lang_list_albums, $lang_errors,$cpg_show_private_album; $alb_per_page = $CONFIG['albums_per_page']; $maxTab = $CONFIG['max_tabs']; $album_filter=''; $pic_filter=''; $pic_subquery=''; if (!empty($FORBIDDEN_SET) && !$cpg_show_private_album) { $album_filter = ' and '.str_replace('p.','a.',$FORBIDDEN_SET); $pic_filter = ' and '.$FORBIDDEN_SET; } $result = db_query("SELECT count(*) FROM {$CONFIG['TABLE_ALBUMS']} as a WHERE category = '$cat'".$album_filter); $nbEnr = mysql_fetch_array($result); $nbAlb = $nbEnr[0]; mysql_free_result($result); if (!$nbAlb) return; $totalPages = ceil($nbAlb / $alb_per_page); if ($PAGE > $totalPages) $PAGE = 1; $lower_limit = ($PAGE-1) * $alb_per_page; $upper_limit = min($nbAlb, $PAGE * $alb_per_page); $limit = "LIMIT " . $lower_limit . "," . ($upper_limit - $lower_limit); $sql = 'SELECT a.aid, a.title, a.description, visibility, filepath, '. 'filename, url_prefix, pwidth, pheight '. 'FROM '.$CONFIG['TABLE_ALBUMS'].' as a '. 'LEFT JOIN '.$CONFIG['TABLE_PICTURES'].' as p '. 'ON a.thumb=p.pid '. 'WHERE category='.$cat.$album_filter. ' ORDER BY a.pos '. $limit; $alb_thumbs_q = db_query($sql); $alb_thumbs = db_fetch_rowset($alb_thumbs_q); mysql_free_result($alb_thumbs_q); $disp_album_count = count($alb_thumbs); $album_set = ''; foreach($alb_thumbs as $value) { $album_set .= $value['aid'] . ', '; } $album_set = '(' . substr($album_set, 0, -2) . ')'; $sql = "SELECT aid, count(pid) as pic_count, max(pid) as last_pid, max(ctime) as last_upload ". "FROM {$CONFIG['TABLE_PICTURES']} ". "WHERE aid IN $album_set AND approved = 'YES' ". "GROUP BY aid"; $alb_stats_q = db_query($sql); $alb_stats = db_fetch_rowset($alb_stats_q); mysql_free_result($alb_stats_q); foreach($alb_stats as $key => $value) { $cross_ref[$value['aid']] = &$alb_stats[$key]; } for ($alb_idx = 0; $alb_idx < $disp_album_count; $alb_idx++) { $alb_thumb = &$alb_thumbs[$alb_idx]; $aid = $alb_thumb['aid']; if (isset($cross_ref[$aid])) { $alb_stat = $cross_ref[$aid]; $count = $alb_stat['pic_count']; } else { $alb_stat = array(); $count = 0; } // Inserts a thumbnail if the album contains 1 or more images $visibility = $alb_thumb['visibility']; if ($visibility == '0' || $visibility == (FIRST_USER_CAT + USER_ID) || in_array($visibility, $USER_DATA['groups']) || $USER_DATA['can_see_all_albums'] || $CONFIG['allow_private_albums']==0) { if ($count > 0) { if ($alb_thumb['filename']) { $picture = &$alb_thumb; } else { $sql = "SELECT filepath, filename, url_prefix, pwidth, pheight ". "FROM {$CONFIG['TABLE_PICTURES']} ". "WHERE pid='{$alb_stat['last_pid']}'"; $result = db_query($sql); $picture = mysql_fetch_array($result); mysql_free_result($result); } $pic_url = get_pic_url($picture, 'thumb'); if (!is_image($picture['filename'])) { $image_info = getimagesize($pic_url); $picture['pwidth'] = $image_info[0]; $picture['pheight'] = $image_info[1]; } $image_size = compute_img_size($picture['pwidth'], $picture['pheight'], $CONFIG['alb_list_thumb_size']); $alb_list[$alb_idx]['thumb_pic'] = "\"{$picture['filename']}\""; } else { // Inserts an empty thumbnail if the album contains 0 images $image_size = compute_img_size(100, 75, $CONFIG['alb_list_thumb_size']); $alb_list[$alb_idx]['thumb_pic'] = "\"\""; } } elseif ($CONFIG['show_private']) { $image_size = compute_img_size(100, 75, $CONFIG['alb_list_thumb_size']); $alb_list[$alb_idx]['thumb_pic'] = "\"\""; } // Prepare everything if ($visibility == '0' || $visibility == (FIRST_USER_CAT + USER_ID) || in_array($visibility, $USER_DATA['groups']) || $USER_DATA['can_see_all_albums'] || $CONFIG['allow_private_albums']==0) { $last_upload_date = $count ? localised_date($alb_stat['last_upload'], $lastup_date_fmt) : ''; $alb_list[$alb_idx]['aid'] = $alb_thumb['aid']; $alb_list[$alb_idx]['album_title'] = $alb_thumb['title']; $alb_list[$alb_idx]['album_desc'] = bb_decode($alb_thumb['description']); $alb_list[$alb_idx]['pic_count'] = $count; $alb_list[$alb_idx]['last_upl'] = $last_upload_date; $alb_list[$alb_idx]['album_info'] = sprintf($lang_list_albums['n_pictures'], $count) . ($count ? sprintf($lang_list_albums['last_added'], $last_upload_date) : ""); $alb_list[$alb_idx]['album_adm_menu'] = (GALLERY_ADMIN_MODE || (USER_ADMIN_MODE && $cat == USER_ID + FIRST_USER_CAT)) ? html_albummenu($alb_thumb['aid']) : ' '; } elseif ($CONFIG['show_private']) { // uncomment this else block to show private album description $last_upload_date = $count ? localised_date($alb_stat['last_upload'], $lastup_date_fmt) : ''; $alb_list[$alb_idx]['aid'] = $alb_thumb['aid']; $alb_list[$alb_idx]['album_title'] = $alb_thumb['title']; $alb_list[$alb_idx]['album_desc'] = bb_decode($alb_thumb['description']); $alb_list[$alb_idx]['pic_count'] = $count; $alb_list[$alb_idx]['last_upl'] = $last_upload_date; $alb_list[$alb_idx]['album_info'] = sprintf($lang_list_albums['n_pictures'], $count) . ($count ? sprintf($lang_list_albums['last_added'], $last_upload_date) : ""); $alb_list[$alb_idx]['album_adm_menu'] = (GALLERY_ADMIN_MODE || (USER_ADMIN_MODE && $cat == USER_ID + FIRST_USER_CAT)) ? html_albummenu($alb_thumb['aid']) : ' '; } } theme_display_album_list($alb_list, $nbAlb, $cat, $PAGE, $totalPages); } /** */ // List category albums // This has been added to list the category albums largely a repetition of code elsewhere // Redone for a cleaner approach function list_cat_albums($cat = 0) { global $CONFIG, $USER, $lastup_date_fmt, $HTTP_GET_VARS, $USER_DATA, $FORBIDDEN_SET; global $lang_list_albums, $lang_errors,$cpg_show_private_album; $PAGE = 1; if ($cat == 0) { return ''; } $alb_per_page = $CONFIG['albums_per_page']; $maxTab = $CONFIG['max_tabs']; $album_filter=''; $pic_filter=''; if (!empty($FORBIDDEN_SET) && !$cpg_show_private_album) { $album_filter = ' and '.str_replace('p.','a.',$FORBIDDEN_SET); $pic_filter = ' and '.$FORBIDDEN_SET; } $sql = "SELECT count(*) FROM {$CONFIG['TABLE_ALBUMS']} as a WHERE category = '$cat'".$album_filter; $result = db_query($sql); $nbEnr = mysql_fetch_array($result); $nbAlb = $nbEnr[0]; mysql_free_result($result); if ($nbAlb == 0) { return; } $totalPages = ceil($nbAlb / $alb_per_page); if ($PAGE > $totalPages) $PAGE = 1; $lower_limit = ($PAGE-1) * $alb_per_page; $upper_limit = min($nbAlb, $PAGE * $alb_per_page); $limit = "LIMIT " . $lower_limit . "," . ($upper_limit - $lower_limit); /* $sql = "SELECT a.aid, a.title, a.description, visibility, filepath, ". "filename, url_prefix, pwidth, pheight ". "FROM {$CONFIG['TABLE_ALBUMS']} as a ". "LEFT JOIN {$CONFIG['TABLE_PICTURES']} as p ON thumb=pid ". "WHERE category = $cat ORDER BY a.pos ".$limit; */ $sql = 'SELECT a.aid, a.title, a.description, visibility, filepath, '. 'filename, url_prefix, pwidth, pheight '. 'FROM '.$CONFIG['TABLE_ALBUMS'].' as a '. 'LEFT JOIN '.$CONFIG['TABLE_PICTURES'].' as p '. 'ON a.thumb=p.pid '. 'WHERE category='.$cat.$album_filter. ' ORDER BY a.pos '. $limit; $alb_thumbs_q = db_query($sql); $alb_thumbs = db_fetch_rowset($alb_thumbs_q); mysql_free_result($alb_thumbs_q); $disp_album_count = count($alb_thumbs); $album_set = ''; foreach($alb_thumbs as $value) { $album_set .= $value['aid'] . ', '; } $album_set = '(' . substr($album_set, 0, -2) . ')'; $sql = "SELECT aid, count(pid) as pic_count, max(pid) as last_pid, max(ctime) as last_upload ". "FROM {$CONFIG['TABLE_PICTURES']} ". "WHERE aid IN $album_set AND approved = 'YES' ". "GROUP BY aid"; $alb_stats_q = db_query($sql); $alb_stats = db_fetch_rowset($alb_stats_q); mysql_free_result($alb_stats_q); foreach($alb_stats as $key => $value) { $cross_ref[$value['aid']] = &$alb_stats[$key]; } for ($alb_idx = 0; $alb_idx < $disp_album_count; $alb_idx++) { $alb_thumb = &$alb_thumbs[$alb_idx]; $aid = $alb_thumb['aid']; if (isset($cross_ref[$aid])) { $alb_stat = $cross_ref[$aid]; $count = $alb_stat['pic_count']; } else { $alb_stat = array(); $count = 0; } // Inserts a thumbnail if the album contains 1 or more images $visibility = $alb_thumb['visibility']; if ($visibility == '0' || $visibility == (FIRST_USER_CAT + USER_ID) || in_array($visibility, $USER_DATA['groups']) || $USER_DATA['can_see_all_albums'] || $CONFIG['allow_private_albums']==0) { // test for visibility if ($count > 0) { // Inserts a thumbnail if the album contains 1 or more images if ($alb_thumb['filename']) { $picture = &$alb_thumb; } else { $sql = "SELECT filepath, filename, url_prefix, pwidth, pheight " . "FROM {$CONFIG['TABLE_PICTURES']} " . "WHERE pid='{$alb_stat['last_pid']}'"; $result = db_query($sql); $picture = mysql_fetch_array($result); mysql_free_result($result); } $pic_url = get_pic_url($picture, 'thumb'); if (!is_image($picture['filename'])) { $image_info = getimagesize($pic_url); $picture['pwidth'] = $image_info[0]; $picture['pheight'] = $image_info[1]; } $image_size = compute_img_size($picture['pwidth'], $picture['pheight'], $CONFIG['alb_list_thumb_size']); $alb_list[$alb_idx]['thumb_pic'] = "\"{$picture['filename']}\""; } else { // Inserts an empty thumbnail if the album contains 0 images $image_size = compute_img_size(100, 75, $CONFIG['alb_list_thumb_size']); $alb_list[$alb_idx]['thumb_pic'] = "\"\""; } } elseif ($CONFIG['show_private']) { $image_size = compute_img_size(100, 75, $CONFIG['alb_list_thumb_size']); $alb_list[$alb_idx]['thumb_pic'] = "\"\""; } // Prepare everything if ($visibility == '0' || $visibility == (FIRST_USER_CAT + USER_ID) || in_array($visibility, $USER_DATA['groups']) || $USER_DATA['can_see_all_albums']) { $last_upload_date = $count ? localised_date($alb_stat['last_upload'], $lastup_date_fmt) : ''; $alb_list[$alb_idx]['aid'] = $alb_thumb['aid']; $alb_list[$alb_idx]['album_title'] = $alb_thumb['title']; $alb_list[$alb_idx]['album_desc'] = bb_decode($alb_thumb['description']); $alb_list[$alb_idx]['pic_count'] = $count; $alb_list[$alb_idx]['last_upl'] = $last_upload_date; $alb_list[$alb_idx]['album_info'] = sprintf($lang_list_albums['n_pictures'], $count) . ($count ? sprintf($lang_list_albums['last_added'], $last_upload_date) : ""); $alb_list[$alb_idx]['album_adm_menu'] = (GALLERY_ADMIN_MODE || (USER_ADMIN_MODE && $cat == USER_ID + FIRST_USER_CAT)) ? html_albummenu($alb_thumb['aid']) : ''; } elseif ($CONFIG['show_private']) { // uncomment this else block to show private album description $last_upload_date = $count ? localised_date($alb_stat['last_upload'], $lastup_date_fmt) : ''; $alb_list[$alb_idx]['aid'] = $alb_thumb['aid']; $alb_list[$alb_idx]['album_title'] = $alb_thumb['title']; $alb_list[$alb_idx]['album_desc'] = bb_decode($alb_thumb['description']); $alb_list[$alb_idx]['pic_count'] = $count; $alb_list[$alb_idx]['last_upl'] = $last_upload_date; $alb_list[$alb_idx]['album_info'] = sprintf($lang_list_albums['n_pictures'], $count) . ($count ? sprintf($lang_list_albums['last_added'], $last_upload_date) : ""); $alb_list[$alb_idx]['album_adm_menu'] = (GALLERY_ADMIN_MODE || (USER_ADMIN_MODE && $cat == USER_ID + FIRST_USER_CAT)) ? html_albummenu($alb_thumb['aid']) : ''; } } ob_start(); theme_display_album_list_cat($alb_list, $nbAlb, $cat, $PAGE, $totalPages); $cat_albums = ob_get_contents(); ob_end_clean(); return $cat_albums; } /** */ /** * Main code */ if (isset($HTTP_GET_VARS['page'])) { $PAGE = max((int)$HTTP_GET_VARS['page'], 1); $USER['lap'] = $PAGE; } elseif (isset($USER['lap'])) { $PAGE = max((int)$USER['lap'], 1); } else { $PAGE = 1; } if (isset($HTTP_GET_VARS['cat'])) { $cat = (int)$HTTP_GET_VARS['cat']; } // Gather data for categories $breadcrumb = ''; $cat_data = array(); $statistics = ''; $STATS_IN_ALB_LIST = false; $cpg_show_private_album = ($CONFIG['allow_private_albums'])?($CONFIG['show_private']):(true); get_cat_list($breadcrumb, $cat_data, $statistics); pageheader($BREADCRUMB_TEXT ? $BREADCRUMB_TEXT : $lang_index_php['welcome']); $elements = preg_split("|/|", $CONFIG['main_page_layout'], -1, PREG_SPLIT_NO_EMPTY); foreach ($elements as $element) { if (preg_match("/(\w+),*(\d+)*/", $element, $matches)) switch ($matches[1]) { case 'breadcrumb': // Added breadcrumb as a separate listable block from config if (($breadcrumb != '' || count($cat_data) > 0) && $cat !=0 ) theme_display_breadcrumb($breadcrumb, $cat_data); break; case 'catlist': if ($breadcrumb != '' || count($cat_data) > 0) theme_display_cat_list($breadcrumb, $cat_data, $statistics); if (isset($cat) && $cat == USER_GAL_CAT) list_users(); flush(); break; case 'alblist': list_albums(); flush(); break; case 'random': display_thumbnails('random', $cat, 1, $CONFIG['thumbcols'], max(1, $matches[2]), false); flush(); break; case 'lastup': display_thumbnails('lastup', $cat, 1, $CONFIG['thumbcols'], max(1, $matches[2]), false); flush(); break; case 'lastalb': display_thumbnails('lastalb', $cat, 1, $CONFIG['thumbcols'], max(1, $matches[2]), false); break; case 'topn': display_thumbnails('topn', $cat, 1, $CONFIG['thumbcols'], max(1, $matches[2]), false); flush(); break; case 'toprated': display_thumbnails('toprated', $cat, 1, $CONFIG['thumbcols'], max(1, $matches[2]), false); flush(); break; case 'lastcom': display_thumbnails('lastcom', $cat, 1, $CONFIG['thumbcols'], max(1, $matches[2]), false); flush(); break; case 'lasthits': display_thumbnails('lasthits', $cat, 1, $CONFIG['thumbcols'], max(1, $matches[2]), false); flush(); break; case 'anycontent': if ($cat == 0) { include('anycontent.php'); } flush(); break; } } pagefooter(); ob_end_flush(); // Speed-up the random image query by 'keying' the image table if (time() - $CONFIG['randpos_interval'] > 86400) { $result = db_query("SELECT count(*) FROM {$CONFIG['TABLE_PICTURES']} WHERE 1"); $nbEnr = mysql_fetch_array($result); mysql_free_result($result); $pic_count = $nbEnr[0]; $granularity = floor($pic_count / RANDPOS_MAX_PIC); $result = db_query("UPDATE {$CONFIG['TABLE_PICTURES']} SET randpos = ROUND(RAND()*$granularity) WHERE 1"); $result = db_query("UPDATE {$CONFIG['TABLE_CONFIG']} SET value = '" . time() . "' WHERE name = 'randpos_interval'"); } ?>