pizzadox Posted January 14, 2015 Share Posted January 14, 2015 (edited) hey i wanted to add to my site a background music from youtube so i did and its working fine but there only one problem i have no idea why but the youtube player leaving me a black line on the top of the page for some reason i tried to use some factions and some codes to remove it but i couldnt even when i putted the width and height to 1 or 0 its still stays the same heres my site http://niggazone.allalla.com/loadingtaiv/loading.html (look at the top theres a black line there and the thing is its making my page scroll) and heres the code that im using var gtavid='<div class="video"><iframe width="1" height="1" src="http://www.youtube.com/watch?v=S70-qOCg1FY?hd=1&autoplay=1&loop=1&playlist=S70-qOCg1FY" frameborder="0" allowfullscreen></iframe></div>';document.write(gtavid); Edited January 14, 2015 by pizzadox Link to comment Share on other sites More sharing options...
Ingolme Posted January 14, 2015 Share Posted January 14, 2015 I find that setting the height of class .video to zero makes the black line disappear. Link to comment Share on other sites More sharing options...
pizzadox Posted January 14, 2015 Author Share Posted January 14, 2015 (edited) I find that setting the height of class .video to zero makes the black line disappear. i tried it before and its the same check it again i updated it to 0 i remember theres like few ways to get it done one of em its by using this code/format <embed id="audio-music" src="http://www.youtube.com/watch?v=S70-qOCg1FY?autoplay=1&loop=1" type="application/x-shockwave-flash" width="1" height="1" allowscriptaccess="always" allowfullscreen="true"> but the thing is this code is not fully working on my game (garrys mod) i want to use this site as a loading screen to some game soon i will try to look again at the full code of the site Edited January 14, 2015 by pizzadox Link to comment Share on other sites More sharing options...
Ingolme Posted January 14, 2015 Share Posted January 14, 2015 I can't see this rule in your stylesheet: .video { height: 0; } I have no idea what browser Garry's mod uses internally, if it has one at all. 1 Link to comment Share on other sites More sharing options...
pizzadox Posted January 14, 2015 Author Share Posted January 14, 2015 (edited) I can't see this rule in your stylesheet: .video { height: 0; } I have no idea what browser Garry's mod uses internally, if it has one at all. its not a known one dont worry i will check the code again if i will not be able to get rid of this black line i will use a different way to code it EDIT: forget about it i will use the second code for it something is wrong with this one var gtavid='<div class="video"><iframe width="0" height="0" src="http://www.youtube.com/watch?v=S70-qOCg1FY?hd=1&autoplay=1&loop=1&playlist=S70-qOCg1FY" frameborder="0" allowfullscreen></iframe></div>';document.write(gtavid); i replaced it with this one <embed id="audio-music" src="http://www.youtube.com/watch?v=ZKyCpyDqZPg?autoplay=1&loop=1" type="application/x-shockwave-flash" width="1" height="1" allowscriptaccess="always" allowfullscreen="true"> thanks for trying to help if somethin i will ask again and by the way setting the width and height to zero will stop the music for some reason(im talking about the fixed code) and on the wrong code if you will set it to 1/0 its making no difference Edited January 14, 2015 by pizzadox Link to comment Share on other sites More sharing options...
Ingolme Posted January 14, 2015 Share Posted January 14, 2015 I think Flash player doesn't like to be invisible. What you might be able to do is set its position to "absolute" and put it behind something by giving it a negative z-index property. Elements with absolute position don't reserve space on the page. Your page uses the HTML 5 <canvas> element, only modern browsers are capable of using it, browsers created approximately within the last three years. Link to comment Share on other sites More sharing options...
pizzadox Posted January 14, 2015 Author Share Posted January 14, 2015 (edited) I think Flash player doesn't like to be invisible. What you might be able to do is set its position to "absolute" and put it behind something by giving it a negative z-index property. Elements with absolute position don't reserve space on the page. Your page uses the HTML 5 <canvas> element, only modern browsers are capable of using it, browsers created approximately within the last three years. its was on absolute in the first place #audio-music { position: absolute; opacity: 0; } and about html5 its fine.. almost ever browser support it (im using opera next 27) i tested it with IE too and its fine i updated the code to the fixed one and its cool now.. http://niggazone.allalla.com/loadingtaiv/loading.html EDIT: i got what was the problem even on the fixed code the black line is still existing there but the line is hiding behind the images so you cant see em but on the normal code its forcing it to be over the images for some reason i dont sure why but the flash player is forcing it to be visible Edited January 14, 2015 by pizzadox Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now