Recent Topics

1 Oct 27, 2009 01:52    

My b2evolution Version: 3.3.1

Hi All...working on a new site ;o) The test site is at...

http://www.suewaitelangley.com/DrC/templateinside.html

This is how the inside pages of this site will look-ish. (Just started)

Here's the CHALENGE...

Will it be possible to use this page as a skin for the blog? Client wants to add new articles himself. Ideally what I'd like to see is the post title appear in the colored in lines...and then the post content to appear in the blocks that appear when the title line is clicked.

It seems like there should be a way to do this...but just thinking about it is making my head hurt. Before I started trying to skin this I thought I'd ask the experts if it's even a possibility...I can just use the block for posts...but...that's soooooo boring ;o)

2 Oct 27, 2009 01:58

That the javascript for the accordian effect uses a designation for odd and even <li> to work. This is where I think I will run into trouble. I "think" that if the <li> were <div> then it would be easier to get the effect I want. I'm no javascript queen and if this is the case this may not be possible. If you need to see the javascript code it's...

$(function() {
	// Hide all the content except the first
	$('.accordian li:odd:gt(0)').hide();
	
	// Add a padding to the first link
	$('.accordian li:first').animate( {
		paddingLeft:"30px"
	} );
	
	// Add the dimension class to all the content
	$('.accordian li:odd').addClass('dimension');
	
	// Set the even links with an 'even' class
	$('.accordian li:even:even').addClass('even');
	
	// Set the odd links with a 'odd' class
	$('.accordian li:even:odd').addClass('odd');
	
	// Show the correct cursor for the links
	$('.accordian li:even').css('cursor', 'pointer');
	
	// Handle the click event
	$('.accordian li:even').click( function() {
		// Get the content that needs to be shown
		var cur = $(this).next();
		
		// Get the content that needs to be hidden
		var old = $('.accordian li:odd:visible');
		
		// Make sure the content that needs to be shown 
		// isn't already visible
		if ( cur.is(':visible') )
			return false;
		
		// Hide the old content
		old.slideToggle(500);
		
		// Show the new content
		cur.stop().slideToggle(500);
		
		// Animate (add) the padding in the new link
		$(this).stop().animate( {
			paddingLeft:"30px"
		} );
		
		// Animate (remove) the padding in the old link
		old.prev().stop().animate( {
			paddingLeft:"10px"
		} );
	} );
});

3 Oct 27, 2009 19:48

You wouldn't believe all the crap I had to click to allow you js, google apis js and THEN and only cos I'm in a good mood cos I just got back from 2 weeks in malta ... anyway ... THEN I had to allow your site to call content from google ... I need a bloody holiday to recover

It may interest you to know that evo ships with jquery in /rsc/js/ ;)

To answer your question, yes

¥

4 Oct 27, 2009 20:05

THANKS for the js clue...I'll change that.

Now...yes...I'm in trouble and don't try to make this work? ...OR

yes...I should be able to change the <li> to <div> and get this working the way I want it to?

5 Oct 27, 2009 20:43

your question wrote:

Will it be possible to use this page as a skin for the blog? Client wants to add new articles himself. Ideally what I'd like to see is the post title appear in the colored in lines...and then the post content to appear in the blocks that appear when the title line is clicked.

Yes to that one ;)

I'd be tempted to change li to a classname on the block level element of my choice though

¥

6 Oct 27, 2009 21:09

OK...I'll try it...not sure if I'm smart enough to get it working but we'll see.

BTW..just changed the js link to my own file...and deleted the jquery.color.js call 'cause the link when I tried to access it directly didn't exist. Looks like I don't need it. I think the page is ok...can you pull it up and tell me if it's any better for you...any less obnoxious?

THANKS, Sue


Form is loading...