显示动画之前显示我的index.html [英] Show an animation before show my index.html

查看:124
本文介绍了显示动画之前显示我的index.html的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个网站,很少的内容。因此,它加载速度快的导航仪。
我想之前加载一个jQuery的动画显示前的index.htm。结果
真诚,我不知道该如何实现这个想法。我不希望在动画用户点击继续主站点。我想要做的X时的动画,当它完成后,会自动充电的下一个HTML或页面的其余部分。

I have a website, with few content. So, it loads fast in the navigator. I want to load an jquery animation before show the first index.htm.
Sincerely I don't know how implement this idea. I don't want that the user clicks in the animation to continue to the main site. I want make an animation of 'x' time and when it finish, charges automatically the next html, or the rest of the page.

非常感谢。

推荐答案

更改页面加载的所有内容一下子包括动画的方式。不过,最主要的内容是隐藏的(例如,通过内联CSS)和动画块所示。一旦你的动画完成隐藏动画块并显示主要内容来代替。就如此容易。这也给浏览器足够的时间,而它播放你的动画渲染的主要内容。

Change your page the way that it loads all content at once including the animation. But the main content is hidden (e.g. by inline CSS) and the animation block is shown. Once your animation is done hide the animation block and show main content instead. As simple as that. This also gives browser enough time to render main content while it plays your animation.

或选项2 - 负载index.html的动画只有然后一边播放动画时隐入元素加载通过AJAX含量

Or option 2 - load index.html with animation only and then load content via AJAX while animation is playing into hidden element.

我会提供一个例子code如果我在手上的笔记本电脑或PC,但基本顺序应该明显

I would provide an example code if i had laptop or PC at hand, but basic sequence should obvious

这篇关于显示动画之前显示我的index.html的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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