Seems to be possible doing this using Javascript. And use PHP to pepare the HTML part. See http://msdn.microsoft.com/en-us/library/office/fp161148%28v=office.15%29.aspx
diafol commented: That was my take as well +15
arafath077 commented: thanks.itz worked +0