Apply style to textbox substring
<p>I have a simple search form consisting of just a textfield, but it has filters (e.g., beginning the query with "type:" only searches a database column of "type"). What I'd like to have is for that text before the actual search term (i.e., "type:") to be styled in such a way that it's obvious to the user that it's a filter and not a search term. In fact, it might look something like StackOverflow's Tags textfield after a user has typed in a tag (see <a href="http://i.imgur.com/tvP6R.png" rel="nofollow">this</a>). So far, I've got a .keypress() method being called on the textfield to determine if the first term is indeed a filter, but I'm not sure how to style the filter text. Any help is appreciated!</p>
