Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / How can I fix CSS Border bug showing on form.hidden tags?

How can I fix CSS Border bug showing on form.hidden tags?

Locked

Views: 4,928

Results 1 to 13 of 13
This thread is locked. New replies are disabled.
26 Mar 2007, 4:49 AM
#1
stevenicel avatar

stevenicel

New Zenner

Join Date:
Oct 2006
Location:
Euroa, Victoria, Australia
Posts:
27
Plugin Contributions:
0

How can I fix CSS Border bug showing on form.hidden tags?

Hi folks,
I have just encountered a little visual abnormality which is a very small border showing on any type="hidden" form tags on my test site. It only shows like this on firefox but not ie.
I have added a border style to the: input and select properties which is fine, but it also creates two small left and right border lines directly to the left of my header search input box and a few other spots on the site.
Obviously it is rendering the form:input border properties on the hidden tags as well as the visible tags.
Any earthly soul know of a possible solution/fix for this?:sleepy:

Steve

26 Mar 2007, 5:03 AM
#2
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: How can I fix CSS Border bug showing on form.hidden tags?

Would have to see this or at least the code you added

26 Mar 2007, 6:27 AM
#3
stevenicel avatar

stevenicel

New Zenner

Join Date:
Oct 2006
Location:
Euroa, Victoria, Australia
Posts:
27
Plugin Contributions:
0

Re: How can I fix CSS Border bug showing on form.hidden tags?

Hi Cobra,
Thanks for the reply. Sorry, should have included the live site link in the original post. :blink:

Here 'tis http://www.yalolowa.com.au

Simply added a:
border: 1px solid #EFF9EE; property to the input and select to the form elements of the main stylesheet.css sheet. Z cart version 1.3.0.2

26 Mar 2007, 8:58 AM
#4
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: How can I fix CSS Border bug showing on form.hidden tags?

Try converting to em and make it small:

border: .01em solid #666633;

26 Mar 2007, 10:16 AM
#5
stevenicel avatar

stevenicel

New Zenner

Join Date:
Oct 2006
Location:
Euroa, Victoria, Australia
Posts:
27
Plugin Contributions:
0

Re: How can I fix CSS Border bug showing on form.hidden tags?

Just made it thinner but didn't fix the problem. It's happening in every instance where there is a form with the *type="hidden" *tag in the html, or so it seems. Because when i click the area then right click to view source in firefox it highlights that area of code. Got me a tad stumped this one.

Any more thoughts.

Thanks for the replies so far though. Appreciate it.

26 Mar 2007, 10:21 AM
#6
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: How can I fix CSS Border bug showing on form.hidden tags?

Is this a visual problem? as when I mad it .01em visually I did not see the wing on the search box.

Or can you post a url to the exact page and provide a description of what to look for and the browser you see it in (FF if as before)

26 Mar 2007, 11:25 AM
#7
stevenicel avatar

stevenicel

New Zenner

Join Date:
Oct 2006
Location:
Euroa, Victoria, Australia
Posts:
27
Plugin Contributions:
0

Re: How can I fix CSS Border bug showing on form.hidden tags?

Is this a visual problem?Yeah, just a visual thing Kobra.

Or can you post a url to the exact page and provide a description of what to look for and the browser you see it inSure. Seems to show in FF1.5 and NN7.2, but not in Opera9.0.2 or IE6.

If you look at http://www.yalolowa.com.au/catalog/index.php with FF 1.5.?or NN7.2 you will see a thicker green line on the left border of the search input box in the header which is actually part of a "hidden" feild, not that input field. If you also go to the log-in page, http://www.yalolowa.com.au/catalog/index.php?main_page=login
you will see a small green rectangle just below the "forgot your password" link.

Hope this helps...

26 Mar 2007, 11:58 AM
#8
paulm avatar

paulm

Totally Zenned

Join Date:
Nov 2003
Posts:
1,878
Plugin Contributions:
5

Re: How can I fix CSS Border bug showing on form.hidden tags?

Weird,

it happens in FF2.0.0.3 too

Not sure if usefull, but when INPUT is removed form the "display: inline;" the borders don't appear anymore here. For example like:

FORM, SELECT{
	display: inline;
	font-size: 1em;
	margin: 0.1em;
	}
input, select {
  border: 1px solid #666633;
  margin: 0;
}
```Seems like the hidden inputs are hidden as if they have a css "display: none;" setting.
26 Mar 2007, 12:06 PM
#9
paulm avatar

paulm

Totally Zenned

Join Date:
Nov 2003
Posts:
1,878
Plugin Contributions:
5

Re: How can I fix CSS Border bug showing on form.hidden tags?

Sorry for interupting BTW,

but I found a workaround:

input[type=hidden] { visibility: hidden; }

source: http://pennypacker.net/articles/five_bad_things_about_firefox

(weird that I never noticed this issue before though)

26 Mar 2007, 12:16 PM
#10
paulm avatar

paulm

Totally Zenned

Join Date:
Nov 2003
Posts:
1,878
Plugin Contributions:
5

Re: How can I fix CSS Border bug showing on form.hidden tags?

paulm:

Seems like the hidden inputs are hidden as if they have a css "display: none;" setting.:D It seems like that really is the case.

Mozilla Firefox/res/forms.css:

/* hidden inputs */
input[type="hidden"] {
  -moz-appearance: none;
  display: none;
  padding: 0;
  border: 0;
  cursor: auto;
  -moz-user-focus: ignore;
  -moz-binding: none;
}
```Looks like they forgot to add !important here..? (or maybe there is a reason for it???).
26 Mar 2007, 12:20 PM
#11
paulm avatar

paulm

Totally Zenned

Join Date:
Nov 2003
Posts:
1,878
Plugin Contributions:
5

Re: How can I fix CSS Border bug showing on form.hidden tags?

I need to get a life I suppose... :ohmy:

But better use:

input[type=hidden] { display: none; }

(using "visibility: hidden;" the hidden inputs still take up some space)

26 Mar 2007, 12:49 PM
#12
stevenicel avatar

stevenicel

New Zenner

Join Date:
Oct 2006
Location:
Euroa, Victoria, Australia
Posts:
27
Plugin Contributions:
0

Re: How can I fix CSS Border bug showing on form.hidden tags?

paulm, you have gone way above and beyond the call of helpfulness here. These anecdotes have worked an absolute treat. Many thanks to you and Kobra for your time and ...input*:unsure:...* get it..... input. Sorry.. huuh hum.. Really reeeeally bad pun.:lamo:

Any way, many thanks.

btw: > Not sure if usefull, but when INPUT is removed form the "display: inline;" the borders don't appear anymore here. I had noticed this also, but obviously quite a few steps behind you paulm.:blush:
Hope this may help others also.

20 Apr 2009, 9:36 PM
#13
meshach avatar

meshach

Zen Follower

Join Date:
Jun 2008
Location:
USA
Posts:
188
Plugin Contributions:
0

Re: How can I fix CSS Border bug showing on form.hidden tags?

This thread is a little old but I just wanted to say... Thanks! it works great, I had this exact same problem. The Zen-Cart forum rules!