Home User profile
tagDiv Member
This user did not write anything. So we are just showing here some random text to make the profile page look nice :)
manasek
tagDiv Member

Hi Calin,

I have been investigating hard and finally found there was a temporary issue with PHP version upgrade at the hosting provider side.

Thanks for reply anyway!

manasek
tagDiv Member

The same problem. Until last week everythink OK. Today – Failed to contact the templates API server. I have done no update of the core, no plugins updates, no changes on server side… Any help?

manasek
tagDiv Member

Yes, I have this field already translated. The point is, a string from that field does not get displayed in the front end…

manasek
tagDiv Member

Thank you Vlad.

manasek
tagDiv Member
manasek
tagDiv Member

The code above has been cut off. Have tried several times, cannot modify it any more, please delete it…

manasek
tagDiv Member

Hi,

for those interested, below is the code I have gone with. In my case, I created a shortcode and pasted it in the content area of the text block placed in an inner row inside the single featured background image block (by the way, why the pure HTML block doesn’t accept shortcodes?)


<?php global $wp_query, $post, $tdb_state_single;
$post_id = $tdb_state_single->get_wp_query()->post->ID;
$post_title = $tdb_state_single->get_wp_query()->post->post_title;
$td_post_video = get_post_meta($post_id, 'td_post_video', true); ?>
<div class="my_wrap_icon_style">
" data-mfp-src="<?php echo $td_post_video['td_video'];?>">
<span><i class="tds-icon tdc-font-tdmp tdc-font-tdmp-play-round1 my_icon_style"></i></span>

</div>

  • This reply was modified 6 years by manasek.
  • This reply was modified 6 years by manasek.
manasek
tagDiv Member

Vlad, I have managed the first half of the task. I am able to retrieve the featured video URL using following snippet inside any single post template:

global $wp_query, $post, $tdb_state_single;

$post_id = $tdb_state_single->get_wp_query()->post->ID;
$post_title = $tdb_state_single->get_wp_query()->post->post_title;

$td_post_video = get_post_meta($post_id, 'td_post_video', true);

I have found the answer inside tdb_view_single.php

manasek
tagDiv Member

Thanks Vlad!

It works inside the post. I have already achieved it also using td_post_video meta keys.

The issue is that I would like to make the snippet work in a single page template. But, it does not work there… Any ideas to point me?

One example of the use could be to update an icon block or a button block via theme API in a way we clould use the featured video URL in the video popup field…

Thanks!

  • This reply was modified 6 years by manasek.
manasek
tagDiv Member

I vote for this!!

Viewing 10 posts - 1 through 10 (of 10 total)