-
AuthorPosts
-
February 8, 2016 at 4:54 pm #579748
I’d like to have the title in the Portfolio link directly to the portfolio post. If you look at our Portfolio page, you’ll see that when I add an image that links to video it plays perfectly! But, there are additional details on the portfolio page that I would like to link to. Also, I noticed that when there is NO image, the title of the Portfolio links to that specific portfolio page. How can I keep that link even when there is an image in place?
In other words, I would like to add a video link to the image and a portfolio link to each title.
- This topic was modified 8 years, 10 months ago by Jdclark18.
February 10, 2016 at 4:10 pm #581212Hi Jdclark18!
Thank you for using our theme.
Please try to add following code to Functions.php file of your child theme (or parent theme, if not using a child theme)- you can use Dashboard -> Appearance > Editor:
function my_custom_title_link( $title_link, $entry ) { if( ! empty( $title_link ) ) { return $title_link; } $title_link = get_permalink( $entry->ID ); return $title_link; } add_filter( 'avia_settingsf_output_settings_field', 'my_custom_title_link', 10, 2 );
Best regards,
GünterFebruary 10, 2016 at 11:13 pm #581378Thanks! I added that code to my child theme in the functions.php and it’s not working.
Here’s a screenshot of what I’m talking about. As you can tell, right now I’ve only uploaded two images, both of which are Vimeo videos. This part is working great. However, the Title is not linking to the actual portolfio page:
https://www.dropbox.com/s/uzasibl2l0t5rk8/Screen%20Shot%202016-02-10%20at%204.03.10%20PM.png?dl=0
(I highlighted the text that I want to be the link: “God Is Not Your Problem.”) Every portfolio will have a Vimeo Video and I need each title to link to the actual portfolio page.You can see the page here:
The weird thing is that the other portfolio items that DON’T have vimeo video links have links in the titles. It seems as if the Vimeo link is causing the Title link to disappear. Thanks in advance for your help!
February 13, 2016 at 4:26 pm #582744Hi!
Try setting a custom link (to the video) for the portfolios containing Vimeo links – http://screencast.com/t/j3eSp27Waa
Best regards,
JosueFebruary 14, 2016 at 6:31 am #582827Thank you, but I’ve already done that. All that does is provide the Vimeo Video link for the IMAGE and that’s working great.
What I’m looking for is to have the text of the title become a permalink to the portfolio time (NOT the video link which is the custom link). In other words, the IMAGE = CUSTOM LINK and then I need the TITLE = PORTFOLIO PERMALINK.
I thank you in advance for a swift reply. This is one of the main things holding me back from launching this website!
February 14, 2016 at 1:07 pm #582928Hi,
Can you please create us a WordPress administrator account? post it here as a private reply.
Regards,
JosueFebruary 14, 2016 at 3:05 pm #582958Yes, thank you Josue. The log-in info is in the private data for this post. I look forward to your help!
- This reply was modified 8 years, 10 months ago by Jdclark18.
February 14, 2016 at 9:18 pm #583004Hey!
Please change the code as following
function my_custom_title_link( $title_link, $entry ) { if( ! empty( $title_link ) ) { return $title_link; } $title_link = get_permalink( $entry->ID ); return $title_link; } add_filter( 'avia_settings_output_settings_field', 'my_custom_title_link', 10, 2 );
please let me know if it works
Best regards,
BasilisFebruary 15, 2016 at 4:29 am #583060Thanks Basilis,
I’ve added that code to my child theme’s functions.php file and it’s still not doing what I need it to. Any further suggestions?
February 15, 2016 at 8:22 am #583175Hey!
It should work as you expect now, correct code to use was:
function my_custom_title_link( $title_link, $entry ) { if( ! empty( $title_link ) ) { return $title_link; } $title_link = get_permalink( $entry->ID ); return $title_link; } add_filter( 'avf_portfolio_title_link', 'my_custom_title_link', 10, 2 );
Best regards,
JosueFebruary 15, 2016 at 2:56 pm #583472Perfect, thank you!
February 15, 2016 at 5:07 pm #583586You are welcome, glad to help :)
Regards,
Josue -
AuthorPosts
- You must be logged in to reply to this topic.