Page 1 of 1

frame or iframe?

Posted: Thu Sep 26, 2013 8:52 am
by louiegiezer
is it ok to add some iframe on your site? i've heard b4 to jacek not to use idunno if "frame" or "iframe"... something like dat.. iframe is java right?...

Re: frame or iframe?

Posted: Thu Sep 26, 2013 4:51 pm
by ScTech
Iframe is HTML to show contents of another page in the page you are viewing. Iframes are not very safe security wise so you should only use them when the page you want is trusted, and there is no other way but to use iframes. I'm not sure what the difference between iframe and frame are because I've never really used either. Perhaps someone else can explain further.
<iframe src="http://google.com">Text here if iframe is not supported in their browser</iframe>

Re: frame or iframe?

Posted: Thu Sep 26, 2013 7:10 pm
by Temor
I hate iframes, I really do. They are fine to use however if you've taken the necessary precautions first.

I prefer doing it this way instead:
Apply a <div> with some styling, including scrolling etc.
use either php or ajax, or a combination of both to fetch the data from one file and insert it into the div I want.

It does require a bit more work, but it's not using iframes, so it's a win in my book.

Re: frame or iframe?

Posted: Fri Sep 27, 2013 12:03 pm
by louiegiezer
the reason why i asked about that is bcuz of rich text editor or wysiwg... instead of textarea they put it on iframe... can anyone know how to make a simple rich text editor... i onyly need bold,italic,underlined, and images only.. i dont need plugins... i want to learn how they do that... btw im looking 4 that in youtube... and other references ^^

Re: frame or iframe?

Posted: Fri Sep 27, 2013 2:47 pm
by Temor
I'm not sure I understand what you want exactly, but I'm guessing it has to do with BBcode.
Are you looking for something like tinyMCE?

Re: frame or iframe?

Posted: Fri Sep 27, 2013 3:38 pm
by louiegiezer
yup sr... something like that..

Re: frame or iframe?

Posted: Fri Sep 27, 2013 3:43 pm
by ScTech
Are you saying that you want to learn how to make one from scratch, or want one that is open source?

If you want to learn, there is a nice example of how to convert BBCode from text to HTML via PHP in this thread.

Re: frame or iframe?

Posted: Fri Sep 27, 2013 5:00 pm
by louiegiezer
wow this awesome... thx much:) :D