iFrame,shortcodes & displaying custom meta data breaks it :(
-
A iframe plugin for displaying iframes with shortcodes this works fine displays the video from the custom meta data its finding.
<?php echo do_shortcode('[iframe_loader src="http://player.vimeo.com/video/'. get_post_meta($post->ID, 'rw_vid-url',true) .'" width="834" height="467" frameborder="0"title="0""]');?>
However, this one breaks, with it not finding the code, the only difference being the additional embedding edits…<?php echo do_shortcode('[iframe_loader src="http://player.vimeo.com/video/'. get_post_meta($post->ID, 'rw_vid-url',true) .'?title=0&byline=0&portrait=0&color=ffffff" width="580" height="326" frameborder="0""]');?>
This one works though when the post meta info is not inside it..<?php echo do_shortcode('[iframe_loader src="http://player.vimeo.com/video/1856437?title=0&byline=0&portrait=0&color=ffffff" width="580" height="326" frameborder="0""]');?>
The custom meta data shows fine as well using this…<?php $meta = get_post_meta(get_the_ID(), 'rw_vid-url', true); echo $meta;?>
For some reason i cannot add it into the second iFrame code without it breaking the whole thing.Any ideas would be a massive help? 🙂
Many thanks.
- The topic ‘iFrame,shortcodes & displaying custom meta data breaks it :(’ is closed to new replies.