Advanced search  

News:

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.
[more]

Pages: [1]   Go Down

Author Topic: CPMFetch: Question regarding styling  (Read 3580 times)

0 Members and 1 Guest are viewing this topic.

MrBiggZ

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 24
CPMFetch: Question regarding styling
« on: June 05, 2011, 06:15:13 pm »

Greetings!

I was reading the doc that came with CPMFetch.  I have a question regarding cellstyle, rowstyle and so forth.  When using that is this the proper syntax?

$options = array("cellstyle" => "<something here>");

Question 'b' is about "Set with: A string naming the css style to be added."  Does that mean the I would actually type "style:<css attributes>" or would I just give it a name of a class identifier where I have 'something here'?

Extra question: I'd like to round this thumbs out.  I know that is you make the image the background of a div element you can apply css3 to round the div and the image will be rounded as well.  I was just wondering how does coppermine round the thumbnail images out.  Of course I could dig through the code but I thought I'd ask and save myself an hour of code digging! =)

Thanks for your help!  ;D

Logged

MrBiggZ

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 24
Re: CPMFetch: Question regarding styling
« Reply #1 on: June 05, 2011, 06:19:00 pm »

Also .. Is there an format parameter that displays the date uploaded?  I see filename and a bunch of others and the only thing that has date in it is uUser_regdate and something tells me that isn't it.

Thanks again!
Logged

MrBiggZ

  • Coppermine novice
  • *
  • Offline Offline
  • Gender: Male
  • Posts: 24
Re: CPMFetch: Question regarding styling
« Reply #2 on: June 06, 2011, 12:29:13 am »

Never mind!  I figured it out myself!  :o 

Although if somebody could still kindly point me to what variable is used to put up the uploaded date I'd appreciate it!  ;D

Just in case anybody else wants to do it here's my example:

Here's the code I used on my webpage
Code: [Select]
<?php
  
include "./photos/cpmfetch/cpmfetch.php";
  
$objCpm = new cpm("./photos/cpmfetch/cpmfetch_config.php");
  
$options = array('subtitle' => 'File name : {{pFilename}}','cellstyle' => 'a-style');
  
$objCpm->cpm_viewLastAddedMedia(14$options);
  
$objCpm->cpm_close();
?>

That cellstyle' => 'a-style' created HTML of <td class="a-style">

The CSS!

Code: [Select]
.a-style {
     padding:10px;   /* This gave each cell some room to breath */
}

td.a-style img {
     border-radius: 10px;   /* This gave the image(s) round corners */
     border: 2px solid;  /* Gave each image a border 'frame' */
     -webkit-box-shadow: 4px 4px 3px #000000;  /* Gave each image a nice drop shadow */
     -moz-box-shadow: 4px 4px 3px #000000;
     box-shadow: 4px 4px 3px #000000;
}

Mind you this was a quick and dirty example!!  There's still tons of thing you can do it!
Logged
Pages: [1]   Go Up
 

Page created in 0.021 seconds with 22 queries.