Databases Reference
In-Depth Information
Uploading binary content
If we edit one row, we see the Binary - do not edit warning and a Browse… button.
The exact caption on this button depends on the browser. Even though editing is not
allowed, we can easily upload a text or binary file's contents into this blob column.
Let us choose an image file using the Browse button—for example, the logo_left.
png file in a test copy of the phpMyAdmin/themes/pmahomme/img directory located
on our client workstation. We now click on Go .
We need to keep in mind some limits for the upload size. Firstly, the blob column
size is limited to 64 KiB, but in Chapter 16 we will change the type of this column to
accommodate bigger images. Hence, phpMyAdmin reminds us of this limit with
the Max: 64KiB warning. Also, there could be limits inherent to PHP itself (refer to
Chapter 7 for more details). We have now uploaded an image inside this column for a
specific row.
We notice that BLOB - 4.9KiB is a link; it permits to download any binary data to
our workstation should the need arise.
If we put a check mark for the Show BLOB Contents display option, we now see the
following in the BLOB column type:
To really see the image from within phpMyAdmin,
refer to Chapter 16 .
 
Search WWH ::




Custom Search