andrew valums ajax upload to codeigniter |
[eluser]runrun[/eluser]
Hello, http://valums.com/ajax-upload/ Did anyone successfully implement andrew valums's upload to codeigniter ? Would you like to give me some tips ? My problem implementing is, the script sends a query string to server instead of segment URI, therefore, I don't know how to handle with codeigniter.
[eluser]SPeed_FANat1c[/eluser]
I have used it few months ago and I guess this was then older version of this plugin. It worked with post. I did not find any code line where I enable post or something like that. Maybe in new version it is something differrent. Edit: Just took a look at the chrome console, when I upload it writes : Failed to load resource and on the right side the url to the upload function. But it still works ![]()
[eluser]Danes[/eluser]
To use this you will need to enable query strings as explained here: http://ellislab.com/codeigniter/user-gui.../urls.html . Check this post: http://ellislab.com/forums/viewthread/177158/ Sorry, the forum does not currently allow the posting of links.
[eluser]seibelj[/eluser]
Here's how to use the latest Valums Ajax Uploader with the progress bar: Download latest one here: http://valums.com/ajax-upload/ Extract the download. In the extracted folder is the server folder, and inside that is a file named php.php Put php.php in your application/libraries folder and rename it qquploadedfilexhr.php Delete the final lines that are not part of any class (line 154 and after in my version). Create a controller function for where you want the uploader action to be. Inside the function put this code: Code: $this->load->library('qquploadedfilexhr'); Change the file extensions and size to what you want, and you MUST put in the correct path to the upload folder (mine is /var/www/website-name/www/uploads). Include the javascript and CSS files on your page, and this in your markup where you want the upload button: Code: <div id="file-uploader"> Create a new javascript file and put this in it, and include it on your page: Code: $(document).ready(function() { Change action: 'FULL PATH TO UPLOAD FUNCTION' to the server route, like http://localhost/index.php/controller_na...d_function. This works fine for me, let me know if you have any problems. Make sure to increase the max file upload size in php.ini to the max size you set for the upload, or you'll get an error.
[eluser]runrun[/eluser]
I've no longer used this upload script, I have created an html5 upload script that suits my need better, and it's easier to use.
[eluser]seibelj[/eluser]
I don't think an HTML5 upload script will be backwards compatible with older versions of ANY browser, not just IE.
[eluser]predat0r[/eluser]
seibelj, can you tell me what to type for upload path because I cant figure out.. I use wamp at localhost so c:/wamp/www/sitename/.. and what to type if I go online? and cant see what are my server directories thanks!
[eluser]SPeed_FANat1c[/eluser]
$config['upload_path'] = './uploads/'; we use relational path for file uploading. In my example the uploads folder is in the root directory.
[eluser]predat0r[/eluser]
[quote author="SPeed_FANat1c" date="1305720196"]$config['upload_path'] = './uploads/'; we use relational path for file uploading. In my example the uploads folder is in the root directory.[/quote] thx!
[eluser]chamil sanjeewa[/eluser]
view Code: <div id="file-uploader-demo1"> controllers: Code: function multi_uplode() { Model : Code: <?php |
Welcome Guest, Not a member yet? Register Sign In |