Over the past year, I've been working on the side on a WordPress plugin that implements an idea that has been growing in me over the last couple of years. Decentralized Social Networking. The plugin that does it is called Friends.
Starting with the frustration that there are few alternatives for people who use Facebook: if you don't want them to own your data but still want to privately keep your friends and family up to date about your live and discuss what interests you, where do you go?
I realize that many people just switched to instant messaging (like WhatApp) which does allow exchanging private messages (and photos) with your friends, but overall I do like the idea of having a more structured publishing platform. I just don't like a single entity to control it all.
So I realized: We actually had an alternative all along: blogging.
Blogging is decentralized: you decide where you host, you decide which blogs you read and nobody really knows which ones you have subscribed to.
What disqualifies it as an alternative to my wish to keep friends and family up to date, is that it public by default. While there is the option to publish something as "private," there is not a lot you can then do with a privately published post.
So what if you were easily able to give your friends access to your private posts?
Here comes the Friends plugin. And with it, the downside to the solution:
You need to have your own blog to become friends with each other.
Right now, this is only implemented on WordPress, the technology is framework agnostic, though.
When everyone involved has their own blogging platform and they'd decide where they want to host, we automatically get a decentralized platform.
The technological ingredients to this are actually pretty old:
- REST API
- Authentication via keys
After friendship has been established (this involves both parties accepting friendship and exchange private keys in the background), your server will use that key when requesting your friend's RSS feed which will in turn (since you are friends) contain private posts. And vice versa.
For commenting, you'll go to your friend's blog, it's a one-click-authentication away. This can also eliminate spam if you only allow friends to comment on your posts.
All of this is highly compatible with standard WordPress: if you want to accept a friend request on your mobile phone, use the WordPress iOS or Android app and change that user's role to "Friend."
Chicken-and-egg problem: I use a social network because all my friends are there.
So why use a social network that not all of your friends use (yet)? Because the Friends plugin is actually a pretty decent way to consume RSS feeds.
Since it is based on RSS, it means you can also subscribe any blog or website that offers this well-established way of distributing content.
As you are in control of the server, you can also decide what you're interested in and tailor the feeds to your liking: you can define rules for incoming feed items and ignore posts you know you won't be interested in.
I personally like to consume notifications via e-mail as it provides read/unread functionality and I can sort and categorize e-mails to my needs. You can now also read your friends' posts (or subscriptions) via e-mail. But you don't need to.
Another method to view your friend posts and subscriptions is the "Friends Page," a timeline of friend posts and subscriptions. You can therefore scroll down the list of your friend's posts and subcriptions, just as you see it people doing it all the time on Facebook.
There is quite a bit more to this, you can Emoji react to a post, recommend it specifically to friends, have sections in your posts for friends/not-friends, and more.
Overall, I see this as a way to take blogging to the next level: Choose your private audience. Choose where you host. Publish publically if it's meant to be public.
It's clear that setting up and having your own blog is not (yet) for everyone. It's more work than just signing up for some social network. Often you'll need to pay for hosting (and domain). But it also gives you the freedom to take your data somewhere else if you want to. Or delete it.
We'll have to see who will use this. As of now, it's for a technical audience but maybe someday there will be dedicated Friends-WordPress hosting?
The Friends Plugin is open source under GPL2. If you have a WordPress blog, try it out, and if you think this could be better, different, enhanced: create an issue, or better: create a patch and send a pull request.
Probably it's not ready for prime time yet, we're at version 0.14. But it's getting there, at least I am already using it daily :) There are many ideas left to be implmented, and these are only mine so far.
Oh, if you happen to be in Vienna coming week, I'm going to talk about Decentralized Social Networking with WordPress at our WordPress meetup on November 7, 2018.
Recently I've had the issue to have a completely unsorted Photo Library in Android after migrating to a new phone. The reason is that WhatsApp images are copied into internal storage and end up with the last modification date when they were copied, thus conglomerating together when they should be spread out over time.
The problem is not that trivially to solve because you cannot mount internal storage into a computer and then modify the file dates. Thankfully, I was still able to create a viable solution using a bash script.
It all revolves around the Android Terminal Emulator Termux which allows you to execute scripts on your phone.
- Grant Termux access to your storage directories.
- Install core tools apt install
- Copy this script into your file tree (for example via Android File Transfer):
for f in IMG-20* VID-20* AUD-20*; do [ -e "$f" ] || continue NEWDATE=`echo $f | cut -c5-8`-`echo $f | cut -c9-10`-`echo $f | cut -c10-11` echo touch -d $NEWDATE "$f" touch -d $NEWDATE "$f" done
- Run the script in the directories you need to fix file dates (for example in /storage/emulated/0/WhatsApp/Media/WhatsApp Images)
- Delete the data of MediaStorage (and maybe reboot) to make Android re-index the files with the new file dates.
This year, 2016, the Vienna WordCamp team (which includes me) was able to get WordCamp Europe to come to Vienna. So may I present to you:
Unfortunately it is constantly sold out, but there is a waiting list, should you still decide to come.
Looking forward to the event in June!
This is in response to the Stack Overflow Meta question: Why is Stack Overflow so negative of late?
In my opinion the problem that Stack Overflow is currently facing is caused by a lot of new users that are characterized by user Mysticial as "help vampires". They care nothing for the site and just want their code fixed. They don't research (or very little) and provide less than the minimum information needed. Most of the times the questions are very basic and can be answered by an intermediate programmer in a few minutes.
In a normal forum, users would not yield any responses. Not so on Stack Overflow: you get reputation for answering questions and therefore even theses badly researched questions get answers within under a minute. Mystical calls these users "reputation whores".
The problem is that "help vampires" and "reputation whores" create a vicious circle: they both need each other and therefore the circle continues to spin.
The outcome of this situation: the site is flooded with a high number of low quality questions, experienced programmers who are interested in learning something don't see the forrest for the trees. Even though questions can be voted up, they don't stand out enough to gain momentum.
a) Create a "beginners test"
This would create a higher burden for low reputation users before they can ask their question. They need to invest more time and rethink their action before they get to post something.
A few ideas what that could be:
- The user needs to give 3 search queries that he used either on Google or on Stack Overflow that didn't yield results.
- If they don't include any code, they must confirm that they are asking a non-code question. See this proposal on Stack Exchange Meta.
- Specify the time that they took to research the problem (while this can be easily faked, it makes the user reconsider if they had taken enough time for the problem)
b) Have experienced users review a question, before it goes online
There would be a process where a new user asks his or her question, but it doesn't go online. Higher reputation users read the question but are unable to answer it, and give feedback if the question has enough information or has been researched enough. Finally, the question get's thrown into the shark tank.
It would be fine to give these reviewing higher reputation users even more reputation for reviewing this: they are helping to improve the site, this is actually what the reputation system has been designed for: to make the site interesting, not for feeding the "help vampires".
All in all it is remarkable that despite the current situation, Stack Overflow has reached the quality it has. The reputation and badge system has for sure been a very big factor in this but it is very appalling that in order to reach a certain reputation level, you really have to feed the "help vampires".
You can find me on Stack Overflow as akirk.
When updating a blog of mine to WordPress 3.9 the page wouldn't load anymore because of qTranslate not able to cope with the update. In the error log it says:
PHP Catchable fatal error: Object of class WP_Post could not be converted to string in ../wp-content/plugins/qtranslate/qtranslate_core.php on line 455
The error is caused by this change: get_the_date() to accept optional $post argument
qTranslate registers the function qtrans_dateFromPostForCurrentLanguage($old_date, $format ='', $before = '', $after = '') for the hook get_the_date but it actually only accepts one parameter. With the new update it accepts a second parameter $post, which now wrongly fills the variable $before that is in the process being converted to a string.
So the solution simply is to delete the two parameters that were assigned the wrong meaning and have defaults anyway.
Just a quick note, we made the Thinkery API public.
If you don't know thinkery.me, it is a simple yet powerful tool for storing both notes and bookmarks. The contents of the saved page is stored in your Thinkery which you can keep even if the webpage goes down. With #hashtags you can easily categorize everything.
Zur Abwechslung mal ein Post auf deutsch. Ich bin Fan der (inzwischen abgesetzten) Fernsehsendung Genial daneben. Es gibt da eine Genial Daneben Datenbank mit (nahezu) allen Fragen, die in den Sendungen vorkamen. Ohne konkreten Nutzen habe ich diese Daten aus der Text-Form in eine echte Datenbank konviertiert (Script hier) und bin zu folgender Tabelle gekommen. Für alle die es interessiert:
Fragen: 2732 (1087 beantwortet, das sind fast 40%)
|Teilnehmer||Teilnahmen||gelöst||gelöst pro Teilnahme|
|Hella von Sinnen||390||202||0.52|
|Christoph Maria Herbst||20||3||0.15|
|Jürgen von der Lippe||19||3||0.16|
|Eckart von Hirschhausen||9||0||0.00|
|Bürger Lars Dietrich||7||2||0.29|
|Hans Werner Olm||6||0||0.00|
|Cindy aus Marzahn||6||0||0.00|
|Michael "Bully" Herbig||2||1||0.50|
|Badesalz (Gerd Knebel und Hendrik Nachtsheim)||1||0||0.00|
|Markus Maria Profitlich||1||1||1.00|
|Matze Knop (als Franz Beckenbauer)||1||0||0.00|
|Ulrike von der Gröben||1||0||0.00|
Ich habe den Großteil der Daten nicht überprüft, aber im Groben dürfte es stimmen.
Just a quick note in order to save someone else searching for a solution to this problem.
When you want to display HTML content in an Android WebView do it like this:
String html = "my >b<HTML content>/b<. 100% cool.";
WebView webView = (WebView) findViewById(R.id.myWebView);
webView.loadData(">?xml version=\"1.0\" encoding=\"UTF-8\" ?<" + html.replace("%","%25"), "text/html", "UTF-8");
If you don't replace the % to its url encoded equivalent you will get a "Web page not available". Simple, arguable but not at all apparent.
It happens quite often to me that I start committing things and only afterwards decide I should have created a new branch.
git status says something like:
Your branch is ahead of 'origin/master' by 4 commits.
but I don't want to push to origin/master but rather create a new branch. (Of course this works for any other branch, not named master)
So you can use this sequence of commands:
git checkout -b newbranch
git push origin newbranch
git checkout master
git reset --hard origin/master
1. creates a new branch pointing to the current changes (and switches to it)
2. pushes this new branch including the changes to the server
3. switches back to the branch master
4. and undoes the changes that were made locally
The important thing to know is that the changes remain in the repository because a branch is merely a pointer to a commit.
Afterwards you can continue to commit to master, for example:
(screenshots done with a fork of gitx)