XF 2.2 GoFundMe Widget Doesn't Work

btmgreg

Well-known member
Hi there everyone - Hoping someone can help me.

I'm trying to display a GoFundMe widget - the code is as such -

Code:
<div class="gfm-embed" data-url="https://www.gofundme.com/f/the-truth-runs-marathons/widget/large/"></div><script defer src="https://www.gofundme.com/static/js/embed.js"></script>

It doesn't display upon saving - and these are the errors in the browser -

Mixed Content: The page at 'https://www.behind-the-mask.net/' was loaded over HTTPS, but requested an insecure frame 'http://www.gofundme.com/f/the-truth-runs-marathons/widget/large'. This request has been blocked; the content must be served over HTTPS.

and

Uncaught TypeError: Cannot set properties of undefined (setting 'height')
at embed.js:1

Not really sure where to go from here. The link within the widget code is https. My site is https. It seems to be where the widget code directs, too. Not sure why.

Any tips? Thank you in advance :)
 
Solution
Not entirely sure, I tried your code on the default style and getting the same error.

Doing a manual iframe loading in that page seems to work, but not entirely sure it'd be the best practice:

Code:
<iframe src="https://www.gofundme.com/f/the-truth-runs-marathons/widget/medium" frameBorder="0" width="500" height="200" title="Donation">
</iframe>

It also doesn't really scale well for the sidebar. You were using the "large" version which definitely wouldn't fit into the sidebar.
Further update - Still unable to get this to work, and it just appears blank. Not sure if @Russ has any ideas (Using a PixelExit theme)

I approached gofundme and they gave me this code instead, but it still doesn't work -

Code:
<iframe class='gfm-media-widget' image='1' coinfo='1' width='100%' height='100%' frameborder='0' id='https://www.gofundme.com/f/the-truth-runs-marathons'></iframe><script src='//funds.gofundme.com/js/5.0/media-widget.js'></script>

Thank you :)
 
Not entirely sure, I tried your code on the default style and getting the same error.

Doing a manual iframe loading in that page seems to work, but not entirely sure it'd be the best practice:

Code:
<iframe src="https://www.gofundme.com/f/the-truth-runs-marathons/widget/medium" frameBorder="0" width="500" height="200" title="Donation">
</iframe>

It also doesn't really scale well for the sidebar. You were using the "large" version which definitely wouldn't fit into the sidebar.
 
Solution
Not entirely sure, I tried your code on the default style and getting the same error.

Doing a manual iframe loading in that page seems to work, but not entirely sure it'd be the best practice:

Code:
<iframe src="https://www.gofundme.com/f/the-truth-runs-marathons/widget/medium" frameBorder="0" width="500" height="200" title="Donation">
</iframe>

It also doesn't really scale well for the sidebar. You were using the "large" version which definitely wouldn't fit into the sidebar.
Thanks Russ. As always, very helpful. Odd that the default code didn't work :/
 
Back
Top Bottom