Thank you both for your replies.

In my model I have writable=False and readable=False, in case a field 
should be readable I set readable=True.
Web2py renders readable=True and writable=False fields in a div

<div>field value</div>

By adding:

if isinstance(controls, basestring) or isinstance(controls, int):
    _controls = DIV(controls, _class='form-control', _readonly=True)

to my custom formstyle_bootstrap3() function, the styling comes closest to

<input class="form-control" type="text" placeholder="Readonly input here…" 
readonly>



if isinstance(controls, basestring) or isinstance(controls, int):
    _controls = INPUT(controls, _class='form-control', _readonly=True)

results in an error ticket.


Regards,

Annet

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to