1 successfulwithyou_co Sep 16, 2006 08:48
3 successfulwithyou_co Sep 18, 2006 09:09
hey thanks John.
after many hours of tweeking/experimenting....I see this is way to complicated for me...especially when Im try to add content to my blog... Ill forward my domain to the post itself if Im unable to work it out.
However I understand that the setting is in my main.php
<?php
/**
* This is the main template. It displays the blog.
*
* However this file is not meant to be called directly.
* It is meant to be called automagically by b2evolution.
* To display a blog, you should call a stub file instead, for example:
* /blogs/index.php or /blogs/blog_b.php
* @package evoskins
* @subpackage custom
*/
if( !defined('DB_USER') ) die( 'Please, do not access this page directly.' );
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<?php locale_lang() ?>" lang="<?php locale_lang() ?>">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=<?php locale_charset() ?>" />
<title><?php
$Blog->disp('name', 'htmlhead');
single_cat_title( ' - ', 'htmlhead' );
single_month_title( ' - ', 'htmlhead' );
single_post_title( ' - ', 'htmlhead' );
arcdir_title( ' - ', 'htmlhead' );
last_comments_title( ' - ', 'htmlhead' );
?>
</title>
<base href="<?php skinbase(); // Base URL for this skin. You need this to fix relative links! ?>" />
<meta name="description" content="<?php $Blog->disp( 'shortdesc', 'htmlattr' ); ?>" />
<meta name="keywords" content="<?php $Blog->disp( 'keywords', 'htmlattr' ); ?>" />
<meta name="generator" content="Microsoft FrontPage 4.0" /> <!-- Please leave this for stats -->
<meta name="robots" content="all">
<meta name="revisit-after" content="14 days">
<meta name="Author" content="GoMillennium Media inc">
<link rel="alternate" type="text/xml" title="RDF" href="<?php $Blog->disp( 'rdf_url', 'raw' ) ?>" />
<link rel="alternate" type="text/xml" title="RSS .92" href="<?php $Blog->disp( 'rss_url', 'raw' ) ?>" />
<link rel="alternate" type="text/xml" title="RSS 2.0" href="<?php $Blog->disp( 'rss2_url', 'raw' ) ?>" />
<link rel="alternate" type="application/atom+xml" title="Atom" href="<?php $Blog->disp( 'atom_url', 'raw' ) ?>" />
<link rel="pingback" href="<?php $Blog->disp( 'pingback_url', 'raw' ) ?>" />
<link rel="stylesheet" href="custom.css" type="text/css" />
</head>
<body>
<div id="wrapper">
<?php
/**
* --------------------------- BLOG LIST INCLUDED HERE -----------------------------
*/
require( dirname(__FILE__).'/_bloglist.php' );
// ----------------------------- END OF BLOG LIST ---------------------------- ?>
<div class="pageHeader">
<h1 id="pageTitle"><?php $Blog->disp( 'name', 'htmlbody' ) ?></h1>
<div class="pageSubTitle"><?php $Blog->disp( 'tagline', 'htmlbody' ) ?></div>
</div>
<div class="bPosts">
<h2><?php
single_cat_title();
single_month_title();
single_post_title();
arcdir_title();
last_comments_title();
profile_title();
?></h2>
<!-- =================================== START OF MAIN AREA =================================== -->
<?php // ------------------------------------ START OF POSTS ----------------------------------------
if( isset($MainList) ) $MainList->display_if_empty(); // Display message if no post
if( isset($MainList) ) while( $Item = $MainList->get_item() )
{
$MainList->date_if_changed();
?>
<div class="bPost" lang="<?php $Item->lang() ?>">
<?php
locale_temp_switch( $Item->locale ); // Temporarily switch to post locale
$Item->anchor(); // Anchor for permalinks to refer to
?>
<div class="bSmallHead">
<a href="<?php $Item->permalink() ?>" title="<?php echo T_('Permanent link to full entry') ?>"><img src="img/icon_minipost.gif" alt="Permalink" width="12" height="9" class="middle" /></a>
<?php
$Item->issue_time();
echo ', ', T_('Categories'), ': ';
$Item->categories();
echo ', ';
$Item->wordcount();
echo ' ', T_('words'), ' ';
locale_flag( $Item->locale, 'h10px' );
?>
</div>
<h3 class="bTitle"><?php $Item->title(); ?></h3>
<div class="bText">
<?php $Item->content(); ?>
<?php link_pages() ?>
</div>
<div class="bSmallPrint">
<a href="<?php $Item->permalink() ?>" title="<?php echo T_('Permanent link to full entry') ?>" class="permalink_right"><img src="img/chain_link.gif" alt="<?php echo T_('Permalink') ?>" width="14" height="14" border="0" class="middle" /></a>
<?php $Item->feedback_link( 'comments' ) // Link to comments ?>
<?php $Item->feedback_link( 'trackbacks', ' • ' ) // Link to trackbacks ?>
<?php $Item->feedback_link( 'pingbacks', ' • ' ) // Link to trackbacks ?>
<?php $Item->edit_link( ' • ' ) // Link to backoffice for editing ?>
<?php $Item->trackback_rdf() // trackback autodiscovery information ?>
</div>
<?php // ------------- START OF INCLUDE FOR COMMENTS, TRACKBACK, PINGBACK, ETC. -------------
$disp_comments = 1; // Display the comments if requested
$disp_comment_form = 1; // Display the comments form if comments requested
$disp_trackbacks = 1; // Display the trackbacks if requested
$disp_trackback_url = 1; // Display the trackbal URL if trackbacks requested
$disp_pingbacks = 1; // Display the pingbacks if requested
require( dirname(__FILE__).'/_feedback.php' );
// ---------------- END OF INCLUDE FOR COMMENTS, TRACKBACK, PINGBACK, ETC. ----------------
locale_restore_previous(); // Restore previous locale (Blog locale)
?>
</div>
<?php } // ---------------------------------- END OF POSTS ------------------------------------ ?>
<p class="center"><strong>
<?php posts_nav_link(); ?>
<?php
// previous_post( '<p class="center">%</p>' );
// next_post( '<p class="center">%</p>' );
?>
</strong>
<?php // ---------------- START OF INCLUDES FOR LAST COMMENTS, STATS ETC. ----------------
switch( $disp )
{
case 'comments':
// this includes the last comments if requested:
require( dirname(__FILE__).'/_lastcomments.php' );
break;
case 'arcdir':
// this includes the archive directory if requested
require( dirname(__FILE__).'/_arcdir.php');
break;
case 'profile':
// this includes the profile form if requested
require( dirname(__FILE__).'/_profile.php');
break;
}
// ------------------- END OF INCLUDES FOR LAST COMMENTS, STATS ETC. ------------------- ?>
</div>
<!-- =================================== START OF SIDEBAR =================================== -->
<div class="bSideBar">
<div class="bSideItem">
<h3><?php $Blog->disp( 'name', 'htmlbody' ) ?></h3>
<p><?php $Blog->disp( 'longdesc', 'htmlbody' ); ?></p>
<p class="center"><strong><?php posts_nav_link( ' | ', '< '.T_('Previous'), T_('Next').' >' ); ?></strong></p>
<!--?php next_post(); // activate this if you want a link to the next post in single page mode ?-->
<!--?php previous_post(); // activate this if you want a link to the previous post in single page mode ?-->
<ul>
<li><a href="<?php $Blog->disp( 'staticurl', 'raw' ) ?>"><strong><?php echo T_('Recently') ?></strong></a> <span class="dimmed"><?php echo T_('(cached)') ?></span></li>
<li><a href="<?php $Blog->disp( 'dynurl', 'raw' ) ?>"><strong><?php echo T_('Recently') ?></strong></a> <span class="dimmed"><?php echo T_('(no cache)') ?></span></li>
</ul>
<?php // -------------------------- CALENDAR INCLUDED HERE -----------------------------
require( dirname(__FILE__).'/_calendar.php' );
// -------------------------------- END OF CALENDAR ---------------------------------- ?>
<ul>
<li><a href="<?php $Blog->disp( 'lastcommentsurl', 'raw' ) ?>"><strong><?php echo T_('Last comments') ?></strong></a></li>
</ul>
</div>
<div class="bSideItem">
<h3 class="sideItemTitle"><?php echo T_('Search') ?></h3>
<?php form_formstart( $Blog->dget( 'blogurl', 'raw' ), 'search', 'SearchForm' ) ?>
<p><input type="text" name="s" size="30" value="<?php echo htmlspecialchars($s) ?>" class="SearchField" /><br />
<input type="radio" name="sentence" value="AND" id="sentAND" <?php if( $sentence=='AND' ) echo 'checked="checked" ' ?>/><label for="sentAND"><?php echo T_('All Words') ?></label><br />
<input type="radio" name="sentence" value="OR" id="sentOR" <?php if( $sentence=='OR' ) echo 'checked="checked" ' ?>/><label for="sentOR"><?php echo T_('Some Word') ?></label><br />
<input type="radio" name="sentence" value="sentence" id="sentence" <?php if( $sentence=='sentence' ) echo 'checked="checked" ' ?>/><label for="sentence"><?php echo T_('Entire phrase') ?></label></p>
<input type="submit" name="submit" class="submit" value="<?php echo T_('Search') ?>" />
</form>
</div>
<div class="bSideItem">
<h3><?php echo T_('Categories') ?></h3>
<?php form_formstart( $Blog->dget( 'blogurl', 'raw' ) ) ?>
<?php // -------------------------- CATEGORIES INCLUDED HERE -----------------------------
require( dirname(__FILE__).'/_categories.php' );
// -------------------------------- END OF CATEGORIES ---------------------------------- ?>
<br />
<input type="submit" class="submit" value="<?php echo T_('Get selection') ?>" />
</form>
</div>
<div class="bSideItem">
<h3><?php echo T_('Archives') ?></h3>
<ul>
<?php // -------------------------- ARCHIVES INCLUDED HERE -----------------------------
require( dirname(__FILE__).'/_archives.php' );
// -------------------------------- END OF ARCHIVES ---------------------------------- ?>
<li><a href="<?php $Blog->disp( 'arcdirurl', 'raw' ) ?>"><?php echo T_('more...') ?></a></li>
</ul>
</div>
<?php if( ! $Blog->get('force_skin') )
{ // Skin switching is allowed for this blog: ?>
<div class="bSideItem">
<h3><?php echo T_('Choose skin') ?></h3>
<ul>
<?php // ------------------------------- START OF SKIN LIST -------------------------------
for( skin_list_start(); skin_list_next(); ) { ?>
<li><a href="<?php skin_change_url() ?>"><?php skin_list_iteminfo( 'name', 'htmlbody' ) ?></a></li>
<?php } // ------------------------------ END OF SKIN LIST ------------------------------ ?>
</ul>
</div>
<?php } ?>
<?php // -------------------------- LINKBLOG INCLUDED HERE -----------------------------
require( dirname(__FILE__).'/_linkblog.php' );
// -------------------------------- END OF LINKBLOG ---------------------------------- ?>
<div class="bSideItem">
<h3><?php echo T_('Misc') ?></h3>
<ul>
<?php
user_login_link( '<li>', '</li>' );
user_register_link( '<li>', '</li>' );
user_admin_link( '<li>', '</li>' );
user_profile_link( '<li>', '</li>' );
user_logout_link( '<li>', '</li>' );
?>
</ul>
</div>
<div class="bSideItem">
<h3><?php echo T_('Syndicate this blog') ?> <img src="../../img/xml.gif" alt="XML" width="36" height="14" class="middle" /></h3>
<ul>
<li>
RSS 0.92:
<a href="<?php $Blog->disp( 'rss_url', 'raw' ) ?>"><?php echo T_('Posts') ?></a>,
<a href="<?php $Blog->disp( 'comments_rss_url', 'raw' ) ?>"><?php echo T_('Comments') ?></a>
</li>
<li>
RSS 1.0:
<a href="<?php $Blog->disp( 'rdf_url', 'raw' ) ?>"><?php echo T_('Posts') ?></a>,
<a href="<?php $Blog->disp( 'comments_rdf_url', 'raw' ) ?>"><?php echo T_('Comments') ?></a>
</li>
<li>
RSS 2.0:
<a href="<?php $Blog->disp( 'rss2_url', 'raw' ) ?>"><?php echo T_('Posts') ?></a>,
<a href="<?php $Blog->disp( 'comments_rss2_url', 'raw' ) ?>"><?php echo T_('Comments') ?></a>
</li>
<li>
Atom:
<a href="<?php $Blog->disp( 'atom_url', 'raw' ) ?>"><?php echo T_('Posts') ?></a>,
<a href="<?php $Blog->disp( 'comments_atom_url', 'raw' ) ?>"><?php echo T_('Comments') ?></a>
</li>
</ul>
</div>
<?php
log_hit(); // log the hit on this page
debug_info(); // output debug info if requested
?>
</div>
</div>
</body>
</html>
and I want this post to display http://successfulwithyou.com/index.php/2006/09/16/whois_duncan
Could some clever cookie post the appropriate main.php in a reply post...I would very much appreciate that!!
Also...youll see my meta tags...keywords are entered above...to no avail......where would these be put to get spidered?
many thanks so far
4 john Sep 18, 2006 10:28
Well, here is the easiest method to display a sticky at the top of your home page.
<div class="bText">
<?php
if( !$s && !$cat && empty($catsel) && !$m && $disp=='posts' && !$title && !$p )
{
?>
<p><?php bloginfo('longdesc', 'htmlbody'); ?></p>
<?php
}
?>
</div>
The
<?php bloginfo('longdesc', 'htmlbody'); ?>
is generated in the Admin section under the Blog settings section
Description
Long Description:
simply format your blurb in that text box and it will appear at the top of your front page.
This is usually reserved to appear at the top of your side bar, but works fine as a "fake post"
Oh, and try putting it in your _main.php just after..
<div class="bPost" lang="<?php $Item->lang() ?>">
<?php
locale_temp_switch( $Item->locale ); // Temporarily switch to post locale
$Item->anchor(); // Anchor for permalinks to refer to
?>
Here are three posts to get you started...
http://forums.b2evolution.net/viewtopic.php?t=2933&highlight=sticky
http://forums.b2evolution.net/viewtopic.php?t=7909&highlight=sticky
http://forums.b2evolution.net/viewtopic.php?t=899&highlight=sticky