Advanced search  


cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.

Pages: [1]   Go Down

Author Topic: [cpg1.2.2b for phpNuke only]: Picture of the Week block  (Read 3429 times)

0 Members and 1 Guest are viewing this topic.


  • Coppermine newbie
  • Offline Offline
  • Posts: 1
[cpg1.2.2b for phpNuke only]: Picture of the Week block
« on: February 02, 2005, 06:12:48 am »

I'm posting this here, because i dont think i have permissions to post this in the hacks/mods forum. I've created a "Picture of the Week" block/module for my install of coppermine(v1.22b) in PHP Nuke. I'm posting in case anyone is interested. the code probably doesnt live up to the standards of the rest of the coppermine/nuke code because it doesnt really take advantage of the language features, and some things have been hardcoded that probably should be made more dynamic. I'll leave it up to you to make it better if you desire.

I created a new block to go on the index/portal in the center thatll show the "picture of the week", pic's of the week are stored in a table (nuke_weeklypic) with date, img src and url information. the picture will "go live" on the date stored in that table, and will stay alive until the date at which the next picture is set to go live, admins set these dates via a mod to displayimage.php which allows them to set a date when viewing a potential picture of the week, and clicking on the appropriate button to add that record to the table.

things created/modded:
a block, to go on the index/portal page with the picture of the week
a module to show all past pictures of the week (admins can see pictures in the queue that havent gone live yet)
mod to displayimage.php to add the form that will add a picture to the nuke_weeklypic table.

install procedure: create the nuke_weeklypic table by hand, fields: date (YYYY-MM-DD), url(char[255]), src(char[255])
copy files into proper place (you might not wanna use my displayimage.php, you should probably just copy my mod out and paste it into your file)

code isnt terribly clean, its being posted here in case there is interest in adding this feature or something like it to coppermine.
« Last Edit: February 02, 2005, 08:09:23 am by GauGau »
Pages: [1]   Go Up

Page created in 0.044 seconds with 18 queries.