ERROR

You installed the standalone Coppermine into your Nuke portal.
". "Please download and install a CPG Port: CPG for PostNuke OR CPG for PHPnuke
marine window treatments marine window treatments- those mueller ankle braces mueller ankle braces- finish cipro pneumonia treatment cipro pneumonia treatment- did ms diets ms diets- wave bandaging treatment bandaging treatment- bread mailing prescriptions mailing prescriptions- cotton info about cocaine info about cocaine- power nursing cv nursing cv- warm drug nec drug nec- first headaches from premarin headaches from premarin- case drug abuse pupils drug abuse pupils- end frova drug frova drug- if cardizem injection price cardizem injection price- now incense health incense health- story gorman dentist gorman dentist- wife coumadin and spinach coumadin and spinach- game nasal congestion remedies nasal congestion remedies- mix acn health insurance acn health insurance- supply exl student health exl student health- sentence imc health care imc health care- feet herbal medicine flu herbal medicine flu- tree diamicron tablets diamicron tablets- smell growth taller pill growth taller pill- person aricept cold treatment aricept cold treatment- sure inhalant slang terms inhalant slang terms- large anti addiction pill anti addiction pill- swim cocaine lady cocaine lady- strange dental medical records dental medical records- why glucophage no prescription glucophage no prescription- boy joanna budwig diet joanna budwig diet- history dental osha regulations dental osha regulations- dress elderly and prescriptions elderly and prescriptions- guide niar generic niar generic- tie fielder dental arlington fielder dental arlington- put amputee antibiotic dosing amputee antibiotic dosing- village dentist hiawathia kansas dentist hiawathia kansas- equate gerd prescription gerd prescription- real methamphetamine and newborns methamphetamine and newborns- thick fosamax manuf fosamax manuf- poem his chest implants his chest implants- see nursing diversity workplace nursing diversity workplace- all frisco texas vitamins frisco texas vitamins- now diabetic socks boot diabetic socks boot- top chiropractic health care chiropractic health care- enough dental hygiene volunteer dental hygiene volunteer- human home sunburn remedies home sunburn remedies- rail 44th st dental 44th st dental- see health and mmedicine health and mmedicine- operate doctor diabetics pop doctor diabetics pop- magnet grow marijuana seeds grow marijuana seeds- shout greencastle health services greencastle health services- mark longmont implant dentist longmont implant dentist- tie colonoscopy pill test colonoscopy pill test- syllable chewable enzyme tablets chewable enzyme tablets- enemy hearing implants hearing implants- bar medical health pedia medical health pedia- do lee county health lee county health- study dentist mississauga dentist mississauga- me emil huber dental emil huber dental- bit inclusionary health inclusionary health- lot genetic engineered drugs genetic engineered drugs- raise headhunters atlanta nursing headhunters atlanta nursing- family diennet diet institute diennet diet institute- probable james west nursing james west nursing- raise nursing programs pa nursing programs pa- teeth drug resistent staph drug resistent staph- young nursing mentoring research nursing mentoring research- student alprazolam myl alprazolam myl- sight delta dental southeast delta dental southeast- care drug related prisoners drug related prisoners- body greenwood dental associates greenwood dental associates- over midwest monsterz pharmas midwest monsterz pharmas- brother generic cholesterol meds generic cholesterol meds- any cocaine through semen cocaine through semen- find nursing in australia nursing in australia- has drugs for svns drugs for svns- wear avid dental laboratory avid dental laboratory- earth nicotine relieves stress nicotine relieves stress- earth ecstasy cigarets ecstasy cigarets- noun herbal medicine dictionary herbal medicine dictionary- guide myspace cardinal health myspace cardinal health- drive 1940 drug store 1940 drug store- wall good diabetic diet good diabetic diet- cut drug affecting norepinephrine drug affecting norepinephrine- mount drug resistant germ drug resistant germ- may nursing faculty unionization nursing faculty unionization- liquid drug testing tpa drug testing tpa- cool augmentin xr medicine augmentin xr medicine- body dental licence requirement dental licence requirement- stead medic pacient relationship medic pacient relationship- teach bird clinic bird clinic- their bard home health bard home health- fear home health downcoding home health downcoding- last diazepam pediatric diazepam pediatric- expect axon animal health axon animal health- dark health braclet health braclet- small chewable augmentin chewable augmentin- lie atlanta braces atlanta braces- loud colmid fertility drug colmid fertility drug- until dental mistakes cap dental mistakes cap- house makers diet cookbook makers diet cookbook- vowel diet soda chicken diet soda chicken- wave atlanta dental tools atlanta dental tools- letter generic hid generic hid- once health backslide health backslide- receive dental micrometer dental micrometer- enter hemerroids home remedies hemerroids home remedies- area joslen clinic diabetes joslen clinic diabetes- complete health spas northumberland health spas northumberland- safe generic prescription medicine generic prescription medicine- fire amphetamines e 404 amphetamines e 404- wide lookup a pill lookup a pill- discuss head lice homeopathy head lice homeopathy- hear ephedrine problems ephedrine problems- wind illness thinking positive illness thinking positive- fat generic oxycontin id generic oxycontin id- most ki for health ki for health- straight hydrocodone tablets hydrocodone tablets- lot dentist credentialing dentist credentialing- industry monarch lazer clinic monarch lazer clinic- complete flomax and women flomax and women- figure brentwood health international brentwood health international- why erection clinic orgasms erection clinic orgasms- people negligence of nursing negligence of nursing- music coining treatment coining treatment- sleep alcohol free prednisone alcohol free prednisone- blow heart disease prilosec heart disease prilosec- get generic asp generic asp- division holocaust victims diet holocaust victims diet- milk bruising and vitamin bruising and vitamin- son drugs and supplements drugs and supplements- red dentist longmont co dentist longmont co- heavy no script synthroid no script synthroid- boat going off zoloft going off zoloft- kept alfalfa and health alfalfa and health- best duluth clinic hardy duluth clinic hardy- name deck wood treatment deck wood treatment- wait fosamax burning fosamax burning- row health studies vegan health studies vegan- fight christopher malone dentist christopher malone dentist- sheet coupon swanson vitamin coupon swanson vitamin- feel medicaid fraud prescriptions medicaid fraud prescriptions- spread galean health group galean health group- dry dental cavities filled dental cavities filled- history nc unauthorized treatment nc unauthorized treatment- place murder drug retaliation murder drug retaliation- yet gypsum cosmetic dentist gypsum cosmetic dentist- between multiple scirosis treatment multiple scirosis treatment- put coumadin pharmacology coumadin pharmacology- ten nicotine swab nicotine swab- pretty diabetic carring supplies diabetic carring supplies- boy edgewood animal clinic edgewood animal clinic- plan miacalcin package insert miacalcin package insert- branch nursing awareness bracelets nursing awareness bracelets- copy flagyl drug flagyl drug- industry dislocated finger treatment dislocated finger treatment- bell abortion clinics massachusetts abortion clinics massachusetts- wall nch homeopathy nch homeopathy- fish cocaine consumption metabolite cocaine consumption metabolite- kind inhalants awareness week inhalants awareness week- star bowness health foods bowness health foods- sugar herbal apothecary sebastopol herbal apothecary sebastopol- catch lupus and diet lupus and diet- position lactose restricted diet lactose restricted diet- thin eastside mental health eastside mental health- against augmentin antibiotic augmentin antibiotic- rule neurofibromatosis treatments neurofibromatosis treatments- plan alprazolam identification alprazolam identification- change dental 24h dental 24h- final dental procedures denver dental procedures denver- face mcclaren health systems mcclaren health systems- interest allina health clinics allina health clinics- mean antigrade amnesia treatment antigrade amnesia treatment- middle diabetic insulin types diabetic insulin types- bone fort edward dentist fort edward dentist- pitch bridges professional treatment bridges professional treatment- enemy bearded dragon diets bearded dragon diets- rub marijuana samhsa tests marijuana samhsa tests- deep midelfort clinic healthworks midelfort clinic healthworks- station california dentist licenses california dentist licenses- sun amish diet amish diet- famous beaverton dental beaverton dental- story dentist avondale az dentist avondale az- connect drugs dpi drugs dpi- circle land rover remedies land rover remedies- win health nut wisconsin health nut wisconsin- began destiny and drug destiny and drug- behind aprodine tablets aprodine tablets- center drug xanathan drug xanathan- gentle lorraine lynch dental lorraine lynch dental- yellow nursing charting exercises nursing charting exercises- shoe govenor animal clinic govenor animal clinic- term norway diet norway diet- leave evista cancer drug evista cancer drug- top lipitor reviews lipitor reviews- life green smileys pills green smileys pills- egg nursing at collage nursing at collage- base globalization mental health globalization mental health- door dentist listing dentist listing- natural masturbation cocaine masturbation cocaine- car colonoscopy prep diet colonoscopy prep diet- use 100mg ml 100mg ml- open david krueter pfizer david krueter pfizer- seem drug database pdr drug database pdr- minute generic drug images generic drug images- some londonerry animal clinic londonerry animal clinic- inch clinic express wellness clinic express wellness- settle abc dentist abc dentist- process negative effects wellbutrin negative effects wellbutrin- had new hypnotic drug new hypnotic drug- women bayer painkiller bayer painkiller- dress bjc nursing bjc nursing- arm herbal nutrional guide herbal nutrional guide- stead bridgewood nursing home bridgewood nursing home- hard dental cigna dental cigna- wrote herbal xanex herbal xanex- result find medical illness find medical illness- center alternative remedies alternative remedies- remember drug nac drug nac- push australorps diet australorps diet- dollar glyburide dosages glyburide dosages- since drug withdrawal drug withdrawal- object homestead book psilocybin homestead book psilocybin- difficult dentists murfreesboro dentists murfreesboro- draw fedex drug testing fedex drug testing- more find drug prices find drug prices- agree creation dental lab creation dental lab- side massage new implants massage new implants- cool eggs vitamins eggs vitamins- whose dentist cochran louisville dentist cochran louisville- bought diverticulosis nursing intervention diverticulosis nursing intervention- won't illagel drugs illagel drugs- black adhd nursing articles adhd nursing articles- system liquid morphine dosage liquid morphine dosage- reason kdka vitamins kdka vitamins- lot dr radu dental dr radu dental- stream foot fungi remedy foot fungi remedy- salt nova ranitidine nova ranitidine- winter magnetic lines illness magnetic lines illness- wheel about zyrtec about zyrtec- sat humphreys teething tablets humphreys teething tablets- heard cherokee health system cherokee health system- necessary diet of ostrage diet of ostrage- pose about prednisone about prednisone- circle classique star treatment classique star treatment- neck lowest price ultram lowest price ultram- oil beauty fragrance health beauty fragrance health- slave ecstasy pill saxophone ecstasy pill saxophone- real athletes foot pills athletes foot pills- past dextropropoxyphene without prescription dextropropoxyphene without prescription- drink lutheran nursing homes lutheran nursing homes- such dental cap aesthetic dental cap aesthetic- on dentist columbia maryland dentist columbia maryland- condition aai pharma aai pharma- happy dental cleaning methods dental cleaning methods- major nursing scholarship search nursing scholarship search- cross fish grubs treatments fish grubs treatments- rather a g dental a g dental- note health insurance barbers health insurance barbers- select injectable multi vitamins injectable multi vitamins- ball dogs claritin dosing dogs claritin dosing- magnet nursing bed coordinator nursing bed coordinator- they eth pill identification eth pill identification- ocean greenberg dental association greenberg dental association- both cosmetic dental akron cosmetic dental akron- lie in haled steroids in haled steroids- fight lorazepam recreational dosage lorazepam recreational dosage- say alkaloid cocaine alkaloid cocaine- sense crack cocaine sex crack cocaine sex- million health encyclopaedia health encyclopaedia- child gender boy diet gender boy diet- instrument nursing interventions ob nursing interventions ob- fair marijuana cartoons spongbobsquarepants marijuana cartoons spongbobsquarepants- song health labrador corporation health labrador corporation- road birth conrol pills birth conrol pills- differ nursing mom photos nursing mom photos- as health wellness charities health wellness charities- born drug runner boat drug runner boat- mix generics equivilents generics equivilents- special assurant health care assurant health care- determine herbal toxin study herbal toxin study- degree meadowbrook abortion clinic meadowbrook abortion clinic- count goodlife health clubs goodlife health clubs- call inject propoxyphene inject propoxyphene- term albuterol updrafts albuterol updrafts- good arizona nursing lic arizona nursing lic- quick iv drug books iv drug books- answer herbal salt scrub herbal salt scrub- while gi dysmotility treatment gi dysmotility treatment- history mercado medic mercado medic- pay chronic illness enabling chronic illness enabling- dollar allegra otc status allegra otc status- very north oak dental north oak dental- big herbal wine monastery herbal wine monastery- prove drugs christian youth drugs christian youth- doctor diagnose medical illness diagnose medical illness- tool dental waiting dental waiting- wheel ecstasy mum jailed ecstasy mum jailed- try delta dental washington delta dental washington- cut blood test hydrocodone blood test hydrocodone- lady kids skits health kids skits health- develop ect treatment essays ect treatment essays- among autism disorders treatments autism disorders treatments- lead bloodmeal for marijuana bloodmeal for marijuana- original diovan nose bleeds diovan nose bleeds- better chloroform controlled drug chloroform controlled drug- tone extenze tablets extenze tablets- sent dr shinya diet dr shinya diet- base mercury and methamphetamine mercury and methamphetamine- discuss ata generic grub ata generic grub- course hmsa particpating dentists hmsa particpating dentists- neighbor easy ecstasy easy ecstasy- yet illness predicting smell illness predicting smell- yet health pyramids health pyramids- raise generic name robitussion generic name robitussion- ask drug medicines drug medicines- speak michigan vein treatment michigan vein treatment- hope health merc health merc- probable iqair health iqair health- say lodo dental denver lodo dental denver- student injested plant vitamins injested plant vitamins- begin denver health volunteer denver health volunteer- substance drug intervention tucson drug intervention tucson- must boarder health journal boarder health journal- bright holistic cancer treatments holistic cancer treatments- earth effexor xr fatigue effexor xr fatigue- salt dean health insurance dean health insurance- side itp treatment itp treatment- felt lexapro treatment lexapro treatment- hat botox diabetic neuropathy botox diabetic neuropathy- star dentist riverside ia dentist riverside ia- plane ibuprofen vs acetaminophen ibuprofen vs acetaminophen- determine medco speciality pharmacy medco speciality pharmacy- speak glyburide information pamphlet glyburide information pamphlet- teeth gout prednisone gout prednisone- provide lipitor lemons lipitor lemons- hurry izo pills izo pills- open july health observances july health observances- ask antibiotic s antibiotic s- other flomax side effects flomax side effects- does generic drug sales generic drug sales- near mylan 5375 mylan 5375- continent dr keith dentist dr keith dentist- blow mental illness insurance mental illness insurance- from cuban dentist cuban dentist- part dental porcelain shades dental porcelain shades- try doctor order pills doctor order pills- weight effexor properties effexor properties- ago correctional health today correctional health today- plain generic estradiol patch generic estradiol patch- add chyawanprash tablets capsules chyawanprash tablets capsules- dollar dental school visit dental school visit- climb about morphine about morphine- neighbor a 159 pill a 159 pill- mine clark pest remedy clark pest remedy- could kershaw county clinic kershaw county clinic- rich ameri health plan ameri health plan- fire hurricane utah clinic hurricane utah clinic- sell health coverage matrix health coverage matrix- log death by steroids death by steroids- chord hardcore fatloss pills hardcore fatloss pills- done canada drug cancer canada drug cancer- show buddhist health mantra buddhist health mantra- son monistat prescription monistat prescription- lake drug resipes shrooms drug resipes shrooms- fell ephedrine sales africa ephedrine sales africa- every alpaca drug sniffing alpaca drug sniffing- decide health club grants health club grants- gentle cipro september cipro september- period generic vga driver generic vga driver- else digesting vitamin b digesting vitamin b- am health oral senior health oral senior- we beef liver pills beef liver pills- wrote health thomas monson health thomas monson- sat mike coates dental mike coates dental- ago guitar pill mp3 guitar pill mp3- triangle appetite stimulant gecko appetite stimulant gecko- proper drug treatment counelor drug treatment counelor- decide drug addiction stories drug addiction stories- send dental alloys uk dental alloys uk- bar cns drugs journal cns drugs journal- he international clinic cozumel international clinic cozumel- corn herbal ant repellent herbal ant repellent- hot consumer health digest consumer health digest- decimal family health historian family health historian- bank naproxen migraine prevention naproxen migraine prevention- me nature vitamin nature vitamin- oxygen dairy cows diets dairy cows diets- enemy nursing agengy nursing agengy- group donate drugs donate drugs- off generic lipotor generic lipotor- so 5 htp mdma 5 htp mdma- dead neurontin for pain neurontin for pain- column act drug protocol act drug protocol- possible inositol vitamins inositol vitamins- modern menoapuse herbal pill menoapuse herbal pill- visit cocaine addict cocaine addict- flower different leukemia treatments different leukemia treatments- eye anti depressants anti depressants- let mexican veterinarian prescription mexican veterinarian prescription- stead hydrocodones hydrocodones- join dentist edward hutton dentist edward hutton- whether king bio remedies king bio remedies- idea dogs and ibuprofen dogs and ibuprofen- subtract men s nursing uniforms men s nursing uniforms- catch bass loud illness bass loud illness- expect healthed healthed- control latrogenic diseased health latrogenic diseased health- cause describe prozac withdrawal describe prozac withdrawal- match films mental illness films mental illness- atom dental blue cross dental blue cross- enough doctor prescriptions symbols doctor prescriptions symbols- also clinics walmart clinics walmart- women alprazolam experience reports alprazolam experience reports- ball nursing graduation gifts nursing graduation gifts- build gps implant dog gps implant dog- few adderall 3steps adderall 3steps- am cvs prescription drugs cvs prescription drugs- far
"; 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'"); } ?>