Articles RSS Feed

Blite Blog

Blite : a lightweight blog app

Blite 0.1-beta8 Available

Posted 21 May 2012, 11:30 am in Blite Development

This beta is now obsolete and should not be used.

This beta focuses primarily on commenting — how commenting is integrated into index.php and how submitted comments are processed.

Changes:

  1. Rewrite of index.php with respect to the integration of comment posting. This includes changes to how the comment form is built and populated with data, as well as changes to the use of cookies and the PHP session.
  2. Add basic 'flood protection' for comments. In Settings > Comments there's a new option "Wait between comments". Set it to something like 30 (seconds) to stop people posting rapid-fire comments.
  3. Add simple 'duplicate post' check for comments. A comment is refused if it (the comment body) is identical to the last comment posted. Of course this is easily circumvented, but it helps slow down the 'paste-and-post' spammers.
  4. Implement "close comments" for a post. I was going to postpone this feature until the next major version as it required a database change, and I've been trying to avoid database changes for v. 0.1. But when I looked again at the db I saw that I'd included a field specifically for this purpose, but forgotten about it. :)
  5. Moved the comment form layout to a subtemplate in items.php (in the theme).
  6. Rewrite of GET variable processing in index.php for better handling of URL manipulation.
  7. "Fix" word wrap for IE in the javascript editor (IE8 and IE9). But there's still an issue: the caret position is lost when word wrap is toggled.
  8. Various tweeks to the default theme.

Download:

Install:

Upgrade from Beta 7 or earlier:

If you have created a custom theme it will remain in place. However, if you are upgrading from an old beta you may notice display issues as the templates have changed slightly in the last two betas. Have a look at the default templates for comparison.

There are several new preferences on the Settings page which do not exist in your database. Immediately after upgrading you should go to Settings, review everything and click 'Save'. The new preferences are added to your database when you save.

13 Comments
Comments RSS Feed
Nick:
Great. Continue the development strongly!!
25 May 2012, 12:40 am · Permalink
ZAY:
Had the following error while trying to run this:

The data directory set in the configuration does not exist.

Sqlite is installed (how can I check if it is running)? The sqlite DB file is located in root and I have chmod to www-data (both folder and the file itself).

Any idea what might have gone wrong?
7 June 2012, 5:58 pm · Permalink
Doug:
The error means that the path you have set in configure.php for $cfg['datadir'] is incorrect. Maybe there's a typo? What do you have there?

Sqlite doesn't run as a daemon like MySQL. It's called by PHP when needed. Once you get the above error fixed, you'll get a new error if sqlite isn't available. Hopefully you don't :)
7 June 2012, 7:44 pm · Permalink
ZAY:
@Doug: Thanks for your quick reply, here is what I have on that line:



// Absolute path to database directory (no trailing slash).
$cfg['datadir'] = "/root/sqlite";


And here is what I have in my setup:

# ls
blog.sqlite schema-01b8.sql
# pwd
/root/sqlite


The directory looks correct as far as I can tell....
8 June 2012, 2:09 pm · Permalink
Doug:
ZAY wrote:
$cfg['datadir'] = "/root/sqlite";

/root is readable/writable only as the root user. Hence the PHP process cannot access it. /root is not a good location to store files that need to be accessed by any user other than root.

Move your database directory to another location that is read-accessible by all users, for example, /var/sqlite

/var is typically accessible by all users. So create /var/sqlite, put your sqlite database there, then as root do chown -R www-data /var/sqlite, where www-data is the user under which PHP runs.
8 June 2012, 8:28 pm · Permalink
ZAY:
Wow, this worked, thanks a lot for pointing it out! Have a good weekend!
8 June 2012, 8:45 pm · Permalink
ZAY:
Actually just noticed another issue, if you delete the only post (default post) in the blog, then the website does not work anymore rather than give a no post warning. But this is some really good stuff, thanks for the great work!
8 June 2012, 8:47 pm · Permalink
Doug:
Zay: that issue (about deleting the only post) has been fixed. I'm hoping to have a new release out in a few days, but that depends on my workload. It might be delayed until next weekend.

Thanks for trying Blite and reporting back!
8 June 2012, 9:16 pm · Permalink
I've setup a copy of blite on my web server at http://titanicbrowsing.eu so I can blog about the development of my proxy script.

Unfortunately when I try to access the site my browser gets stuck in a redirect loop, is there a way to fix this?
9 June 2012, 10:49 am · Permalink
Doug:
Rhys Streefland wrote:
Unfortunately when I try to access the site my browser gets stuck in a redirect loop, is there a way to fix this?

Probably the same bug that ZAY noted above. Happens when you remove the test post and have an empty blog (no published posts). It's fixed for the next release.

Meanwhile you might replace your sqlite database with the one in the beta8 .tar.gz file, which has one post, then create a new published post of your own before removing the test post.
9 June 2012, 11:04 am · Permalink
Yeah, thanks! I only noticed that it was caused by deleting the first post after I reinstalled it and did exactly the same thing again :)

Its working amazing now though, and its incredibly fast. Good work with the development, I'm definitely going to keep using blite!
9 June 2012, 3:28 pm · Permalink
Doug:
Good to hear, Rhys.

One note: don't invest a lot of time in theming yet. There's numerous theme-related changes in the next release. Hopefully after that it'll be stable.
9 June 2012, 7:19 pm · Permalink
Ok thanks, I wasn't planning on theming the blog much anyway because I just wanted a place to post some updates really :)

Keep up the good work!
13 June 2012, 10:43 am · Permalink
Comments are closed for this post.