B2Evolution Code for Linkblog Inclusion

Published by Andrew Hreschak in Web Development, b2evolution 0.9.x, PHP
Published on 09/15/05 @ 09:57:00 pm using 100 words, and has 83149 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)

B2Evolution 'smallhead' Div Source Code

Published by Andrew Hreschak in Web Development, b2evolution 0.9.x, PHP
Published on 09/11/05 @ 06:33:00 pm using 109 words, and has 76467 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 '&nbsp; |&nbsp; ', 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>&nbsp; |&nbsp;
<?php
$Item->wordcount();
echo ' ', T_('words');
?>
</div>

Contemporaneous Auditory Narcotics:
or, What my speakers are currently pumping...
Hallucinogen - Promotheus Process EP

Sticky Posts for b2evolution 0.9.x

Published by Andrew Hreschak in Web Development, b2evolution 0.9.x, PHP
Published on 09/10/05 @ 07:23:00 pm using 1122 words, and has 38589 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 story

B2Evolution Hack: Exit to Active Blog

Published by Andrew Hreschak in Web Development, b2evolution 0.9.x, PHP
Published on 09/10/05 @ 06:41:00 pm using 288 words, and has 45436 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>&middot;<a href="#" onclick="setActiveStyleSheet('Desert'); return false;" title="Desert">D</a>&middot;<a href="#" onclick="setActiveStyleSheet('Legacy'); return false;" title="Legacy">L</a><?php if( is_file( dirname(__FILE__).'/custom.css' ) ) { ?>&middot;<a href="#" onclick="setActiveStyleSheet('Custom'); return false;" title="Custom">C</a><?php } ?>
&bull;
<a href="<?php echo $htsrv_url ?>/login.php?action=logout"><?php echo T_('Logout') ?></a>
&bull;
<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 story

New b2evo skin: darkling

Published by Andrew Hreschak in Web Development, b2evolution 0.9.x, b2evolution blog skins
Published on 08/21/05 @ 05:15:00 pm using 545 words, and has 44260 views

I've been working on this thing on and off for a couple days when I had a few spare moments here and there. I call it darkling. It's starting to come together now. I think it's a pretty nice, minimalistic skin for the b2evolution blog software. I've incorporated a lot of hacks found around the b2evo forums, and put that all behind a customized css layout. There are still a few bugs I'm working out, and still some things to add, but it's getting there.

If you've been to this blog using another skin, you can switch to the darkling skin by clicking here or, as always, you can select the skin of your choice using the skin switcher in the sidebar on the right. (Skin switcher has been removed). (This skin was designed for a now obsolete version of b2evo and has been removed. Check back for an updated release. If you need a custom skin design built for a current b2evo release, leave a comment or send a message)

Read the full story

B2Evolution: Linking Author Name To Author Page

Published by Andrew Hreschak in Web Development, b2evolution 0.9.x, PHP
Published on 08/16/05 @ 11:17:00 pm using 62 words, and has 35650 views

To link the blog author's name to their main 'About Me' page in b2evolution 0.9.x blogs, add the following code to the b2evo skin /skinname/_main.php template file:

<?php $authorurl = $Item->Author->get('url');
if (($authorurl != 'http://') and ($authorurl != '')) {
if( !preg_match('#://#', $authorurl) ) {
$authorurl = 'http://'.$authorurl;
} ?>
<a href="<?php echo $authorurl ?>" title="<?php echo $authorurl ?>"><?php $Item->Author->prefered_name(); ?></a>

Contemporaneous Auditory Narcotics:
or, What my speakers are currently pumping...
X Project - Conquering Lion [dubplate4]

Cross-posting Between Blogs in b2evolution

Published by Andrew Hreschak in Web Development, b2evolution 0.9.x, b2evolution 1.10.x
Published on 08/15/05 @ 10:55:00 am using 137 words, and has 30490 views

To allow cross-posting a blog post across multiple blogs or categories on a b2evolution blog, open the /conf/_admin.php file and adjust the following settings as desired... They are fairly self-explanatory.

/**
* Cross posting
*
* Possble values:
* - 0 if you want users to post to a single category only
* - 1 if you want to be able to cross-post among multiple categories
* - 2 if you want to be able to cross-post among multiple blogs/categories
* - 3 if you want to be able to change main cat among blogs (which will move the
* posts from one blog to another; use with caution)
*/
$allow_cross_posting = 2;

This configuration setting is available in the (obsolete) b2evolution 0.9.x series and the newer 1.10.x series. In fact, it should be available in all releases of the b2evolution blog software.

Contemporaneous Auditory Narcotics:
or, What my speakers are currently pumping...
Digital And Spirit - Phantom Audio [PHAX002]