May 31
My Sites: My Blog | My Tech Blog | Follow me on Twitter
—-

It’s amazing, isn’t it? Even a sneeze at google makes the headlines. Well, it’s not the sneeze today but the new favicon I just got. So, are you also seeing the all new, re-designed, artisticly polished “g” as the new favicon?

New Google Favicon

In other news, my Twitter-Webcam integration post has bypassed my earlier lifehacked post about Remote File Access Through E-mail by more than a few thousands, even though the time difference between the two posts is more than 3 months. Thanks Stumble Upon :)


—-
If you liked this post, then you can Subscribe to my feed
Quote of the day: “If there are any questions, direct them to that brick wall over there.” — Network President

written by Shantanu Goel \\ tags: , , , , , , , ,

May 26
My Sites: My Blog | My Tech Blog | Follow me on Twitter
—-

If you think that all geeks do is walk around wearing thick glasses, code in unreadable languages and make weird gizmos from parts scrapped out of your junkyard, well you think wrong. We do like to have our share of fun. And what better to begin the day with a nice hot cuppa along with some geeky humour. Folks, here it is, the 5 comic strips that I love the most (in no particular order):

1. Dilbert: Our friendly neighbourhood engineer is in town. Have fun reading through his daily life’s traumas. Of course, his tragedies couldn’t be as funny without the able support of the likes of Wally, Asok, dogbert, catbert, and yeah the “pointy haired manager”.

2. XKCD: Don’t know if this is the abbreviated form of something but the author calls it a webcomic of romance, sarcasm, math, and language. You’d be frowning at your monitor screen right now, trying to understand the relation between these things but you know the saying, There is the biggest order behind the biggest chaos (or something, I just made up that saying just now :-) )

3. Userfriendly: This is a story about a small ISP with your regular, average joe, sys-admins having a fun time at the expense of their unsuspecting management and, of course, about Pitr who has bigger plans for world domination than even google.

4. Ctrl+Alt+Del: Your last resort on Windows is now your daily appetite in the form of this little story about (mis)adventures of a group of nerdy friends who just love to get into trouble, all while playing that game of Halo with one hand (and that too tied behind their backs).

5. Penny Arcade: If you are a gamer, you can’t miss this. Even “Jack Thomson” couldn’t, so you know, this one is a keeper ;-).

So, go and have a nice time and yeah, don’t forget to tell me about what are your favourite tech comics.


—-
If you liked this post, then you can Subscribe to my feed
Quote of the day: Homer: [drunk] Look, the thing about my family is there’s five of us. Marge, Bart, Girl Bart, the one who doesn’t talk, and the fat guy. How I loathe him.

written by Shantanu Goel \\ tags: , , , , , , , , ,

May 01
My Sites: My Blog | My Tech Blog | Follow me on Twitter
----

If you have ever had these errors or just want to be prepared in case they pop up somtime (and they surely will), then read on as I discuss various situations that lead to them and also their solutions.

I generally use desktop clients (mostly blogjet, but also Windows Live Writer and Scribe Fire sometimes) to blog to my WordPress based blogs. Some months ago, I started getting "Http 406: Not Acceptable" error while posting a particular post. Tried posting through the WordPress inbuilt TinyMCE editor, but got the same result. A little bit of research told me that this was because the post contained some words that were considered harmful by the "mod_security" plugin for apache that had been installed by my host to prevent hacking attempts. The quick resolution was to include the following lines in my .htaccess:

CODE:
  1. <ifmodule mod_security.c>
  2. SecFilterEngine Off
  3. SecFilterScanPOST Off
  4. </ifmodule>

Sure enough, I put them in, published the post, and it worked. But since this meant opening up my site to the real hacking attempts, I commented them out and went about my work, occassionally turning them on as and when required.

But, a few days ago, after a server upgrade, the problem reared its head again, and in a more vicious manner. I started getting the dreaded 406 error again, and this time for any post, even a blank post, and through all clients. But this time, TinyMCE was working without issues. A little bit of looking around my site told me that the problem was that my desktop clients were not able to connect to my "x mlrpc.php" file which is responsible for taking care of all the remote api provided by WordPress. Trying to access it through any means provided the 406 error. My site's error log was filled with:

An appropriate representation of the requested resource /x mlrpc.php could not be found on this server.

Now, the xml rpc methods are used not just by WordPress but many other CMS's (like drupal, joomla, etc) and sure enough a quick search resulted in many similar reports for all the platforms. Enabling my previous mod_security options resulted in "503: Server misconfiguration" errors, complicating things further.

On seeing the error logs, I found that the server could not understand the options, and then I discovered that the mod_security had been upgraded to and it wasn't backward compatible with old options. Modifying the options to their latest counterparts also didn't work, as further wading through mod_security manual told me that now, its options cannot be overridden through .htaccess and can only be changed by the web admin.

I found that my host has basically blocked the x mlrpc.php file from being accessed at all instead of using proper rules for blocking only the attacks while allowing valid accesses. This was the problem that a huge number of people are also having and moreover they (like me) are not able to convince their hosts to switch to proper rules.

