Location: PHPKode > projects > phpBB Blog > docs/readme.html
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">


<meta content="text/html; charset=ISO-8859-1" http-equiv="content-type">
<title>phpBB Blog readme</title>
<meta content="Anthony Boyd" name="author">
<style type="text/css">
body, p, td, th, dt, dd, li {
	font-size: small;
dt {
	font-weight: bold;

<body style="background-color: rgb(225, 242, 196); color: rgb(0, 0, 0);" alink="#a8d59d" link="#724c21" vlink="#000000">

<table style="margin-left: auto; margin-right: auto; width: 575px; text-align: left; font-family: helvetica,arial,sans-serif;" border="0" cellpadding="2" cellspacing="2">

<td colspan="2" style="vertical-align: top;"><img alt="Meet phpBB Blog's mascot, Bob." src="logo.png" style="width: 575px; height: 195px;"><br>

<td style="width: 175px; vertical-align: top;"><a href="#Overview">Overview</a><br>
<a href="#Contrib">Contributors</a><br>
<a href="#Features">Features</a><br>
<a href="#Requirements">Requirements</a><br>
<a href="#License">License</a><br>
<a href="#Installation">Installation</a><br>
<a href="#Upgrade">Upgrade</a><br>
<a href="#Howto">Howto</a><br>
<a href="#Troubleshooting">Troubleshooting</a><br>
<a href="#Changelog">Changelog</a><br>
<a href="#Feedback">Feedback</a><br>
<a href="#Mascot">Mascot</a><br>
<td style="vertical-align: top;">

<h1><a name="Overview"></a>Overview</h1>
This is phpBB Blog, version 2.3, released January 11, 2006.&nbsp; Copyright &copy; 2006 by Tony Boyd.<br>
This is a blog tool for phpBB.&nbsp; The basic idea is this: you have a
phpBB installation already running, you've set up a forum for your
posts, and now you want to have a blog-ish page and RSS file to show
off each post.<br>
There are 3 major ways to use this product.&nbsp; You'll have to decide
which one you want to pursue.&nbsp; First, there is the default setup,
which uses the provided index.php file to display the blog.&nbsp; If
you wish to use that, see the <a href="#Installation">Installation</a> heading, below.&nbsp;
Second, there is the option to bypass the provided index.php file, and
simply embed the blog display into your pre-existing home page.&nbsp;
To do that, see the <a href="#Howto">Howto</a> section, below.&nbsp; The third option is to
embed a mini-blog into your pre-existing home page.&nbsp; All this
displays is the title of recent posts.&nbsp; If you're interested in
that, see the <a href="#Howto">Howto</a> section, below.<br>

<h1><a name="Contrib"></a>Contributors</h1>
<p>Thanks to aetolus & wileyD.  The extra features are appreciated!
UPDATE for 2.3: new blog comment interface thanks to MissP!  Also,
the RSS feed should now be iTunes compatible, thanks to Boum.</p>

<h1><a name="Features"></a>
Features include an RSS 2.0 feed for syndication;
full support for BBCode, smileys, and avatars; permalinks with
first/next/previous navigation; trackbacks; 7 different stylesheets to
choose from; and as many Geo-URL settings as possible (so you can get
listed in all those blog indexes that categorize you by location and/or
language).  Oh, and it integrates with
<a href="http://www.outshine.com/podcast/">phpBB Podcast</a>, too.<br>

<h1><a name="Requirements"></a>
PHP 4.10 or greater.&nbsp; Apache 1.3.x or
2.0.36+ on Unix or Linux.&nbsp; It might run on IIS and/or Windows -- I
don't know.&nbsp; A working phpBB 2 installation is needed.&nbsp; While
this will work with any database that phpBB can use, MySQL support is the
most extensive.<br>

<h1><a name="License"></a>
My code is licensed to you under a GPL
license, which should have been included with all these files.&nbsp;
The general summary of the GPL license is that you can use my code for
free, even in a commerical business.&nbsp; And you can modify my
code.&nbsp; But you must keep the license, keep the attribution, and
any changes you sell or give away must also be GPL.&nbsp; It is not
public domain.&nbsp; Do not remove <a href="license.txt">license.txt</a>.<br>

<h1><a name="Installation"></a>
<ol><li>Before anything else, you should have a working installation of phpBB.
In addition, you should have set up a forum for your blogs.</li><li>Unzip the
file you downloaded. If you're reading this, you've already done it. After
unzipping, you should have 2 folders: blog &amp; docs.</li><li>One
of the files in the blog folder is called settings.php. Open that in a
text editor. You'll need to give attention to the first 220 lines or
so. Change each setting, using the comments as a guide.</li><li>Save
settings.php, and upload the entire "blog" folder to your Web server.
If an existing folder named "blog" already exists, be careful. I'm not
liable for stupidity, so don't overwrite your important stuff.</li>

<li>Note that you should change the extension (the .php part) of each PHP file
to match what you use in phpBB.  So if you changed all your phpBB files to use
.php4 for the file extension, then you need to change phpBB Blog similarly.
HOWEVER, do NOT change settings.php.</li>

up the blog/createtable.php (or .php4, or whatever you named it :) page in your Web browser. If you get an
error message, check that you typed in the correct URL, and then check
your settings.php file to be sure you entered the URLs &amp; paths
correctly.  If you get stuck, try dropping the included pwd.php file into your
phpBB directory, and view it in a browser.  Does the setting it recommends
match with your settings.php file?  Once everything is OK, if you are using a MySQL database,
you should get a message that a table has been created for you. If you
are using any other database (or if the MySQL code didn't work) you
will get some instructions on how to create the new database table
manually, which you should do. Once the table is ready, remove the
createtable.php file from the blog directory on the server.</li><li>Finally,
pull up the blog/index.php page in your Web browser. Do the entries
appear as you expected? If so, you're done. If not, see the
<a href="#Troubleshooting">Troubleshooting</a> section, below.</li>
<li>OPTIONAL: If you already have a home page and want the blog to appear as part of it, see the <a href="#Howto">Howto</a> section, below.</li></ol>

<h1><a name="Upgrade"></a>
Upgrading to 2.3</h1>

<p>Many, many lines changed.  There is no quick patch for this.  So we'll
basically reload the files.  <strong>This only works for a normal install</strong>.
If you custom-integrated the blog into your existing home page, you may have to
review these steps and adapt them to your situation.</p>

<li>Open your pre-existing settings.php file, and transfer/copy any settings
you wish to keep to the new settings.php file.</li>
<li>Review the new settings.php file for all the new fields that have been
added.  Change whatever you like.</li>
<li>Save the new settings.php file.</li>
<li>Backup the blog directory on your Web server.  You can just make a copy of
it somewhere, nothing fancy.</li>
<li>Upload everything in the new blog directory to your server.  In other words,
overwrite your pre-existing, working phpBB Blog directory with the <em>new</em> blog directory.</li>
<li>Delete createtable.php from the server (you already ran that file during the
original install, don't need it now).</li>
<li>Change the extension (the .php part) of each PHP file to match what you use
in phpBB. So if you changed all your phpBB files to use .php4 for the file
extension, then you need to change phpBB Blog similarly. HOWEVER, do NOT change
<li>Test the blog.  If it works, you're done.  If not, see 
<a href="#Troubleshooting">Troubleshooting</a>, or smile happily and take
advantage of that backup you just made.  :)</li>

<h1><a name="Howto"></a>
<dt>I saw in the changelog that it's possible to delete spam trackbacks.  How?</dt>
<dd>Go to your phpBB forum, and login. Then go to your blog, and click a trackback link. You will see checkboxes by each trackback listed, and a "delete" button at the bottom of the list.  The option to delete should only appear if <em>you wrote the blog entry</em>. I tried to make it very secure, so you can't switch logins before hitting the delete button, or spoof. Hopefully. :)</dd>
<dt>How do I embed the blog in my existing home page?</dt>
<dd>First go through the <a href="#Installation">Installation</a> steps.  Then come back here.  OK.  Ready?
Often this is very easy. There are two steps.
First, you must include the settings file at the very top of your page,
before any HTML or other code appears. To do so, just place this one
line at the top of your page: <p>&lt;?php include_once('blog/settings.php'); ?&gt;</p> Second, you need to include the file blog.php.  This should be placed wherever you want the blog listing to appear:    <p>&lt;?php include_once('blog/blog.php'); ?&gt;</p>
If it doesn't seem to work, make sure you put that line after the
&lt;body&gt; tag. If you've done that, make sure your home page is also
PHP. So if your home page was index.html, rename it to index.php. The
page should continue to work just fine, but now it should grab the blog
file and display the entries. If you still have problems, check the
path. For example, if you renamed the blog folder to "journal" then the
correct path might be "journal/blog.php". Finally, the blog listing
will probably be ugly until you add a stylesheet. You can just copy the
stylesheet line in the index.php file I've provided.</dd>
<dt>How can I have multiple blogs on a single page?</dt>
<dd>Assuming you have a single blog working already,
making the jump to multiple blogs is easy. First, embed as many blogs
as you want, but don't use the "include_once" command. Use "include"
like this: <p>&lt;?php include('blog/blog.php'); ?&gt;</p>
Sprinkle that throughout your page, wherever you want it. If you try
viewing the page at this point, you should have many blogs all showing
the same entries. To get each to show a different set of entries, you
just need to override the $forum variable with a new number. Like this:
<p>&lt;?php $forum=5; include('blog/blog.php'); ?&gt;</p>
So if you add $forum=# (where # is the number of a forum) right before
each include command, you'll be able to have many different blogs on a
<dt>How am I supposed to send out pings if you haven't built it into phpBB Blog?</dt>
<dd><a href="http://pingomatic.com/">http://pingomatic.com/</a></dd>
<dt>How do I queue up posts/blog entries for future release?</dt>
<dd>You do it manually for now. I suggest creating a
private forum that only you have access to, and work on them there.
When an entry is ready, you can post to the "real" blog forum.</dd>
<dt>How do I make the blog show only my posts?</dt>
<dd>You have to set up a forum that allows only you to
post (don't worry, people will still be able to reply). To do this, log
in to phpBB as the admin, and go to the administration panel. Under
Forum Admin you'll see a Management link. Go there and create a new
forum. Next, also under Forum Admin, you'll see a Permissions link. Go
there and select your new forum. On the page that appears, use the
Advanced Mode link. Now you'll see a page with lots of settings to
change. Under "Post" change it to Admin. You might also want to change
"Sticky," "Announce," and "Poll create." Save your changes. Now you
have a forum that will contain only your posts. Set up the blog to use
<dt>How do I stop people from replying to my posts/blog entries?</dt>
<dd>Same as the previous answer, but when you get into the Advanced Mode area, change the "Reply" option to admin.</dd>
<dt>What is the blog_mini.php file for?</dt>
<dd>It just displays a simple list of blog titles.
Although it was planned for version 2.0, it didn't make it into any of
the betas. So I'm happy to sneak it in, and I feel that (as it is very
simple) it is stable. But without testing, it seemed right not to
mention it anywhere but here. To use it, just add two lines to your
index.php (or whatever file you want the list to appear in). First line
includes the settings file, and it should be at the tip-top of the page
(first thing): <p>&lt;?php include_once('blog/settings.php'); ?&gt;</p>
If you already have that line at the top of your page, you don't need
to double-up. Second, you need to include blog_mini.php. This should be
placed wherever you want the list to appear: <p>&lt;?php include_once('blog/blog_mini.php'); ?&gt;</p>
Note that you can also include one of the provided stylesheets to style
the list. However, it's just one style, blog_box. You could just copy
that one item to your existing stylesheet. In settings.php,
"$max_blogs" controls how many titles to show.</dd>

<h1><a name="Troubleshooting"></a>
<dt>I'm getting LOTS of errors.  What do I do?</dt>
<dd>First, you ARE using phpBB forums, right? This program requires
phpBB to be installed and running first. If everything is OK with
phpBB, the next thing to review is your settings.php file. Double-check
everything you entered. Did you escape the single-quotes in any data
you entered? Did you put trailing slashes on the URLs you entered? Is
the path to phpBB correct? The settings file mentions putting pwd.php into
your phpBB directory and running it.  Have you done that?  Does your settings
file match the results?  Make your fixes and try again.</dd>
<dt>Still getting errors.  Any other ideas?</dt>
<dd>Yes.  If you're using a custom/tweaked index.php file, did you include both the settings.php file AND the blog.php file?</dd>
<dt>I get this error: "Warning: Cannot modify header information - headers already sent..."</dt>
<dd>This means that you didn't include settings.php at the very top of
your page. This PHP code:
<p>&lt;?php include_once('settings.php'); ?&gt;</p>
MUST BE THE FIRST LINE. Of course, be sure that the correct path to
settings.php is listed. For example, a common path is
<dt>I get this error: "SQL Error: 1146, Table doesn't exist."</dt>
<dd>You closed the database connection, or changed the default
connection. This happens a lot if you've integrated multiple PHP
projects on your page. The solution is to re-establish the phpBB
database connection. Or hunt down the offending code and eliminate it.
For example, if code from another project uses mysql_select_db() to
change the default database, phpBB won't be able to talk to the
database it expects. Remove the conflicting code, and the problem is
<dt>I get "404 file-not-found" errors with the trackback feature.  Why?</dt>
<dd>If you're running a non-Apache web server, then your guess is as
good as mine. If you're running Apache 2, you need to use version
2.0.36 or above. Also, trackback relies on Apache's AcceptPathInfo
directive. Be sure that is enabled. See here:
<dt>Trackback says, "no trackbacks found."  What's wrong?</dt>
<dd>Nothing.  It's working and waiting for trackbacks to come in.</dd>
<dt>How come I don't get archive links like everyone else?</dt>
<dd>The SQL query for the archive is MySQL only (it's tricky). If you
use PostgreSQL or MS SQL, the archive feature won't appear. If you can
give me sample SQL that works for non-MySQL databases, I'll add it.</dd>
<dt>Why is the blog page showing lots of posts I don't want?</dt>
<dd>It's possible you set the variable $forum to the wrong number. In
that case, just go back into the forum you want, and scrutinize the
URL. You should find the correct forum number there. Change $forum and
try again.</dd>
<dt>I think some of your blog variables and stylesheet names are
stomping on my pre-existing stuff! For example, you applied a style to
the &lt;table&gt; tag &amp; it's affecting ALL my other tables! Do you
plan to fix this?</dt>
<dd>Yes, although I do not find it urgent. If you're smart enough to be
doing PHP or CSS work on your own, you're smart enough to rename
things. But I agree that this is less than desirable. I plan to use a
single, uniquely- named array for everything in a future release.
UPDATE for 2.3: the table, th, and td tags are no longer styled.</dd>

<h1><a name="Changelog"></a>Changelog</h1>
<dt>CHANGES FROM 2.2.2 TO 2.3</dt>
<li>The $phpEx variable is (mostly) respected now.  This is a setting in phpBB's
extension.inc file, which controls what extension your files use for PHP.
However, settings.php should <em>not</em> have its file extension changed.</li>
<li>Trackbacks can now be disabled via the settings.php file.</li>
<li>A comment system has been integrated with phpBB Blog.  This
allows you to show comments right in the blog, rather than sending the reader
into the forum itself.  This feature is optional.  Thanks MissP!</li>
<li>Stylesheets no longer try to style all your TABLE, TD, and TH tags.</li>
<li>When doing a fresh install on top of phpBB 2.0.18 and 2.0.19, there was a bug that
prevented createtable.php from creating the table.  Fixed.</li>
<li>The RSS feed should now be iTunes compatible.  Thanks Boum!</li>
<li>The RSS feed now properly links to the permalink.</li>
<li>Fixed a calendar bug -- the months Jan 2006 & May 2005 now display properly.</li>
<dt>CHANGES FROM 2.2.1 TO 2.2.2</dt>
<li>Smileys weren't showing for people who used absolute paths in the config.
Fixed.  Thanks to isaacr for the bug report!</li>
<li>Minor corrections to this file.</li>
<dt>CHANGES FROM 2.2 TO 2.2.1</dt>
<li>Added a calendar.  This feature was entirely implemented by wileyD.  Thanks!</li>
<li>Added pwd.php -- a tool to help those having trouble with $phpbb_root_path
in the settings file.</li>
<dt>CHANGES FROM 2.0.1 TO 2.2</dt>
<li>Integration with <a href="http://www.outshine.com/podcast/">phpBB Podcast</a>.  Install phpBB Podcast, and phpBB Blog will automagically start podcasting.</li>
<li>Added a new stylesheet called museum.  It looks more like a Moveable Type style.</li>
<li>Fixed the GEO meta tags, they were all plain HTML, but I prefer XHTML.</li>
<li>Added meta tags for author, geo.country, and dc.language.  See settings.php.</li>
<li>Cool! Figured out a system to remove spam trackbacks.</li>
<li>Added Google's nofollow attribute to the trackback links. This means that even if a spammer manages to get listed in your trackback page, their spammy little link will be IGNORED by Google.</li>
<li>Got rid of every single "php short open tag" -- replaced with normal tags. This gets rid of the requirement to have short open tags enabled.</li>
<li>Rewrote the documentation as a single HTML file.</li>
<li>Fixed typo ("Transistional") in index.php and trackback.php.</li>
<li>Various fixes.</li>
<li>Laid claim to some of my own artwork so that phpBB Blog could have a mascot.</li>
<dt>CHANGES FROM 2.0 TO 2.0.1</dt>
<li>Changed the meta tag in index.php, it should display international characters better this way (I still don't know why -- UTF8 should be the true international character set -- but everyone told me otherwise, so it's changed).</li>
<li>Removed the optional super-shorten function, as no-one appeared to be using it.</li>
<li>Added avatars as an optional feature. This is mostly just incorporating the mod from aetolus. I made tiny changes to make the code XHTML compliant. See settings.php if you wish to enable this. Thanks aetolus!</li>
<li>Revised the help file, added some entries for database connectivity problems.</li>
<dt>CHANGES FROM 1.0.1 TO 2.0</dt>
<li>Changed license from BSD to GPL.</li>
<li>Added trackbacks!  This enables your blog to GET trackbacks.  I have not built anything to SEND trackbacks.</li>
<li>Fixed trackbacks!  Thanks to erikbjohn for the bug report!</li>
<li>Added option (in settings.php) to hide stickies &amp; announcements.</li>
<li>Added GEO features.  Your blog can now appear on the map at "World as a Blog."</li>
<li>Added LINK tag in index.php to point to rss.php.</li>
<li>Moved many variables to settings.php, so they can be reused.</li>
<li>In order to closely match whatever phpBB does, I now include() phpBB's "common" file. This adds overhead, but it allowed me to make 3 changes: dropped my $quick_config stuff, standardized on phpBB's $board_config; dropped my MySQL code, standardized on phpBB's database abstraction layer. My system should now handle any database that phpBB handles; my system now uses phpBB's naughty-word filter &amp; smiley function.</li>
<li>I also pull in phpBB's bbcode file, so phpBB Blog now handles bbcode.  Hoo-hah!</li>
<li>RSS 0.91 is limited to 15 entries, and 500 characters per entry. None of you guys followed that. :) So I upgraded rss.php to output RSS 0.92. No limits.</li>
<li>RSS 0.92 offers no date field. Bloglines was listing ALL blog entries with the current time. So I upgraded rss.php again, to use the RSS 2.0 "pubDate" tag.</li>
<li>Since it was already using RSS 2.0 features, I added ttl to rss.php.  Helps aggregators to know how often to check your site.</li>
<li>Added permalinks to blog.php. After the first beta, I changed permalinks to point at the phpBB Blog page, and included extra navigation goodies (previous entry, next entry, and first entry). In this way someone could come into the blog and read through everything in chronological order.</li>
<li>I added the guid tag (also a permalink) to rss.php.</li>
<li>Changed the rss.php file to output UTF-8. I had to. I can't predict what character set each person might be using. UTF-8 is a good catch-all.</li>
<li>Added keywords.  I can't believe I didn't have this before.</li>
<li>Made cleanup function case-insensitive. Previously, tags with miXEd CasE were parsed improperly. Now phpBB Blog "understands" more, and is harder to fool.</li>
<li>Changed the way I built the image/logo tag, so it shouldn't display a broken image icon if you choose to leave the image settings blank, and if you DO have an image, it now uses the height and width tags for faster display.</li>
<li>Dropped support for scattering the blog files anywhere and renaming them. Now the blog system expects the files to remain as named, and to all be grouped together in the same directory -- although you can still name the directory whatever you want, or even drop all the files into your top-level directory. This allowed me to remove a few variables that hardly anyone used.</li>
<li>Created a new index.php with a new layout.</li>
<li>Added archives in the sidebar. This only displays if you use a MySQL backend, but eventually other databases will get to join in the fun.</li>
<li>Added TONS of stylesheets for the new layout.</li>
<dt>CHANGES FROM 1.0 TO 1.0.1</dt>
<li>mookie found a bug: old blog entries were re-appearing at the top of the blog page whenever comments were added. Fixed. Thanks mookie!</li>
<dt>CHANGES FROM 0.9 TO 1.0</dt>
<li>Updated the docs.</li>
<li>Split blog.php into index.php, blogstyle.css, and blog.php.  This should allow for templating.</li>
<li>Create settings.php and move all config options there.  Add lots of extras.</li>
<li>Split the dot function into shorten &amp; cleanup functions. Give both more awareness of HTML to avoid broken tags, add space where needed, etc. Add a super_shorten function as an alternative for the adventurous.</li>
<li>Add settings to allow for # of blogs displayed, as well as options to truncate long entries.</li>
<li>Add # of comments, timestamps, parting shots, and profile links.</li>
<li>Various other little improvements.</li>

<h1><a name="Feedback"></a>
Please note that <strong>no support is provided by the developer</strong>.&nbsp;
However, there is a community-based forum for discussion.&nbsp; If you
have questions, bug reports, code improvements to share, feedback,
and/or feature requests, go here:
<a href="http://www.outshine.com/forums/">http://www.outshine.com/forums/</a>

<h1><a name="Mascot"></a>Mascot</h1>
The mascot's name is Bob.&nbsp; He is an orca.&nbsp; I originally
created him for NetBSD, but I didn't win their logo contest.&nbsp; For
a while, I left Bob for any other BSD project that needed a mascot, but
no one claimed him.&nbsp; On March 3rd, 2005, I finally decided to
claim him for myself!&nbsp; I like him.&nbsp; He's happy.<br>
Bob is Copyright &copy; 2004 by Tony Boyd.  Please do not use him for anything
other than phpBB Blog.  Thanks!<br>
-Tony Boyd<br>
Return current item: phpBB Blog