avielesp
Member
Posted 1 year ago #
Hello,
I’m working with Zincious Theme and I want to change post published in the home to one category but I can’t find the recent_post function anywhere in the files! Any tip or trick to help me find the code line?
I'm also trying to set the posts in the home to 3 maximum… how can I do this?
Can someone help me pls!?
The site link is: http://contactoyprotocolo.com/mx/
avielesp
Member
Posted 1 year ago #
Please help!
I wanto to have one a category shown in home page instead of recent post or all post but I'm a lost!
This is the LOOP I have that is pulled to the home page... any advice?
[Code moderated as per the Forum Rules. Please use the pastebin]
avielesp
Member
Posted 1 year ago #
Sorry, here is the pastebin:
http://pastebin.com/RHUT88w9
I kind of understan de query_post but I'm not sure where to use it with this LOOP.
Any advice?
You need to add your custom query to the very top of the file.
avielesp
Member
Posted 1 year ago #
I move it to the first line and it is not working, the site report the next error:
Fatal error: Call to undefined function query_post() in /home/.../zincious/loop.php on line 1
Any idea of what am I doing wrong?
This is my new code: http://pastebin.com/HtbCaeHv
avielesp
Member
Posted 1 year ago #
I did it!!
Change the code on the top to:
<?php if ( is_home() ) { query_posts('cat=4&posts_per_page=3&';} ?>
I share it just in case someone need the tip...
creativego
Member
Posted 1 year ago #
hi this is what u meant
<?php if ( is_home() ) { query_post ( 'cat=37&posts_per_page=3&' ); } ?>
however still doesnt work for me..
Fatal error: Call to undefined function query_post() in ..............