Upgrading to WordPress 2.1 Tip

I upgraded to WordPress 2.1 recently and I want to share a tip. I uncompressed the new WP 2.1 files into a new directory. I name it wordpress2.1 then I upload the entire new directory to my server. When I was ready to switch to the new version, I jus renamed the current wordpress directory to something like wordpress2.07. Then I renamed the new version to match the name of my official wordpress directory (ie – wordpress). This way, I have a clean install and I still have the old version to cut back to if something went wrong.

If you look at the WordPress upgrade instructions, it'll tell you to delete certain files and don't delete certain files. Seems kinda of messy to me. Below are the steps I took. Keep in mind my situation will be different from your setup, so you will need to modify the steps to suit your needs.

  1. Download and extract WP 2.1 to a new directory named wordpress2.1
  2. Back up the database by using the WordPress backup plugin or phpMyAdmin
  3. I made a change to template-functions-post.php in the old version of WordPress to alter the behavior of the more tag, so I had to make the change in the new version. In WP 2.1, I had to make the change in a new file called post-template.php.
  4. Copy the following files from the old WordPress directory to the new directory:
    • wp-config.php (it's in the root wordpress directory)
    • plugins (except Akismet because WP 2.1 comes with a new version of Akismet)
    • theme files
  5. Deactivate the plugins (don't forget to write down special codes, like the Akismet api key, in case you need to re-enter them after you re-activate the plugins)
  6. Rename the old wordpress directory (ie: wordpress –> wordpress2.07)
  7. Rename the new wordpress directory (ie: wordpress2.1 –> wordpress)
  8. Run the upgrade script (load …/wordpress/wp-admin/upgrade.php in the browser)
  9. Reactive the plugin one by one

Remember, the above steps are for my situation. You will need to look at the WordPress upgrade instructions and modify the above steps for your setup.

free eWeek

CoolPlayer 9

Andot just rolled out version 9 of his cool CoolPlayer plugin for WordPress. With this new version, you no longer have to hack the plugin to use a local version of the RPC Server. You can specify the location of the server in the admin area (options -> coolplayer). By default, the plugin points to a RPC Server in China. But you can easily change it now. Not only that, you can also set options and test the plugin from the admin page:

CoolPlayer 9 admin menu

Note: It appears your web server needs to support php mbstring and sockets extension in order for the RPC Server to work locally. So if you can't get the RPC Server to work locally, you will have to use the RPC Server in China.

coolplayer tag from WordPress post menuThe new version of CoolPlayer supports both the plain text editor and the rich text editor in WordPress. Now you can insert the coolplayer tag directly from the create/edit post page by clicking on the coolplayer button. This version also fixed the auto play problem in FireFox. Now the video doesn't auto start unless you want it to. The audio player also has a new skin:

CoolPlayer audio player

The embedded player supports these types of files: rm, rmvb, ra, rv, ram, smil, smi, rtsp, rpm, asf, wm, wma, wmv, wax, wvx, ogg, ape, avi, mid, midi, wav, mms, m3u, asx, mov, qt, mqv, m4v, m4a, m4b, mpeg, mpg, m1s, m1v, m1a, m75, m15, mp2, mpm, mpv, mpa, flc, fli, cel, aiff, aif, aifc, cdda, bwf, rts, 3gp, 3gpp, 3g2, 3gp2, au, snd, ulw, smf, kar, qcp, sdv, gsm, amr, caf, amc, mp4, sdp, pdf, fdf, xfdf, xdp, xfd, gif, jpg, jpeg, bmp, png, xpm, dir, dxr, dcr, cst, cct, cxt, w3d, fgd, swa, swf, spl, mp3, flv, rtmp, rbs, xml, rss, xspf, atom.

It also supports YouTube, Ifilm, VSocial, TuDou Video, Evil Chili, Wildko, Yikers Videos & Games, Red Balcony Videos & Games, Live Video, Odeo Audio, Revver, MetaCafe, MySpace, GoEar, Break, Stupid Videos, DailyMotion and Google Video.

The installation is fairly simple. Just download, extract, upload folder to your plugin directory, and activate. I recommend testing the player plugin first before uploading the RPC Server locally. To install the RPC Server: download, extract, upload the files to your coolplayer folder, and activate. Then change the location in the options -> coolplayer menu.

free creative and multimedia magazines

Here's an example of the video player in action:

Continue reading

Someone Hacked Me to Pieces

So far, the last few days have been really crappy. First, the medical bill came in for my 14-month old daughter's 30-minute surgery. It was over $10,000. The HMO will pay a good part of it, but the amount I owe will still be staggering. Kinda puts a damper on Christmas and Thanksgiving (yes, I am thankful my daughter is OK now).

The second reason why things are crappy is because Akismet does not appear to be working on my blogs. Every few minutes, I get an email to approve a comment that has about 100 links in it. This has been going for a few days now. And it is getting reaaaaallllly ANNOYING.

Then there's my daddy blog, which was hacked early Saturday morning. Somehow, a hacker was able to insert a script and a bunch of links above the WordPress template's code. The hacked stuff loads before <!DOCTYPE html section of each web page. I downloaded my templates and I didn't see any modifications to my templates. I deactivated all the plugins and selected the default WordPress theme. It didn't make a difference. I upgraded to WordPress 2.0.5 from 2.0.4 and the hack is still there. I couldn't figure out how to resolve the problem so I submitted a ticket to my web host. Seven and a half hours later, they reply with something like, "We don't support third party applications and perhaps your password has been compromised."

That was really helpful. It's possible my password was compromised, but I didn't see any tampering of any of my files. I really don't understand how the hacker was able to insert the extra code before the html header. Makes me wonder if the web host has some sort of WordPress related virus that was doing it. I created a non-WordPress page and it loaded without any additional code. So, the problem is WordPress related.

The next thing I did was uninstall WordPress. I didn't want to do this, but I didn't see how I had any choice (my content was not viewable). So, after uninstalling, I reinstalled the latest version. Then I restored the database from back-up. Guess what? I got the exact same result with the default theme. I didn't upload my plugins so the only ones enabled were the ones that came with WordPress (Akismet and Database Backup).

At this point, I was wondering if the hack occurred in the database. To test this, I restore the database to another site with a different web host (#2). This time, the hack was gone. The database was fine. Since my blog was now working correctly, I had web host #2 change the domain name to daddyforever.com and then I change the entries for the name servers to point to web host #2. The dns propagation could take up to 48 hours, but I saw the change in less than 24 hours. But it wasn't what I was expecting. I could no longer connect to my site at web host #1 or #2. I didn't want to be Chicken Little, so I waited several hours before asking web host #2 to recheck their work. Sure enough, they discovered they made a mistake in the dns setup on their end.

My daddy blog is now back online after two days. I still have no idea how the hack occurred. The morale of the post? Back-up often.

free Internet Retailer

Cool Player Plugin

[Update: Version 9 of CoolPlayer is out and you no longer need to use the hack mentioned in this post]

I've been playing with the Cool Player plugin for WordPress since yesterday. The plugin allows you to play multimedia files in your blog. I've only tested the plugin with mp3 and wmv (Windows Media Video) files, but the plugin is suppose to work with all of these types of files:

Google Video, Youtube Video, vSocial Video, ASF, ASX, WM, WMA, WMV, WAX, WVX, OGG, APE, AVI, MID, MIDI, WAV, SWF, SPL, MP3, FLV, RM, RMVB, RA, RV, RAM, SMIL, PDF, FDF, XFDF, XDP, XFD, MOV, QT, MQV, MPEG, MPG, M1S, M1V, M1A, M75, M15, MP2, MPM, MPV, MPA, FLC, FLI, CEL, RTSP, RTS, 3GP, 3GPP, 3G2, 3GP2, SDV, AMC, MP4, SDP, GIF, JPG, BMP, PNG, XPM

The plugin is suppose to work with IE, Firefox, Opera, and other browsers. I can confirm it does work with IE, Firefox, and Opera.

A nice feature about the Cool Player is being able to specify more than one file at a time (see example below). In addition, a user can can enter a media url to play by double clicking the bottom of the player.

Here's an example of the Cool Player plugin configured with two files.

Continue reading