Home › Forums › General Questions › Customize “No WebGL” Notice
Is it possible for customize the notice that users receive if they don’t have WebGL support on their browsers?
What does your notice look like now?
Route 66 Digital
Right now it displays the default Verge3D notice and links to the Soft8Soft website. My users aren’t tech-savvy people so they won’t know what is going on, it would make more sense for me to display my own notice. How can I do it?
I haven’t seen it but I would want to change it. Can you provide a pic or url it’s going to and I will track down it’s origin and see if we can find a solution.
This one here. I have it displayed after disabling WebGL in Safari. How can I customize this?
Ok… just so happens I ran into this yesterday during testing….on Firefox. I am going to dig in and see how to replace it. Thank you.
Ok…found it in the v3d.js file. You can modify the text and the link there. I am still digging around to find a more elegant way of handling it with a branded graphic etc.
You can override the styles for this notice by using the following CSS classes:
You can also override the content of this message (text and link). However, this piece of HTML code is only injected if there is no webgl.
So, to do this, in the your_app.js you could try to obtain a WebGL context first.
var canvas = document.getElementsByClassName('v3d-canvas');
var gl = canvas.getContext('webgl');
If there is no WebGL, retrieve the HTML elements of this message with getElementsByClassName and update with innerHTML.
Chief 3D Verger | LinkedIn | Twitter
Test your math:
Log in / Register