How to Show Full Content on Sticky Post
Topics related to Realistic theme goes here.
You are great. thank you very much
- Asmi Khalil
-
- Posts: 779
- Joined: Fri Jun 26, 2015 7:13 am
- Display Name: Asmi Khalil
- Location: Tunisia
Most welcome 
Glad I helped you!

Glad I helped you!
I think there is a world market for maybe five computers. - IBM chairman Thomas Watson, 1943
I need some more help
It is possible to add code if someone searching and sticky post show as excerpt on search page. currently show fully content on search page. thank you

- Asmi Khalil
-
- Posts: 779
- Joined: Fri Jun 26, 2015 7:13 am
- Display Name: Asmi Khalil
- Location: Tunisia
Yes, of course! All what you need to do is to create a copy of the original /template-parts/content.php and name the file to content-search.php and place it in the /template-parts folder (Exactly where content.php is located). Since you have changed your content.php file. Download content-search.rar archive directly from the attachments. Extract content-search.php file from it and copy it to your theme /template-parts folder.
I think there is a world market for maybe five computers. - IBM chairman Thomas Watson, 1943
I want sticky post show as excerpt on search page only, but above method work sticky post show as excerpt on post page too.
- Asmi Khalil
-
- Posts: 779
- Joined: Fri Jun 26, 2015 7:13 am
- Display Name: Asmi Khalil
- Location: Tunisia
Are you sure? Did you place the content-search.php file inside /template-parts folder and kept your modified content.php?yepezd wrote:I want sticky post show as excerpt on search page only, but above method work sticky post show as excerpt on post page too.
Because of the "-search" word in the file name, this file will be used exclusively by the search page and because this file contains the same code as default "content.php". Your search page will be rendered exactly as theme demo site home/blog page. And since you have modified content.php which will be used by archives and blog/home page, your sticky posts will be displayed with full content instead of excerpt.
Could you give me a link to your website?
I think there is a world market for maybe five computers. - IBM chairman Thomas Watson, 1943
Who is online
Users browsing this forum: No registered users and 1 guest
It is currently Fri Feb 22, 2019 9:02 pm