team-ok
Forum Replies Created
-
Forum: Plugins
In reply to: [Switch Video Quality] Uncaught ReferenceError: _svqSettings is not definedThe docs of your theme say there’s an option in the customizer to disable ajax functionality or to enter urls that shouldn’t be loaded via ajax:
https://apollo13.eu/docs/photon/#ajax_settings
Could you please try if this solves your issue?Some of the scripts of my plugin need to be loaded dynamically (e.g., when the embed feature is deactivated for a post), so this can’t be a general solution.
- This reply was modified 5 years, 8 months ago by team-ok.
Forum: Plugins
In reply to: [Switch Video Quality] Uncaught ReferenceError: _svqSettings is not definedThere are some strange things going on: when you click on the first link of your main page, the scripts of my plugin seem to be included just right (they appear in the html source of the page), but for some reason some of them are removed afterwards (they don’t appear in the dom tree of DevTools).
There is a function in your theme’s main script that should handle the loading of scripts when content is fetched via ajax. I guess there’s something going wrong here. That would explain why everything’s fine when you reload the page or open it directly (no ajax involved).
There’s not much I can do here, but inside of the main script of your theme there’s a check if the link that was clicked on has the class “no_ajax” and if it’s there, the page is loaded without ajax and everything is working. I tested it by simply adding this class to the<a>
-element in DevTools, but I guess there is an option in the admin area or on your page edit screen for doing that saying “don’t load this page via ajax” or something similar.As a last resort I could make a special version of the plugin that loads its scripts on every page (not only when the shortcode is actually used). Maybe this would avoid the error, but please try the other solution first.
Forum: Plugins
In reply to: [Switch Video Quality] Uncaught ReferenceError: _svqSettings is not definedI think this happens when the content is loaded on demand (via ajax).
My plugin loads scripts only when the shortcode is actually used by calling default wp functions that load these scripts in the footer.
Your theme seems to have a mechanism that loads these scripts into the footer even when it’s an ajax call, but there must be something wrong with the order of the scripts that get loaded. So one script calls a variable that is not defined yet(ReferenceError), because the scripts are loaded in the wrong order.I will try to find a solution for you but again it’s hard to debug without seeing your scenario.
Forum: Plugins
In reply to: [Switch Video Quality] Not working in AlbumsThis happens when you remove the padding in Dev tools of your browser. You need to resize the browser window afterwards, as the width of the video player is calculated by JavaScript on resize.
When there’s no padding on page load, the width should be calculated correctly.But anyways this is all related to your theme, so I’m afraid I can’t do anything more to it.
Forum: Plugins
In reply to: [Switch Video Quality] Not working in AlbumsYou’re right to expect that, but only if your theme uses the default wp way of embedding videos in your page. If it is providing custom functionality related to video or the way media is embedded, there’s a possibility of conflict. And I can’t debug or see where this conflict is coming from if it’s a commercial theme.
Forum: Plugins
In reply to: [Switch Video Quality] Not working in AlbumsWordPress doesn’t have a default album post type.
It’s created by your theme:
https://themeforest.net/item/photon-fullscreen-photography-wordpress-theme/11543656Sorry, but I can’t reproduce errors that are related to commercial themes.
But you can easily improve the look of the player in your album with a little css by removing the padding of this selector: .album-content .inside.
There’s also an empty p tag below the video that creates extra space and should be removed.
So it may look like this:
Forum: Plugins
In reply to: [Switch Video Quality] Not working in AlbumsHi,
what do you mean by “album post type”? Is it a custom post type created by another plugin?
Can you please provide some more details about your WP configuration (Gutenberg or classic editor, WP version, other plugins)?Forum: Plugins
In reply to: [Switch Video Quality] Update for “Switch Video Quality” ?Hi, no update needed, works just fine.
Forum: Plugins
In reply to: [Switch Video Quality] Need an update, help !Hi,
I didn’t find any problems with WP v5.1 in my tests. Please give me some more details and check if there’s no other plugin conflicting with the Gutenberg editor or SVQ.
Forum: Plugins
In reply to: [Switch Video Quality] Need an update, help !Hi,
though I couldn’t find any bigger problems with the plugin and WP version 5, there was an error when saving a post with required subtitle fields (label and language code) left blank. I released an update today.
If your problem persists, it would be great if you could give me some more details.
Forum: Plugins
In reply to: [Switch Video Quality] Subtitles on by defaultHi,
you could do it with a small jQuery snippet.
If you want to switch on the first subtitle track of a video, use this:jQuery(document).ready(function($){ $('.mejs-video.svq .mejs-captions-selector-input:not([value="none"])').eq(0).click(); });
Or, if you want to switch on a specific language, you could use this (change “en” to a language code of your choice):
jQuery(document).ready(function($){ $('.mejs-video.svq .mejs-captions-selector-input[value$="en"]').click(); });
Put the snippet in a custom javascript file that is loaded by your theme or in a script tag in a post/page.
Hi,
I had the same issue, only in Firefox. The provided css code solved it without any side effects in other browsers.
Thanks!
Forum: Plugins
In reply to: [Switch Video Quality] No quality options availableHi Dennis,
ja, das ist wieder das gleiche Problem: dein Theme fügt bei Eingabefeldern Icons hinzu.
L?sch einfach von dem Code, den du beim letzten Mal eingefügt hast, diesen Teil weg:
.mejs-sourcechooser-button .mejs-sourcechooser-selector
Der Code sollte dann so aussehen:
.svq .mejs-controls ul li label::before { display: none; }
Dadurch gilt er für alle Label in der Controlbar des Players, nicht nur für den sourcechooser.
Forum: Plugins
In reply to: [Switch Video Quality] No quality options availableHi,
there’s only a single video file referenced on your page, so there’s nothing to select from. Did you upload and add multiple qualities in the plugin’s settings?
Btw, your video is labelled as 1080p, but has dimensions of 1536 x 216.
Forum: Plugins
In reply to: [Switch Video Quality] how to insert multiple video in one postHey,
sorry for my late reply. My little daughter was born two months ago, so my focus has been somewhat biased lately ??I’ve created a new branch of the plugin that allows to insert multiple videos into the same page. It works just like before, but now there’s a new post type ‘SVQ Video’ that allows to set up your multi-quality videos. Every SVQ-Video post can then be inserted into a page with a shortcode.
Here’s how:
- Dowload the zip-file from here: https://github.com/team-ok/switch-video-quality/archive/multi_vid.zip
- Upload the zip file to your WordPress instance (from the backend or via FTP)
- Important: Make sure to deactivate your currently installed version of SVQ to avoid conflicts. If you have another WP instance suitable for testing, it’s better to use that one.
- Activate the new plugin. It should show up as Version 1.6000
- Now there’s a new item in your admin menu on the left labelled as ‘SVQ Video’. Create a new video post here as usual (Turn on the svq functionality, insert multiple qualities and labels or create a playlist) and save it (Note: Previewing or displaying a svq video post won’t work, it’s solely meant to be included somewhere else).
- On the right (below the WordPress saving dialog), there’s a box displaying the shortcode to be used when you want to insert this video into a page. Copy this shortcode.
- Paste the shortcode somewhere in a page
- Repeat the last steps above for each video you want to include
This allows you to insert multiple multi-quality videos into the same page.
Let me know if it works for you. I’ll update the main plugin with this feature if everything’s ok.