I need to freeze the two columns from the large amount of data which is fetched from database using php.
For e.g

using the table students
column name:- id, name, class, section, roll number,remarks,address,etc...

I want to freeze two colums i.e id and name, so how can i create a script for this.

please help me...

Please explain what you mean by 'freeze'.

generally Freeze option is used in excel sheets if you want to see then check in microsoft office excel 2007-> view-> freeze panes(freeze top row & freeze first column)

You mean you don't want to edit them ? I don't use Excel, so I can't check what you describe. In PHP you determine what happens with the data, so if you already have some code, show it, so we can help you adjust it.

I need a way to scroll down the rows, but still see the columns headings.

Did you write it yourself, or are you using a tool like DataTables (they have built-in support for this)?

This is more to do with html I guess.

The headers I'd imagine being fixed as 'absolute' in your css file.

Member Avatar

You can use an css overflow for the tbody, leaving a static thead. I think. Haven't tried it. Will that do?