Title: responsive input tables
Last modified: September 1, 2016

---

# responsive input tables

 *  [guylancaster](https://wordpress.org/support/users/guylancaster/)
 * (@guylancaster)
 * [9 years, 9 months ago](https://wordpress.org/support/topic/responsive-input-tables/)
 * I want to code a responsive checkbox table in a form.
 * I coded it by reading from a database to a php variable, and generating the table
   of checkboxes with javascript, and regenerating it from the php variable on resize.
 * So far so good….
 * But then my boss tried to click a few check boxes on his ipad and swiveled it
   round, changing the resolution, refreshing, but losing the added check box values(
   as it read from the initial php variable).
 * Maybe I should save the db values to a session, update the screen from the session,
   and on change of any checkbox, update the session (javascript or ajax php?), 
   and then read the session back on resize.
 * Is this the best way to do this?

Viewing 1 replies (of 1 total)

 *  Moderator [bcworkz](https://wordpress.org/support/users/bcworkz/)
 * (@bcworkz)
 * [9 years, 9 months ago](https://wordpress.org/support/topic/responsive-input-tables/#post-7666818)
 * You may want to avoid using your boss as an alpha/beta tester in the future 🙂
 * By far the best way to be responsive is to implement a CSS only scheme. Anything
   involving regenerating content is going to be inferior. In some cases there may
   be no choice, but if the content is set up well, a CSS solution should be possible.
 * Ideally your CSS will just work regardless of screen width or orientation. In
   most cases that’s just not possible. Fortunately, you can use [media queries](https://developer.mozilla.org/en-US/docs/Web/CSS/Media_Queries/Using_media_queries)
   to alter the CSS for certain screen sizes (and different output devices such 
   as printers).
 * I’d recommend trying to stay with either all `max-width` or all `min-width` expressions,
   otherwise it gets difficult to know what rule is applied where. Your browser’s
   CSS inspector is a huge help if you do have to mix things up. I’d also try to
   avoid using `orientation` if you can help it. The simpler the better 🙂

Viewing 1 replies (of 1 total)

The topic ‘responsive input tables’ is closed to new replies.

## Tags

 * [checkboxes](https://wordpress.org/support/topic-tag/checkboxes/)
 * [form](https://wordpress.org/support/topic-tag/form/)
 * [input](https://wordpress.org/support/topic-tag/input/)
 * [tables](https://wordpress.org/support/topic-tag/tables/)

 * In: [Hacks](https://wordpress.org/support/forum/plugins-and-hacks/hacks/)
 * 1 reply
 * 2 participants
 * Last reply from: [bcworkz](https://wordpress.org/support/users/bcworkz/)
 * Last activity: [9 years, 9 months ago](https://wordpress.org/support/topic/responsive-input-tables/#post-7666818)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