However, not all hope is lost. I have "fixed" this issue with a workaround for now. It is pretty simple really. Just rename your x mlrpc.php to something else (e.g. myrpc123.php) and also replace all references to it in your CMS with your new file name. You can use sed to automate this task. I used perl however:

CODE:
  1. perl -e 's/x mlrpc.php/myrpc123.php/gi' -p -i *

Now, the 406 errors should be gone. If this worked for you, or you had any issues let me know. Also, if you have any other workarounds/fixes of your own, do drop me a word.

Note: In the above article, please ignore the space between "x" and "mlrpc" as the mod_security rules prevent them from being in content also. Moreover, use some unique name for rpc file.


----
If you liked this post, then you can Subscribe to my feed
Quote of the day: Ralph: Me fail English? That's unpossible.

written by Shantanu Goel \\ tags: , , , , ,

May 01
My Sites: My Blog | My Tech Blog | Follow me on Twitter
----

I installed google toolbar (linux version) today in firefox and for this blog, it says that its page rank is 7. I can't believe my eyes. I suppose it's a google glitch may be (but have a wishful thinking at the back of mind that its true :-) ).

Are you getting the same result for this blog (or weird page rank results for other places that you frequent?)

tech_shantanugoel_com_pagerank_7_thumb


----
If you liked this post, then you can Subscribe to my feed
Quote of the day: Grandpa: My Homer is not a communist. He may be a liar, a pig, an idiot, a communist, but he is not a porn star.

written by Shantanu Goel \\ tags: , , , , ,

Apr 12
My Sites: My Blog | My Tech Blog | Follow me on Twitter
----

Everyone wants to make a name for himself. Everyone wants to do something new and extra-ordinary. People like me (read software engineers) want to develop “something” cool. BUT, the stage where most of them go wrong is the very first one. Most of them think that the road to develop something cool starts from a particular “language” or a tool. But I beg to differ. I say the first stage is “The Idea”.

Most of my friends and others around me think that having a particular skill set is very important to develop something the world hasn’t seen till now. And for this they end up reading through piles of books, which claim to make them a master in C, C++, PHP, Python, Web 2.0 and what not. This is all OK, but the problem is, when they have gone through the books, done all the exercises, made all the samle projects, then they have a question in their minds “Now What”?

What I think is that this question should have been asked in the very beginning of the journey. And it should have been answered by the occurrence of a new idea.

Don’t get me wrong. I’m all for reading books, developing skill sets, learning new technologies, etc. But the only point I want to make is that all this is a “means” to give your “idea” a shape. They are not where your story begins. What if you spent a lot of time acquiring perl skills and then when (and if) you get your brilliant idea, you find out that the best way to implement it would be using C. Are you back to square one? No. Skills acquired are never a waste. “Concepts” developed can easily be applied to the new tool that you have to use.

But one more thing, its again not a hard rule that now you should just sit in your chair all day long and keep thinking. I bet its much harder to get the idea stream flowing that way. Ideas don’t have a pattern that they follow while coming into your mind. They may come to you any place unexpected (I get most of mine while bathing ;-) ).

But there is something you can do to ensure that your brain gets accustomed to recognize an idea when you do get it. So, while you are reading through that book on C programming, don’t just get engrossed in typing out the exact source code that’s fed to you. “Think” about whether is that enough? Can you make some modification to it so that it becomes more efficient? Can you tweak it a bit to do more than its already doing?

Keep your eyes open when you go around your daily chores. Think when you open your door whether wouldn’t it be nice if the door could recognize you are there and open itself. There’s your idea. And while you are at it, think wouldn’t it be even nicer if your home would have poured you a cool drink itself when you enter it?

Now, tell me whether you would like to wait to think about these ideas till you read the book’s epilogue, or do you want to start thinking now?


----
If you liked this post, then you can Subscribe to my feed
Quote of the day: "There's a time and a place for everything, and it's called college." -- Chef

written by Shantanu Goel \\ tags: , , , ,

Apr 11
My Sites: My Blog | My Tech Blog | Follow me on Twitter
----

Updated my WordPress plugin shantz-wp-qotd to version 1.2.2 today.

Introduction: Shantz WP QOTD is a plugin to add quotes to your wordpress blog in a few easy clicks. It adds quotes to your posts and your sidebars with a multitude of options for sources and customization.

Changelog:

Version 1.2.2

  • Fixed a bug because of which quotes were blank some times. Thanks to Thom for reporting it.

For more details and download, go to Shantz WordPress QOTD Home Page


----
If you liked this post, then you can Subscribe to my feed
Quote of the day: "Kenny's family is so poor that yesterday, they had to put their cardboard box up for a second mortgage." -- Cartman

written by Shantanu Goel \\ tags: , , , , ,

Apr 07
My Sites: My Blog | My Tech Blog | Follow me on Twitter
----

