To be conscious that you are ignorant is a great step to knowledge... ~Benjamin Disraeli
20 September 2005
Written by
Yours Truly (

)
Published on September 20th, 2005 @ 02:52:13 pm, using 220 words, 69 views
In b2evolution 0.9.x automatically updating the antispam database involves the creation of a local file which will process the new entries and add them to the database. First, create a file in your b2evolution blog's /admin/ folder (in this example we name the file b2antispam_poll.php) and paste the following code into it:
<?php
require_once( dirname(__FILE__) . '/../conf/_config.php' );
$login_required = false;
require_once( dirname(__FILE__) . "/$admin_dirout/$core_subdir/_main.php" );
require_once (dirname(__FILE__).'/'.$admin_dirout.'/'.$core_subdir.'/_functions_antispam.php');
b2evonet_poll_abuse();
?>
Then, create the following crontab:
0 */6 * * * /path/to/php /path/to/blog/admin/b2antispam_poll.php
When CRON executes the b2antispam_poll.php file, the central antispam database is polled for new entries which are then entered into the local antispam database. Essentially, this process automates the task of updating the antispam list, eliminating the need for an administrator to manually keep the local antispam blacklist up to date.
(The above CRON syntax specifies that CRON will execute the b2antispam_poll.php file at the top of the hour, every six hours. Read this page for additional information on CRONtab syntax.)
Contemporaneous Auditory Narcotics:
or, What my speakers are currently pumping...
Quannum - I Changed My Mind
15 September 2005
Written by
Yours Truly (

)
Published on September 15th, 2005 @ 09:57:06 pm, using 123 words, 54 views
The following block of PHP code will insert a blogroll or linkblog into the sidebar of your b2evolution 0.9.x blog. A blogroll is an aggregatated listing of external links which are stored, typically, on a dedicated 'linkblog' blog on a b2evolution system, and displayed as a list in the sidebar of other blogs on the same system.
<!-- ============== LINKBLOG ============= -->
<!-- =========== START SIDEITEM 7 ============ -->
<div class="bSideItem">
<!-- <h3><?php echo T_('Linkblog') ?></h3>-->
<?php require( dirname(__FILE__).'/_linkblog.php' ); // LINKBLOG INCLUDED HERE ?>
</div>
<!-- ============ END SIDEITEM 7 ============= -->
Contemporaneous Auditory Narcotics:
or, What my speakers are currently pumping...
Orbital - In Sides (U.S. Bonus Disc, Second Version)
11 September 2005
Written by
Yours Truly (

)
Published on September 11th, 2005 @ 06:33:12 pm, using 167 words, 45 views
This block of PHP code shows the original 'smallhead' div in a typical b2evo 0.9.x blog skin. It displays the categories, author, post-time, and wordcount of each post. This code is located in the /skins/skinname/_main.php file of a typical b2evo skin, and is shown here for reference purposes in case changes are made which break something in the template:
<div class="bSmallHead">
<?php
$Item->issue_time();
echo ' | ', T_('Categories'), ': ';
$Item->categories();
?>
<br />
Posted by: <a href="<?php $Blog->disp( 'blogurl', 'raw' ) ?>?author=<?php the_author_ID() ?>" title="<?php echo T_('Browse all posts by this author') ?>"><?php $Item->Author->prefered_name() ?></a> |
<?php
$Item->wordcount();
echo ' ', T_('words');
?>
</div>
Contemporaneous Auditory Narcotics:
or, What my speakers are currently pumping...
Hallucinogen - Promotheus Process EP
10 September 2005
Written by
Yours Truly (

)
Published on September 10th, 2005 @ 07:23:45 pm, using 1758 words, 1970 views
This PHP hack for b2evo skins gives the ability to designate a particular post in each blog on a b2evolution system as a "sticky post" (i.e. that post will always appear at the top of the blog, and will not be listed chronologically). This is useful for creating a post which describes the contents of the blog or category, or which contains some other information which would be useful to have shown always on the entry page to a specific b2evo blog.
First, modify your "blogs" table so you can assign a post ID as 'sticky' for each blog. You will be able to set this in the b2evolution back office later. Assigning a value of 0 (zero) will mean no sticky post. I altered the b2evo blogs table via phpMyAdmin with the following mySQL command:
ALTER TABLE `evo_blogs` ADD `blog_stickypost_ID` INT( 10 ) DEFAULT '0' NOT NULL
Read the full text of this post...
Written by
Yours Truly (

)
Published on September 10th, 2005 @ 06:41:28 pm, using 539 words, 1303 views
This hack allows you to avoid the annoyingness of exiting to the first blog/stub after creating or editing a post in a sub-blog. In short, it saves a mouse-click and a little confusion... This hack for the b2evolution 0.9.x admin interface only works for people who use stubfiles to access their b2evo blogs, and who have correctly configured their stubfiles in their server's .htaccess file.
In /admin/_menutop.php find:
<div id="headfunctions">
<?php echo T_('Style:') ?>
<a href="#" onclick="setActiveStyleSheet('Variation'); return false;" title="Variation (Default)">V</a>·<a href="#" onclick="setActiveStyleSheet('Desert'); return false;" title="Desert">D</a>·<a href="#" onclick="setActiveStyleSheet('Legacy'); return false;" title="Legacy">L</a><?php if( is_file( dirname(__FILE__).'/custom.css' ) ) { ?>·<a href="#" onclick="setActiveStyleSheet('Custom'); return false;" title="Custom">C</a><?php } ?>
•
<a href="<?php echo $htsrv_url ?>/login.php?action=logout"><?php echo T_('Logout') ?></a>
•
<a href="<?php echo $baseurl ?>"><?php echo T_('Exit to blogs') ?> <img src="img/close.gif" width="14" height="14" class="top" alt="" title="<?php echo T_('Exit to blogs') ?>" /></a><br />
</div>
and change it to:
Read the full text of this post...