python - How to get the whole strings with space in jinja2 -


i use python, jinja2, gae.

i have python list passed jinja2. list looks ['hi mate', 'hello world"]. can 'hi', 'hello' 'item'

{% item in pylist %}  

if put in

<input type="text" name="line1" value={{item}}>.  

the left after space missed out. how can whole string?

since values have space, have quote them. otherwise html looks like

<input type="text" name="line1" value=hi mate> 

mate considered custom attribute, , in effect nothing; , hi gets set value. when quote though:

<input type="text" name="line1" value="hi mate"> 

now entire string in quotes set value


Comments

Popular posts from this blog

image - ClassNotFoundException when add a prebuilt apk into system.img in android -

I need to import mysql 5.1 to 5.5? -

Java, Hibernate, MySQL - store UTC date-time -