The jquery plugin has been updated to a new version, the old wiki for the version this extension uses, has been mostly removed, many documentation and examples were lost, this is sad but not responsability of the extension, the old wiki with the old versione examples has been restored, so I’m opening a discussion, in wheter or not the extension should update to the current plugin version.
Take into account however, that the new jquery plugin does not have a complete wiki yet. mostly missing examples.
I haven’t tried the new version yet, nor could I found a list of either new features or bug fixes, so I don’t have a word here.
But I can tell that the lack of examples in the new version is a failure, many of the how-tos in the old version wiki are very common and used very often, forcing users to use the new version without this examples may lead into rejection of the extension for "lack of documentation".
What I propose ,is to keep the current version, until examples and extended documentation for the new version is added, time when it’d be more correct to upload the extension version.
Indeed there is a new plugin version, the version the extension currently uses its V4, I havent updated the extension yet, because i think the new version of the plugin lacks documentation, like the how tos avaliable for V4 thats why I havent updated yet. because people often come with this common issues, and without a wiki, i would have to provide examples or write the wiki myself, but im not the author of the plugin, and I dont use it often, so I dont really have the ability to write such a documentation. so I better stick to the V4 until the new version has better docs.
I vote for an update as well. I would be willing to help some, but I haven’t created an extension before.
I don’t think the extension can do this with the version of file upload contained in the assets folder. I think you will have to update to a later version in the V4 branch where “acceptFileTypes” is available as an option, or write your own callback function which tests the file type. If I’m wrong could someone please post how they did it. Thanks in advance.
Asgaroth, let me start by saying that this is a great extension!
Now i have a question, i dont know if i havent look very carefully but here is what i ended up doing. I tried to use:
<?php
Yii::import("xupload.models.XUploadForm");
class SiteController extends Controller {
public function actions() {
return array(
'upload' => array(
'class' => 'xupload.actions.XUploadAction',
'path' => Yii::app() -> getBasePath() . "/../images/uploads",
"publicPath" => Yii::app()->getBaseUrl()."/images/uploads",
'subfolderVar'=>false,
),
);
}
/**
* This is the default 'index' action that is invoked
* when an action is not explicitly requested by users.
*/
public function actionIndex() {
// renders the view file 'protected/views/site/index.php'
// using the default layout 'protected/views/layouts/main.php'
$model = new XUploadForm;
$this -> render('index', array('model' => $model, ));
}
/**
* This is the action to handle external exceptions.
*/
public function actionError() {
if ($error = Yii::app() -> errorHandler -> error) {
if (Yii::app() -> request -> isAjaxRequest)
echo $error['message'];
else
$this -> render('error', $error);
}
}
}
but it didnt work for me (the subfolderVar) it kept uploading to the path with ("mdY") name, now what i did was comment out this part of xuploadaction.php:
hi, i’m using your xupload extension. this extension is works great, my question is how to disable the jquery ui css? the jui css always loaded. thanks