Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Demo Screenshots #4

Closed
coxw opened this issue Jan 30, 2015 · 9 comments
Closed

Demo Screenshots #4

coxw opened this issue Jan 30, 2015 · 9 comments

Comments

@coxw
Copy link

coxw commented Jan 30, 2015

Would you be able to take some screenshots and put them in the readme? It's hard to know what the anticipated output is on this. For example, it doesn't look like you support the strongest feature of this JS plugin, https://blueimp.github.io/jQuery-File-Upload/. Checkout the Basic Plus UI view.

@SUKOHI
Copy link
Owner

SUKOHI commented Feb 2, 2015

Oh, sorry for the messy readme.
Because I originally published this package mainly for myself.
So I'll try to improve it in the future.
Thanks for a helpful advice.:)

@mamunhq
Copy link

mamunhq commented Apr 2, 2015

Can you also Upload a test complete project so any one can understand how its work. doc is not easy no understand. thanks

@SUKOHI
Copy link
Owner

SUKOHI commented Apr 3, 2015

Hi, mamunhq.
Thank you for your comment.
I added a folder named "example" and the folder has controller, view and route.
I hope the files will help you.:)

@mamunhq
Copy link

mamunhq commented Apr 3, 2015

Thanks :)

@mamunhq
Copy link

mamunhq commented Apr 3, 2015

@SUKOHI i need one more information line when i want to save this multiple image to database with outhers form value how can i save?

@SUKOHI
Copy link
Owner

SUKOHI commented Apr 4, 2015

Hi, mamunhq.
You mean you'd like to save other data related to an image at the same time when saving the image?
If so, this package is not supposed to do it.(I might add the function in future, though)

However, you can save the form data when submitting like the below.

(in a controller action to submit data)

$surpass = Surpass::path($this->_surpass_test_path)->dir($this->_surpass_test_dir);
$image_file_ids = Surpass::imageFileIds('dir_name'); // If you use example files, you should set "surpass_test".

foreach($image_file_ids as $image_file_id) { // $image_file_id refers to ID of DB table called image_files.

$surpass->saveAttributes($image_file_id, array(
    'key_1' => 'value_1',
    'key_2' => 'value_2',
    'key_3' => 'value_3'
));

}

*Note: I haven't tested it yet, sorry.

or

It's not a stylish way but you might save them by adding the form values to TUSurpassTest.formData in JavaScript.("TUSurpassTest" might be different from yours. It depends on the directory name you'd like to save)
Because "formData: {}" will be sent with an uploading image.
I hope this can help you.:)

@mamunhq
Copy link

mamunhq commented Apr 4, 2015

Actualy i have a from where i need to atatch multiple images.

screenshot from 2015-04-05 03 47 09

i am trying to use https://blueimp.github.io/jQuery-File-Upload/ this is my view but when i submit the form its shoe null valu why ? array(7) { ["_token"]=> string(40) "jBhSOk5pKt9DPvglv6MJqWr2nbjR1YgdJeDJ4Ctt" ["title"]=> string(0) "" ["description"]=> string(0) "" ["price_30_min"]=> string(0) "" ["price_60_min"]=> string(0) "" ["price_90_min"]=> string(0) "" ["files"]=> array(1) { [0]=> NULL } }

@mamunhq
Copy link

mamunhq commented Apr 5, 2015

I already upload image( its save the files)before submit this form.

@SUKOHI
Copy link
Owner

SUKOHI commented Apr 6, 2015

Hi, mamunhq.

I think jQuery-File-Upload can only upload images.
So you might need to set image data into input-hidden-tag or something through Ajax callback as soon as images will be uploaded like the following.

$('#id_name').fileupload({
dataType: 'json',
done: function (e, data) {

    // Set or generate hidden-tag using "e" or "data".

}

});
Thank you!

@SUKOHI SUKOHI closed this as completed Apr 14, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants