Recent Topics

1 Feb 22, 2012 20:10    

Hi everyone.

I was hoping you could help me . .

I have read the 2 below links and been trying to implement truncating my posts to a fixed amount of characters.

I'd like it so I have 3 or 4 blogs on my blog page with each blog opening up to full size of my content area . . . I'm told I can just type read more but I can't seem to get it to work . .

Can anyone point me in the right direction please?

Thanks, Alan

http://manual.b2evolution.net/Change_the_read_more_icon

http://doc.b2evo.net/v-1-9/evocore/Item.html#methodcontent

2 Feb 22, 2012 21:10

open up your _item_content.inc.php file, (if you dont have one in your skin folder, copy it from ../skins/ dir to ../skins/your_skin folder.

replace the content area with this:


// Display CONTENT:
$content = $Item->get_content_teaser();
$content .= $Item->get_more_link( array(
                    'force_more'  => $params['force_more'],
                    'before'      => $params['before_more_link'],
                    'after'       => $params['after_more_link'],
                    'link_text'   => $params['more_link_text'],
                ) );
$content .= $Item->get_content_extension( '#', $params['force_more'] );

$read_more = '<span class="readf"><a href="'.$Item->get_permanent_url().'">Continued...</a></span>';

echo cut_text( $content, 190); 
echo ($read_more);
// an old hack i found, by sam2kb

Where "Continued" is read more text, and 190 is the number of char. to truncate.

Dont forget to set a max-height, and overflow-y:hidden, to exactly match all heights.Because char. count is not an exact measure, an "m" char takes almost 8 times of an "i" character.

Btw, dont take manual into much consideration, if you must, only browse the HEAD version.See the "v-1-9" on the page your read ? v1.9 was like 4 years ago, nothing in there is going to work.

http://doc.b2evo.net/v-1-9/evo...hodcontent

3 Feb 22, 2012 21:26

Ok . . i have made the change and it's not displaying my footer or the blog post . . .

I'm just about to change overflow bit just now . .

can you see whats wrong at all tilqicom?

p.s. I don't understand to what exactly you want me to apply the following instruction too ??

Dont forget to set a max-height, and overflow-y:hidden, to exactly match all heights.Because char. count is not an exact measure, an "m" char takes almost 8 times of an "i" character.

4 Feb 23, 2012 11:50

Hi there . . hope your well . .

I was wondering if you were able to elaborate on this as when I carry out your instruction all my blog apart from the tilte of the posts seem to disappear. Ive messed about with it a good bit but can't get it to work yet.

I wonder if it's because I haven't set a max-height, and overflow-y:hidden but I'm not quite sure where you say I would apply these styles?

I am removing the following code from my _item_content.inc.php file and replacing it with what you have said and it is this that is giving me the afore mentioned error.


			// Display CONTENT:

		$Item->content_teaser( array(
					'before'      => $params['before_content_teaser'],
					'after'       => $params['after_content_teaser'],
				) );

		$Item->more_link( array(
				'force_more'  => $params['force_more'],
				'before'      => $params['before_more_link'],
				'after'       => $params['after_more_link'],
				'link_text'   => $params['more_link_text'],
				'anchor_text' => $params['anchor_text'],
				'link_to'     => $params['more_link_to'],
				) );

		if( ! empty($params['image_size']) && $more && $Item->has_content_parts($params) /* only if not displayed all images already */ )
		{

would you have any ideas tilqicom. Once again thanks a great deal for taking the time to help me on my way, I've learned a great deal

6 Feb 26, 2012 13:54

Glad you could solve it.. Thanks goes to sam2kb.. He is the only one helping around anymore.Hell i wouldnt even be here and drop b2 if it wasnt for him.

7 Feb 26, 2012 17:25

I've noticed that in my travels through the forums . . Both of you are an asset, and I really like b2e so keep up the good work, so my thanks to sam2kb also

My blog is just how I want it now :)


Form is loading...