Saturday, October 3, 2009

Buddypress 1.1 Works

I've been following the development of Buddypress since it was first announced because I had been searching for a community solution that would have many of the features they announced would be included.    I had even tried an alpha version with horrible results last year.  At that point I had decided to wait until it was beyond 1.0.

qTranslate plugin incompatible


I was actually testing the 1.1 release candidate so I could help with some bugs and I did actually find one.  I also discovered that the current version of qTranslate the multilingual plugin I use totally breaks the new buddypress pages causing "page not found" or whatever your Wordpress 404 page says. This is due to something in the URL rewriting.  I reported it to the qtranslate forum on Monday, but now it is Saturday and there wasn't even a reply to my thread there. This is frustrating because Wordpress doesn't check language tags so pages that were translated display their content twice when the plugin is disabled.

The bug  I had discovered involved a Buddypress function being called when I had that feature disabled in the Buddypress configuration. I was happy to see that the if function exists check was added to the problem line of code the same day I reported it.

Buddypress adds several features and fixed one important problem.

Working Forums


The problem I had and any reader will notice is the integration of forums with wordpress. Wordpress's parent company started their bbPress forum software project before Buddypress but after Wordpress however my testing of the software over the last year only made me want to cry. It was never compatible with recent versions of Wordpress and for about a year there was always a message of it being just a month or two away of being up to date. Also the integration needed so that people wouldn't have to register and log in never seemed to work right.   When it was announced that Buddypress would use bbPress as the forum software I was brought to tears and I totally refused to try 1.0 since you had to manually install bbPress and I remember how much fun that was.

I had tried the SimpleForum software on my sites for several months and it was easy to install and configure, but when I updated my sites to Wordpress 2.8 the forums broke and no content would display even after following their instructions so that promising plugin lost my favor.

In Buddypress 1.1, special code was added so that the integration of the bbPress forum software was automated so you couldn't do it wrong. Additionally the display of forums is also handled so you don't need to log in to bbPress to edit themes and other frustrating tasks you'd want to avoid.  This is great because having to manage a separate theme for integrated forums just does not make sense.

Groups


Buddypress set up a group system which works like bbPress's main forums, but the difference here is that different users can join groups and start threads.  On a group page you can see who is part of the discussion group and the admin can manage it all there.

Friends


Being able to friend someone is fun, but the functionality is that you can invite your friends to join a group not any member.

Blog Directory and Member directory


I was surprised to discover that the system automatically added a directory of blogs (including blog 1) and a directory of members.  I thought I'd need a plugin for those, but they just appeared.

Sitewide Recent Posts


If you enable the Buddypress option to track posts, you'll discover a widget for displaying recent posts from all the blogs.  Before you needed a plugin to do that on Wordpress MU. I don't know when that was added, but I'm glad it was. It saved the installation and configuration of yet-another-plugin.

Buddypress still has much work to do even though it is officially 1.1 it still feels like a beta. Although it was announced from the beginning there still isn't a system for users to make a photo gallery.  You can use a plugin for that though.

There also isn't any way to set a membership level or be able to charge for features. (so you can pay for that dedicated server you'll need)  Since the plugin is for setting up communities, I think memberships really should be included as an essential core feature not something left for plugins.

In any case, I'm happy that the development of Buddypress is active and have great hope for Buddypress in the future.  It was nice to see that Buddypress took care of about half of my "wishlist" in the previous post.

Tuesday, September 8, 2009

Goodbye Popshops Hello Custom RSS

Goodbye Popshops, Hello Custom RSS!


You may remember that I mentioned how I was using Popshops a graphic interface system for creating product tables for affiliate websites using datafeeds. It let you include up to 99 (100?) products in a table and change the display css and column number all graphically. While this is very nice and at first I was extremely amazed by the product over time I discovered it wasn't the right product for my needs and this month I finally canceled my Popshops account.

