ciao Kahm prova così:
ciao Kahm prova così:
Ultima modifica di neo1976; 11-04-2021 a 03:17
Ciao Kahm prova così:
codice:.parent { width: 100%; height: 30px; border: 1px solid #AAA; white-space: nowrap; overflow-y: hidden; } @media(max-width:768px){ .child {height: 30px; overflow-x: hidden; }} @media(min-width:769px){ .child {height: 45px; overflow-x: auto !important; }} <div class="parent"> <div class="child"> <table id="ctl00_ContentPlaceHolder1_DataList1" cellspacing="0" border="0" style="border-collapse:collapse;"> <tbody> <tr> <td> <a id="ctl00_ContentPlaceHolder1_DataList1_ctl00_hypCateg" href="Index.aspx?CodCateg=19">cat 1</a> </td> <td> <a id="ctl00_ContentPlaceHolder1_DataList1_ctl01_hypCateg" href="Index.aspx?CodCateg=22">cat 2</a> </td> <td> <a id="ctl00_ContentPlaceHolder1_DataList1_ctl02_hypCateg" href="Index.aspx?CodCateg=17">cat 3</a> </td> <td> <a id="ctl00_ContentPlaceHolder1_DataList1_ctl03_hypCateg" href="Index.aspx?CodCateg=9">cat 23</a> </td> <td> <a id="ctl00_ContentPlaceHolder1_DataList1_ctl04_hypCateg" href="Index.aspx?CodCateg=12">cat 5</a> </td> <td> <a id="ctl00_ContentPlaceHolder1_DataList1_ctl05_hypCateg" href="Index.aspx?CodCateg=7">FARINA DA GRANI ANTICHI</a> </td> <td> <a id="ctl00_ContentPlaceHolder1_DataList1_ctl06_hypCateg" href="Index.aspx?CodCateg=13">FRUTTA</a> </td> <td> <a id="ctl00_ContentPlaceHolder1_DataList1_ctl07_hypCateg" href="Index.aspx?CodCateg=15">FUNGHI NATURALI</a> </td> <td> <a id="ctl00_ContentPlaceHolder1_DataList1_ctl08_hypCateg" href="Index.aspx?CodCateg=16">MAIALE</a> </td> </tr> </tbody> </table> </div> </div>
Ultima modifica di neo1976; 11-04-2021 a 03:23
ciao Kahm ecco la soluzione, l'ho testata:
.parent {
width: 100%;
height: 30px;
border: 1px solid #AAA;
white-space: nowrap;
overflow-y: hidden;
}
@media(max-width:768px){ .child {height: 30px;
overflow-x: hidden;
}}
@media(min-width:769px){ .child {height: 45px;
overflow-x: auto !important;display: inline-block;
}}
<div class="parent">
<div class="child">
<table id="ctl00_ContentPlaceHolder1_DataList1" cellspacing="0" border="0" style="border-collapse:collapse;">
<tbody>
<tr>
<td>
<a id="ctl00_ContentPlaceHolder1_DataList1_ctl00_hypC ateg" href="Index.aspx?CodCateg=19">cat 1</a>
</td>
<td>
<a id="ctl00_ContentPlaceHolder1_DataList1_ctl01_hypC ateg" href="Index.aspx?CodCateg=22">cat 2</a>
</td>
<td>
<a id="ctl00_ContentPlaceHolder1_DataList1_ctl02_hypC ateg" href="Index.aspx?CodCateg=17">cat 3</a>
</td>
<td>
<a id="ctl00_ContentPlaceHolder1_DataList1_ctl03_hypC ateg" href="Index.aspx?CodCateg=9">cat 23</a>
</td>
<td>
<a id="ctl00_ContentPlaceHolder1_DataList1_ctl04_hypC ateg" href="Index.aspx?CodCateg=12">cat 5</a>
</td>
<td>
<a id="ctl00_ContentPlaceHolder1_DataList1_ctl05_hypC ateg" href="Index.aspx?CodCateg=7">FARINA DA GRANI ANTICHI</a>
</td>
<td>
<a id="ctl00_ContentPlaceHolder1_DataList1_ctl06_hypC ateg" href="Index.aspx?CodCateg=13">FRUTTA</a>
</td>
<td>
<a id="ctl00_ContentPlaceHolder1_DataList1_ctl07_hypC ateg" href="Index.aspx?CodCateg=15">FUNGHI NATURALI</a>
</td>
<td>
<a id="ctl00_ContentPlaceHolder1_DataList1_ctl08_hypC ateg" href="Index.aspx?CodCateg=16">MAIALE</a>
</td>
</tr>
</tbody>
</table>
</div>
</div>
Ultima modifica di neo1976; 13-04-2021 a 11:45