Page 1 of 1

#include v <iframe>

Posted: Fri Sep 30, 2016 8:48 am
by Vegan
right now my chess site is old fashioned HTML 5 with PHP document assembly

now I was pondering WordPress for the site but I have not been able to figure out how to get PHP include working

so I was thinking maybe <iframe> could allow me to add chess results to a page/post?

suggestions?

Re: #include v <iframe>

Posted: Fri Sep 30, 2016 9:19 am
by Celauran
Both include and iframe seem like poor solutions. What are you trying to accomplish?

Re: #include v <iframe>

Posted: Fri Sep 30, 2016 11:21 am
by Vegan
I have some various things in mind

system requirements for games are almost boilerplate text so why not use 3 or 4 basic includes for the various classes of consoles etc

the chess site is made up of html files which are #included now

Re: #include v <iframe>

Posted: Fri Sep 30, 2016 12:09 pm
by Celauran
Oh I see. I was trying to steer you away from an include-based architecture. For fragments of markup, includes definitely make sense. Have you looked at get_template_part? I seldom use WP, but this looks like it might be what you want.

Re: #include v <iframe>

Posted: Fri Sep 30, 2016 1:38 pm
by Vegan
My chess site is all modularized into PHP components like WP is. WP however has new ways to doing things so I was attempting to find alternatives.

So what is this class based architecture going to do for me?

iframes are flakey with WP, they do not position as easily as I would like but that is more of a CSS problem

eg:

CPU: i3-2100
RAM: 8GB
GPU: GTX 760 or R9-370
DISK: 68GB


NB: need a bulleted list for the forum

Re: #include v <iframe>

Posted: Fri Sep 30, 2016 1:53 pm
by Celauran
Vegan wrote:So what is this class based architecture going to do for me?
If you're going to be using WordPress, it's a moot point. Otherwise, it keeps your code organized and DRY

Re: #include v <iframe>

Posted: Fri Sep 30, 2016 7:18 pm
by Vegan
Back with my roll your own I used 5 different machines for system requirements. So I used PHO #include to choose the one that was needed. Easy.

So now I have <iframe> which has been around for a while

Code: Select all

<iframe src="//hardcoregames.azurewebsites.net/"></iframe>
but I would have a folder with the relevant parts

so do I need to do anything with the iframe content, or do I need a new DOM to work with?