The autoblog project
-
Technical informations
Requirements
For webmasters to adopt the replication system, it must be light, easy to setup and require no maintenance.
We want it to run on as many hosts as possible, thus we need to keep requirements to a minimum.
We want to stick to the KISS principle (Keep It Simple, Stupid).
Features
- Single file source, no dependencies.
- Less than 400 lines of php.
- Fast.
- Reads RSS 2.0, RSS 1.0/RDF and ATOM feeds.
- No database (like mySQL) required.
- Simplified URLs (No mod_rewrite necessary).
- Paging.
- Search engine included.
- Media (images,txt,pdf,odt) are cached locally.
- Automatic refresh from the feed by simply visiting the page.
- Source feed caching (updates at most once per hour) (Forced refresh is possible).
- Republishes the articles in a RSS 2.0 feed.
- Articles deleted from the source remain visible on the autoblog.
- Provides a link to download the config file (
vvb.ini
)
and the database (store
) for easy cloning.
- Works with php5 (does not work under php4).
Files
VroumVroumBlog consists of 3 files:
index.php
: The program itself (less than 400 lines of php).
vvb.ini
: The configuration files (mandatory).
store
: The database. (Optional: Will be re-created automatically.)
Database
VroumVroumBlog does not require a database like mySQL or Postgres. It uses a simple file, store
.
This is a serialized php array.
Media cache
All media present in the article body (
src=...
and
href=...
) are downloaded in a local cache,
in the
media
subdirectory (which will be created if necessary).
Images will be downloaded only:
- if they have an absolute URL in the article body.
- if they are hosted on the hosts specified in the
vvb.ini
file, in the DOWNLOAD_MEDIA_FROM=...
parameter.
- if they have the jpg, jpeg, png, gif, txt, pdf or odt extension.
- Files larger than 4 Mb will be truncated.
Updates
The autoblog will automatically update from the source feed when someone visits the page,
except if it has been updated less than 60 minutes ago.
This ensure the autoblog is up-to-date as soon as someone visits it, without hammering the source feed.
You can force the refresh by adding ?force_the_fresh
in the URL of the autoblog.
Licence
VroumVroumBlog is public domain.
Changes
Here is the list of changes:
- 0.1.24 (anonymous) to 0.1.25 (sebsauvage)
- config is now in a separated file (vvb.ini)
- Now supports ATOM feeds (in addition to RSS 2.0)
- added link to download config file (vvb.ini) and articles database (store)
- added option to download media from other domains (DOWNLOAD_MEDIA_FROM in config)
- removed gzip compression (This caused some weird problem)
- Media download are now restricted to certain types (jpg/gif/png) (to prevent the download of webm content, for example).
- Media download is now limited to 4 Mb.
- Corrected the RSS 2.0 feed output (there was an improper encoding of description field causing problem with some websites).
- 0.1.25 to 0.1.26
- Patch by Le Hollandais Volant: Added
link rel="canonical"
in header to prevent referencing problems.
- 0.1.26 to 0.1.27
- Link to source article is now displayed on each article.
- Corrected a bug when reading the source link from RSS 2.0 feed.
- Added link to the project page at screen bottom.
- 0.1.27 to 0.1.28
- Added support for RSS 1.0/RDF feeds (thanks to BohwaZ).
- Added automatic background media download after feed is read.
- Added download of linked media (href=...).
- Added support for more media types: txt, pdf, odt.
- Added patch from BoboTiG
- When viewing an article, added source article link in
link rel="canonical"
tag url (instead of website URL).
- 0.1.28 to 0.1.29
- In RSS 2.0 feeds, if
content:encoded
is missing, description
will be used instead (eg. laquadrature.net).
- 0.1.29 to 0.1.30
- Added support for
dc:date
(Some RSS feed put the article date in this tag instead of pubDate
, typically SPIP CMS feeds).
- 0.1.30 to 0.1.31
- Added: In ATOM feed, some feed put the article date in
updated
instead of published
(such as the ATOM feed of PluxML).
- 0.1.31 to 0.1.32
- Corrected: Patched potential security flaw (XML injection) with php >= 5.2.0 (Thanks to BohwaZ).
Improved version (0.2.x series)
If you wish, there is a more elaborate version of VroumVroumBlog
published by BohwaZ (using SQLite3, translatable interface, object model, better paging...).
This version is faster and the 0.1.x series, but may not work on all php hosts.
If you want the improved version (faster, better paging, etc.), use the 0.2.x series from BohwaZ.
If you want to make sure it runs everywhere, even on crappy hosts, use the 0.1.x series (from me).
Back