Technology

WordPress Comment Stats Query

KarmaDude Jan 14, 2009 2 Comments

Here is a query you can run against your WordPress comments table to view total comments by year and month. If you use a different table name prefix, then substitute ‘wp’ with your table name prefix.

SELECT year(comment_date) as y, month(comment_date) as m, concat(substr(monthname(comment_date),1,3), " ", year(comment_date)) as month, count(*) as total
FROM wp_comments
GROUP BY y, m
ORDER BY m, y ASC

Apple’s Suggested Fix For iPhone 3G GPS Malfunction

blogswami Aug 8, 2008 4 Comments

My iPhone 3G GPS thinks I am in Minnesota even though I am in Utah. So I called up Apple support, and here is their simple set of steps to supposedly solve the GPS issue! Did not work for me though.

  • Go to Settings->General
  • Turn Location Services Off
  • Go to Home Screen
  • Go back to Settings
  • Turn Airplane mode on and wait 20 seconds
  • Turn Airplane mode off
  • Go to Home Screen and then back to Settings->General
  • Tap on Reset, and then Reset Network Settings (WARNING: You will lose all your network settings)
  • Go to Home and the Settings->General
  • Turn Location Services On

Seriously, is this a joke or some wizard at Apple sat and figured this sequence! Here is a suggestion, Settings->General->Reset->Reset GPS Settings, now that would have been an Apple like solution.

WordPress 2.5 Duplicate Autosave Drafts

KarmaDude Mar 31, 2008 Add comment

After upgrading to the recently released WordPress 2.5, I have been noticing duplicate autosave draft posts. Looks like this issue is caused by the use of custom fields in posts. The number of duplicate draft posts increases with the number of custom fields being used. There is an issue logged for this, and a discussion related to this issue underway in the forums.

The duplicate drafts are not deleted after the post has been published, and would require manual deletion. If you are experiencing this issue, then here is the suggested work around from the forum:

Before creating your custom fields SAVE your post.

UAE Bans Facebook

KarmaDude Feb 24, 2008 2 Comments

Facebook Blocked in UAE
If you live in UAE, then the internet just got even more boring for you, with UAE banning Facebook due to ’sex clubs’ and unislamic lifestyle groups on Facebook. Facebook joins a long list of popular sites blocked in the UAE including: Flickr, Twitter, Orkut, BoingBoing, YouTube, Metacafe, MySpace.

If the ‘unislamic’ nature of the site is what leads to these bans, then I wonder how many Islamic terrorism related sites are blocked by UAE!? But I feel these bans are superficial, and probably there to impress the Islamic fundamentalists, because within UAE, in the free trade zones like Media City, and Internet City, none of these sites are blocked.

Now, if you are not in one of these privileged areas, then here are some ways you can access the blocked sites:

  • If possible, VPN into an outside network, and if the VPN server is not blocked, you will be able to access all the sites.
  • For Flickr access try the Access Flickr Firefox add-on which is supposed to circumvent filters in Iran, UAE, Saudi Arabia, China, and other banned locations.

Apple retail store invoice to the rescue

KarmaDude Dec 29, 2007 Add comment

Apple Bose InvoiceApple retail stores provide a very convenient feature by automatically emailing the invoice after a purchase from the store. Yesterday, this simple feature came to the rescue when an invoice was required for product warranty confirmation. My wife had recently purchased a pair of Bose Triport Headphones from the Apple retail store in Salt Lake City, Utah, and during our travel to Dubai, the cheap connector on the headphones came apart. Not what one would expect from a $192 pair of headphones, and so my wife was really pissed off.

Since she wanted the headphones for her trip back to US and the product was still under warranty, we decided to try the Bose service center in Dubai to see if they could provide a replacement connector. After a couple of calls, and callbacks, we finally found the Bose service center, which is located opposite Cars Garage in Dubai. So, yesterday we headed there, and the service technician was able to get us a replacement connector. However, without the invoice the connector was going to cost us about $16.

There was no way I was going to pay $16 for a connector still under warranty, so the quick thinking geek and miser in me, quickly spotted the pc at the service center, and once internet access was confirmed, I got on Gmail, did a search for the keyword “Apple”, downloaded the pdf invoice of the purchase, and walked out with the free connector. As simple as that, it felt great, and kudos to Apple for thinking up such a convenient feature.

Even though that ended great, the service center technician still had to print out the invoice, which I felt was unnecessary. I guess old habits die hard; the entire process could have been digital with a simple forward of the invoice from my email to the service centers email.