Last active
August 29, 2015 14:12
-
-
Save golanlevin/a90dbc100dc7c7128f38 to your computer and use it in GitHub Desktop.
Repair to Sketchfab Viewer WP Plugin
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This fixes an error in the Sketchfab Embed Wordpress plugin. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* The code for the Sketchfab Embed Wordpress plugin, | |
sketchfab-viewer/sketchfab-viewer.php | |
had fault-inducing line breaks. I replaced the following section: | |
*/ | |
return '<iframe frameborder="0" height="'.$height.'" | |
width="'.$width.'" | |
webkitallowfullscreen="true" mozallowfullscreen="true" | |
src="https://sketchfab.com/embed/'.$id.'?autostart='.$start.'&autospin='.$spin.'&controls='.$controls.'&transparent='.$transparent.'" | |
></iframe>'; | |
/* with the following replacement code: */ | |
return '<iframe frameborder="0" height="'.$height.'" width="'.$width.'" webkitallowfullscreen="true" mozallowfullscreen="true" src="https://sketchfab.com/embed/'.$id.'" autostart='.$start.'&autospin='.$spin.'&controls='.$controls.'&transparent='.$transparent.'"></iframe>'; | |
/* after which everything worked perfectly. Note, there was also a missing quote mark, I believe. */ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment