Sometime back I wrote a step-by-step guide for setting up PHP development environment in a virtual machine. This is a simplified (& less tiring) version of that.
You’ll need a few things to proceed:
- A computer, ofcourse. I used a MacBook Pro running OS-X Lion.
- Oracle’s VirtualBox VM software – get it from here.
- A linux distro. We will use Ubuntu Server here. Current LTS version is 12.04. Download the 32 bit ISO from here. Remember to download 32 bit version, the 64 bit version is kinda sluggish on less than 4 GB of RAM. 32 bit version is good enough for running web development stack unless you have specific needs.
Twitter Cards are quite the rage now when it comes to sharing your stuff on Twitter. They add that zing to sharing. But there are loads of plugins for WordPress already, so why did I create my own?
Well, here’s the brief rundown:
- The ones I saw, none of them are WordPress.com VIP compliant
- Most just get the job done but the code is well….. unhealthy!
- The ones I saw, none supported player card
- I needed filters to be able to override the output etc. fully or partially
- Being the attention seeking douche I am, I wanted to roll my own plugin 😀
Its all pretty easy and neat to use. Just activate the plugin, set a few global options on plugin settings page and done. By default it produces summary card tags for all posts and pages. If you want finer control or want player card for any post or page then select the global option for control on post pages and it will provide a meta box on post/page add and edit pages in wp-admin where you can set card to player card. Read More
So Google announced that it is forking Webkit (the rendering engine which powers its Chrome browser, & Apple’s Safari among others) and will be making significant changes to it under the project named Blink. All of a sudden exasperated bemoaning of idiots started which included run of the mill phrases like “web fragmentation”, “browser wars”, etc. And all that without seeing what Blink will bring to the table? Seriously?!! 🙄 Read More
So Corey popped a question last night in company chat room on whether WordPress has an equivalent of Rails’ to_sentence() function or not. The answer was no it doesn’t, & I thought heck that can be written quick!
Here is what I wrote quickly (and updated after that):
It can be further improved, the evaluation of three cases in switch can be removed entirely as demonstrated here. Read More
A change that I pushed in iG:Syntax Hiliter v4.2 was that shorthand style tags were enabled for all languages. Apart from the GeSHi language files bundled in the plugin, you can add additional language files in the “geshi” directory of your theme and those will be picked up by the plugin. Since the architecture of the plugin relies on Shortcode API of WordPress rather than doing its own regex for tag parsing, the plugin always needs to know what language files are available to it to be able to allow shorthand style tags else the code blocks won’t get picked up by the plugin. Read More
iG:Syntax Hiliter v4.2 is now available for download. Some bugs have been fixed in v4.1 and v4.2 along with a few new additions and improvements, some of which are:
- Additional language files can be put in “geshi” folder inside current theme so that the files won’t get overwritten on plugin upgrade
- Github Gist embed XSS bug fixed
- Shorthand tags for all languages are now supported
- A code block is parsed only once, subsequent similar code blocks in same post/page use the same output, for better performance
A more detailed changelog is available here. Read More
The last release of iG:Syntax Hiliter was about 7 years ago when v3.5 was released. After that I got side tracked with other things which staked claim over my time, the plugin didn’t have any show stopper bugs & it worked fine with subsequent WordPress updates. So I kinda didn’t feel like there was any need to update the plugin, which was one of the reasons it didn’t see any updates after that. Read More
If you develop stuff on WordPress, chances are you’ll be familiar with the plugin activation and de-activation hooks. But should they be used? Or are they to be avoided? Now that’s a bit of a tricky question, as there are compelling reasons for both sides and not all are applicable to generic scenarios but deal with specific use-cases, so the decision to use them or not is subjective. Read More
I’ve been meaning to move my local development stack to a VM for sometime now. The hardware has come a long way and running a Linux server as a Virtual Machine with 1-2 GB of RAM allocated to it doesn’t break any sweat today. Setting up the development stack inside a VM has many advantages like you can mimic the production environment of your website/app, have more than one type of server environment on a single computer & OS, etc. I’m not going into details of it, everyone has their own preferences, running the setup directly on your computer has worked well so far & still works, so if you don’t feel like going the VM way then that’s cool too! 🙂 Read More
….. 8 years down the line and 6 years of hibernation, feels kinda weird that I kinda let this go into hibernation just 2 years after I started here, not because I didn’t have time but because something else caught my attention. As it happened, I was enjoying blogging in Hindi so much that the priorities just shifted without any effort towards the action & I let this blog just go into a slumber. And there’s a shift now again, I don’t blog much these days, in Hindi or English, heck, even my Photo blog doesn’t see much action! And then there’s this craving, an itch at the back of the head, to write here again, I surely didn’t stop working/coding all these years, doesn’t feel right that I should stop writing then. 🙂 Read More