Situation: You are migrating your WordPress blog from PHP4 to PHP5 (intentionally or being forced to as you web host won’t support PHP4 anymore). Most of the times, this is as simple as adding some simple lines to .htaccess (e.g. AddHandler application/x-httpd-php5 .php ). And you might not notice any issues. But many of you still do. The issues range from weird page layouts, to some controls not working, to some errors popping up here and there, and probably your blog not even displaying. This occurs because even though WordPress is PHP5 compatible, some of the plugins you are using might not be. But even if you ensure that all your plugins are PHP5 compatible, there is still one more problem that I just saw today.

Problem: My host supports both PHP4 and PHP5. I decided to migrate my personal blog to PHP5 today by adding the aforementioned line to my .htaccess. Immediately, my blog disappeared, and in its place, all that was left was a few errors:

[07-Apr-2008 12:11:49] PHP Warning:  flock() expects parameter 1 to be resource, boolean given in /…/wp-cache-phase2.php on line 105
[07-Apr-2008 12:11:49] PHP Warning:  fopen/…/wp-cache-e3ba4b7161eb59d50c5e976a0b66782a.meta) [<a href='function.fopen'>function.fopen</a>]: failed to open stream: Permission denied in /…/wp-cache-phase2.php on line 240
[07-Apr-2008 12:11:49] PHP Warning:  fputs(): supplied argument is not a valid stream resource in /…/wp-cache-phase2.php on line 241

Note: I’ve deleted the exact file paths above for security reasons.

It gave me an idea that it had something to do with wp-cache. When I tried to open the settings for wp-cache, it again gve error that web server doesn’t have the permissions to write the file wp-cache-config.php, wp_cache_mutex.lock etc.

Continue reading »


----
If you liked this post, then you can Subscribe to my feed
Quote of the day: Ralph: Me fail English? That's unpossible.

written by Shantanu Goel \\ tags: , , , , , , , ,

Apr 07
My Sites: My Blog | My Tech Blog | Follow me on Twitter
----

Many users reported errors while activating the version 1.0.1 of my WordPress plugin shantz-wp-prefix-suffix. I tracked it down to a typo that crept into the release somehow. So, if you are using it, then download the fixed version 1.0.2 from the shantz-wp-prefix-suffix homepage.


----
If you liked this post, then you can Subscribe to my feed
Quote of the day: Grandpa: My Homer is not a communist. He may be a liar, a pig, an idiot, a communist, but he is not a porn star.

written by Shantanu Goel \\ tags: , ,

Apr 06
My Sites: My Blog | My Tech Blog | Follow me on Twitter
----

Tweetup_logo_73x73_bigger

  • If you are twittering kinds, doesn’t matter online or offline
  • If you blog or are interested in all things blog and blogging
  • If you live in Delhi, have lived there, have been there, or just connect with Delhi somehow else
  • If you want to meet up with your fellow twitterers and bloggers

Then you’ve got to be a part of the your very own City of The People With Hearts, Delhi. How, you ask? It’s as simple as pointing your mice and keyboards towards Delhi Tweetup to get the latest on every scoop about blogging, twittering and blogging and twittering in Delhi (and outside as well).

And if you want to be a little bit more involved, you can also join the Delhi Bloggers’ Yahoo Group.


----
If you liked this post, then you can Subscribe to my feed
Quote of the day: Grandpa: My Homer is not a communist. He may be a liar, a pig, an idiot, a communist, but he is not a porn star.

written by Shantanu Goel \\ tags: , , , , , ,

Apr 06
My Sites: My Blog | My Tech Blog | Follow me on Twitter
----

Some time back I had posted a little hack to fix an issue that users of i3theme have, i.e., their right sidebar drops to below the main content area in IE6. But it wasn’t that good as it took care of only the situation when this phenomena was caused by the tag cloud widget. So, here is a little modification I did to fix the issue more properly.

1. Go to your wp-content/themes/<i3theme> folder and open the style.css file in your favourite text editor.

2. Search for “#sidebar” (without the quotes) until you reach the following code:

CODE:
  1. #sidebar-right,
  2. #sidebar-left {
  3.  width: 210px;
  4.  color: #666666;
  5.  line-height: 160%;
  6. }

3. Now, modify this code to look like:

CODE:
  1. #sidebar-right,
  2. #sidebar-left {
  3.  width: 210px;
  4.  color: #666666;
  5.  line-height: 160%; 
  6.  word-wrap: break-word;
  7. }

4. That’s it. Save your file and you are done.

So what does it do? Basically I just added an attribute “word-wrap: break-word” to the sidebar handling. So, if there is a word that cannot fit in the sidebar width, the word will be broken to continue in the next line and thus the sidebar alignment will remain intact. let me know if you face any issues with this.

Note that this particular word-wrap property is Internet Explorer specific. Firefox (and other browsers) will ignore it, but since the problem with sidebar alignment occurs only with IE, so it will enable IE to display your site properly.


----
If you liked this post, then you can Subscribe to my feed
Quote of the day: Grandpa: My Homer is not a communist. He may be a liar, a pig, an idiot, a communist, but he is not a porn star.

written by Shantanu Goel \\ tags: , , , , , , , , ,