This was actually planned this spring, but I was going to replace those product tables or "shops" as Popshops calls them, with my own custom RSS solution. Unfortunately I kept coming up with other tasks to do and kept seeing my credit card charged.  I decided to just cancel my account and spend the next couple weeks removing those old tables and add my custom display as I can.

Popshops is a good solution for people who want to have very general display of products that updates with other products from the same merchants OR people who want a few displays of products that are hand selected.  My problem was that I wanted to have UPDATING displays of SELECT products... see the problem?

Well actually it was simple. I wanted to be able to select up to 4 merchants and using positive and negative keywords show a display of products.  I had asked for that feature for their updates, but it must have been a low priority.

When I used their updating table feature, I'd get replacement products that were not very related. For example I'd have a table with men's swimsuits and I'd get baby clothes and womens bras appearing to replace out of stock or discontinued items. If  just had a general clothing site that would work, but if I call my page "Men's Swimsuits" and the site is for men's clothing there is a problem.

Yes, I could easily log in and scroll down my list of  "shops" find the offending table, remove the unrelated replacement products, do another search in their interface, and add new products. That process is much longer than just doing what I wanted to do which just takes a minute or two to get the right keyword combination and always have existing products appear on those pages.

While it is very easy to make a product table or "shop", it isn't so easy to keep them updated and relevant using that system. I really tried to keep them updated by logging in once a week and finding unavailable products and replacing them in the Popshops system, but sometimes I'd do that and find the next day that some of the replaced products are gone too! I actually got to the point where over half the products in my displays were invalid!  *sigh* Automation is important if you want to have more than one website.  Why reinvent the wheel and make busy work?  I'd rather update my code once in a while than spend a few hours a day updating product tables.      I suppose that isn't really a problem for someone with just one niche site, but with several or many sites, that's a big headache. As I said, it wasn't the right product for me, but it could be the right product for you.

In the last few months Popshops has been releasing a new API which will use positive keywords. (perhaps only one keyword) which looks like a step in the right direction, but I didn't see how that would integrate with a CMS like for the regular shops. I can't give a review of that system because I only saw an example page linked to a forum thread.  To use that you needed to have a more expensive "Data Pack"  account which now costs $59.99 a month pre-paid discounts (as of September 8, 2009). They have added some information on their website about what that service can do.  I unfortunately don't get enough website traffic to justify that expense.  If you have a high traffic website and you don't mind using an API, this might be a good solution for you. Lower traffic websites probably would find themselves breaking even or worse after subtracting their expenses.  Good economy or bad economy, you still have to renew your domain name every year, and pay for hosting in addition to fees for services like this one.

Conceptually the Data Pack service is an interesting option for people willing to program, but who don't want to go through the set up of getting and importing datafeeds from each merchant on their own hosting account.  If time is more important than money and you want to skip those steps  for your high-traffic website then this might be good for you.

Unfortunately, dear reader, I don't have any real alternative to recommend for what I wanted to do  other than to code your own system.  I found that RSS feeds are the easiest to work with when managing external content. That way if you switch from Wordpress to Joomla or Joomla to Drupal, etc.  you can just figure out how to import RSS and your display will still work.   I coded my own PHP display as RSS taking information from my mysql tables which got their info from merchant datafeed files. Sound complicated? yes, it was. It took me about a year to learn how to program in PHP and at least a couple months learning how to use mysql, automating my datafeed imports and at least a month working on the display and search options.  It isn't for the unmotivated. You have been warned.  :-)

Thursday, April 30, 2009

Google Adsense Google Analytics Integration FINALLY available

Integrate Google Adsense with Google Analytics


Way back in October Google Adsense's blog officially launched integration for Adsense with Analytics so you'd actually know when your blog posts or pages are getting clicks and be able to optimize even more.  I don't know about you, but I found the Adsense channels not very interesting and sometimes more confusing.

The Problem with Adsense channels


Yes, if you set up a channel for a site you'd know that a site was getting clicks, but without knowing which URLs or URIs were getting the clicks, there wasn't much you could do.

