Within Messanine, what is the best way to add a favicon to your site rss feed?
The favicon discovery which works with any HTML page should work with RSS as well ;) Juts pout it in /favicon.ico under the host that serves the RSS feed.
Related
There are a series of weird behaviors which all seem to be stemming from a Content-Type header issue.
The site will be running fine but then the problem happens "randomly" throughout the day. But I can replicate the problem by doing the following:
On server, clear HTCache from mod cache disk and flush cache from apache pagespeed module.
Test any page URL from my WordPress Site, on redbot.org/ which shows correct headers.
Content-Type: text/html; charset=UTF-8
Go to any browser and load the feed url. mysite.com/en/feed/
The XML feed looks good. Or go to http://redbot.org/ and check the header of the feed, which looks good.
Content-Type: application/rss+xml; charset=UTF-8
Go back and test the URL of any page on http://redbot.org/ . Now the Content-Type switched from text/html to rss+xml !
Content-Type: application/rss+xml; charset=UTF-8
This automatic switching of content-type makes In-App Browsers (IAB) like Facebook and Instagram go berzerk. Instead of the IAB rendering the html page, it loads the XML file for the RSS feed. The RSS Feed will be a random one, either the comments feed for some random page or the posts feed.
Multiple problems related to RSS Feed showing up instead of loading web site blog post url.
Google pagespeed testing sometimes shows RSS feed. https://developers.google.com/speed/pagespeed/insights/
Twitter Card Validator, Facebook Debugger Validator, whatsapp chat and LinkedIn validator not showing metadata image, title and description.
Doing this command in linux will show RSS feed instead of HTML of site
curl -A Twitterbot mysite.com/
Testing my RSS feed (mysite.com/en/feed/) in https://validator.w3.org/feed/ sometimes shows the comment RSS feed instead of post RSS feed.
I've ruled out the following possible causes because I've either updated each item or checked the code for errors:
Updated WordPress
Updated Plugins
Updated theme
No longer inserting/Writing/Inlining CSS stylesheets directly into HTML page
Posts are NOT custom post types. They are regular wordpress posts.
Used Wordpress Native Text Editor to write posts to prevent RSS code errors generated by plugins like TinyMCE Editor.
RSS Feed is validated. Tested with: validator.w3.org/feed/
and Feedvalidator.org
With Apache PageSpeed Module disabled, the problem still occurs.
I've also tested by deactivating all plugins but one, polylang which makes the site bilingual. I can't disable polylang since without it, many posts wouldn't show up on the site.
What temporarily solves the problem for now:
Manually clearing the HTCache always makes the Content-Type for regular URLs back to HTML/txt.
sudo htcacheclean -v -t -p /var/cache/apache2/mod_cache_disk -l1b -L1b
So I went ahead and disabled cache_disk and the Site has been working fine all day so far. Every time I load the RSS Feed url in the browser and then test the header of any web page at Redbot.org the header shows up correctly (html/txt)
sudo a2dismod cache_disk
sudo systemctl restart apache2
sudo systemctl stop apache-htcacheclean
I still do not comprehend what is the root of this problem in the first place. So I am bewildered and reaching out to you all for help.
Any ideas what can be causing such odd behavior and how to fix it?
I'm migrating a blog from WordPress to GitHub pages. In the logs for my site, I've noticed that there are many requests like this:
GET /wp/?feed=atom
This 301 redirects to the ATOM feed for the site.
I'd planned to use httrack to scrape my site and migrate all the static content. But this presents a problem. Is there any way to replicate the /wp/?foo=bar redirects using Jekyll?
You can use Jekyll redirect_from plugin which is one of the rare plugin that can be used on github pages.
The only problem is that yoursite.github.io/wp/?foo=bar from the server point of view is yoursite.github.io/wp/index.php?foo=bar. So, any ?foo=bar is resolved to the same file.
I you have only your xml feed to redirect, this does the trick :
---
layout: null
redirect_from:
- /wp/
---
content ...
If you have multiple files to redirect, you will have to switch to a javascript solution from a wp/index.html file.
I have one old blog using blogspot http://satindersinght.blogspot.in/ .On many places have shared my blog links. Now i have launched my new blog using wordpress startcoding.in .
Thing I want to do is how I can redirect all my blogspot link to this new wordpress blog without any loss of data.
Have already exported XML data file by login blogspot --> Setting --> Other --> Export Blog. This gives XML data format file, which i import in wordpress.
Doing this all my post are imported sucessfully thought some googleplus comments are missed now i need to transfer all blogspot link to my new blog
In the case of only wanting to redirect certain posts or pages all you have to do is use the form of Redirect 301 / http://startcoding.in/
though where the "/" is just write the page on your old site and where http://startcoding.in/ is just write the website then the page you want it to redirect to.
for example if you wanted to redirect "satindersinght.blogspot.in/my_page" to "startcoding.in/my_new_page" all you would have to do is:Redirect 301 /my_page http://startcoding.in/my_new_page
This is assuming that direct access to an api is not available. Since I am requesting ALL posts, I am not sure RSS would help much.
I considered a simple system that would loop through each year and month and download each html file but changing the following URL for each year month pair. This works for wordpress and blogger blogs.
http://www.lostincheeseland.com/2011/05
However, is there a way to use the following search function provided by blogger to return all blogs? I have played around with it, but documentation seems sparse.
http://www.lostincheeseland.com/search?updated-max=2012-08-17T09:44:00%2B02:00&max-results=6
Are there other methods I have not considered?
What you're looking for is a sitemap.
First of all, you're writing a bot so it's good manners to check the blog's robots.txt file. And lo and behold, you'll often find a sitemap mentioned there. Here's an example from the Google blog:
User-agent: Mediapartners-Google
Disallow:
User-agent: *
Disallow: /search
Allow: /
Sitemap: http://googleblog.blogspot.com/feeds/posts/default?orderby=UPDATED
In this case, you can visit the Sitemap URL to get an xml sitemap.
For Wordpress, the same applies but it's not built-in as standard so not all blogs will have it. Have a look at this plugin which is the most popular way to create these sitemaps in Wordpress. For example, my blog uses this and you can find the sitemap at /sitemap.xml
(the standard location)
In short:
Check robots.txt
Follow the Sitemap url if it's present
Otherwise, check for /sitemap.xml
Also: be a good Internet citizen! If you're going to write a bot, make sure it obeys the robots.txt file (like where blogspot tells you explicitly not to use /search!)
Im using Apache's Url Rewrite engine to rewrite my blog post's urls in
hebrew.
Im using Feedburner as my rss provider.
everything works fine with my website, as well as with my rss.xml file.
the problem is when I click on a link from Feedburner: It turns all of
the hebrew characters into question marks. Here's an example:
the link:
http://feedproxy.google.com/~r/Webdeskil/~3/v4V5nVxzOS8/כסף-באינטרנט-גוגל-אדסנס
becomes:
http://www.webdesk.co.il/articles/???-????????-????-??????
So I figure out its a Feedburner issue, rather than an issue with my
code.
any suggestions?
I figured it out: feedburner doesnt encode a given url, so urls in hebrew have to be encoded before being "sent" to feedburner via .rss.
I used the built in PHP function urlEncode() and the problem was solved.