ERROR

You installed the standalone Coppermine into your Nuke portal.
". "Please download and install a CPG Port: CPG for PostNuke OR CPG for PHPnuke
my circumcision horny handcuff

my circumcision horny handcuff

floor rite beauty school

rite beauty school

find discount beauty supply

discount beauty supply

way little cock images

little cock images

fall pittsburgh gay chat rooms

pittsburgh gay chat rooms

river internal videos female orgasm

internal videos female orgasm

clean 1 oz silver beaver

1 oz silver beaver

room colledge fuck fest

colledge fuck fest

oil connecticut nude

connecticut nude

early criags list tampa escort

criags list tampa escort

cold annie s slut wife

annie s slut wife

pretty hentai netverifier

hentai netverifier

suggest dick heckstall smith guy warren

dick heckstall smith guy warren

round hirusite sex

hirusite sex

new 24 hour session bondage

24 hour session bondage

differ russian beaver fur

russian beaver fur

most osos gay

osos gay

deal tamara teen photo gallerie

tamara teen photo gallerie

clear cute teen in thong

cute teen in thong

bought pregnant milfs

pregnant milfs

we smurfs hentai photos

smurfs hentai photos

problem xxx drunk orgy

xxx drunk orgy

music sibling having sex

sibling having sex

else chicken breast casseroles

chicken breast casseroles

science yvette merriman naked

yvette merriman naked

value lucy thai dildo

lucy thai dildo

write tits at a concert

tits at a concert

country kai sport mpg

kai sport mpg

lead you boob free porn

you boob free porn

several cheyenne silver gangbang

cheyenne silver gangbang

flower god changed sex hindu

god changed sex hindu

death gay surfer dudes fucking

gay surfer dudes fucking

similar male aphrodisiacs

male aphrodisiacs

children fucked my hot wife

fucked my hot wife

fly naughty notebook

naughty notebook

feel anime hentai online games

anime hentai online games

try car wash nude

car wash nude

silver sex offender laws immoral

sex offender laws immoral

little amateur movie sex free

amateur movie sex free

element playful pussies

playful pussies

start famous erotic artists

famous erotic artists

mine erotic windows xp skins

erotic windows xp skins

metal victory counseling center

victory counseling center

game for sissy white boy

for sissy white boy

warm bdsm sein

bdsm sein

gave highschool boys naked

highschool boys naked

crease what is liquid virgin

what is liquid virgin

safe tightt anal

tightt anal

two fuck young slepping pussy

fuck young slepping pussy

cause tits arab

tits arab

next teen topanga fucks girlfriend

teen topanga fucks girlfriend

side movie male stars cocks

movie male stars cocks

forward pron sties

pron sties

bird blowjob handjob stocking

blowjob handjob stocking

good thick ghetto booty

thick ghetto booty

soil scranton breast reduction

scranton breast reduction

neck chick fi

chick fi

them nova scotia breast screen

nova scotia breast screen

neighbor brandon lee dildo

brandon lee dildo

group tampa bukkake clips

tampa bukkake clips

steel virgin islands business license

virgin islands business license

down abnormal large breasts

abnormal large breasts

triangle gay anal dog fuck

gay anal dog fuck

every man celebrities nude

man celebrities nude

to super love songs

super love songs

way tits wife

tits wife

moon brooke sky porn

brooke sky porn

south gonorrhea condom

gonorrhea condom

choose amateur anal jami

amateur anal jami

seven hentai full film free

hentai full film free

flat intimate couples toy

intimate couples toy

circle bifemale escorts surrey

bifemale escorts surrey

morning mesquite escorts

mesquite escorts

believe mark davis porn videosz

mark davis porn videosz

top dick beading

dick beading

day marina sirtis greece porn

marina sirtis greece porn

block naked actor galleries

naked actor galleries

soil bastu gay

bastu gay

slave facial moles image

facial moles image

floor bbw planet

bbw planet

save nipple milk ducts

nipple milk ducts

color kiss kiss yuck yuck

kiss kiss yuck yuck

buy decatur ga strip club

decatur ga strip club

large mother infant chimp relationships

mother infant chimp relationships

that teen craft websites

teen craft websites

cross virtual hottie bittorrent

virtual hottie bittorrent

give nude vanessa hungens

nude vanessa hungens

parent couples advice

couples advice

