News:

Wondering if this will always be free?  See why free is better.

Main Menu

Embedding SMF Into My Website

Started by usdualsports, May 15, 2016, 01:36:00 PM

Previous topic - Next topic

usdualsports

I'm trying to embed my SMF into a page on my website. I'm using Iframe and it keeps showing up blank when I use my smf url. If I use a general url the iframe works so it makes me think that SMF has some sort of security that won't allow it to be embedded into a website page. If there is a way to cure this issue I appreciate the info.

Shambles

I just did a search, using the search button, putting "iframe" in the search criteria, and the search results shows lots of discussion.

Try the search box - it's pretty good.

This, for example...

http://www.simplemachines.org/community/index.php?topic=537044.msg3816555#msg3816555

usdualsports

Thank for the reply, but unfortunately I can't do that with my website. I was able to do it a few years ago using only iframes, but for some reason I can't anymore.

Shambles

Can't do what? Search?

The search box may yield other search results. Did you try...?

usdualsports

No I searched before posting just didn't find the solution. I can't do what that post you suggested.

Arantor

It really was done for security - I'm the person who introduced the code to do it, because having your forum run inside an iframe can easily lead to all kinds of cases where people can be tricked into doing things they don't mean to.

If I knew exactly how you were trying to embed (e.g. which domain the iframe is on vs which domain the forum is on), or whether editing the theme to integrate it properly is actually feasible, we would be able to help better.

usdualsports

Quote from: Arantor on May 15, 2016, 02:25:55 PM
It really was done for security - I'm the person who introduced the code to do it, because having your forum run inside an iframe can easily lead to all kinds of cases where people can be tricked into doing things they don't mean to.

If I knew exactly how you were trying to embed (e.g. which domain the iframe is on vs which domain the forum is on), or whether editing the theme to integrate it properly is actually feasible, we would be able to help better.

Thank for the reply and here is the code I'm trying to use.
<iframe src="hxxp:usdualsportsforum.com/index.php [nonactive]" frameborder="0" width="100%" height="100%" scrolling="no" allowfullscreen></iframe>

The main site will be hxxp:www.usdualsports.com [nonactive] and my forum addresse is hxxp:www.usdualsportsforum.com [nonactive]

thanks

Arantor

Yeah, cross domain iframes are a security nightmare which is why the rule prevents them running. That would also imply multiple hosting accounts ruling out proper integration between the two. :(

Quickest way is to take the insecure route and remove the line from the top level index.php which says:

header('X-Frames: SAMEORIGIN');

usdualsports

Thanks that is what I did last time. Thanks it worked perfect.

Advertisement: