Difference between #9 and #11 of
Saving files to a blob field in the database

Changes

Title unchanged

Saving files to a blob field in the database

Category unchanged

Tips

Yii version unchanged

Tags unchanged

File upload

Content changed

[...]
In the view we put the code:


```php
'value'=><? echo CHtml::link(my_link_name,array('displaySavedImage','id'=>$model->primaryKey)),; ?>
```
[...]
header('Cache-Control: must-revalidate, post-check=0, pre-check=0');
header('Content-Transfer-Encoding: binary');
header('Content-length: '.$model->
cv_file_size); header('Content-Type: '.$model->cv_file_type); header('Content-Disposition: attachment; filename='.$model->cvfile_name); echo $model->cv_file_content; } ``` Note *$_GET\['id'\]* as passed argument of loadModel function.
6 2
17 followers
Viewed: 79 752 times
Version: 1.1
Category: Tips
Written by: zaccaria
Last updated by: zaccaria
Created on: Nov 3, 2010
Last updated: 13 years ago
Update Article

Revisions

View all history