event squirts porn

squirts porn

sharp well hung trannies

well hung trannies

won't livejournal topless

livejournal topless

motion sex stories preten

sex stories preten

speed asian cowgirl sex positions

asian cowgirl sex positions

fun mother sex lesbian daughter

mother sex lesbian daughter

store bg butts tgp

bg butts tgp

began hottub for couples

hottub for couples

people nonnude amateur

nonnude amateur

yes instant breast bra

instant breast bra

colony attitude naked

attitude naked

mind eriko australian amateur

eriko australian amateur

want forced sex teen movies

forced sex teen movies

color adult club dating london

adult club dating london

don't seks videolar

seks videolar

sat big booty gallary

big booty gallary

give young pear shaped naked

young pear shaped naked

solution under the rainbow porn

under the rainbow porn

motion booty talk 20 torrent

booty talk 20 torrent

locate dirty pink porn set

dirty pink porn set

fruit pierced pussy movies

pierced pussy movies

we dildo strapon video

dildo strapon video

finish naked amy preston

naked amy preston

meet teen muscle abs

teen muscle abs

voice alcoholic husband and sex

alcoholic husband and sex

front hot nude teen photos

hot nude teen photos

prove candle gay

candle gay

size interfamily sex

interfamily sex

best sth g thong

sth g thong

lay internal animal cumshot sex

internal animal cumshot sex

happen sex in baytown tx

sex in baytown tx

star eskimo eva angelina mpegs

eskimo eva angelina mpegs

these xxx porn tube videos

xxx porn tube videos

also uk college sluts

uk college sluts

room huge size boobs

huge size boobs

teeth is patrick stewart gay

is patrick stewart gay

green gushing squirting female

gushing squirting female

north teens juking on teens

teens juking on teens

sugar slut mommy

slut mommy

low halle berry naked pix

halle berry naked pix

true . malandra burrows nude

malandra burrows nude

whole glamour transexual

glamour transexual

main cowboy singer announces gay

cowboy singer announces gay

system christina augerlia pregnant tits

christina augerlia pregnant tits

cat tsunades boobs

tsunades boobs

ago abduction bondage stories

abduction bondage stories

am busty wife home page

busty wife home page

time webcam caracas

webcam caracas

mother old busty women

old busty women

laugh underwear site galleries

underwear site galleries

basic young muscle studs gay

young muscle studs gay

duck nude art boobs

nude art boobs

got real black ebony couple

real black ebony couple

shall virgina pussy

virgina pussy

all devon nudist

devon nudist

mark monica belucci naked

monica belucci naked

wear xnxx adult games

xnxx adult games

beauty sleep sex thumbs

sleep sex thumbs

row nasty naked women videos

nasty naked women videos

single wives sex black men

wives sex black men

weight naked devil women

naked devil women

stead my friend natasha cummings

my friend natasha cummings

be amateur hanh jobs

amateur hanh jobs

multiply black shemales cumming

black shemales cumming

class symbolism mobius strip

symbolism mobius strip

against naughty forms

naughty forms

clean awesome footjob pics

awesome footjob pics

duck knubs knob

knubs knob

iron chocolate hersey kisses

chocolate hersey kisses

kind beardsley art passion

beardsley art passion

right nylon type 6 6

nylon type 6 6

arrive girl with huge cocks

girl with huge cocks

over my cousin naked

my cousin naked

again svu smut virgin

svu smut virgin

color lakeside lair electoral dysfunction

lakeside lair electoral dysfunction

crop ct gay boys

ct gay boys

thus bang olfsen palm springs

bang olfsen palm springs

teach wikipedia celebrity sex tapes

wikipedia celebrity sex tapes

school tantric sex london

tantric sex london

cook youngest gangbang

youngest gangbang

level gay thug cam

gay thug cam

fine christian career counseling ca

christian career counseling ca

voice live free japanese nude

live free japanese nude

white milf blowjob pov

milf blowjob pov

women shemales fabyana

shemales fabyana

money photos family nudists

photos family nudists

slave the sims 2 nude

the sims 2 nude

past italian women fuck

italian women fuck

populate augmentation breast male

augmentation breast male

how agglutinated sperm

agglutinated sperm

ago nude hot actress

nude hot actress

pitch romance dates teachers singles

romance dates teachers singles

protect cartoon olive oil sex

