Book Image

Elgg Social Networking

By : Mayank Sharma
Book Image

Elgg Social Networking

By: Mayank Sharma

Overview of this book

<p>Elgg is an open-source social web application licensed under GPL version 2, and runs on the LAMP (Linux, Apache, MySQL, and PHP) or WAMP (Windows, Apache, MySQL, PHP) platform. It offers a networking platform combining elements of blogging, e-portfolios, news feed aggregation, file sharing, and social networking. Elgg has its own plug-in architecture, and can use plug-ins to provide a calendar and a wiki. It supports a number of open standards including RSS, LDAP for authentication, FOAF, and XML-RPC for integration with most third-party blogging clients. It can be integrated with MediaWiki, Moodle, Drupal, and WebCT.<br /><br />Elgg provides each user with a personal weblog, file repository (with podcasting capabilities), an online profile, and an RSS reader. Additionally, all of a user's content can be tagged with keywords&acirc;&euro;&rdquo;so they can connect with other users with similar interests and create their own personal learning network. However, where Elgg differs from a regular weblog or a commercial social network (such as MySpace) is the degree of control each user is given over who can access their content. Each profile item, blog post, or uploaded file can be assigned its own access restrictions&acirc;&euro;&rdquo;from fully public to readable only by a particular group or individual.<br /><br />Using Elgg is the easiest way to create your own fully customized, hosted social network for your business, organization, or group of friends. Elgg communities can include blogs, discussion groups, media galleries, friends' lists, and much more. Because it's open source, and has many plug-ins, Elgg can be extended in unlimited ways. Elgg lets you host your own Facebook-style social network and retain complete control over how it works. This book shows you all you need to know to create safe, fun social networks.<br />&nbsp;<br />While anybody can use Elgg to create their social network, it is especially useful in education as it has many features making it suitable for e-learning, including groups, communities, and blogs that can be used for online classes where students can communicate in a new way with each other and with students around the world&acirc;&euro;&rdquo;in a managed, protected environment, creating what its authors term a "personal learning landscape". This book also covers using Elgg in teaching/learning.</p>
Table of Contents (14 chapters)
Elgg Social Networking
Credits
About the Author
About the Reviewer
Preface

Appendix A. Installing Elgg

In addition to its impressive feature list, Elgg is an admin's dolly. It can install in the popular Linux web application rollout stack of Linux, Apache, MySQL, and PHP, fondly referred to as LAMP. As MySQL and PHP can run under Windows operating system as well, you can set up Elgg to serve your purpose for such an environment.

Setting Up LAMP

Let's look at setting up the Linux, Apache, MySQL, PHP web server environment. There are several reasons for the LAMP stack's popularity. While most people enjoy the freedom offered by these Open Source software, small business and non-profits will also be impressed by its procurement cost: $0.

Step 1: Install Linux

The critical difference between setting up Elgg under Windows or Linux is installing the operating system. The Linux distribution I'm using to set up Elgg is Ubuntu Linux (http://www.ubuntu.com/). It's available as a free download and has a huge and active global community, should you run into any problems.

Covering step-by-step installation of Ubuntu Linux is too much of a digression for this book. Despite the fact that Ubuntu isn't too difficult to install, because of its popularity there are tons of installation and usage documentation available all over the Web. Linux.com has a set of videos that detail the procedure of installing Ubuntu (http://www.linux.com/articles/114152). Ubuntu has a dedicated help section (https://help.ubuntu.com/) for introduction and general usage of the distribution.

Step 2: Install Apache

Apache is the most popular web server used on the Internet. Reams and reams of documents have been written on installing Apache under Linux. Apache's documentation sub-project (http://httpd.apache.org/docs-project/) has information on installing various versions of Apache under Linux.

Ubuntu, based on another popular Linux distribution, Debian, uses a very powerful and user-friendly packaging system. It's called apt-get and can install an Apache server within minutes. All you have to do is open a terminal and write this command telling apt-get what to install:

apt-get install apache2 apache2-common apache2-doc apache2-mpm-prefork apache2-utils libapr0 libexpat1 ssl-cert

This will download Apache and its most essential libraries. Next, you need to enable some of Apache's most critical modules:

a2enmod ssl
a2enmod rewrite
a2enmod include

The rewrite module is critical to Elgg, so make sure it's enabled, else Elgg wouldn't work properly.

That's it. Now, just restart Apache with: /etc/init.d/apache2 restart.

Step 3: MySQL

Installing MySQL isn't too much of an issue either. Again, like Ubuntu and Apache, MySQL can boast of a strong and dedicated community. This means there's no dearth of MySQL installation or usage related documentation (http://www.mysql.org/doc/).

If you're using MySQL under Ubuntu, like me, installation is just a matter of giving apt-get a set of packages to install:

apt-get install mysql-server mysql-client libmysqlclient12-dev

Finally, set up a password for MySQL with:

mysqladmin -h yourserver.example.com -u root password yourrootmysqlpassword

Step 4: Install PHP Support

You might think I am exaggerating things a little bit here, but I kid you not, PHP is one of the most popular and easy to learn languages for writing web applications. Why do you think we are setting up out Linux web server environment to execute PHP? It's because Elgg itself is written in PHP! And so are hundreds and thousands of other web applications.

So I'm sure you've guessed by now that PHP has a good deal of documentation (http://www.php.net/docs.php) as well. You've also guessed it's now time to call upon Ubuntu's apt-get package manager to set up PHP:

apt-get install libapache2-mod-php5 php5 php5-common php5-gd php5-mysql php5-mysqli

As you can see, in addition to PHP, we are also installing packages that'll hook up PHP with the MySQL database and the Apache web server.

That's all there is to setting up the LAMP architecture to power your Elgg network.