Jump to content


Photo

Unique content in tag and category page without framework in platformpro


  • Please log in to reply
14 replies to this topic

#1 bizint

bizint

    Advocate

  • Members
  • 399 posts
  • Country: Country Flag

Posted 20 February 2012 - 08:52 PM

I bought framework to tweak customise category and tag pages that are ranking well, but my custom case study section will not move easily to a new theme so I've had to go back to platform pro. What I need to do is create unique content in my tag and category pages to make these high ranking pages more compelling. For example I need to pull the tag or category title to a H1 title above the posts...and also include unique content in each tag or category page, by perhaps pulling the tag and category description into the page. I think I can do this in a time consuming manner by using widget logic to create a unique text header and description for each category or tag, that only shows in a fullwidth sidebar above the hosts in each unique category. Ideally I either want a widget that goes into a full width sidebar above the category or tags posts, that pulls the tag/category title and tag/category description as a unique header and content for each category and tag. Is there a plug in that can do this easily? I currently use a text widget in my categories that says the same thing in all...but I would like a text that pulls from the title and description Here is a category page with the standard text, that I'd like to be more dynamic or customisable... http://www.businessi...ocation-london/ Any ideas much appreciated....nothing too complicated!

#2 catrina

catrina

    Advocate

  • Members
  • 12345 posts
  • LocationCalifornia
  • Country: Country Flag

Posted 21 February 2012 - 03:36 AM

I don't know of any plugin that can do this off the top of my head, but you may want to look into these ones: http://www.tripwirem...et-plugins.html

#3 bizint

bizint

    Advocate

  • Members
  • 399 posts
  • Country: Country Flag

Posted 21 February 2012 - 05:56 PM

Mmm...is there something simpler...for example if I put in a text or html widget...then using widget logic, I get to only show on all category pages. Then I can write a snippet of html that says something like

%%categorytitle%% %%categorydescription%%

then that pulls the category or tag description below the header as unique text content? The only other option is to create about 100 text widgets (for each category or tag)...each with it own widget logic code that only shows up in each category or tag....that doesnt seem very elegant....when all the info is already in catagory and tag titles and descriptions...it just needs to be automatically pulled in...I'd be very surprised if someone hasnt done this....Thesis theme seems have it...this seems to be on the right lines...I'll check it out and report back!: http://wpsites.net/w...ategory_Content


#4 catrina

catrina

    Advocate

  • Members
  • 12345 posts
  • LocationCalifornia
  • Country: Country Flag

Posted 22 February 2012 - 02:54 AM

Let us know what happens. :)

#5 bizint

bizint

    Advocate

  • Members
  • 399 posts
  • Country: Country Flag

Posted 22 February 2012 - 09:59 PM

Nope...the thesis theme has exactly what is needed. An introductory content area for the tag and categories ... Yoast Seo allows to put a title and description for meta...but it doesn't show in the actual tagh or category pages...shame... I've got six category pages that I have customised by putting unique text widgets in each, that only show in those categories... see here example category page: http://www.businessi...ce-design-news/ but I've got about 160 tags...and that's increasing all the time, so there is now way I can do that for each tag page. Without a widget or plug-in that pulls the header and content automatically form the tag title and description...I'm screwed! Will keep hunting - but if anyone has a solution please let me know! Thanks

#6 bizint

bizint

    Advocate

  • Members
  • 399 posts
  • Country: Country Flag

Posted 22 February 2012 - 10:27 PM

Mmm I think I need to make a tag template page that pulls the description into the tag pages... http://figure-w.co.u...-for-wordpress/ has anyone done this before?!

#7 Simon_P

Simon_P

    Messer

  • Administrators



  • 8388607 posts
  • LocationDevon
  • Framework Version:2.1.1
  • Country: Country Flag

Posted 22 February 2012 - 11:02 PM

This takes 3 or 4 minutes to do in Framework:

 <?php
	/*
		Section: Category Titles
		Author: Simon
		Author URI: http://www.pagelines.com
		Description: Add a category title!
		Class Name: Categorizer
		Workswith: templates, main
		Version: 0.1
	*/
	
	class Categorizer extends PageLinesSection {
	
		function section_template() {
	
	
			$cat = get_category( get_query_var('cat'),false );
	
			echo '<div class="cat-titler">';
	
			echo '<h2>' . $cat->name . '</h2>';
	
			echo '<h3>' . $cat->description . '</h3>';
	
			echo '</div>';
	
		}
	
	} /* End of section class */

Same thing could easily be replicated for tags too.

#8 Simon_P

Simon_P

    Messer

  • Administrators



  • 8388607 posts
  • LocationDevon
  • Framework Version:2.1.1
  • Country: Country Flag

Posted 22 February 2012 - 11:10 PM

The above code is for 2.0, you could emulate it for 1.5. Not so easy though as things have to be registered in the platformbase functions file. The above code you could simply drop into pagelines-section/cats/section.php and it would work out of the box.

#9 bizint

bizint

    Advocate

  • Members
  • 399 posts
  • Country: Country Flag

Posted 28 February 2012 - 02:09 PM

I've paid for and downloaded framework....unfortunately my "case study" section wont follow over easily, so I will have to pay a developer to take it across...when I realised the additional time and expense to move to framework 2.0 (not an upgrade more a completely new theme)...I put it on hold... http://www.businessi...se-studies/.... Waaahhh... guess I'll figure a way to bite the bullet...more time and money :-(

#10 bizint

bizint

    Advocate

  • Members
  • 399 posts
  • Country: Country Flag

Posted 19 March 2012 - 02:04 PM

Hi Simon, I've upgraded to framework...I'm still not sure where this code goes?! For Tag? I've got a child theme before the framework....?!

#11 Simon_P

Simon_P

    Messer

  • Administrators



  • 8388607 posts
  • LocationDevon
  • Framework Version:2.1.1
  • Country: Country Flag

Posted 19 March 2012 - 03:06 PM

make a new folder in plugins/pagelines-sections/ call it 'tag-header' or something, then make a new file in that new folder called section.php and paste the code in, then go back to the wp-admin pagelines store, click refresh store. The section should now be available.

#12 bizint

bizint

    Advocate

  • Members
  • 399 posts
  • Country: Country Flag

Posted 19 March 2012 - 07:40 PM

...and is this just for categories? Or do I need to do another one for tags? *heads into the unknown!*

#13 bizint

bizint

    Advocate

  • Members
  • 399 posts
  • Country: Country Flag

Posted 19 March 2012 - 11:42 PM

Simon that worked great for categories, but it doesn't work for tags....I'm going to try changing everything in your code that says cat to tag?! Would that work?!

#14 bizint

bizint

    Advocate

  • Members
  • 399 posts
  • Country: Country Flag

Posted 19 March 2012 - 11:47 PM

Is this a mad idea?! http://www.pagelines.com Description: Add a Tag title! Class Name: Tagliatelle-izer Workswith: templates, main Version: 0.1 */ class Tagliatelle-izer extends PageLinesSection { function section_template() { $tag = get_tag( get_query_var('tag'),false ); echo '
'; echo '

' . $tag->name . '

'; echo '

' . $tag->description . '

'; echo '
'; } } /* End of section class */

#15 bizint

bizint

    Advocate

  • Members
  • 399 posts
  • Country: Country Flag

Posted 19 March 2012 - 11:58 PM

Ah ha...no chance. It broke the whole site server 500....Simon...any ideas?! If you look in current categories....I've installed a widget that only shows unique content in each category 1) a header...2) a sub header between two lines.... http://www.businessi...ce-design-news/ Now I've got 170 tags...so ideally I need auto content that does the same with the same layout for tags...but takes tag Title as 1) header 2) A Sub header below that takes tag title and adds by Business Interiors 3) Takes the description of the tag and makes it the content. Thats a good start! Does anyone know how to easily write unique content into a tag page...abit like a page?!