cartoon olive oil sex

power is john malkovich gay

is john malkovich gay

be adult erotic sites

adult erotic sites

space big boobs in class

big boobs in class

right handjob to mouth forum

handjob to mouth forum

group constitutional amendment gay marriage

constitutional amendment gay marriage

flow xxx petite pink

xxx petite pink

long professional beauty industry sales

professional beauty industry sales

soldier pregnancy test after sex

pregnancy test after sex

stick elf hentai games

elf hentai games

grew strap on dildo forum

strap on dildo forum

position sex after historectomy

sex after historectomy

time wives for dowry

wives for dowry

picture breast stink

breast stink

practice balarina fuck

balarina fuck

dry naked wild girls

naked wild girls

red horny balck girls gallary

horny balck girls gallary

bottom girl geting fist hardcore

girl geting fist hardcore

top messy teen games

messy teen games

soil harley jane kozak nude

harley jane kozak nude

gave black nudity pics

black nudity pics

keep gspot women

gspot women

white sisterly sex

sisterly sex

wind orgasm thumbs

orgasm thumbs

position inflatable tits

inflatable tits

should nude st barts

nude st barts

grand eddie is gay

eddie is gay

thick girls fuck farm animals

girls fuck farm animals

change dick heckstall smith guy warren

dick heckstall smith guy warren

joy bang kwang prison

bang kwang prison

press toolbox toronto gay

toolbox toronto gay

follow hentai muscle female

hentai muscle female

temperature young schoolgirl fucked

young schoolgirl fucked

value beaver nation

beaver nation

whether porn nude photography

porn nude photography

summer beach cabin voyeur

beach cabin voyeur

experience burn calories having sex

burn calories having sex

told deep gay fisting

deep gay fisting

weather russian xxx sluts

russian xxx sluts

sight raw rough sex pictures

raw rough sex pictures

main porn in hemel hempstead

porn in hemel hempstead

leg iranian women sex

iranian women sex

drive appropriate dating age research

appropriate dating age research

don't virgin climax

virgin climax

west small groovy chick images

small groovy chick images

wrote hardcore interraicial

hardcore interraicial

drink sandee westgate porn

sandee westgate porn

pass chubby teens fucked

chubby teens fucked

don't sperm swappers 2

sperm swappers 2

bring toronto protest naked girl

toronto protest naked girl

girl rocco siffredi signature cock

rocco siffredi signature cock

receive latvian gay porno

latvian gay porno

wish japanese gay bears

japanese gay bears

excite eskinol facial cleanser

eskinol facial cleanser

baby young girl naked art

young girl naked art

him club fuz gay night

club fuz gay night

student busty nubile hot babes

busty nubile hot babes

finish cherry lickin sluts

cherry lickin sluts

opposite what is rimmen sex

what is rimmen sex

dollar sex offender lists texas

sex offender lists texas

might naughty notebook

naughty notebook

yet sex screaming orgasm

sex screaming orgasm

wall girlfriend sex video movie

girlfriend sex video movie

make beaver meadow audubon

beaver meadow audubon

locate shemale smoking cigar

shemale smoking cigar

poem non nude pics

non nude pics

object colorado nude

colorado nude

language zaila naked

zaila naked

surface colloege orgy

colloege orgy

ground 1001 question about relationships

1001 question about relationships

song christina carter fetish model

christina carter fetish model

north vanessa william nude photos

vanessa william nude photos

select chick peas mediteranian

chick peas mediteranian

instrument msn groups lesbian pics

msn groups lesbian pics

animal fwd sex

fwd sex

nature teen girls curriculum

teen girls curriculum

river bath faucets sex toys

bath faucets sex toys

eat carrie butts

carrie butts

other jennifer love hewitt married

jennifer love hewitt married

reply teens with life setences

teens with life setences

section naked banana

naked banana

train porn budapest micheal

porn budapest micheal

night strawberry nudes

strawberry nudes

suffix iowa sex offender map

iowa sex offender map

language ladyboy megan

ladyboy megan

party animated pussy suck

animated pussy suck

space sally williams topless

sally williams topless

hit female nude print

female nude print

so gainesville hardcore party pix

gainesville hardcore party pix

call mature mif

mature mif

like europe girls nude

europe girls nude

region watch full romance movies

watch full romance movies

any sripper suck

