- NewsmagPage templates
it is supose to do this: https://bygselvviden.dk/vaerktoejstest/bajonetsav/
But on some categories it returns no posts.
i use this loop: <?php if ( have_posts() ) : ?> to get them, but for some reason the if case returns false on some categories. ?
I use this code to handle it: https://pastebin.com/FaKCeUma
Regards.
Hi,
For customizing the printed version you could try maybe with code or plugins
– https://www.wpkube.com/make-your-website-printer-friendly-wordpress/
– https://www.wpbeginner.com/plugins/how-to-add-a-printer-friendly-option-to-your-wordpress-posts/
The theme itself doesn’t have a separate stylesheet to apply for the printed post, or any settings in this matter.
That co-authors solution is for post pages and modules. So basically any of the default post templates and default modules would be able to display the co-authors.
If you mean that this does not work with Cloud templates, that would be the case. For example if a tag page would use standard modules you can modify that module to display co-authors by editing the module file.
But in a tag page that uses a cloud loop element like this
– https://www.terrestres.org/tag/anthropocene/
That would require modifications in the cloud plugin files, in this case the loop module
– https://www.screencast.com/t/6UXEqJdpt4
Doing that will affect all the loop modules, no matter where it is placed (including search pages).
However I can’t say if it will work or not, haven’t tried to do something like this. Also after a theme update when the cloud template will be updated, the modification will be lost.
Thanks
I’ve got a custom post type for a glossary. On the glossary archive page I’d like to display it with no thumbnail or meta data, display the content rather than the excerpt, and remove the link from the title. Basically on the archive page it just needs to have the title and content displaying in alphabetical order, with 25 posts per page and paging.
What would be the best way to do this? I’m assuming it would be best to do a custom archive page calling to a custom loop? Or can I hook in with a function in my child theme just for that custom post type? I know I can hook in with pre_get_posts to change the amount of posts displayed, but as far as not displaying the other stuff, I’d rather not just hide it through CSS.
Hi,
In category template just set the offset numbers, for examples in first category grid will show 5 post ( latest 5 posts ), in post loop will set the offset from 5 ( will skip the first 5 posts ) https://www.screencast.com/t/kvVAYT4I1d
Thanks.
Hi,
Yes, you understand correctly, that is a custom made for our blog; you can create it with posts loop, or with flex block.
Thanks you for your understanding.
Hi,
Our theme do not work with the that WordPress setting, (unfortunately any page you set in the Post page will take the template from the theme panel, template settings, blog and posts templates ), please do not use that setting.
Sorry for the inconvenience.
https://www.screencast.com/t/7TRSzO5lOHM
Way not not change the name of loop template and set it in menu, and in this way you’ll have both.
I will give you an example, I will set the loop template as home page and I have the New set in menu, in this way I got goth settings, also you can have both in menu if you want.
https://www.screencast.com/t/Sww6KQpoN
Hope this will help you.
Thank you for your understanding.
Hi,
Glad you found a workaround. That new issue would require some modifications to the mobile theme files. You could copy the homepage loop code in the page template file
– https://www.screencast.com/t/M9HjPo2HBl2
– https://www.screencast.com/t/95x0Twob
Then wrap that code in a condition like this to make sure it appears only in the page you want
– https://developer.wordpress.org/reference/functions/is_page/
Next add an additional parameter to make the loop display posts from a specific category you want
– https://www.screencast.com/t/dnoo7WyqkZy
That should display posts from a specified category in that page only.
Thanks
Thank you Simion for your response.
We’ve invested a lot of time in carefully designing our website using your Cloud Templates so reverting to the standard category template isn’t an acceptable solution, nor is discontinuing the use of the plugin that enables our podcast to work.
As an interim solution since I haven’t gotten a resolution that solves the actual problem, I have created a page that is identical to the Cloud Template originally created for the category and redirected the category to it.
This way, when someone accesses the category — https://www.theapex.racing/the-braking-point-podcast, they are transparently taken to the page at https://www.theapex.racing/the-braking-point. Because the category itself retains a standard Newspaper template, the functioning of the feed located at https://www.theapex.racing/the-braking-point-podcast/feed is unaffected.
This solution has worked fine, except we also use your mobile theme. By redirecting the category to a page, we have to create a mobile page that acts like a category.
Is there a way I can add a post loop of posts from a specific category on a mobile page?
Hi Calin,
It seems like you did not quite understand my question so let me try again.
There appears to be an issue with the Newspaper theme and WordPress setting for blog posts. Let me explain by giving you a few examples.
I created a page using the Tagdiv composer which is fine. Here is what the page looks like before I go to the settings in WordPress and I assign it as the official “blog posts page” – https://www.staging1.successunscrambled.com/our-podcasts/
If I head over to the settings in WordPress and go to settings -> reading -> posts page and place this page or a duplicate of that same page as the official “posts page” this is what happens – https://www.staging1.successunscrambled.com/loop-template-9-full-1/
As you can see in the 2nd example I used a cloud template without any adjustments as the page.
Where in the Newspaper theme is there template coding that instructs the page to behave differently when it is assigned as the official “posts page”? As you can see this coding overrides the fact that I want this page to be displayed as a regular page without a sidebar but there is a bit of coding somewhere that is preventing that from happening.
Can you please advise?
Thanks,
Alven
Hello,
I have the problem, which stands in some categories the sidebar under the similar posts. For other categories, but right next to the content.
Example for under the content https://salzsau-panorama.de/2018/11/13/aussenbordmotoren-gestohlen/
Example for next to the content https://salzsau-panorama.de/2018/11/08/termine-zum-volkstrauertag-in-bleckede/
I do not know why that is. Because I have changed from the template single loop on single loop 13 to change nothing.
How can I change that?
Hi,
There would be a way to do that, but if there are many authors it will take some time because an author page template will have to be created for each author.
Author templates can be created with the tagDiv composer and cloud library plugin
– https://forum.tagdiv.com/tagdiv-cloud-library-plugin/
Blocks and grids can display pages as well. If you would create templates for each author you could place blocks or grids set to display pages and also filtered by author ID in them
– https://www.screencast.com/t/zyJkqZTPL5
This may take some time if there are many authors, each will require a template with a block or grid set to display pages filtered by specific author.
Currently there is a post loop which can simply be placed in various templates and will get content automatically, but only posts not pages. Maybe this will chnage in the future, can’t say for sure.
Thanks
Hi Calin, my server has 128 MB/request WP memory limit.
Can we please test compatibility with Wishlist Member for the next release of Cloud Library.
In your solution above I tried it and it did not work for me, I copied the code from loop-single-1 into loop single 13 but that broke the loop single 13 template. I do not want to overwrite single-1 as it is my core template for posts.
I deleted the M1 section on my page that listed the most recent posts with a list of categories at the top to click and update the list (with the “load more” option at the bottom), and now I just use the regular post loop option and I think that fixed it.
Something was preventing M1 from updating posts on my page on mobile devices (iphone/fire tablet). I also added Nginx Helper plugin that purges cache, maybe that had something to do with it (?). But it should have worked with your WP Super Cache plugin settings you provided to begin with. The website is https://distresssedvolatility.com. I used to be able to show multiple categories next to the latest news title, which was cool because it would load the most recent posts for each category. Now I don’t do it.
-
This reply was modified 7 years by
dvolatility. Reason: added link to site
Hi,
You need to have set the template page on Page Builder + Latest Articles + Pagination, and from the “Posts loop settings” tab you can customize the Latest Articles
https://www.screencast.com/t/UjxQZmjIxVeA
Please read about Page Builder + Latest Articles + Pagination ->https://forum.tagdiv.com/page-templates-2/
Thank you.
Hello
Thanks, I success to have custom ads on default loop, archive, tag and category after 3 posts. this will be great if we can place custom ads on block for various customization in tagdiv composer.
I do some experiment to place custom ads on block 18. I put this code:
//insert adsense
$adcounter++;
if ($adcounter == 2 or $adcounter == 4 or $adcounter == 6){
$buffy .= do_shortcode('[td_block_ad_box spot_id="custom_ad_2"]');
}
On this file http://www.screencast.com/t/pmWcAIXu the custom ads show up on the block 18 after 2, 4 and 6 from posts lists http://www.screencast.com/t/wsT6hLeT. Also see live result is perfect http://www.screencast.com/t/5Ta26Pjoy. But the code is still not perfect, it’s because I can’t access tagdiv composer anymore hahaha http://www.screencast.com/t/sNKNE1u1o
It would be better if someone volunteered to help me to make this code works on the block 18 file. If this code is working, we can put custom ads in another block file. 🙂
Hello Guys, i am wondering whether there is an option to modify post by adding block under the post except of more articles from user? Is there any option to modify post option in order to have infinite loop of more posts under the post?
cheers
jan
Hi,
Can’t say I do, no tests were made with the plugin you mention. How is the data set to appear in the loop? The loop file is this one
– https://www.screencast.com/t/MZk1W5E7mQ9
In similar topics where for example ads were inserted in the loop after a certain number of posts this had to be coded inside the loop itself
– https://forum.tagdiv.com/topic/how-to-add-adsense-ad-after-5-10-articles-on-main-page/
– https://forum.tagdiv.com/topic/ads-on-category-between-posts/
– https://forum.tagdiv.com/topic/ads-on-category-pages/
I use the The Events Calendar Extension Main Blog Loop.
This is to allow events to appear in the loop of the page between posts.
It is set so that events are displayed on the day of the event.
Unfortunately that does not work.
Do you have an idea why that is?
My mean to Post Loop Block is this – http://prntscr.com/l7xjd6
I didn’t change H2 for Block 5 module because I just want to change H2 for new posts, and if I change it for Block 5 then all the others blocks also change the same.
Thanks for the reply.
Well, It works for the TD Block 5, but not for the new PostLoops Block (which comes with 9.1 Update). Because I just want to change the H2 tag for the new posts for the SEO purpose. so, I want to change the title tag to H2 for the new posts.
Here are the screenshots;
http://prntscr.com/l7v2p4
http://prntscr.com/l7v2sr
So, Please let me know how to do this.
Am currently trying a different approach.
I have added this bit to functions, to be able to sort on keyowrd a to z and z to a.
$sortList = array(
'a-z' => array(
'meta_key'=>'keyword',
'orderby'=>'meta_value',
'order' => 'ASC'
),
'z-a' => array(
'meta_key'=>'keyword',
'orderby'=>'meta_value',
'order' => 'DESC'
)
);
I created a page with the tagdiv composer to show all posts that have a keyword starting with the letter D, the posts are ordered by date (which is standard, recent to old)
According to the tutorial that I’m trying to implement these two pieces of code should find their way into the theme
for the loop:
<?php
gloabl $sortList; //to use the $sortList in your functions.php.
$aryQuery = $sortList[$_REQUEST['orderby']] ? $sortList[$_REQUEST['orderby']] : $sortList['keyword'];
$featuredPosts = new WP_Query( $aryQuery );
?>
For the drop down list, which should appear on the page.
Tried adding this via the raw html inserter in tagdiv but that’s not working out.
Should I implement this in a custom page template ?
<ul>
<?php
gloabl $sortList; //to use the $sortList in your functions.php.
foreach( $sortList as $orderby => $aryOrderBySettings){
?>
<li> <a>">Order by <?php echo $orderby;?></a></li>
<?php
}
?>
</ul>
Could you please advise where I should implement the two pieces of code above ?
-
This reply was modified 7 years by
NickDeBaerdemaeker.
Hi,
In order to edit the Latest Article section, you need to open the page and go down on the page until you see the Latest Articles, change from “General” to “Posts loop settings” ( https://www.screencast.com/t/eiCITfPtvVWa ).
Hope this will help you.
Thanks.
Can’t say I have, most unusual. The general setting also affects category loops, there it seems to have worked as it displays 6 posts
– https://staging1.mycentralfloridafamily.com/category/back-to-school/
So this is happening only in the homepage it seems. What if you try to create a test page and select the latest template, does it work there?
Hi,
We are using the default Newspaper demo page as our home page and have been able to customize everything except the latest articles feed that is at the bottom of the home page. It shows 11 articles – we want it to be just six. Any attempts I have made to reduce this to 6 only affect the # of posts that display on pages 2, 3 etc which you click on the page scroll at the bottom of the feed.
Here is what we have attempted to to do address this:
1. When editing the home page at the bottom – edit post loop settings / filters to limit post number to 6. This affects the loop pages but not the home page feed.
2. Tried to change settings using the td composer on the front end, but cannot access the feed.
We did not see where to change this in the theme panel.
Please let us know how to fix this. you can see the issue here: https://staging1.mycentralfloridafamily.com/
Hi Simion, Thanks for the reply.
I’m looking for a simple fix without any extra plugin. Could you tell me where the loop for tag page is located? Is that in includes/wp_booster/td_data_source.php module where I could adjust the order by in wp_query object?
Could you please tell me where can I find that piece of code that picks up the posts for a given tag page?
Thanks, JK