twelve-of-code-official / website

The source code for the Twelve of Code website
https://mesure.x10.mx/twelve-of-code
GNU General Public License v3.0
0 stars 0 forks source link

Remove <!DOCTYPE html> from challenge html files #38

Closed BeepBot99 closed 9 months ago

BeepBot99 commented 9 months ago

What problem were you having?

IE less than version 11 will not load the page if there are two DOCTYPE declarations.

What solution would you like?

Remove the <!DOCTYPE html> declaration and the <body> tag.

What alternatives have you considered?

Using an iframe to display the challenges. That might actually be better in some ways.

What are some pros and cons of doing this?

Pros

What page is this for?

twelve of code

BeepBot99 commented 9 months ago

If you use an iframe, then you can load any page even if it's cross-origin, so that would probably fix issue https://github.com/Mesure73L/Mesures-Website/issues/37 too.

Mesure73L commented 9 months ago

also just telling you now the question titles are h2 (##) so if you want a heading instead of bold for it you should use h3 (###) instead of h1 (#)

Mesure73L commented 9 months ago

Nevermind, I have time right now to work on it

BeepBot99 commented 9 months ago

also just telling you now the question titles are h2 (##) so if you want a heading instead of bold for it you should use h3 (###) instead of h1 (#)

No, the question titles are h3 now (###) so i used h4 (####).

BeepBot99 commented 9 months ago

So are you just removing the <!DOCTYPE html> declaration or are you making it an iframe? Note that if you make it an iframe, then keep the <!DOCTYPE html> declaration and also add a <head>.

BeepBot99 commented 9 months ago

LOL, you assigned me and then realized that you are not a lazy person and assigned yourself instead. You might have also realized that you asked me to stop development soon.

Mesure73L commented 9 months ago

So are you just removing the <!DOCTYPE html> declaration or are you making it an iframe? Note that if you make it an iframe, then keep the <!DOCTYPE html> declaration and also add a <head>.

iframe

Mesure73L commented 9 months ago

LOL, you assigned me and then realized that you are not a lazy person and assigned yourself instead. You might have also realized that you asked me to stop development soon.

no, i just wanted to make it so im not bored 24/7

BeepBot99 commented 9 months ago

So are you just removing the <!DOCTYPE html> declaration or are you making it an iframe? Note that if you make it an iframe, then keep the <!DOCTYPE html> declaration and also add a <head>.

iframe

Are you going to do it or should I? It will only take a few minutes to do.

Mesure73L commented 9 months ago

I'll do it

BeepBot99 commented 9 months ago

OK.

BeepBot99 commented 9 months ago

@Mesure73L What if you put the challenge inside of a modal?

Mesure73L commented 9 months ago

@Mesure73L What if you put the challenge inside of a modal?

No.

Mesure73L commented 9 months ago

Pros and cons of using iframe

Pros:

Cons:

@BeepBot99 what do you think?

BeepBot99 commented 9 months ago

About the second pro: What does that mean? About the first con: No, there is no significant difference. About the second con: What are they?

BeepBot99 commented 9 months ago

Why do you think iframes make it slower? All it is doing is sending an XHTTP request, which is what you are already doing.

Mesure73L commented 9 months ago

No, there is no significant difference.

Yes, there is. I have it open here temporarily

About the second con: What are they?

Challenge verifiers, idk some other stuff

BeepBot99 commented 9 months ago

Well it is slower because it's in GH codespaces. It won't actually be slower on the website. Also, GHCS is blocked in my school so I can't view it.

Mesure73L commented 9 months ago

Well it is slower because it's in GH codespaces. It won't actually be slower on the website. Also, GHCS is blocked in my school so I can't view it.

... JSYK, I tried the old one before this and it was WAY FASTER. It being GHCS does not make a difference

Mesure73L commented 9 months ago

It's not slower because of the information it's getting, it's slower because of how it's displaying that information.

Mesure73L commented 9 months ago

An alternative is to say "Challenge is loading, please wait" or something like that while it's loading

Mesure73L commented 9 months ago

@BeepBot99 I think the current method is better, I'll remove <!DOCTYPE html> and <body> elements if you think thats better

Mesure73L commented 9 months ago

Moving to pull request, #39