Note that there are some explanatory texts on larger screens.

plurals
  1. POFreezing Table columns and rows using only one table
    primarykey
    data
    text
    <p>I have a dynamic table which is filled from an Application. My problem is that I need some way to freeze the first row and the first four columns BUT using only one table, obviously because I will be posting the table back again to the application.</p> <p>My Current Table Code :</p> <pre><code>.... &lt;form name="myform" method="post" action="test123.php" onsubmit="set_value();"&gt; //this form is used to post back the data after user updates it. &lt;br /&gt; &lt;table align="center" id="dataTable"&gt; &lt;thead&gt; &lt;tr class="header"&gt; ... $arratt49 = (explode(',',$response49,-1)); //sending an array from application $dayscounter = sizeof($arratt49); $sizemon = strlen($month1); if($sizemon &gt; 0) { echo "&lt;th class='text ce6'&gt;No.&lt;/th&gt;"; echo "&lt;th class='text ce6'&gt;Emp code&lt;/th&gt;"; echo "&lt;th class='text ce6'&gt;Name&lt;/th&gt;"; echo "&lt;th class='text ce6'&gt;Department &lt;/th&gt;"; for($kkk=0;$kkk&lt;$dayscounter;$kkk++) { echo "&lt;th class='text ce7'&gt;"; echo $arratt49[$kkk]; echo "&lt;/br&gt;"; echo $arratt49[$kkk+1]; echo "&lt;/th&gt;"; $kkk = $kkk +1; } } &lt;/tr&gt; &lt;/thead&gt; &lt;tbody&gt; &lt;tr&gt; ....//Here goes the Body for($k=0;$k&lt;=$arrcnt;$k++) { echo "&lt;td class='text ce2'&gt;"; echo $counter; echo "&lt;/td&gt;"; echo "&lt;td class='text ce2'&gt;&lt;INPUT type='text' name='code[]' size = '8' readonly='true 'value='"; echo $arratt[$k]; echo "'"; echo "&lt;/td&gt;"; echo "&lt;td class='text ce2'&gt;&lt;INPUT type='text' name='name[]' size = '40' readonly='true' value='"; echo $arratt[$k+1]; echo "'"; echo "&lt;/td&gt;"; echo "&lt;td class='text ce2'&gt;&lt;INPUT type='text' name='dept[]' size = '12' readonly='true 'value='"; echo $arratt[$k+2]; echo "'&gt;"; echo "&lt;/td&gt;"; </code></pre> <p>Already tried : <br /> <a href="http://www.imaputz.com/cssStuff/bigFourVersion.html" rel="nofollow noreferrer">Big Four</a> method <br /> and also <a href="http://meetselva.github.io/fixed-table-rows-cols/" rel="nofollow noreferrer">This</a> <br /> <br /> Any Good Ideas? Again I <strong> CANNOT </strong> use more than one table method.</p> <p><img src="https://i.stack.imgur.com/n3ggx.png" alt="enter image description here"></p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload