Hello,
How to add more than one news/blog pages?
Currently you have to specify the blog page from the theme settings, what i need to have seprate page for each category?
(122 posts)
(28 voices)
Hello,
How to add more than one news/blog pages?
Currently you have to specify the blog page from the theme settings, what i need to have seprate page for each category?
Hello pixelsoft,
I'm afraid that currently the team doesn't support this. It is part of extra customization. You should look forward hiring a freelancer to do this for you.
Cheers
Hey pixelsoft,
I went ahead and created a template for this as I thought other people would want to do this also.
Download the attached template-one-category.zip and extract it to wp-content/themes/infocus/
In your dashboard create a new page and select the 'One Category' template. Then you would need to set a custom field with a name of 'category' and a value of whichever category you would like to appear.
pixelsoft,
Sorry about that, try this one. It should work whether your category has spaces or not.
@jayce103, I will look into it.
jayce103,
This one should work with Awake. Try it out and tell me if everything works fine. Just follow the instructions above.
Like a dream Elliott, thanks for this. Webtreats= the only pro themes for me :D
Jayce
Can I make a suggestion and put this as a sticky? Probably everyone that uses Wordpress will want to do this.
Thanks for the suggestion jayce103, I created stickies for tutorials and will just create a link to this post.
Thanks alot
I used this new file and got one page working but ...
I added other 2 pages to use other categories and both giving the prev error:
"Sorry, that document can not be found."
only one page is working fine
Despite being a different category the page still has the heading "News" - any ideas why?
Hey MiguelGonzalez,
Right now it uses the page title. Make sure your page title is not set to "News" and if it is then try changing it to whatever you feel like.
Let me know if this works.
@pixelsoft, I just tested it and it is working with multiple pages. Are you sure you are typing in the category name correctly? Currently it only accepts one category to display, make sure you are not trying to type in multiple categories. This may be updated in the future though.
For other users that are using these templates and cannot get them to work..
If your slugs are different from your category names then you would need to type in your slug in the custom field. To view your category slugs login to your admin menu and go to Posts -> Categories.
The value you need to type in is the slug as seen in the attached image.
Hi,
I'm having the same issue as MiguelGonzalez. The page name is "News" but the <h1> displays "Blog". I turned off all plug-ins and the error still occurred.
I created a page called "News2" with everything the same as "News" EXCEPT for the template and it displayed correctly. When I changed it to "One Category", the heading changed to "Blog" like the other page.
FWIW, the posts are displaying correctly (and everything else seems to be cool).
Thanks much.
Hey Suburb, you must have your header disabled. Just caught this.. find line 165 which should look like this..
<h1><?php echo get_the_title($blog_page) ?></h1>
And change it to this..
<h1><?php echo the_title(); ?></h1>
Let me know if that clears it up.
Perfect. Thank you. And many thanks for the super quick reply.
Help, I'm not figuring this out. I have a blog page and I created a news page as well. When I post to the news page, it post on both the blog page and the news page.
What I am not understanding here?
Hello mglodfelter,
If you do not want your posts to show up on your regular default blog page then you would need to exclude them under the blog tab.
This will not affect the One Category template so you can select a category to show up on this template and exclude it from your regular blog page.
I'm am so sorry for being so dumb on this. What do you mean exclude them under the blog tab? I could not find a blog tab anywhere. Please forgive me for my ignorance.
Sorry, it is my fault for not being clear.
In your dashboard under the inFocus settings you would need to click on the blog tab (see attached image). When you click on categories to exclude they will not be shown on your regular blog page (not the one category template).
Hi,
I followed all the steps and it's working fine! Just a little detail that I don't know how to fix. I would like my other blog page to a left sidebar like all of my pages... is there a way to do it?
Hello autreschine,
That is currently not a feature of inFocus but I will look into getting it done for you as other people might want this also.
I'll get back with you by the end of the day.
Forgot to ask whether you are using inFocus or Awake. Here is one for inFocus, test it out and let me know if it works okay for you. If it works good then I'll create one for Awake.
Hi Elliott, I'm using AWAKE, can I use the template you create?
thanks again
Hey autreschine,
Try this one and let us know if it works for you.
Hi Elliott,
it's working, but the left sidebar seems to be larger than the other pages' one. can you fix that too?
thx again
Hello autreschine,
If you open the file up and at the bottom around lines 104 - 109 you can see the sidebar div which should look like this..
<div id="sidebar" style = 'left: -20px;'>
Go ahead and change it like this..
<div id="sidebar" style = 'left: -0px; width: 200px;'>
You can play around with the values until you get something you like.
thx for the support Elliott!!
Dear Elliott,
one more detail, my blogroll is still on 2 columns and there is a gray line that should be on the right end of the sidebar, instead, it's on the left.... can you help me one more time?
If you add an "overflow: visible;" to your sidebar div like we did with the width then it will take care of the two columns.
As for the gray line I cannot see it. If possible can you send us a link to your page?
Hi Elliott,
i've put the "overflow: visible;" in my sidebar div, but my blogroll list is still in 2 columns... if you go on my "Nos articles" page you will see the differences.
thx a lot for your help!
Try adding this line..
.blogroll li { margin-right: 50px !important; }
That will make them all fall into one column. Let us know if it works for you.
Hey, posting here because it has to do with the One Category Template Elliot put up in this thread. I am using that template on my site now and it works like a charm, the only thing I noticed is that in the breadcrumbs at the top of the page eventhough the category is set as whitepapers and it pulls correctly from that category, the bread crumbs still say Blog, is there anyway to change that so it pulls the Category name.
it is correct on the main Category page Whitepapers
http://grahamober.com/develop/wpinstall/white-papers/
but on the single post it says blog
http://grahamober.com/develop/wpinstall/2010/09/account-coordination/
Thanks for your help!
Dear Elliott,
where exactly should I add the line? also, did you saw the gray line that I was talking about?
thx again for your help!!
Hello askmaridee,
By default pages will list the page title in the breadcrumbs. If you want change this then open up the one category template and around line 146 you should see this..
<?php
$show_on_front = get_option('show_on_front');
$page_on_front = get_option('page_on_front');
if ( (!$breadcrumb_disable) && ($show_on_front != 'page') && ($page_on_front != $blog_page) ) {
if (class_exists('simple_breadcrumb')) {
$bc = new simple_breadcrumb;
}
}
?>
Go ahead and change it like this..
Home / <?php echo get_post_meta($post->ID, 'template_breadcrumbs', true); ?>
And then when you edit the page create a new custom field with a name of template_breadcrumbs and a value of whatever you want to appear in the breadcrumbs.
Let us know if this works for you askmaridee.
EDIT - Hey askmaridee, sorry I misunderstood you. Which version of inFocus are you using? I checked this on my local setup with inFocus 1.6 and I was not having this issue.
@austrechine, anywhere inside /wp-content/themes/infocus/style.css is fine.
I am unsure what version I am using, how would I find that out?
You can view which version you are using by logging into Wordpress and navigating to Dashboard -> Appearance -> Themes.
You can see the version under the inFocus theme. It should say something like inFocus 1.6 by WebTreats.
oh GRRRR, 1.5 is my version so what is my work around? lol
Alrighty, not sure if this will fix the breadcrumb issue or not but it is always best to have the lastest version.
First create a backup of your inFocus theme folder, /wp-content/themes/inFocus/ in case something goes wrong or you have made customizations.
Next download the latest verion of inFocus from themeforest. Currently 1.6 is the latest version. Then upload it to /wp-content/themes/ and test it out to see if everything looks okay.
If something went wrong then just copy and paste your backup of 1.5. Let us know if this fixes your breadcrumbs.
I think I have customized way too many files to try and upgrade successfully so I guess I'll end up hard coding it somehow.
Here is the breadcrumb.php file from 1.6. Not sure if this will work for you but you can try..
Create a copy of your theme folder before trying.
Download and extract to /wp-content/themes/inFocus/lib/classes/
If it does not work as expected then revert to your backup.
Elliot, could you tell me what lines I would have to edit if I do not wish to have a sidebar on the new blog page?
Did the breadcrumb issue get resolved? I am using the latest version of inFocus. I have created the one category page named testimonials that pulls only from posts with the category testimonial. In the breadcrums for the testimonial post it reads:
Home / Blog / Crossfit Testimonial
it should be
Home/ Testmonials/ Crossfit Testimonial
Thank you!
Hello dchao90,
Which theme are you using?
I'm using the Awake theme.
Open up the file and at the end you should see this..
<?php if($get_template == 'template-full.php') { echo '</div></div>'; }else{ get_sidebar(); } ?>
Go ahead and change it to this..
</div></div>
You might also want to take a look at line 23..
<div id="main">
And add a width to it..
<div id="main" style = 'width: 900px;'>
@eodesign, which theme and version are you using?
You must log in to post.