Closed finferflu closed 8 years ago
Which version of oembed field are you running ? Twitter stopped returning xml responses a couple of time ago and we've made the switch to 'json' so it should work...
Thanks a lot for getting back to me. I'm using the latest version available on symphonyextensions.com (1.9.0). As I mentioned, this was working just fine up until 2-3 weeks ago. Has anything changed in the last couple of weeks?
when I visited the entry page
In the backend you mean ?
this was working just fine up until 2-3 weeks ago. Has anything changed in the last couple of weeks?
Not that I am aware of...
I am sadly not able to reproduce. Can you give me a complete url of a tweet that won't work ?
Yes, that error shows up in the log when I visit the entry page in the backend. On the front end, in debug mode, I can see the following:
<twitter-feed-data>
<section id="9" handle="twitter-feed">Twitter Feed</section>
<entry id="88">
<feed-url id="https://twitter.com/finferflu">
<title handle=""></title>
<url>https://twitter.com/finferflu</url>
<thumbnail></thumbnail>
<driver>Twitter</driver>
<protocols>
<item>https</item>
<item>http</item>
</protocols>
<error>Error while loading the xml into the document</error>
</feed-url>
</entry>
</twitter-feed-data>
I am trying to embed a whole timeline, so the URL I'm using is this one, for example: https://twitter.com/finferflu
Here is a screenshot of what the back-end looks like:
For the record, I did try to delete and reinstall the extension, but it didn't make a difference.
I've never actually tried to embed complete timelines! But I just did and it works...
Can you go into the database to check what's the saved xml ?
Sure, can you please point me to where in the database I should check exactly? Thanks!
Also, the screenshot you attached is exactly how I would see that area in the back-end. I don't understand why it has stopped working all of a sudden.
I know why you are seeing an error in the log, and they are ok. But it should work.
You can check in the sym_entries_data_X
(where X is your field's id). In the column oembed_xml
. You should oddly find some json data in there...
Do you have any errors in the console ?
Thanks, found it!
The column url_oembed_xml
contains:
https://publish.twitter.com/oembed?url=https%3A%2F%2Ftwitter.com%2Ffinferflu
The column oembed_xml
contains:
{"url":"https:\/\/twitter.com\/finferflu","title":"","html":"\u003Ca class=\"twitter-timeline\" href=\"https:\/\/twitter.com\/finferflu\"\u003ETweets by finferflu\u003C\/a\u003E\n\u003Cscript async src=\"\/\/platform.twitter.com\/widgets.js\" charset=\"utf-8\"\u003E\u003C\/script\u003E","width":null,"height":null,"type":"rich","cache_age":"3153600000","provider_name":"Twitter","provider_url":"https:\/\/twitter.com","version":"1.0"}
Yeah I have the same thing...
But I do have
Syntax error, malformed JSON. on 97 of file /home/dev/public_html/sym6/symphony/lib/toolkit/class.json.php
in my data source tho..
Hah! I'm a bit embarrassed about having to report this, but it turns out my browser extension Ghostery was blocking that content. I had AdBlock disabled but forgot about that extension altogether. That error in the log misled me to think it was an issue with the extension and not with the browser. Sorry for wasting your time like that!
At the same time, though, the feed is still not visible in the front-end. I still get that "Error while loading the xml into the document" message. So there is still an issue somewhere.
Ok great we are making progress. At least, we both have the same result!
Yes. In that case, though, I can't remember whether the front-end was working at all in the past because I had just come back to it today in order to work on it for the first time.
It does not looks like it ever worked, sadly. Or it did but Twitter changed some things in their JSON responses and it broke it. I'll dig deeper to try to fix it ;)
Well, I'm glad to hear that, thank you very much! :)
@finferflu wanna test the latest dev
branch ? d3166c6 would be enough, but I could not NOT touch other things as well (while debugging) Thanks!
yeah dev is now 8 commits ahead :P but a 1.10.0 release is ready to be shipped. If you could just test it before I release, that would be cool. Thanks again.
Sorry, I eventually went to bed. I am going to test this today and will let you know. Thank you very much for the super speedy updates!
OK, I tried it and it works! Thanks for that!
As a side note, though, I can't seem to get any URL parameters (the ones you set in when creating the section) to actually work. I tried with "width=200" or "maxwidth=200" (as indicated in the Twitter oEmbed documentation), but I see no difference either in how the feed is displayed or in the XML in Symphony debug mode. Is there anything I'm missing?
UPDATE: All the other URL parameters I tried are working ok, it's just an issue with the maxwidth parameter, but I don't really mind about it right now.
As the doc says:
This value must be between 220 and 550 inclusive.
So if 200 is not working, it's normal ;)
Thanks. I'll release right now.
Ah you're right, thanks!
;) 1.10.0
is available right now ;)
Yes, I've noticed thanks a lot! I kept the dev version installed as I believe there's no difference with the master one, right?
Nope, no difference.
Hello,
This extension was working just fine when I installed it, however, today when I visited the entry page, the feed wasn't displayed, and I saw the following error in the Symphony log:
Warning: GenericErrorHandler 2: DOMDocument::loadXML(): Start tag expected, '<' not found in Entity, line: 1 on line 165 of file /path/to/symphony/extensions/oembed_field/lib/class.serviceDriver.php
The oEmbed URL in question is https://twitter.com/finferflu or any Twitter timeline really.
Is there anything that could have caused that issue to appear all of a sudden?
Thanks!