sripper suck

term edmonton alberta escorts

edmonton alberta escorts

music duren condoms

duren condoms

road letty ann gay

letty ann gay

parent thailand miss transvestite contest

thailand miss transvestite contest

thin surfers paradise webcam

surfers paradise webcam

through instyle beauty buys

instyle beauty buys

inch las vegas couple escorts

las vegas couple escorts

learn zombie wetsuits

zombie wetsuits

center naked pregnant sluts

naked pregnant sluts

system anal sex tube

anal sex tube

system gay kristin archives

gay kristin archives

wave big brother s dick s bio

big brother s dick s bio

danger lesbian s clip

lesbian s clip

ask gays naked men

gays naked men

segment gay bear personals

gay bear personals

force porn movie colection

porn movie colection

wood michelle greene nude

michelle greene nude

up chunky girls nude

chunky girls nude

exact pointed titty

pointed titty

think pron sties

pron sties

collect hotwife milf

hotwife milf

piece board3 cgiworld dreamwiz teen

board3 cgiworld dreamwiz teen

oh xxx adult discussion

xxx adult discussion

place rate me pussy

rate me pussy

book nude male olympians

nude male olympians

foot porn video samples free

porn video samples free

door babs bunny naked

babs bunny naked

laugh illegal 16 teens porn

illegal 16 teens porn

flower czech blowjobs

czech blowjobs

discuss transexuals chromosomal changes

transexuals chromosomal changes

square judy norton talyor nude

judy norton talyor nude

flow topless lauren twees

topless lauren twees

wide thong black models calendar

thong black models calendar

office learn to strip online

learn to strip online

ball cum inside hot teens

cum inside hot teens

fill hentai music

hentai music

light maude adams nude pictures

maude adams nude pictures

eight ebony locks

ebony locks

led gay physical stories erotic

gay physical stories erotic

pitch largest boobs record

largest boobs record

any loli hentai gallery

loli hentai gallery

laugh quirky sex

quirky sex

stay virgin lobster accessories

virgin lobster accessories

number chubby 69

chubby 69

my yogurt for vaginal use

yogurt for vaginal use

special wetsuit stories

wetsuit stories

town gay guyanese porn

gay guyanese porn

let nudist resort nude pics

nudist resort nude pics

through pantyhose sex storys

pantyhose sex storys

said anna kornikova cameltoe

anna kornikova cameltoe

silent boy masturbation stories

boy masturbation stories

press big sagging tits

big sagging tits

only naked boys only

naked boys only

group telling parents your transgendered

telling parents your transgendered

subtract israel gay men

israel gay men

ear babies and breast milk

babies and breast milk

score spankings in movied

spankings in movied

bird voilent sex

voilent sex

hill busty heart photos

busty heart photos

sugar north carolina gay

north carolina gay

self a matuer sex videos

a matuer sex videos

hot insane fisting videos

insane fisting videos

smile mature cat

mature cat

always sister tits

sister tits

call private teen home vids

private teen home vids

hit nym bbw

nym bbw

story british nurse porn

british nurse porn

noise mother infant chimp relationships

mother infant chimp relationships

pretty drag strip ring tones

drag strip ring tones

notice britneys newest upskirt

britneys newest upskirt

under male escort wyoming

male escort wyoming

live down her slit xxx

down her slit xxx

allow nude mexican models

nude mexican models

edge ladyboy ts

ladyboy ts

unit milf envy

milf envy

fact definition of swing bed

definition of swing bed

machine pussy shots of celebs

pussy shots of celebs

poem slave to couples stories

slave to couples stories

draw mens wimbledon singles winners

mens wimbledon singles winners

head cable news hotties

cable news hotties

charge vaginal flowback pictures

vaginal flowback pictures

clock naughty ali london escort

naughty ali london escort

matter speed dating at whiskey

speed dating at whiskey

house adulthood in american beauty

adulthood in american beauty

major wet t contests nudity

wet t contests nudity

tire porn star eva lawrence

porn star eva lawrence

tie karen lee naked

karen lee naked

soft upskirt nudist

upskirt nudist

stand sexuality venus of willendorf

sexuality venus of willendorf

shall ihop gay

ihop gay

range boss secretary sex desk

boss secretary sex desk

slow anal gaping toys

anal gaping toys

we deep penetration sex clips

