question

$$anonymous$$ avatar image
0 Likes"
$$anonymous$$ asked ·

Retrieved messages from GetMyMessages Text tag html errors

Hi, I'm building an application that manages messages from multiple ebay accounts. But I'm having trouble parsing the retrieved messages using GetMymessages api call. I can parse the XML response and cache the data extracted to a database without any problem, but in parsing the contents of the tag in the XML is where my application starts to break down. There seem to be HTML syntax errors in the content of the tag as using DOMDocument to load the HTML produces the following exception: DOMDocument::loadHTML(): Unexpected end tag : img in Entity, line: 1. Also, displaying the HTML contents of the message messes up my web app's view, as if there are div tags that are not closed within the HTML. Although this only happens to messages that have reply threads in them. I understand that the XML also contains a tag which contains a text-format version of the message but it's awfully useless to parse because there are no tags like on html that are easier to extract. Can anybody assist me with parsing the HTML properly? I'm not sure if I'm doing something wrong or if the HTML need further processing. Thanks, Caleb P.S. here's an example of an HTML I have that's causing problems: eBay sent this message to Test User (testuser_calebtestthree). Your registered name is included to show this message originated from eBay. Learn more. Buyer has responded to your question about this item Do not respond to the sender if this message requests that you complete the transaction outside of eBay. This type of offer is against eBay policy, may be fraudulent, and is not covered by buyer protection programs. Learn More Dear testuser_calebtestthree, Message 3 on pay for item message - testuser_caleb.andrada.seller Click "respond" to reply through Messages, or go to your email to reply
From: testuser_calebtestthree To: testuser_caleb.andrada.seller Subject: Re: Pay for item: testuser_caleb.andrada.seller sent a message about asdfdsadfsda #110139491651 Sent Date: Mar-21-14 00:08:21 PDT Dear testuser_caleb.andrada.seller, Reply 2 on pay for item message - testuser_calebtestthree
From: testuser_caleb.andrada.seller To: testuser_calebtestthree Subject: Re: Pay for item: testuser_caleb.andrada.seller sent a message about asdfdsadfsda #110139491651 Sent Date: Mar-20-14 21:23:45 PDT Dear testuser_calebtestthree, Message 2 on pay for item message - testuser_caleb.andrada.seller
From: testuser_calebtestthree To: testuser_caleb.andrada.seller Subject: Re: Pay for item: testuser_caleb.andrada.seller sent a message about asdfdsadfsda #110139491651 Sent Date: Mar-20-14 21:10:48 PDT Dear testuser_caleb.andrada.seller, Reply 1 for pay for item message - testuser_calebtestthree
From: testuser_caleb.andrada.seller To: testuser_calebtestthree Subject: Pay for item: testuser_caleb.andrada.seller sent a message about asdfdsadfsda #110139491651 Sent Date: Mar-20-14 00:28:06 PDT Dear testuser_calebtestthree, This is a payment question. :D - testuser_caleb.andrada.seller asdfdsadfsdaItem Id:110139491651End time:Mar-26-14 22:35:14 PDT Buyer: testuser_caleb.andrada.seller ( 500)0.0% Positive FeedbackMember since Dec-18-13 in United StatesLocation: WA, United States Listing Status:This message was sent while the listing was active. Marketplace Safety Tip
  • Keep your money safe - never pay for items with cash or instant money transfer services, such as Western Union or MoneyGram. In the past some sellers have exploited these payment methods in order to defraud buyers, so eBay has banned them from the site.
  • Received a Second Chance Offer email? Double check that it's genuine: Second Chance Offer emails come directly from eBay and are shown in your My Messages.
  • Trade safely. Beware of anyone who contacts you about buying or selling outside of eBay. When you trade outside of eBay, you're not able to leave feedback or take advantage of protection programs and case resolution tools available on eBay. Report an inappropriate email.
  • eBay helps guard your privacy and online safety when you use our messaging tools. If you and the member you're contacting haven't bought or sold from each other recently, our tools may make both of your email addresses anonymous.

Email reference id: [#a05-lbqxhyvosh#]_[#4132036fcdc34d858af85b5a65234d67#] Please don't remove this number. eBay customer support may ask you for this number, if you should need assistance.
Learn More to protect yourself from spoof (fake) emails. Another eBay member sent this email to your email address through the eBay platform. eBay takes no liability for the sending of this email or its content. Visit our Privacy Policy and User Agreement if you have any questions. You can report this message as unsolicited (spam/spoof) email. Copyright © 2014 eBay Inc. All Rights Reserved. Designated trademarks and brands are the property of their respective owners. eBay and the eBay logo are trademarks of eBay Inc. eBay Inc. is located at 2145 Hamilton Avenue, San Jose, CA 95125.
api-problemmessagesgetmymessagesmessagemessage-parsing
10 |600 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

· Write an Answer
vijayta.developersupport avatar image
0 Likes"
vijayta.developersupport answered ·
Hi Did you already figure it out or do you still need help ? In case you need help, file a support ticket. Thanks
· 1 · Share
10 |600 characters needed characters left characters exceeded

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Hi, thanks for responding. I kind of figured it out but I'm still not able to display the code properly. It seems that the html from ebay is an email html format. I haven't gotten around a solution yet because I moved on to program a different part of my program. I do still need help but it seems that my dev account has run out of hours? and I can't file a support ticket even for possible bugs. Do I really have to purchase support hours, or is there some way to send out bug reports without doing so? Thanks.
0 Likes 0 · ·

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.