Notifications
Clear all

Paid Addons Support Forum Only

Please note, that here we only support Paid Addons issues and questions.

gVectors Support staff works from 6am to 6pm (GMT+0)

All questions related to wpForo and wpDiscuz free plugins should be asked in the corresponding plugin support forum:

 

wpDiscuz Support Forum   wpForo Support Forum

Video preload  


igork82
Posts: 3
(@igork82)
New Member
Joined: 4 weeks ago

Hi guys!

How to set the video html tag preload to none?

Thanks!

Topic Tags
1 Reply
Elvina
Posts: 1364
Moderator
(@elvina)
Noble Member
Joined: 1 year ago

Hi @igork82,

Please put the following JS code in the current active theme functions.php file:

add_filter("wpdiscuz_after_read_more", function ($content) {
return preg_replace('~(<video[^>]*)>~is', "$1preload='none'>", $content);
}, 999);

Don't forget to delete all caches and press CTRL+F5(twice) on the frontend before checking.

Also please note the code works only for the front-end

Reply
Share:
Scroll to top