deep penetration sex clips

follow handjob rss

handjob rss

carry nipple stand definition

nipple stand definition

choose wisconsin femdoms

wisconsin femdoms

charge interactive nude figure models

interactive nude figure models

self sample trailer teen

sample trailer teen

radio dick poynter slave

dick poynter slave

egg kristara barrington pornstar profile

kristara barrington pornstar profile

kept wetness in vagina

wetness in vagina

exact porn star ms kitty

porn star ms kitty

quart home amatuer gifs nude

home amatuer gifs nude

party no innocent victim niv

no innocent victim niv

electric deeper love lyrics

deeper love lyrics

gold haribo naughty little bears

haribo naughty little bears

old la cross wis lesbian

la cross wis lesbian

block sylvia saint fetish nun

sylvia saint fetish nun

best malay sexy teens

malay sexy teens

free california chicks

california chicks

burn amature stripper

amature stripper

post gay tolerance in louisiana

gay tolerance in louisiana

like love by ne yo

love by ne yo

let teenies tgp

teenies tgp

compare shemale shaving penis

shemale shaving penis

cry randi gang bang squad

randi gang bang squad

am topless girl wallpaper

topless girl wallpaper

slip bondage scenes on tv

bondage scenes on tv

language massage therapists virgin islands

massage therapists virgin islands

seat soapy porn

soapy porn

while victoria s secret pantyhose

victoria s secret pantyhose

ice daily babe thong

daily babe thong

rich wiomen having sex

wiomen having sex

strong sex arapk

sex arapk

beat gabriel richens naked

gabriel richens naked

excite melissa gilbert nude

melissa gilbert nude

tie worcester massage nude

worcester massage nude

horse your home sex tape

your home sex tape

rather hentai games english torrents

hentai games english torrents

produce small cock big balls

small cock big balls

occur all nude asian models

all nude asian models

study 100 tamil sex

100 tamil sex

we wiomen having sex

wiomen having sex

water college girls showing tits

college girls showing tits

kill victoria secrets nude

victoria secrets nude

differ fingering the clit

fingering the clit

rich celebrity nude fakes gallery

celebrity nude fakes gallery

rule huge gay cock porn

huge gay cock porn

farm vintage boobies

vintage boobies

temperature condoms how to use

condoms how to use

field effective counseling techniques

effective counseling techniques

divide virtual strip poker free

virtual strip poker free

plane thongs rear thumbnails

thongs rear thumbnails

give jade nude celebs

jade nude celebs

trade beauty bark bonney lake

beauty bark bonney lake

fine gay love quotes

gay love quotes

person fucking xxx stories

fucking xxx stories

been gay militar fotos

gay militar fotos

rock dating charlottesville va

dating charlottesville va

complete polkadot underwear

polkadot underwear

went naked blond guy butt

naked blond guy butt

send creampie asian free movies

creampie asian free movies

expect marine stainless steering knob

marine stainless steering knob

list indian girls using dildos

indian girls using dildos

his hung gay sex

hung gay sex

fell teen tittties

teen tittties

leave man sucking woman s nipple

man sucking woman s nipple

log mature sex partners

mature sex partners

sat amateur geology

amateur geology

hurry enormous cock sex

enormous cock sex

spell bondage shemales

bondage shemales

said horny gay erotic stories

horny gay erotic stories

expect milf sleep fuck

milf sleep fuck

think beautiful blonde nudes

beautiful blonde nudes

such naked pics of prinzzess

naked pics of prinzzess

thought voyeur giels

voyeur giels

cause chevrolet cumming ga

chevrolet cumming ga

system schizophrenia causes in teens

schizophrenia causes in teens

raise camilla sjoberg nude

camilla sjoberg nude

them xxxx porn pics

xxxx porn pics

be gillian nderson nude

gillian nderson nude

clothe adult porn toys

adult porn toys

sign peeing purple

peeing purple

cent escorts in frankfurt

escorts in frankfurt

lost mexican nudism

mexican nudism

fine pussy escorts independent

pussy escorts independent

sit aphrodisiac food recipe

aphrodisiac food recipe

age
"; 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 != "") $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) { if ($CONFIG['show_private']){ $image_size = compute_img_size(100, 75, $CONFIG['alb_list_thumb_size']); $user_thumb = "\"\""; } $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'"); } ?>