![]() |
Wordpress question
Hey Guys,
I got thumbs leading to posts (in pinterest style), but what if i want to add simple gallery from time to time and have thumb to lead directly to it instead to post with content, how to do this? any idea? (not to mention problem with featured image which is actually a thumb on the main page). |
create a custom post type, and a custom field. in the custom field put your gallery url
edit the code pulled by the custom post type in the loop. call the customfield instead of the content. |
i do understand what you wrote however i never done this so i need to process it and figure how to make this custom post and how to make loop.
thank you, i'll work on it. |
To do so you will need to alter the main loop of your index template to make it display not only post links (thumbs linked to posts) but also thumbs linked to the large images.
|
I would keep it simple.
Your theme has code to show the thumb linking to the post. Before that code, add a check for the post custom meta field for an external URL. If it exists, link the thumb to that url. If not, link the thumb to the post normally. Easy peasy. |
https://wordpress.org/plugins/page-links-to/
For the post image, do you have a custom URL option when you click edit on the image? I do. |
Quote:
|
Quote:
|
one way of doing it which occurred to me might be to install an advert plugin, make some thumbs and have them lead to the gallery via those adverts?
|
with Colmike plugin it's fast and non brain solution: you paste gallery url under post in the new field provided by plugin, you simply add featured image as usually, wrote title as usually for post and press "post" (or schedule) all i wanted and save me time cracking wp code for half a day (usualy takes me so long..).
using external plugin is never perfect solution, better is to modify code for your need but again: i have no time for this now. |
Quote:
|
Quote:
|
All times are GMT -7. The time now is 02:35 AM. |
Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc