veysel Posted December 11, 2019 Share Posted December 11, 2019 hello, i have created this table by html and i am changing the content by javascript but when i see the website in mobile device, web interface is not good. İs there any way to do responsive this? here html : <html> <head> <meta charset=utf-8 /> <meta name="viewport" content="width=device-width, initial-scale=1"> <style type="text/css"> .clr{ color:#25b0e9} </style> </head><body> <table id="myTable" border="1"> <tbody> <tr><td></td> <td> <b>C1</b> </td> <td><b>C2</b> </td> <td><b>C3</b> </td> <td><b>C4</b> </td> <td><b>C5</b> </td> <td><b>C6</b> </td> <td><b>C7</b> </td> <td><b>C8</b> </td></tr> <tr> <td> </td> </tr> <tr> <td><b>Left (+)</b></td> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> </tr> <tr> <td> </td> </tr> <tr> <td><b>Left (-)</b></td> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> <td> </td> </tr> <tr> <td> </td> </tr> </tbody> </table> </div> </body></html> Quote Link to comment https://forums.phpfreaks.com/topic/309668-html-responsive-for-mobile-device/ Share on other sites More sharing options...
Barand Posted December 11, 2019 Share Posted December 11, 2019 (edited) Perhaps something without all those non-breaking spaces <!DOCTYPE html> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta http-equiv="Lang" content="en"> <title>Example</title> <style type="text/css"> table { width: 80%; margin: 20px auto; font-family: calibri, sans-serif;} caption { border-bottom: 1px solid gray; } th { text-align: left; padding: 8px 2px; color: #999;} td { color: #25b0e9; padding: 8px 4px; } </style> </head> <body> <table> <caption>Channel State</caption> <tr> <th> </th> <th>C1</th> <th>C2</th> <th>C3</th> <th>C4</th> <th>C5</th> <th>C6</th> <th>C7</th> <th>C8</th> </tr> <tr> <th>Left (+)</th> <td>✓</td> <td>✓</td> <td>✓</td> <td> </td> <td>✓</td> <td> </td> <td> </td> <td> </td> </tr> <tr> <th>Left (-)</th> <td> </td> <td> </td> <td>✓</td> <td>✓</td> <td> </td> <td> </td> <td> </td> <td> </td> </tr> </table> </body> </html> Edited December 11, 2019 by Barand 1 Quote Link to comment https://forums.phpfreaks.com/topic/309668-html-responsive-for-mobile-device/#findComment-1572426 Share on other sites More sharing options...
veysel Posted December 11, 2019 Author Share Posted December 11, 2019 Thank you so much, this is what i search 👍 Quote Link to comment https://forums.phpfreaks.com/topic/309668-html-responsive-for-mobile-device/#findComment-1572427 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.