
Category Archives: web
How to encode WordPress content properly for sharing at Twitter? (Twitter web intents & share)

If you want to create your own Twitter share button at your WordPress blog probably you’d hit an issue related with how content & URL variables are handled which causes some special characters like “&” to break the Twitter web intent/share URL . You have to encode the piece of content that you pass as a variable.
Twitter asks for proper encoding of your variables. You can read more about at Twitter web intents docs.
For the developers this issue is probably easy to solve with some common php functions like urlencode()
Meanwhile, if you’re a WordPress user and if some of titles of your posts involve special characters, you experience a glitch and at Twitter sharing window instead of a correctly typed symbols, you receive encoded characters. Most common case is receiving “%26”s instead of “&”s .
If you’re a wordpress user but not an avid developer, below is my solution that is based on javascript:
Share this information at Twitter
<a onclick="var msg='<?php the_title(); ?>';var url='<?php the_permalink(); ?>';var link='https://twitter.com/intent/tweet?url=' + encodeURIComponent(url) + '&text='+ encodeURIComponent(msg) + '&related=ogomogo&via=ogomogo'; window.open(link);" href="#" title="Twitter">Share on Twitter</a>
You have to insert this into your single.php file or index.php file or wherever you want the Twitter share button to appear inside the Loop.
Bobi (photo) – Pl. de la Concordia
How we decode ‘noisy’ language in daily life: How people rationally interpret linguistic input
A new study by MIT researchers indicates that when we process language, we often make these kinds of mental edits. Moreover, it suggests that we seem to use specific strategies for making sense of confusing information — the “noise” interfering with the signal conveyed in language, as researchers think of it.
“Hooking Users In 3 Steps: An Intro to Habit Testing”
The truly great consumer technology companies of the past 25 years have all had one thing in common: they created habits. This is what separates world-changing businesses from the rest. Apple, Facebook, Amazon, Google, Microsoft, and Twitter are used daily by a high proportion of their users and their products are so compelling that many of us struggle to imagine life before they existed.
Hooking Users In 3 Steps: An Intro to Habit Testing | Nir and Far.
Aperitivo

Minuto de silencio… Un homenaje respetuoso en honor al jabalí caído asesinado por los mossos en la calle Numancia. #Barcelona (photo)

Si no basta la ironía, para quien quiere leer más sobre este tema aquí van los enlaces publicados en la prensa. También en el Foro de Policía podéis conocer otra visión sobre el tema – mencionan la falta de recursos y formación para casos similares (como el uso de anestésicos en lugar de disparar contra el animal). Al final, aparte del animal una persona terminó herido. En este caso era, paradoxalmente, un mosso implicado en la operación pero podía haber sido cualquier vecino…
The Alchemy of Writing — Tips from a Non-Fiction and Fiction Pro
…
Castelldefels
Windy afternoon in Castelldefels – 2008 – “No es país para SUPs”


