سؤال

I am using the following Javascript noscript message on my website for when a user has his JS disabled:

<noscript>

 For full functionality of this site it is necessary to enable <b>JavaScript</b>.
 Here are the <a href="http://www.enable-javascript.com/" target="_blank">
 instructions how to enable JavaScript in your web browser</a>.

</noscript>

My Question:

It is currently at the absolute top of the window. I would like to move it down to say top:20px...

I tried wrapping the text inside a div that has an offset from the top, but only the text moves along with the div and not the red border styling applied by the noscript tag (I did not apply any styling to the noscript, it has its own borders)

هل كانت مفيدة؟

المحلول

Using CSS:

noscript
{
    position: fixed;
    top: 20px;
}
مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top