Difference between #4 and #5 of
XUpload Workflow

Revision #5 has been created by Asgaroth on Nov 8, 2012, 10:30:45 PM with the memo:

file hinting
« previous (#4)

Changes

Title unchanged

XUpload Workflow

Category unchanged

Tutorials

Yii version unchanged

Tags unchanged

xupload, Forms, Widgets, tutorial

Content changed

[...]
------------------
First we need to create the action that will show the form to the user:


```php
// application/controllers/FancyController.php
 
 
public function actionForm( ) {
$model = new SomeModel;
Yii::import( "xupload.models.XUploadForm" );
[...]
```php
// application/views/fancy/form.php
 
 
<fieldset>
<?php
$form = $this->beginWidget('CActiveForm', array(
[...]
```php
<?php
// application/controllers/FancyController.php
 
 
public function actionUpload( ) {
Yii::import( "xupload.models.XUploadForm" );
//Here we define the paths where the files will be stored temporarily
[...]
```php
<?php

 
// application/controllers/FancyController.php
 
 
public function actionForm( ) {
$model = new SomeModel;
Yii::import( "xupload.models.XUploadForm" );
$photos = new XUploadForm;
//Check if the form has been submitted
if( isset( $_POST['SomeModel'] ) ) {
[...]
28 0
43 followers
Viewed: 76 530 times
Version: 1.1
Category: Tutorials
Written by: Asgaroth
Last updated by: Asgaroth
Created on: Jul 2, 2012
Last updated: 5 years ago
Update Article

Revisions

View all history