Hi,
I have this page:
www.therightpic.com (http://www.therightpic.com)
If you look at the bottom of the page I have a list of my albums. I am using the following code to display this:
<?php
$albumsCpm = new cpm("./cpg1.4.11/cpmfetch/cpmfetch_config.php");
$options = array("imageattributes" => array("height" => "90", "width"=>"120"));
$albumsCpm->cpm_showAlbumsUpdatedOverLastDays("365", $options);
?>
I want to put each album listing and thumbnail from the array that this uses into a table cell. In other words, I want to make this pretty, formatted into a nice table with a single (or maybe double) column and each album listing in its own cell on its own row. Is this possible? I have been fiddling with PHP arrays and reading the documentation but I can't figure it out.
I know I can use html tables or CSS to format this but how do I get each element in its own cell?
Quote from: therightpic on August 24, 2007, 06:19:22 PM
Hi,
I have this page:
www.therightpic.com (http://www.therightpic.com)
If you look at the bottom of the page I have a list of my albums. I am using the following code to display this:
<?php
$albumsCpm = new cpm("./cpg1.4.11/cpmfetch/cpmfetch_config.php");
$options = array("imageattributes" => array("height" => "90", "width"=>"120"));
$albumsCpm->cpm_showAlbumsUpdatedOverLastDays("365", $options);
?>
I want to put each album listing and thumbnail from the array that this uses into a table cell. In other words, I want to make this pretty, formatted into a nice table with a single (or maybe double) column and each album listing in its own cell on its own row. Is this possible? I have been fiddling with PHP arrays and reading the documentation but I can't figure it out.
I know I can use html tables or CSS to format this but how do I get each element in its own cell?
I am thinking at this point you may be best getting back the data from cpmfetch and creating the table yourself - that gives you the most control. Will require some basic PHP experience
Vuud,
Thanks for replying. I have enjoyed playing around with CPMFetch and incorporating parts of it into my site. It is very useful. Thank you for taking the time to create it.
So, what you are saying is that instead of using your built in function "cpm_showAlbumsUpdatedOverLastDays" that I should just use the CPMFetch database connection and query for my albums and then feed the results into a dynamic html table?
Am I understanding you correctly?