Hi everyone,
I'm trying to display pictures in a custom module, using the <img> tag. Though the access path to the picture is correct, they are not displayed. I saw on the forum that other people had the some with Odoo 9, I tried to install and upgrade Werkzeug but it didnt fix the problem. Any help would be appreciated.
Thanks in advance.
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Accounting
- Inventory
- PoS
- Project management
- MRP
This question has been flagged
Hi, Before module_name put / and try
<form string='Class'>
<sheet>
<group>
<img src='/module_name/static/image/myimage.png'>
<field name='name'/>
</img>
</group>
</sheet>
</form>
I don't know where you place your image in module. You must place your image in your module to work. I have code that works form me.
So, try it
in xml file i used <img> tag like this,
<form string='Class'>
<sheet>
<group>
<field name='name'/>
<img src='module_name/static/image/myimage.png'/>
</group>
</sheet>
</form>
Hi Bharat, my code looks exactly like yours but my image is still not displayed, I really dont get it. Below is my code :
<form string="Accueil" class="accueil_form" encoding="UTF-8">
<sheet>
<div>
<p> <a class="a_accueil" href="url">Accès à l'ERP</a> </p>
<p> <a class="a_accueil" href="url">Pydio</a> </p>
<p> <a class="a_accueil" href="url">Site vitrine </a> </p>
<sheet>
<group>
<field name="img"/>
<img src='accueil/static/odoo.png'/>
</group>
</sheet>
</div>
</sheet>
</form>
There is a mistake in the code above (2 <sheet> tags, but it's not the reason for my problem).
Go on http://www.pinterest.com
Enjoying the discussion? Don't just read, join in!
Create an account today to enjoy exclusive features and engage with our awesome community!
Sign up