Tag: wordpress

Write WordPress posts on the go using WordPress mobile app

Write WordPress posts on the go using WordPress mobile app

If you are like me who like to spend a lot of time browsing on your mobile phone, you are gonna love this app.

Recently i came across WordPress app on app-store. Having used a similar app earlier, I was not very hopeful but oh boy, I was surprised.

The super easy interface for this app totally blowed me away AND you can use it to manage any of your WordPress site. Thats right, it does not have to be hosted by WordPress.

Search for WordPress in AppStore and install it 


Open the app and click on login button


Click on “Log into your site …”


Enter the base url of your WordPress website


Enter username and password


If successful, it will show your profile as well as site will be added successfully


If you click on your site, it will take you to a nice interface where you can manage your posts, pages, media etc. pretty much everything !!


Once you click on posts, you can click at top dropdown to toggle between published or draft or scheduled or trashed posts. You can add new posts or edit existing one’s. This is pretty amazing

Once done editing you can add tags to the post or publish it right from your mobile phone


Try it out and let us know what you think about this cool app

how to use code syntax highlighter in wordpress

how to use code syntax highlighter in wordpress

One of the thing that you absolutely need for a technical blog is to have some kind of syntax highlighter to make code examples easy to read.

When i started this blog, in my first blog itself i started missing syntax highlighter.

I started to search for one. Following was my selection criteria:

  • Has to support multiple languages
  • Should be easy to setup
  • Should be easy for me to highlight code with just css class

I tried to install a few wordpress plugin but none worked per my expectation.

So i started to search for highlighter which does not have to be a wordpress plugin and i found highlight.js which looked promising And it worked perfectly fine when i tried it for few languages:

  • YAML
  • Dockerfile
  • Go lang

For embedding this with my WordPress installation i had to modify header.php file as follows:

<link rel="stylesheet" href="https://rajatjindal.com/highlight-js/styles/default.css">
<script src="https://rajatjindal.com/highlight-js/highlight.pack.js"></script>
<script>hljs.initHighlightingOnLoad();</script>

Once i did this, highlighting code was as easy as follows:

<pre><code class="yaml">---
kind: Service
apiVersion: v1
metadata:
  labels:
    k8s-app: k8s-awesome-service</code></pre>

which will be displayed as follows:

---
kind: Service
apiVersion: v1
metadata:
  labels:
    k8s-app: k8s-awesome-service

I do plan to use this extensively for other programming languages as i learn and write more.

I will update the post after a few weeks as i use it more