One big question I have is if people are clicking just on product info pages, category pages, coupon pages, blog post pages, etc.?  If people are only clicking on ads on certain pages then I could perhaps use a larger format on them and remove ads from the pages that don't get clicks.

I'd also be able to compare the content and see if a certain writing style or a specific topic or category were getting clicks IF I could see those statistics.

From October my excitement turned to worries of vaporware. It is hard to stay focused and excited after seeing almost half a year go by without an update on the Google Adsense blog. In fact, I had forgotten about it until yesterday I saw the  link in my Adsense statistics telling me I can integrate... It took me a while to remember what that was about and I spent this morning adding Analytics code to my header and footer only loading when no Wordpress cookie is set since normally the logged in user is me 99% of the time.

The Google Adsense Analytics integration solution


Google Adsense integration with Google Analytics adds a new "Adsense" menu item under "content" in Google Analytics's sidebar menu.  If you click on that you'll see statistics on how much money was earned for that website profile and you CAN see which page was clicked on!

You can also see information about the people who clicked on an advertisement like the city they live in.  Perhaps you'll want to make a post just for that visitor next time.  Another great feature to the integreation is the ability to see clicks by referrer (website that linked to you!), so if you got a link from another blog or a forum and someone clicked through and then clicked on a Google Adsense advertisement on your website, there'd be a reference there. This can be useful because you could work more with those sites to get more traffic and hopefully make more money to pay those hosting & domain registration bills!

The Adsense report page is now very detailed with the common statistics to help you understand your CPC earnings. You get statistics per impression, per visit, per Adsense unit,  and Click Through Rate. The pages with the most earnings and the top referrers are listed right below.

I think the pages with the most earnings will be great. The usual pages with the most visits will not necessarily be the pages with the most earnings. I'm excited again! Thank you Google for finally making statistics available. I'll be checking it often.

Tuesday, February 10, 2009

My Love-Hate Relationship with WordPress

I love WordPress, but I hate it too!

I love WordPress because it is easy to use, install, and configure. I also love WordPress because it is updated 2-3 times a year so I don't worry about it not working with the next version of php or mysql.

I hate it because it is getting fat. This last few weeks I've been busy optimizing my own PHP scripts for better perfomance because i noticed some pages loading slowly. I've even redistributed my mysql tables and optimized mysql database table indexes. I also turned off and deleted many WordPress plugins thinking that work help. Yes,  they all did help. Unfortunately they didn't help enough. WordPress too often ends up in my "slow queries" log generated by my shared hosting.

After several months of integration of my php shop scripts with WordPress, I cut the cord!  I commented out the include file that loads the Wordpress backend so I could use the Supercache page caching plugin.

I saved around 10-18 queries!  I don't know why WordPress needs to do around 10-18 queries (depends on the version) just to let me load a plugin on an external page, but that is what Supercache was showing and I finally decided that it wasn't worth it.

Why did it take me so long to do it?  I had to set up my own page caching first.  Fortunately there are several php output or page caching script samples online. I tried one and after finding all of the bugs in the script that kept it from working I fixed it up and have it installed and working.

How much faster are external pages loading?  Comparing the processing time between the supercached versions of my external pages and the time with my own caching script. Some pages are loading between one third and one sixth of the time it took before while others are loading in about the same amount of time.  Page processing time is a good metric, but it isn't precise because it varies according to current server load. If the server is under more load, a script will take a little longer so you have to compare averages.

