My model is composed by some text fields and an image. In the database the image is not saved like a blob field but like a text field. So when I uploaded the file I want to store the file link.
I found a cookbook tutorial that explain how to upload an image http://www.yiiframew...doc/cookbook/2/ but I have some questions.
Where can i find the method saveAs ? How this method save the file? ( have I to pass only the folder path or the folder path plus the file name to store? )
So my problem is: I have to store the file, take the url where the file is stored and save it into the database.
Some hints?
Page 1 of 1
Upload a file and save the link
#2
Posted 06 April 2009 - 05:34 AM
Ok i make some tests and it's ok
i resolve myself my problems
Thank you anyway
Thank you anyway
#3
Posted 06 April 2009 - 05:49 AM
ok to stay in topic. Yii offer something to autoresize the image?
#4
Posted 06 April 2009 - 02:46 PM
No, Yii doesn't offer this. You can use this extension: Kohana Image library
Share this topic:
Page 1 of 1

Help

This topic is locked












