473,404 Members | 2,137 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,404 software developers and data experts.

css transition only working in Firefox

KeredDrahcir
426 256MB
I'm trying to use CSS transitions to make a background image fade in on my menu when you hover over it. I want it to take about 2 seconds to fade it.
It works perfectly in Firefox but all on other browsers it just appears instantly. In IE it doesn't work at all but I'm not worried about that since I never expected it to work.

CSS LAYOUT
Expand|Select|Wrap|Line Numbers
  1. .mainmenu ul li{
  2.     height: 86px;
  3.     display: inline-block;
  4.     margin: 0;
  5.     padding: 0;
  6.     z-index:1000;
  7.     position: relative;
  8. }
  9. .mainmenu li:after{
  10.     content: "";
  11.     opacity: 0;
  12.     -webkit-transition: opacity 1.5s;
  13.     -moz-transition:    opacity 1.5s;
  14.     -o-transition:      opacity 1.5s;
  15.     -ms-transition:     opacity 1.5s;
  16.     transition:         opacity 1.5s;
  17.     top: 0;
  18.     left: 0;
  19.     bottom: 0;
  20.     right: 0;
  21.     position: absolute;
  22. }
  23. .mainmenu li:hover:after{
  24.         opacity: 1;
  25. }
  26.  
CSS APPEARANCE
Expand|Select|Wrap|Line Numbers
  1. .mainmenu li:after{
  2.     background: url(../images/hover.png) no-repeat center bottom;
  3. }
HTML
Expand|Select|Wrap|Line Numbers
  1. <div class="mainmenu"><ul><li><a href=''>Home</a></li><li><a href=''>About Us</a></li><li><a href=''>Contact Us</a></li><li><a href=''>Blog</a></li><li><a href=''>Gallery</a></li></ul></div>
  2.  
Can anyone help? Apart from IE it does work it making the image appear but it would be nice to get the fade in working on Chrome, Safari and Opera. If I can get it working then, I might even be able to think about IE.
Mar 18 '13 #1
0 1316

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Richard A. DeVenezia | last post by:
I hope this is the end of my present 'discovery' phase. I've learned alot about JavaScript in a short time and my head hurts. The following is what came out of all my questions and all the...
4
by: sonic_soul | last post by:
Hi, I was curious if I could make my webservice work with firefox client webservice functionality. (i got it to work with webservice.htc) I am able to get firefox to see my serverside web...
8
by: Workgroups | last post by:
I've got a page where the nature of the beast is such that the user clicks a submit button to ransomize some data in somewhat rapid succession (once per second, give or take). The page generates a...
3
by: TJS | last post by:
I am finding that the serverside requiredvalidator doesn't fire in the firefox browser, and user request proceeds through to my updateProfile method. Validation is working correctly in the IE...
14
by: Gale | last post by:
I wrote a simple script for image rotation. now i need to have some transition effect betwean images in JS What do you suggest ? Thank you
4
by: the other john | last post by:
I came across a third party script I want to learn how to configure as well as learn more dhtml in the doing. I'm not much of a JS guy yet but I'm working on it. This script works fine in IE6...
1
by: papalazarou78 | last post by:
Hi I've been experiementing with actionscripting transitions between sections... this is the first site I have tried this with (last 3 had swf loaded in one after another rather than transitioned...
3
by: geetha v | last post by:
Hi All, I need a scrolling DIV is a to display my dynamic tree in left frame. In my jsp , Div overflow is set to "auto" <DIV id=divScroller style="overflow:auto;height:200px"> <!--...
1
by: puneetmca | last post by:
hello i made a menu using css and js.. it is working properly but the way how it shown is not looking professional .. I think i dont set any transition property to it........ i tried but i failed...
1
by: perhapscwk | last post by:
Hi, I use below in IE, it works but it not work in firefox, please help. <meta http-equiv="Site-Enter" content="revealTrans(Duration=2,Transition=23)"/> <meta http-equiv="Page-Enter"...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.