Another motivating factor in my decision to cut the cord to WordPress on my external pages are the somewhat recent changes to Supercache.  I'm sure Donncha has very valid reasons for doing so, but he removed the notice in HTML comments that a cached page was being served, so I couldn't easily tell if the cache was working or not ( often times it didn't appear to be serving the cache even though the files were being created).

Not really being able to tell if the cache was working or not was the straw that broke the camel's back for me. I don't like working on blind faith when it comes to my web hosting and server stability.

Don't you love it when fixing one problem helps solve another? By setting up my own separate cache, I was able to disconnect the WordPress backend and speed up pages. It made me want to do a dance of joy.

What's next in caching?  I am thinking about setting up a menu cache for dynamically created menus on the shop category and shop discount pages.  If you notice an additional speed up in the next few days on those pages, now you'll know why.

Do you cache your php output or menus?  If you haven't already set up caching today!

Friday, February 6, 2009

Heavy Serverload? Add a bad bot trap before you upgrade.

Reduce server load by blocking bad bots (and help stop spammers and sploggers)


If you're like me you are probably on a shared hosted server because
  1. You don't have a static IP or extra computer from having your sites server from home
  2. You can't afford a dedicated server.

I've noticed on my second hosting account, HostGator, that I was using many files, but many more than I really have in my website folders on my computer  and I realized that those extra files were mostly from my website cache. The cache files are created when a dynamic page loads so the next time it is called the cache is used instead of calling the database for everything.

What is a Bad Bot?


I had read in several forums that it is a good idea to block "bad bots" bad bots are internet spiders that read and copy your content for Splogs (Spam Blogs) or to steal e-mail addresses to spam. Obviously neither are good, so  I ...
  1. Added my robots.txt
  2. A few days later added my trap which points to a path blocked in my robots.txt

How does a Bad Bot Trap work?


You add  some code to your pages to a page that is blocked in robots.txt but you hide the link from human visitors. When a "bad bot" visits your website it will ignore your robots.txt instructions and follow the link. When it lands on your forbidden page, your script registers its IP address in your .htaccess file to deny access to your website.

Does a Bad Bot Trap block all Splog and Spam Bots?


While a bad bot trap does not block all spammers and sploggers using bots, it does get rid of many. Spammers and sploggers aren't very ethical so most never bother  to update their bots to check your robots.txt file to see what is allowed or not.

Because I had added some code to e-mail me whenever a bad bot was blocked, I got regular notices.  I found many sites sending me an e-mail per day about a bad bot being blocked!

About a week after adding my bot trap, I needed to go to my Hostgator control panel to open Phpmyadmin to make some changes to a database  and I noticed the sidebar showing a huge drop in files.

Although I have been trying to eliminate unnecessary files and I have combined a few include files into one with functions, It wouldn't explain the huge drop I saw.

I don't have exact numbers, but my files according to Hostgator went down by about one third. The only explaination I can think of is that blocking bad bots kept many pages from being loaded into cache.  That saves plenty of space and significantly reduces server load without hurting real visitors or reducing features.

Before you upgrade your hosting account, add a bot trap, perhaps it will be enough.

Friday, January 30, 2009

Wordpress MU 2.7 Finally Released!

WordPress MU was just recently released and I've upgraded several of my websites without any problems or error message through out the upgrade process.  It even includes a nice horizontal toolbar on top in addition to the sidebar. I'm very happy with this release for the same reasons mentioned in my previous post regarding WordPress 2.7.

The only real bug I've found is with upgrading plugins. After upgrading one plugin, the upgrade options disappear for a day or so ( I haven't actually timed it).  I'll still see a number by Plugins in the menu, but the options on the plugin page are gone!  This bug first appeared in MU 2.7 "bleeding-edge" when regular 2.7 came out. I reported it informally at the time.

Another thing that is needed for WordPress MU is a way to select all users and all blogs on the page without clicking each one. This is important for not wasting time deleting splogger registrations. I've been fighting the battle and losing against sploggers due to the lack of effective solutions. A simple CAPTCHA is not enough and after several months of this drudgery I've removed the signup link and I've disabled user blog signups. Hopefully in future versions we'll be able to limit signups/per day/month by IP and other tools that could help. Currently in WordPress MU you only have the option to list domains you want to blog signups for, but I've noticed that since .info domains are cheap for the first year, a splogger could easily register hundreds of those. As soon as I block one, they register with another.