10 years ago
10
Topic
Dear Seblod team,
kindly ask you to design "user friendly" image upload field. AT LEAST I see what is really appreciated:
  1. in current field plugin, in file upload_image.php (~line 240) add accept="image/*", therefore user will see only IMAGES and not all files
  2. an image preview script to see what image is going to be uploaded before push send button. User must see img preview before upload!
  3. check filesize before push submit button - it's really annoying to see when size is bigger than needed. I suggest script like this or better
I'd like to pay even couple of euros, but really get working user friendly image upload field from the box and do not customise it by myself! Thanks!
function validateSize(fileInput)
{
var fileObj, size; if ( typeof ActiveXObject == "function" )
{fileObj = (new ActiveXObject("Scripting.FileSystemObject")).getFile(fileInput.value);}
else {fileObj = fileInput.files[0];}
size = fileObj.size;
if(size > 1 * 1024 * 1024)
{alert('Max File size - 1 MB and less than 1024 х 1024. Resize please image and try again');
fileInput.parentNode.innerHTML = fileInput.parentNode.innerHTML; }
}
jQuery('#FIELD_NAME').change(function () {validateSize(this);});
Get a VIP membership
10 years ago
1
Level 1
In options image field you have the option: "Show Preview", change to image or Thumbnail
10 years ago
0
Level 2
Show Preview doesn't work..I just checked joomla3 standard template( thought conflict in my custom template). Is this bug in my template only?
Basically it works, but only when you edit an article...and your image has been saved on server.
However, I'd like to set also default "noimage".jpg. And I normally do this via "default value" (fill images/noavatar.jpg for example)

147 Posts
MtnPavlas
10 years ago
0
Level 1
I second this. Please implement file size adjustment if bigger than allowed size. The preview in the form when creating NEW content would be great too. (The current preview functionality only works when editing.)
Thank you, Seblod team, for your consideration.
548 Posts
joomleb
10 years ago
1
Level 1
Hi guys, 

I suggest/remember you to always don't forget to add here in Forum the Tracker Item link if opened and there (on the Tracker) the Forum Discussion link, so will be simple for Seblod Team to take a look and follow us... 
10 years ago
0
Level 2
actually i've added this as an feature request http://www.seblod.com/resources/tracker/12157
and in update 3.3.3 I still see it old...hope this will happen soon
10 years ago
4
Level 1
@terveg
an image preview script to see what image is going to be uploaded before push send button. User must see img preview before upload!
I don't see why this would be necessary. When a user clicks on upload image, a file browser opens where they can select the image from their computer. In that file browser the user already has a preview of that image if he enables thumbnail view in his file browser.

You say that you would like to have this out of the box and not need to change the code of the plugin yourself. Do you already have a script that gets the preview before upload? If yes, could you please share it here? That would be much appreciated.
10 years ago
3
Level 2
Often...very often happens that user guess that he was uploaded correct pictures...but tis is a guess...after saving form he or she runs preview of just added item(advertisement for example) and immidiately starts edit article. I have a website with more than 500 added ads per day and i don't want my users make 10000 sql/php requests because of their nature. And all other huge projecs which are driven by seblod...i guess everybody wants to do it in smart way. The free image/file upload field is useless for commercial website. I will try to find an suitable package (js+php) and maybe it can be easy to make a separate plugin or use a seblod's codepack. Unfortunately, i'm not experienced coder.
178 Posts
Jeka
10 years ago
2
Level 3
Preview is great, but i think much more need feature is multiupload. There is a lot of scritps for example http://blueimp.github.io/jQuery-File-Upload/. This one have preview feature already.
10 years ago
1
Level 4
Seems, I found a solution for live image-preview...here is an demo  http://jsfiddle.net/terveg/c9f7h/

An example:
1) create basic field image user_avatar
2) we need in this case an extra freetext (is suitable for me) field image_preview, where we place additional html code in text editor
            <div id="image_preview">
                <img src="#">
                <br> 
                <a href="#">Remove</a>
            </div>
and drop a CSS style in Stuff->CSS
#image_preview {display:none;}
3) script to be added in Stuff->JS of the basic field user_avatar

Tip: to hide a label I use in the "live lable" field (in admin view)
HTML space symbol nbsp
I didn't try it yet on working form during submission. I guess it is possible to create Field-X - I don't know yet if this works too.
9 years ago
0
Level 5

Hi terveg,

Any news about your plugin? It could be a great Idea to integreate Multiple Image Upload like jQuery file upload as a JS script upon the current way to make a Gallery using FieldX.

best regards

abram

Get a VIP membership