Html Question, Sorry DOnt mind if you are not interested

Dec 11, 2019 at 2:20am
Im really sorry for posting this

Yall people respond quickly about c++ stuff , i guess i can try for html sorryyyy

IF someone can help me about html css javascrip pls help me

Last edited on Dec 11, 2019 at 2:21am
Dec 11, 2019 at 3:12am
At least post your question so we can answer it!
Dec 11, 2019 at 4:02am
itry to open html file on the same page with this

window.location.href - THis one didint work at all (For me)

&

window.open - This one works but i need to make it open the file on the same page (i already try
window.open("file.html","_self")
Dec 11, 2019 at 4:44am

Why not use an iframe that covers the entire page?

var body = document.getElementById("body");
body.innerHtml = '<iframe height="100%" width="100%" src="page_you_want_to_show"></iframe>'

I mean, it could work.. probably not the best decision, but still..
Last edited on Dec 11, 2019 at 4:45am
Dec 11, 2019 at 5:00pm
What about these methods?
https://www.w3schools.com/howto/howto_js_redirect_webpage.asp

(Edit: I think you’d better post questions like this in the “lounge” section)
Last edited on Dec 11, 2019 at 5:01pm
Feb 1, 2020 at 5:12am
window.location.replace('http://w3c.com');

It’s better than using window.location.href = 'http://w3c.com';

Using replace() is better for redirect, because it does not keep the originating page in the session history, meaning the user won’t get stuck in a never-ending back-button fiasco. More... http://net-informations.com/q/mis/redirect.html
Topic archived. No new replies allowed.