PR
Language Switcher

Inconsistency in appearance of input element without type attribute on WordPress

Inconsistency in Text Box Appearance

I was creating a blog post using the code editor in WordPress. Then, I noticed that the results of the following two codes were different. Since I couldn’t find the answer by searching, I went through some trial and error.

・Regular text box

<input type="text">

・input element with the type attribute omitted

<input>

The results might be different in your environment, so I will include screenshots below just in case.

It seems that the type attribute of the input element is text by default. Therefore, the above two should have the same appearance.

The photo above shows the result in Chrome. I thought the results might differ if the browser was different.

・For Microsoft Edge

・For Brave

I also tested how it looks on Android (using Chrome as the browser).

All of them showed similar results.

The Cause is the WordPress Theme

The cause was the WordPress theme. Currently, this site uses Cocoon Child. I tried changing it to a few others.

First, the popular free theme in Japan, Cocoon. No change.

Next, Astra. There is no change.

Next, 2025, which is also popular overseas.

The two boxes became exactly the same.

Although I only tested it a bit, I came to the conclusion that the WordPress theme might be having an effect.

コメント