How to optimize website for touch devices

It sounds to me like you want to have a touch-screen-friendly option, to cover the following scenarios: iPhone-like devices: small screen, touch only Small screens, no touch (you didn’t mention this one) Large screens, no touch (i.e. conventional computers) Touch-screen-enabled large screens such as iPad, notebooks/pcs with touch screens. For case 1 and 2 you … Read more

Moving a focus when the input text field reaches a max length

I haven’t used this tool before, but it does what you want. You could just look at it’s source to get some ideas: This Plugin on GitHub For your situation, you would add this code: <script type=”text/javascript” src=”https://stackoverflow.com/questions/1959398/jquery.autotab.js”></script> <script type=”text/javascript”> $(document).ready(function() { $(‘#first’).autotab({ target: ‘#second’, format: ‘numeric’ }); $(‘#second’).autotab({ target: ‘#third’, format: ‘numeric’, previous: ‘#first’ … Read more

Delay HTML5 :invalid pseudo-class until the first event

http://www.alistapart.com/articles/forward-thinking-form-validation/ Since we only want to denote that a field is invalid once it has focus, we use the focus pseudo-class to trigger the invalid styling. (Naturally, flagging all required fields as invalid from the start would be a poor design choice.) Following this logic, your code would look something like this… <style> input:focus:required:invalid {background-color: … Read more

How to use the tag in ASP.NET?

I use <asp:Label … AssociatedControlID=”Username” …> controls for this. They get rendered as <label> tags and set the for attribute appropriately. Note that you can also nest other tags within the Label control if you wish: <asp:Label ID=”UsernameLabel” Text=”Username:” AssociatedControlID=”UsernameTextBox” runat=”server”> <asp:TextBox ID=”UsernameTextBox” runat=”server” /> </asp:Label>

Separators for Navigation

If there isn’t a pressing need to use images for the separators, you could do this with pure CSS. nav li + li:before{ content: ” | “; padding: 0 10px; } This puts a bar between each list item, just as the image in the original question described. But since we’re using the adjacent selectors, … Read more

Wysiwyg for dynamic blocks of content? [closed]

YOu could use divs (styles to make them appear as 3 columns not provided): <div id=”wrapperDIV”> <div id=”col1″>column 1</div> <div id=”col2″>column 2</div> <div id=”col3″>column 3</div> </div> or what i prefer is tables: <table> <tr> <td>col 1</td> <td>col 2</td> <td>col 3</td> </tr> </table> you would create a wysiwyg editor into each column. There are tons of … Read more