Books 2005

=’2005-01-01′ AND date_read<='2005-12-31' AND meta_key='bookid' AND meta_value=perma AND post_id=ID ORDER BY Date_Read DESC"; $row = $wpdb->get_results($sql, ARRAY_A);

$yearbooks = sizeof ($row);
$yeardays = 365;
$avdays = number_format ($yeardays/$yearbooks, 2);

echo “

In 2005 I read $yearbooks books, an average of one every $avdays days.

“;

echo “

    “;
    $c = $yearbooks;
    foreach ($row as $book)
    {
    $dread =strtolower (date (“j/m/Y”,strtotime(rawurldecode($book[Date_Read]))));

    $st = strtotime ($book[post_date]);
    $sy = date (“Y”, $st);
    $sm = date (“m”, $st);
    $sd = date (“d”, $st);

    $slug = “/$sy/$sm/$sd/$book[post_name]/”;

    // $link = “http://www.amazon.co.uk/exec/obidos/ASIN/”.$book[uk_asin].”/nocto-21″;
    // $slink = //”http://www.amazon.co.uk/exec/obidos/external-search?tag=nocto-21&keyword=”.$book[First].”%20″.$book[Last].”&mode=books”;
    echo “

  • “;
    echo “$c. $book[Title] by $book[First] $book[Last] ($dread)”;
    echo “
  • “;
    $c–;
    }

    ?>

Start the discussion

Leave a Reply

Your email address will not be published. Required fields are marked *