Recent Topics

1 Feb 14, 2005 22:40    

I'm using issue_date and I'm trying to figure out how to bold the date. My blog is [url=http://tainted-kisses.net/t-k.html]Here[/url]. I've tried

<strong><?php // ------------------------------------ START OF POSTS ----------------------------------------
	if( isset($MainList) ) $MainList->display_if_empty(); // Display message if no post

	if( isset($MainList) ) while( $Item = $MainList->get_item() )
	{
		$Item->issue_date();
	?></strong>

and

<b><?php // ------------------------------------ START OF POSTS ----------------------------------------
	if( isset($MainList) ) $MainList->display_if_empty(); // Display message if no post

	if( isset($MainList) ) while( $Item = $MainList->get_item() )
	{
		$Item->issue_date();
	?></b>

It only bolds the date of my earliest post though. Anyone know how to bold the dates of all of my posts.

2 Feb 15, 2005 00:13

First, <b> is deprecated in XHTML, so it is better to use the <strong> tag, like in your first instance.

Second, I'd recommend using CSS to control your formatting. Are the two instances you quote in a <div> or <span> tag? If so, the formatting is probably done in a *.css file called for in the <head> section.

Need more information to solve the problem.

Normally, I put a <div id="blah"> or <div class="blah"> before any code that I want to format. ("id" is used only ONCE, but "class" can be used again and again).

Because of its position, I'm figuring that you want CLASS.

<strong> should do it, unless you have another CSS selector overriding it.

What is the code above and below the stuff you posted?

3 Feb 15, 2005 01:06

This is whats 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
	 *
	 * 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.' );
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<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><?php comments_popup_script() // Include javascript to open pop up windows ?> 
<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="b2evolution <?php echo $b2_version ?>" /> <!-- Please leave this for stats -->
<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' ) ?>" />
<style type="text/css"><!-- body{background-image:none;background-color:transparent;
scrollbar-face-color: #123456;
scrollbar-arrow-color: #EE869B;
scrollbar-track-color: #123456;
scrollbar-3dlight-color: #123456;
scrollbar-highlight-color: #123456;
scrollbar-shadow-color: #123456;
scrollbar-darkshadow-color: #123456;
}//--></style><link rel="stylesheet" href="http://www.tainted-kisses.net/css2.css" type="text/css" />
<!--[if gte IE 5]>
<style type="text/css">
ul.makeMenu li { behavior: url( IEmen.htc ); width: 100%; }
ul.makeMenu ul { display: none; position: absolute; top: -1px; left: 160px; background-color: #036; }
</style>
<![endif]-->

<script type="text/javascript">
function clearDefault(el) {
  if (el.defaultValue==el.value) el.value = ""
}

</script>


</head>
<body>




<div class="bPosts">

<!-- =================================== START OF MAIN AREA =================================== -->

<strong><?php // ------------------------------------ START OF POSTS ----------------------------------------
	if( isset($MainList) ) $MainList->display_if_empty(); // Display message if no post

	if( isset($MainList) ) while( $Item = $MainList->get_item() )
	{
		$Item->issue_date();
	?></strong>

                
		
		<div class="bText">
			<?php $Item->content(); ?>
			<?php link_pages() ?>
		</div>
	<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="bSmallPrint" align="right">
			

			<b>Asia</b> @ <?php $Item->issue_time() ?><br><b>{&nbsp;&nbsp;&nbsp;</b><?php comments_popup_link("<img src=\"http://tainted-kisses.net/blog/img/smilies/heart.gif\" border=\"0px\">  Me", "1  <img src=\"http://tainted-kisses.net/blog/img/smilies/heart.gif\" border=\"0px\">s  Me", "%d  <img src=\"http://tainted-kisses.net/blog/img/smilies/heart.gif\" border=\"0px\">  Me") ?>&nbsp;&nbsp;&nbsp;<b>}</b>
			

			<?php $Item->edit_link( ' &bull; ' ) // Link to backoffice for editing ?>

			<?php $Item->trackback_rdf() // trackback autodiscovery information ?><br><br>
		<center><img src="http://www.tainted-kisses.net/vday3hr.png"></center><br><br></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 ------------------------------------ ?>
                         
	<div align="right"><strong>
		<br /><br /><?php posts_nav_link(); ?>
		<?php 
			// previous_post( '<p class="center">%</p>' );
			// next_post( '<p class="center">%</p>' );
		?>
	<br /><br /></strong></div>

<?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 'stats':
			// this includes the statistics if requested:
			require( dirname(__FILE__).'/_stats.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. ------------------- ?>
<br><br><br><br><center>
<b>{</b>Powered by <a href="http://b2evolution.net" target="_blank">b2evolution</a>.<b>}</b></center><br><br>
</div>

</body>
</html>

4 Feb 15, 2005 01:09

the start of your tag is outside the loop --



<?php // ------------------------------------ START OF POSTS

thats where the loop starts. move that tag over onto the other side, mess with it over there. youre going to need to add an echo or close then re-open that <?php tag

you wanted it to be easy, and thought you could get around that, eh ;)

5 Feb 15, 2005 01:13

What's happening is it's only reading the "start strong" (or start bold if you insist) tag the very first time through the posts loop. You can see that when you right-click in Mozilla and tell it to view this frame only, though that might be part of the developer's tool bar I use. Anyway it's no biggie and quite fixable. Try it this way instead:

if( isset($MainList) ) while( $Item = $MainList->get_item() )
   {
      echo '<strong';
      $Item->issue_date();
      echo '</strong>';
      // Am I the coolest or what?
   ?>

You can leave out the commented line if you want...

Blech frames are gross. Nothing personal mind you - it's just that I have to click an extra twice to peek at your source. (I'm a source voyeur, but a lazy source voyeur!)

6 Feb 15, 2005 01:20

whoo wrote:

the start of your tag is outside the loop --



<?php // ------------------------------------ START OF POSTS

thats where the loop starts. move that tag over onto the other side, mess with it over there. youre going to need to add an echo or close then re-open that <?php tag

you wanted it to be easy, and thought you could get around that, eh ;)

I actually didn't do that. Well I didn't do it knowingly, if I did. I don't know hardly anything about php so I don't really touch anything if I don't have a clue what its gonna do.

7 Feb 15, 2005 01:21

EdB wrote:

What's happening is it's only reading the "start strong" (or start bold if you insist) tag the very first time through the posts loop. You can see that when you right-click in Mozilla and tell it to view this frame only, though that might be part of the developer's tool bar I use. Anyway it's no biggie and quite fixable. Try it this way instead:

if( isset($MainList) ) while( $Item = $MainList->get_item() )
   {
      echo '<strong';
      $Item->issue_date();
      echo '</strong>';
      // Am I the coolest or what?
   ?>

You can leave out the commented line if you want...

Blech frames are gross. Nothing personal mind you - it's just that I have to click an extra twice to peek at your source. (I'm a source voyeur, but a lazy source voyeur!)

Thanks I'll try it and edit this post with the result.

*EDIT* I get this error, but it works on the blog.

Warning: Cannot modify header information - headers already sent by (output started at /home/tainted/public_html/blog/b2evocore/_class_item.php:1090) in /home/tainted/public_html/blog/admin/b2template.php on line 41

8 Feb 15, 2005 01:34

gees, no-one gets my humour.

9 Feb 15, 2005 01:39

whoo wrote:

gees, no-one gets my humour.

I get it :). I 'm just letting everyone know, I know squat lol.

10 Feb 15, 2005 02:02

Tainted wrote:

*EDIT* I get this error, but it works on the blog.

Warning: Cannot modify header information - headers already sent by (output started at /home/tainted/public_html/blog/b2evocore/_class_item.php:1090) in /home/tainted/public_html/blog/admin/b2template.php on line 41

Line 41 in b2template.php has this:

header("Location: b2template.php?file=$file&a=te");

EDIT NM I got it to work :). Thanks for the help everyone!


Form is loading...