将网页加载设置为黑色而不是白色背景? [英] Set page load to black instead of white background?

查看:155
本文介绍了将网页加载设置为黑色而不是白色背景?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

链接到网站:

http:/ /www.ideagang.co/home.php

当从1页到另一页点击时,是否可以将背景设置为黑色?
现在网站加载完美的黑色背景,这只是当我从一个页面到另一个页面flickr一秒钟浏览.....

Is it possible to set the background to black when click from 1 page to another? Right now the website load perfectly with the black background, it's just that when I navigate from one page to another the page flickr for a second.....

是否还有通过将内部加载页面时将背景设置为黑色来解决此问题?

Is there anyway to resolve this by setting the background to black when loading page internally?

推荐答案

浏览器的默认背景颜色是白色,所以你看到的闪烁是默认的分裂秒,然后才有机会读取CSS规则使其变黑。

Not using only CSS. The browser's default color for the background is white, so the flicker you see is the default coming through for a split second before it has a chance to read the CSS rule to make it black.

我可以想到的唯一方法是加载第一页,然后通过javascript从页面切换到页面,将它们加载到退出页面。无重载意味着无闪烁。在我看来,这是一个很大的开销,很少的价值,所以我建议只是生活在它。

The only way I can think of to get around this would be to load the first page, and then switch from page to page via javascript, loading them in to the exiting page. No reloads means no flicker. In my opinion, that is a ton of overhead for very little value, so I would suggest just living with it.

这篇关于将网页加载设置为黑色而不是白色背景?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