Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6391379
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T03:39:51+00:00 2026-05-25T03:39:51+00:00

HTML5 introduced the placeholder attribute on input elements, which allows to display a greyed-out

  • 0

HTML5 introduced the placeholder attribute on input elements, which allows to display a greyed-out default text.

Sadly the Internet Explorer, including IE 9 does not support it.

There already are some placeholder simulator scripts out there. They typically work by putting the default-text into the input field, give it a grey color and remove it again as soon as you focus the input field.

The drawback of this approach is that the placeholder text is in the input field. Thus:

  1. scripts can’t easily check whether an input field is empty
  2. server side processing must check against the default value, in order to not insert the placeholder into the database.

I would like to have a solution, where the placeholder text isn’t in the input itself.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T03:39:51+00:00Added an answer on May 25, 2026 at 3:39 am

    In looking at the “Web Forms : input placeholder” section of HTML5 Cross Browser Polyfills, one I saw was jQuery-html5-placeholder.

    I tried the demo out with IE9, and it looks like it wraps your <input> with a span and overlays a label with the placeholder text.

    <label>Text:
      <span style="position: relative;">
        <input id="placeholder1314588474481" name="text" maxLength="6" type="text" placeholder="Hi Mom">
        <label style="font: 0.75em/normal sans-serif; left: 5px; top: 3px; width: 147px; height: 15px; color: rgb(186, 186, 186); position: absolute; overflow-x: hidden; font-size-adjust: none; font-stretch: normal;" for="placeholder1314588474481">Hi Mom</label>
      </span>
    </label>
    

    There are also other shims there, but I didn’t look at them all. One of them, Placeholders.js, advertises itself as “No dependencies (so no need to include jQuery, unlike most placeholder polyfill scripts).”

    Edit: For those more interested in “how” that “what”, How to create an advanced HTML5 placeholder polyfill which walks through the process of creating a jQuery plugin that does this.

    Also, see keep placeholder on focus in IE10 for comments on how placeholder text disappears on focus with IE10, which differs from Firefox and Chrome. Not sure if there is a solution for this problem.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I recently introduced HTML into some RSS feeds that I publish (which up to
In HTML5 there is a new input type, 'search'. On most browser it's just
In HTML5, name is no longer a valid attribute of the anchor tag (
I read that the HTML5 spec introduced the ability to select multiple files in
Canvas from html5 was introduced some time ago. Currently it's used (almost) only for
Since Flash 10 was introduced, many of the popular 'copy to clipboard' scripts out
I want to do my stuff on LocationChangeEvent.LOCATION_CHANGE event which is introduced in AIR
I'm currently developping a webapp for iphone which use the local sqlite database introduced
Delphi 2010 introduced custom attributes which can be added to type declarations and methods.
In the HTML5, it introduced the FileReader API. I can't really understand the difference

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.