Caspio Responsive Code Tables
Link to generate responsive html for Caspio table headings – see 1c in code below.
https://docs.google.com/spreadsheets/d/1ALj2K1ji7NV8xLrIQ3T4c5bNKKTu9XZ5J36a78Jjdqs/edit?usp=sharing
<!-- Responsive Code Begin -->
<style>
@media only screen and (max-width: 760px),
(min-device-width: 768px) and (max-device-width: 1024px) {
#tabular * {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
#tabular *:before,
#tabular *:after {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
}
#tabular table[id^="PageActionsCtnr"] {
border-spacing: 0px !important;
border-collapse: separate !important;
margin-bottom: 7px !important;
}
#tabular table[id^="PageActionsCtnr"] td {
display: block;
width: auto!important;
float: left;
text-align: left;
padding: 1px !important;
}
#tabular table[id^="PageActionsCtnr"] td div {
text-align: left !important;
}
#tabular table[data-cb-name^="cbTable"] {
border: none !important;
background: transparent !important;
display: block;
-webkit-box-shadow: none !important;
-moz-box-shadow: none !important;
box-shadow: none !important;
}
#tabular table[data-cb-name^="cbTable"] tbody {
display: block;
}
#tabular table[data-cb-name^="cbTable"] tr:first-child {
display: block;
position: absolute;
top: -9999px;
left: -9999px;
}
#tabular table[data-cb-name^="cbTable"] tr {
display: block;
border: 1px solid #dddddd;
margin-bottom: 7px;
width: 100%;
}
#tabular table[data-cb-name^="cbTable"] td {
display: block;
border: none !important;
position: relative !important;
padding-bottom: 5px !important;
text-align: left !important;
}
#tabular table[data-cb-name^="cbTable"] td:before {
padding-right: 5px;
}
#tabular table[data-cb-name^="cbTable"] td[class^="cbResultSetActionCell"] {padding-bottom: 10px !important; padding-top: 7px !important;}
/* ----------------------------------------------------------
1c. Insert Column Labels into the content attributes below (copy rows and change the td:nth-of-type numbers as needed to match table column number)
------------------------------------------------------------ */
#tabular table[data-cb-name^="cbTable"] td:nth-of-type(1):before { content: "Finish: "; font-weight: bold; }
#tabular table[data-cb-name^="cbTable"] td:nth-of-type(2):before { content: "Finish Cost: "; font-weight: bold; }
#tabular table[data-cb-name^="cbTable"] td:nth-of-type(3):before { content: "Part No.: "; font-weight: bold; }
#tabular table[data-cb-name^="cbTable"] td:nth-of-type(4):before { content: "Customer: "; font-weight: bold; }
</style>
<div id="tabular">
<div class="table-responsive">
Note: The above code goes in the "Header" html in caspio. Place the ending divs shown below in the "Footer" of the caspio data table form.
</div></div>