• Resolved James

    (@webdevjames)


    I’m having an issue with inconsistent aspect ratios. All my videos are 16:9, but for some reason, some of them are being displayed on page as 4:3. I searched this forum and found a code snippet that was supposed to fix the issue, but it was just code for the functions.php file, and when I tried it, it kept erroring and wouldn’t let me save it.

    The settings on all videos are exactly the same, yet they are being rendered different.

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hello James,

    Thank you for choosing Presto and for reaching out to us!

    Our player matches the YouTube video to standard aspect ratios (1:1, 4:3, 16:9, etc.). It seems this video is non-standard. You can use this snippet to add a new aspect ratio to match what they are using:


    add_action(‘wp_footer’, function () { ?> <script> jQuery(function() { if (!wp || !wp.hooks) return; wp.hooks.addFilter(‘presto.playerSettings’, ‘pp-set-aspect-ratio’, function(settings) { settings.ratio = ‘9:16’; return settings; }); }); </script> <?php });


    If there’s anything else, please let me know.

    Have a great day ahead ??

    Thread Starter James

    (@webdevjames)

    Not quite, the videos on my channel are all either 3840×2160 or 1920×1080 (16:9) yet they are being displayed as 4:3. That looks like the same code i found on this forum already, and it’s giving me the same error message:

    Your PHP code changes were not applied due to an error on line 126 of file wp-content/themes/truebuild/functions.php. Please fix and try saving again.Uncaught Error: Undefined constant “‘wp_footer’” in wp-content/themes/truebuild/functions.php:126 Stack trace: #0 wp-settings.php(600): include() #1 wp-config.php(99): require_once(‘/home/972040.cl…’) #2 wp-load.php(50): require_once(‘/home/972040.cl…’) #3 wp-admin/admin.php(34): require_once(‘/home/972040.cl…’) #4 wp-admin/theme-editor.php(10): require_once(‘/home/972040.cl…’) #5 {main} thrown

    Hello there,

    Thank you for your update.

    As checked on our end, it is working. Here is the screencast for your reference: https://d.pr/v/RjUjoR

    Possible conflict with your plugin.

    Further, kindly check your theme builder layout and caching

    Hope that helps. Please let us know how it goes.


    Thread Starter James

    (@webdevjames)

    What do i need to look for in “theme Builder”? I already disabled all plugins and caching, but it still giving me the same error message when i try to save the code the same way you did in the video.

    Also, i’m not really sure why the plugin can’t just work the way it says it does. 2 videos from YouTube with the same settings, resolution, etc, but one is displayed in the plugin as 16:9 and the other 4:3. Makes no sense to me

    Hello James,

    Thank you for your update.

    In order to receive assistance, we kindly request you to open a support ticket using the following link: https://my.prestomade.com/support/

    Our support team will be happy to assist you further through the designated support channel.

    Thank you for your understanding. If you have any other inquiries, feel free to let us know.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Problem with Aspect Ratio’ is closed to new replies.