Databases Reference
In-Depth Information
Another point to note: the
$cfg['ShowBlob']
parameter does not influence the
thumbnail's display - it can be set to
TRUE
or
FALSE
.
Links to an Image
To get a link without thumbnails, we use the
image/jpeg: link
transformation.
There are no transformation options. This link can then be used to view the
photograph (by left-clicking on the link) and then possibly download it (by
right-clicking on the photograph itself):
Date Formatting
We have a field named
date_published
in our
books
table; let's ensure that its
type is
DATETIME
. Then we set its MIME type to
text/plain
and the browser
transformation to
text/plain: dateformat
. The next step is to edit the row for the
'Future souvenirs' book, and enter
2003-01-01 14:56:00
in the
date_published
field
When we browse the table, we now see the field formatted. Moving the mouse over
the field reveals the unformatted original contents:
This transformation accepts two options. The first is the number of hours that will be
added to the original value. (By default, this is zero.) Adding the number of hours
can be useful if we
store
all the times based on
Universal Coordinated Time
(
UTC
)
but want to
display
them for a specific zone (UTC+5). The second option is the time
format we want to use, made from any PHP
strftime
parameters. So, if we put this
in the transformation options,
'0','Year: %Y'
, we will get:
Search WWH ::
Custom Search