从一个网页访问另一个网页时,如何根据您来自哪个网页的按钮添加过渡背景? [英] How to add transition background to buttons when visiting from One webpage to another depending on which webpage you came from?

查看:66
本文介绍了从一个网页访问另一个网页时,如何根据您来自哪个网页的按钮添加过渡背景?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个设计想法要在导航按钮中实现,在导航按钮中,当用户单击任何其他按钮时,会在当前按钮的背景下说 HOME 转换用户点击的按钮在加载用户选择的网页时同时同时更改字体按钮文本的颜色。

I have a design Idea to implement in navigation buttons in which When the user clicks any other button the background of the current button, say "HOME" transition to the button the user clicked, when the webpage the user selected is loaded, WHILE simultaneously changing the font color of the button text.

下面是一张图片,它将为您提供我想要的内容。您认为可以进行此工作的任何想法或任何网站都可以使用。字体颜色正是我要转换的颜色。
预先谢谢您。

Below is an image which will give you want I want to do. Any idea or any website you have sen this working will work. The font color is exactly what I want to transition. Thanking you in advance.

如何应该在网页上查看

推荐答案

您将需要使用ajax来实现此功能,因为只有在温泉。刷新的应用程序将无法使用过渡。我无法为您编写代码,但是如果您有自己尝试过的代码示例,将能够为您提供帮助

you will need to use ajax to implement this as it will only be possible in an SPA. An application that refreshes would defeat the use of transitions. I cant write the code for you but will be able to help you if you have a code sample u have tried

这篇关于从一个网页访问另一个网页时,如何根据您来自哪个网页的按钮添加过渡背景?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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