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 :)
r1kay
tagDiv Member

Well i’ve found another post regarding to the single.php and figured it out myself. Here’s the solution:

$buffy .= '<br><h4 class="block-title"><span>DEEL</span></h4>';
			$buffy .= do_shortcode('[ssba]');

$buffy .= do_shortcode(‘[ssba]’) is the code that triggers my social sharing buttons plugin.

I’ve added this to line 58 in themes/Newspaper/includes/app/modules/td_module_1.php. Any modification to the standard post lay-out (normally made in single.php) can be made in this file.

r1kay
tagDiv Member

Thanks for the replies!

I won’t use the show featured video/image on post function so will embed the videos manually, which raises another problem. I add a lot of parameters to youtube embed codes (as mentioned in my first post) to hide annotations and related videos and other stuff. Now here’s the problem: I have a lot of bloggers and I want to make it as simple as possible for them to embed video’s. The easiest way is to let them just paste the link in the post and let the WordPress oEmbed function insert the HTML embedded iframe. However, oEmbed does not add those parameters to the embed code, it just inserts a regular embed code that looks like this:
<iframe width="100%" height="394" src="http://www.youtube.com/embed/-McFIAlP0Ow?feature=oembed" frameborder="0" allowfullscreen="" style="height: 420px;"></iframe>

Can someone tell me what code I need to add to the WordPress oEmbed function (wp-includes/class-oembed.php) so it will result in this HTML output:
<iframe width="100%" height="394" src="http://www.youtube.com/embed/-McFIAlP0Ow?feature=oembed?rel=0&?wmode=transparent&iv_load_policy=3&showinfo=0&vq=hd1080" frameborder="0" allowfullscreen="" style="height: 420px;"></iframe>

r1kay
tagDiv Member

Merry Christmas to you both too!

I know how to embed videos the regular way, i’m not a total noob 😉 I managed to edit the embed code that is used when showing it as featured video, so that it will start in HD and won’t show annotations and related video’s at the end.

If someone is interested, here’s the code.
Replace line 157 in includes/class/td_video_support.php with this:
<iframe width="600" height="560" src="http://www.youtube.com/embed/' . $this->getYoutubeId($videoUrl) . '?rel=0&?wmode=transparent&iv_load_policy=3&vq=hd1080' . $this->getYoutubeTimeParam($videoUrl) . '" frameborder="0" allowfullscreen=""></iframe> The code’?rel=0&?wmode=transparent&iv_load_policy=3&vq=hd1080′ is the part that does the trick, so the rest of the code will not be edited.

Marius, i’ve already noticed that it will automatically put the normal youtube link in an iframe and that the embed code provided by youtube will also automatically be put in a different iframe. These iframes will force the video to be shown in a 100% width and style=”height:420px”. The featured video comes with a 600 width and 560 height (as can be seen in the code i mentioned above), the embedded video comes with a 600 width and 394 height. However, these heights are forced to 420px because of the style code. Now here’s my question: I don’t know why, but on my other site the embedded video’s will hide the buttom pause/play and options, as can be seen here:
http://www.mannenhumor.com/magazine/stunten-op-een-wielrenfiets.
On the my new site using the Newspaper theme, these functions on the bottom stay visible when the video is playing. I don’t know why, but i think it might have to do something with the height. I tried to find differences in the embed code using the debug tool, but i can’t find them. So how can i edit the height of the iframe that is used by your theme? I can’t seem to find where this style height is set… Is it a css file somewhere? I feel a bit stupid for asking.

Now here’s another question. The iframes forced by the theme don’t use the code as i mentioned above. Where can i find this piece of coding, i would like to add ‘?rel=0&?wmode=transparent&iv_load_policy=3&vq=hd1080’ to it so my bloggers can simply put the youtube link in a post without having to put this code behind every youtube video manually.

As for the fb and disqus comment system, i’ve managed to use it on my other sites. Those use the Avada theme, which is a REALLY slow theme regardless of the double comment system, so i don’t know if it will cause a decrease in page speed. I do know a site that uses them both and their page loads quick enough if you as me. See for yourself here (don’t mind the content, it’s a Dutch site): http://www.vkmag.com/magazine/kind_krijgt_stofzuiger_als_kerstcadeau

  • This reply was modified 12 years by r1kay.
Viewing 3 posts - 101 through 103 (of 103 total)