Export docid logicalname and image in htmltext attribute (closes #4151 #4152)

+ Export docid logicalname in htmltext attribute (closes #4152) 
+ Export image in htmltext attribute (closes #4151)