Giter VIP home page Giter VIP logo

fileupload's People

Contributors

cloudratha avatar hugodias avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fileupload's Issues

Confirm box on file delete

I have successfully added a simple javascript confirm on the file delete button, but when I press cancel it deletes the file anyway. Is there any other way I can get this to work?

JqueryFileUpload

thankyou for ur plugin..
i have downloaded your cakephp-JqueryFileUpload. buttons are displaying correctly.
If i add the file, the file is not displaying.. i used the plugin in my previous cakephp project...
please help me.., why the file list is not displaying..?

Internal Server Error

When i tried to upload a file i got and Error = Internal Server Error.
I already give access to write to the App/Webroot/Files directory.
Any Ideas ?

Responsive design

Not sure if this is the right place to leave this.

I editted the UploadFormHelper so that it would be more responsive and act more like Blueimp's design. The reason was that with Bootstrap enabled, the item table would extend past my mobile screen. The progress bar was also either very small or non-existant.

Here is the updated code:

    private function _loadScripts()
{
    echo '<script id="template-upload" type="text/x-tmpl">
    {% for (var i=0, file; file=o.files[i]; i++) { %}
        <tr class="template-upload fade">
            <td class="preview"><span class="fade"></span></td>
            <td>
            <div class="name"><span>{%=file.name%}</span></div>
            <div class="size"><span>{%=o.formatFileSize(file.size)%}</span></div>
            {% if (file.error) { %}
                <td class="error" colspan="2"><span class="label label-important">{%=locale.fileupload.error%}</span> {%=locale.fileupload.errors[file.error] || file.error%}</td>
            {% } else if (o.files.valid && !i) { %}
                <div>
                    <div class="progress progress-success progress-striped active"><div class="bar" style="width:0%;"></div></div>
                </div>
                </td>
                <td>
                <div class="start">{% if (!o.options.autoUpload) { %}
                    <button class="btn btn-primary">
                        <i class="icon-upload icon-white"></i>
                        <span>{%=locale.fileupload.start%}</span>
                    </button>
                {% } %}</div>
            {% } else { %}
                <td colspan="2"></td>
            {% } %}
            <div class="cancel">{% if (!i) { %}
                <button class="btn btn-warning">
                    <i class="icon-ban-circle icon-white"></i>
                    <span>{%=locale.fileupload.cancel%}</span>
                </button>
            {% } %}</div>
            </td>
        </tr>
    {% } %}
    </script>

Basically changed the td to div and removed some code. Scales perfectly now.

I had to disable the Security csrfCheck to allow the photo to be uploaded.

I had to disable CakePHP Security csrfCheck to allow photo to be uploaded.

After clicking Add File and selecting photo, the photo thumbnail showed, but I got "Error Bad Request" inline error message. The CakePHP error log showed the action was blackholed indicating 'csrf'.

A check CakePHP docn http://book.cakephp.org/2.0/en/core-libraries/components/security-component.html indicated i needed to disable the Security for this operation using $this->Security->csrfCheck = false;

This was put in the beforeFilter() of HandlerController as follows:

function beforeFilter(){
    parent::beforeFilter();
    $this->Auth->allow("*");
    $this->Security->csrfCheck = false;
}

Upload Model not found

I've found a small issue in the UploadComponent on line 27.

You've got:
$this->UploadModel = ClassRegistry::init('Upload');

but because it's a plugin, you're not loading the Upload model within your plugin but the default AppModel of the application you're running. Changes made in the plugins Upload model will be useless because that's not the model you're using.

Change it to:

$this->UploadModel = ClassRegistry::init('FileUpload.Upload');

In this case you are using the Upload model inside the plugin so changes (like $useTable) will have it's effects when you want it to.

Problem

Hi, I am trying to use this pluging, but when I try to access the start controller I receive this message:

Fatal error: Call to a member function allow() on a non-object in /Users/alexleandro/Sites/picstik/app/Plugin/FileUpload/Controller/FileUploadController.php on line 6

I try to call http://localhost:8888/picstik/file_upload

What could be?

json response issue with IE8

I am using your plugin and everything works great in FF, Chrome, etc. When I try to upload a file using IE8, I get an error response saying empty file upload. When I check my folder, the file was successfully uploaded, and when I refresh my browser, the file is there. The error happens just immediately after it uploads the file and tries to send back the file information to the browser.

Using in other views.

How would I go about using this say if I have baked Products
so in /app/View/Products/add.ctp

Essentially I want to be able to upload images specific to this product.

(as standalone form the plugin works just fine like domain.com/file_upload)

Thanks

Strange error every time saved in log file

2013-09-03 13:30:27 Error: [MissingActionException] Action AppController::webroot() could not be found.
Exception Attributes: array (
'controller' => 'AppController',
'action' => 'webroot',
)
Request URL: /cakecms/app/webroot/thumb/p7.png
Stack Trace:
#0 D:\XAMP\htdocs\cakecms\lib\Cake\Routing\Dispatcher.php(187): Controller->invokeAction(Object(CakeRequest))
#1 D:\XAMP\htdocs\cakecms\lib\Cake\Routing\Dispatcher.php(162): Dispatcher->_invoke(Object(AppController), Object(CakeRequest), Object(CakeResponse))
#2 D:\XAMP\htdocs\cakecms\app\webroot\index.php(110): Dispatcher->dispatch(Object(CakeRequest), Object(CakeResponse))
#3 {main}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.