Forum for discussing general topics related to Couch.
2 posts Page 1 of 1
I am trying to create the extended comment form where commenters are allowed to upload images with repeatable functionality. But, I am unable to do it. Please help me how to make it work.

My code is
Code: Select all
<div class="upload-photos">
<cms:repeatable name='photos'>
<label for="photos">Photos :</label>   
<div class="photos-upload-view">
<cms:input type='image' name='photos' label='Upload Photos' width='400' show_preview='1' allowed_ext='jpg, jpeg, png' preview_width='80' />
</div>
</cms:repeatable>
</div>

Thank you in advance.
Hi Upadesh,

Using type 'image' (or 'file') editable region for non-admin users is not allowed owing to security concerns.
The alternative is to use type 'securefile' (search the forum and you'll find plenty of examples) instead.

Unfortunately, 'securefile' cannot be used in a repeatable fashion so you'll have to define a fixed number of such regions (e.g. 5). The user then can choose to upload up to that maximum number of images.

Hope this helps.
2 posts Page 1 of 1