Recent Topics

1 Feb 28, 2005 06:50    

ok, i want to add a link back to my site beside the blog menu at the very top (above the logo), how would i go about doing that? thx

2 Feb 28, 2005 15:04

edit _main.php - you can place an html hyperlink where ever you like

4 Mar 01, 2005 07:04

Heck that's easy! You do it by hacking (of course!). Crack open skin/_bloglist.php and check out

	} // End of testing which blog is being displayed
	echo $blog_item_end;
}
echo $blog_list_end;


By the way I'm assuming your skin is based on the custom skin.

Anyway now you add you're own groovy link (which is probably a link to my website, but I digress) by smoovling it in thusly:

	} // End of testing which blog is being displayed
	echo $blog_item_end;
}
echo $blog_item_start; ?>
<a href="http://wonderwinds.com/" title="egomanical fool">EdB</a>
<?php echo $blog_item_end;
echo $blog_list_end;

Somewhere I have an blog that adds a non-blog link to the bloglist, and that's how I made it happen, so it *should* work.

5 Mar 02, 2005 01:58

um...somehow i think the code that you posted is a bit messed up... :?:

6 Mar 02, 2005 03:53

http://wonderwinds.com/test/index.php?blog=1&skin=custom-extralink

It works. The only thing I didn't put in the hack was a class for the link. To do that you do this:

	echo $blog_item_end;
}
echo $blog_item_start; ?>
<a href="http://wonderwinds.com/" class="<?php echo $blog_other_link_class ?>" title="egomanical fool">EdB</a>
<?php echo $blog_item_end;
echo $blog_list_end;

By the way I took the important stuff from skins/_bloglist.php and moved it into skins/custom-extralink/_bloglist.php so that the extra link would only show up in that skin. If you look at the two files you'll see that the one in the skins/skinname folder has a bunch of "if(!isset($blog_ blah blah" lines then at the bottom it says "require get_path('skins').'/_bloglist.php';". The file in the skins folder has the same "if isset" stuff then all the actual guts to make the bloglist. Move the bottom half from your skins folder into your skins/skinname folder and over-write the "require..." line. I mean, if you only want the extra link to show up in only one skin. Otherwise just edit the very end of the file in your skins folder.

7 Mar 03, 2005 04:31

im sry but i still cant get it to work, here is the bloglist.php file where should i insert the code???

<?php
	/**
	 * This is the template that displays the links to the available blogs
	 *
	 * This file is not meant to be called directly.
	 * It is meant to be called by an include in the _main.php template.
	 *
	 * b2evolution - {@link http://b2evolution.net/}
	 * Released under GNU GPL License - {@link http://b2evolution.net/about/license.html}
	 * @copyright (c)2003-2004 by Francois PLANQUE - {@link http://fplanque.net/}
	 *
	 * @package evoskins
	 * @subpackage custom
	 */
	if( !defined('DB_USER') ) die( 'Please, do not access this page directly.' );

	if( ! $display_blog_list )
	{	// We do *not* want the blog list to be displayed
		return;
	}

	# this is what will start and end your blog links
	if(!isset($blog_list_start)) $blog_list_start = '<ul id="bloglist">'; 			
	if(!isset($blog_list_end)) $blog_list_end = '</ul>';
	# this is what will separate your blog links
	if(!isset($blog_item_start)) $blog_item_start = '<li>';				
	if(!isset($blog_item_end)) $blog_item_end = "</li>\n";
	# This is the class of for the selected blog link:
	if(!isset($blog_selected_link_class)) $blog_selected_link_class = 'BlogButtonCurr';
	# This is the class of for the other blog links:
	if(!isset($blog_other_link_class)) $blog_other_link_class = 'BlogButton';
	# This is additionnal markup before and after the selected blog name
	if(!isset($blog_selected_name_before)) $blog_selected_name_before = '';				
	if(!isset($blog_selected_name_after)) $blog_selected_name_after = '';
	# This is additionnal markup before and after the other blog names
	if(!isset($blog_other_name_before)) $blog_other_name_before = '';				
	if(!isset($blog_other_name_after)) $blog_other_name_after = '';
	# This is the blogparam that will be displayed as the name:
	if(!isset($blog_name_param)) $blog_name_param = 'shortname';
	# This is the blogparam that will be displayed as the link title:
	if(!isset($blog_title_param)) $blog_title_param = 'name';
	
	/**
	 * We now call the default bloglist handler...
	 * However you can replace this file with the full handler (in /blogs) and customize it!
	 */
	require get_path('skins').'/_bloglist.php';

?>

8 Mar 05, 2005 04:31

Nowhere in that particular file. Go one directory up - to the "skins" folder - and look at skins/_bloglist.php. It's not the same as skins/skinname/_bloglist.php. The one in your skinname folder only 'decorates': the one in skins generates.

9 Mar 06, 2005 10:45

OH thank you SO much it works :D cheers!

10 Apr 03, 2005 12:46

I have tried this code but it only worked on the custom template but is not shown on the rest of the skins, is there a way i can modify the main template to have a "Back to main index" My main website showing up on all skins?


Form is loading...