Search The ForumSearch   RegisterRegister  LoginLogin

AfterLogic WebMail Pro

 AfterLogic Forum : AfterLogic WebMail Pro
Subject Topic: How-to: Get message body Post ReplyPost New Topic
Author
Message << Prev Topic | Next Topic >>
MAlly
Newbie
Newbie
Avatar

Joined: 16 March 2017
Location: United States
Online Status: Offline
Posts: 11
Posted: 24 May 2017 at 8:29am | IP Logged Quote MAlly

Is there any way to get a message body of already open message so I can display as a preview in a modal?
Back to Top View MAlly's Profile Search for other posts by MAlly
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 6104
Posted: 24 May 2017 at 8:31am | IP Logged Quote Igor

Can you please describe the task in more detail? In particular, are you referring to the situation when message is open in preview pane? And what exactly does "display as a preview in a modal" mean here? I mean, if you simply copy the HTML displayed in preview pane, via DOM, doesn't that do what you're looking for?

--
Regards,
Igor, AfterLogic Support
Back to Top View Igor's Profile Search for other posts by Igor
 
MAlly
Newbie
Newbie
Avatar

Joined: 16 March 2017
Location: United States
Online Status: Offline
Posts: 11
Posted: 24 May 2017 at 8:56am | IP Logged Quote MAlly

Yes, I can do that via DOM for my particular case when I have already opened message but I was looking for something like getting message body from `oMessage` object.
Back to Top View MAlly's Profile Search for other posts by MAlly
 
Igor
AfterLogic Support
AfterLogic Support


Joined: 24 June 2008
Location: United States
Online Status: Offline
Posts: 6104
Posted: 24 May 2017 at 9:04am | IP Logged Quote Igor

If you're doing it from server side, it doesn't have a concept of message already open, you'd need to download the message from the server once again, parse its HTML body and clean it up like WebMail Pro does prior to displaying it - stripping CSS, JavaScript and other elements unsafe for rendering. Grabbing existing content from preview pane sounds like a much easier job to do.

--
Regards,
Igor, AfterLogic Support
Back to Top View Igor's Profile Search for other posts by Igor
 
MAlly
Newbie
Newbie
Avatar

Joined: 16 March 2017
Location: United States
Online Status: Offline
Posts: 11
Posted: 24 May 2017 at 10:23am | IP Logged Quote MAlly

Well, it looks like then I need to go with the DOM. I thought I can grab a "raw" message body from an object before WebMail Pro displayed it.

Thanks for explaining that situation.
Back to Top View MAlly's Profile Search for other posts by MAlly
 

If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Post ReplyPost New Topic
Printable version Printable version

Forum Jump

Powered by Web Wiz Forums version 7.9
Copyright ©2001-2004 Web Wiz Guide