Planet Hoyer

April 16, 2012

Hartwin Hoyer

Install WordPress on Fedora 16

Here are the steps to install wordpress with a fresh Fedora 16:

Get super user rights:
su -

Install mysql-server:
yum -y install mysql-server

start your mysql database:
service mysqld start

connect your mysql client with your mysql server:
mysql -u root

Configure your wordpress mysql database (use your own username and password):

mysql> create database wordpress;
Query OK, 1 row affected (0.00 sec)


mysql> grant all privileges on wordpress.* to wordpress@localhost identified by 'wordpress';
Query OK, 0 rows affected (0.00 sec)


mysql> flush privileges;
Query OK, 0 rows affected (0.00 sec)


mysql> exit

Install WordPress:
yum -y install wordpress

Edit /etc/wordpress/wp-config.php and change database_name_here, username_here and password_here to the values you provided in the grant sql statement above. Here it would be ‘wordpress’ all three times. The beginning of the config file looks like this:

define('DB_NAME', 'wordpress');

/** MySQL database username */
define('DB_USER', 'wordpress');


/** MySQL database password */
define('DB_PASSWORD', 'wordpress');


/** MySQL hostname */
define('DB_HOST', 'localhost');

The wordpress package installed a httpd config file at /etc/httpd/conf.d/wordpress.conf the following:

Alias /wordpress /usr/share/wordpress

Start your Apache:
service httpd start

Access wordpress at http://localhost/wordpress in your browser. Follow the installation instructions.

Login -> voila

by Hartwin Hoyer at April 16, 2012 14:21

March 27, 2012

Hartwin Hoyer

Installed my own Theme

I made a new theme which you can see here. The theme is going to change in the future, but this is the basic structure of it. It is using html5, css3 and no images.

by Hartwin Hoyer at March 27, 2012 19:39

March 26, 2012

Hartwin Hoyer

Set up phpeclipse for WordPress on Fedora 16

This time we are going to set up phpeclipse to create a Theme for WordPress on Fedora 16. WordPress is installed at our localhost.

We are creating a symbolic link to our workspace. With this configuration, we can change the code on the fly without pushing the code to wordpress every time.:
mkdir -p ~/workspace/themes/mytheme
sudo ln -s ~/workspace/themes/mytheme /usr/share/wordpress/wp-content/themes/mytheme

Install phpeclipse:
yum -y install eclipse-phpeclipse

Start eclipse:
ALT+F2 eclipse
select the workspace as default and click ok.
click: File-New-Project-PHP-PHP Project-Next-mytheme-Finish

Now we are ready to begin with our new theme.

by Hartwin Hoyer at March 26, 2012 20:48

March 22, 2012

Hartwin Hoyer

WordPress Plugin

I wrote my very first plugin for WordPress.

The only thing it does is to append a string to the name of the author of a comment if the email address of the author contains a certain string. I was using the get_comment_author filter hook of WP. It is activated whenever the author of the commentator gets out of the database.

More information about plugins and hooks in wordpress: http://codex.wordpress.org/Plugin_API

A list of the hooks in wordpress with displayed source code of the usage: http://adambrown.info/p/wp_hooks/hook

by Hartwin Hoyer at March 22, 2012 14:40