id : 'signdoctor-iconPath',
name : 'iconPath',
xtype : 'textfield',
fieldLabel : '照片:',
inputType : 'image',
anchor : '30%'
Ext.getCmp('signdoctor-iconPath').setValue("<img src='"+result.iconPath+"'/>");
最终只是在文本框中出现<img src="" />这句话,如何在文本框中显示对应的图片呢?请大家指教
extjs 麻烦大家帮我看看下面的想法怎么实现?
- 写回答
- 好问题 0 提建议
- 关注问题
- 邀请回答
-
2条回答 默认 最新
斯洛文尼亚旅游 2016-03-12 02:57关注Ext.create('Ext.panel.Panel', { renderTo: document.body, title: 'test' , layout: { type: 'hbox', align: 'middle' } , items: [{ xtype: 'label', text: '照片:', margin: '10 0 0 0' }, { id: 'signdoctor-iconPath', name: 'iconPath', xtype: 'box', autoEl: { tag: 'img', src: 'aa.jpg', width: 100, height: 100 } }] });解决 无用评论 打赏 举报