Link to home
Start Free TrialLog in
Avatar of lowpriceskates
lowpriceskatesFlag for United States of America

asked on

Disappearing DIV

I'm having a really strange situation.
Basically, on my ecommerce site the error message for a declined credit card is showing up and then disappearing after about half a second.
I have removed all Javascripts that I thought could be causing it and it is still happening.

Steps to recreate:
1. Add any product to cart. Example:
2. Go to Checkout and put in any address.
3. Enter Credit Card number 5431111111111111 with any future expiration like 0114 and any CVV number like 555. (It's supposed to decline.)
4. Click Place Order and quickly scroll to the top of the page and watch the space under the "Secure Checkout" header. The error message will appear in red and then disappear.

Below is the code for that error message that disappears.
I've tried adding CSS to make those classes and the surrounding DIV's ID display:block as important but it's not working. I can only assume some piece of Javascript is making it hidden. Any help? Thanks!!
<div id="ctl00_pageContent_udpNotification">
<div class="notification text-error">
The payment was declined. Please check your credit card information to make sure it was entered correctly.

Open in new window

Avatar of COBOLdinosaur
Flag of Canada image

That page is quite a disaster.  I would besurprised if it didn't have problems.  The HTML validator identifies 274 errors and issues 100 warnings.  There is really very little to be gained trying to debug something like that when diagnostic tools are going to get lost in a mountain of invalid, structurally broken code.

Before you do anything thing else you need to validate the HTML and CSS; and fix the errors.  The page is at the point where it is just going to keep getting less and less reliable, until it finally goes into a meltdown.

Avatar of lowpriceskates


The shopping cart greatly limits what I can change and there isn't much I can do to fix the errors. That's just how it is.

I'm trying to find what causes that particular DIV to disappear. Thanks!
The page seemed to work ok with Chrome on Mac OS X, and the message didn't appear at all with Safari. That said, I noticed that your page is using jQuery, which may be the code that hides the DIV. So try this: remove or change the CSS classes of the DIV ("notification text-error"), so that it can't be found by a class selector. If this changes your problem, then work backwards from there to find the code that uses these classes as selectors. If not, look for any references to "udpNotification" in any JavaScript code.

Good luck! (You'll need it!)
Unfortunately I am not able to change the class of that. That's set by the shopping cart. I have looked through the scripts and do not see any references to udpNotification.
Avatar of sandygettings
Flag of United States of America image

Link to home
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
If you are that restricted by the cart, then you need to speak to the vendor of the software for support.  When you use non-valid junk and are not able to modify anything, then you are owned by the author and forced to eat whatever they put in front of you.