All Posts by Email, Once a Week

Media Temple logo

CSS-Tricks is brought to you in part by Media Temple, the web hosting that we both use and recommend.

Text Change Trick with Html or CSS?

  • # April 20, 2013 at 12:50 am

    This might sound strange, but I am making a conceptual website and I need the user to be able to click into a text input field and enter text but control what the result is.

    For example, maybe I would type in “apple” but the text that would show up would be “orange” (or whatever). I really appreciate any help! Thank you so much.

    # April 20, 2013 at 1:51 am

    no way to detect user input with css. You can to this with javascript binding the keyup event with the text input and adding one letter at a time while you clear the user input.
    this can get you started

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.

There's a whole bunch of content on CSS-Tricks.

Search for Stuff   •   Browse the Archives

Get the Newsletter ... or get the RSS feed