使用 jQuery mobile 创建 Nx1 网格

发布于 2024-12-10 05:13:38 字数 283 浏览 1 评论 0原文

http://jquerymobile.com/demos/1.0rc1/docs/content /content-grids.html 解释了如何创建 2x1、3x1、4x1 和 5x1 网格。

但是,我需要创建一个 15x15 网格(其中每列都会有一个图标)。

应该如何使用 jQuery mobile 来实现这一点?

http://jquerymobile.com/demos/1.0rc1/docs/content/content-grids.html explains how one can create 2x1, 3x1, 4x1 and 5x1 grids.

However, I need to create a 15x15 grid (where each column will be given an icon).

How should this be achieved with jQuery mobile?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

素手挽清风 2024-12-17 05:13:38

您可以使用表格布局

相关:

示例:

您将需要调整图标的大小以及 CSS 以获得您想要的

HTML

<div data-role="page" class="type-home">
    <div data-role="content">

        <table summary="This table lists all the JetBlue flights.">
            <caption>15 x 15</caption>
            <thead>
                <tr>
                    <th scope="col">Icon 1</th>  
                    <th scope="col">Icon 2</th>
                    <th scope="col">Icon 3</th>
                    <th scope="col">Icon 4</th>
                    <th scope="col">Icon 5</th>
                    <th scope="col">Icon 6</th>
                    <th scope="col">Icon 7</th>
                    <th scope="col">Icon 8</th>
                    <th scope="col">Icon 9</th>
                    <th scope="col">Icon 10</th>
                    <th scope="col">Icon 11</th>
                    <th scope="col">Icon 12</th>
                    <th scope="col">Icon 13</th>
                    <th scope="col">Icon 14</th>
                    <th scope="col">Icon 15</th>  
                </tr>
            </thead>
            <tfoot>
                <tr>
                    <td colspan="5">Total: 15 Icons</td>
                </tr>
            </tfoot>
            <tbody>
                <tr>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                </tr>


            </tbody>
        </table>

    </div>
</div>

You could use a table layout

Related:

Example:

You will need to play around with the size of the icons as well as the CSS to get what you want

HTML

<div data-role="page" class="type-home">
    <div data-role="content">

        <table summary="This table lists all the JetBlue flights.">
            <caption>15 x 15</caption>
            <thead>
                <tr>
                    <th scope="col">Icon 1</th>  
                    <th scope="col">Icon 2</th>
                    <th scope="col">Icon 3</th>
                    <th scope="col">Icon 4</th>
                    <th scope="col">Icon 5</th>
                    <th scope="col">Icon 6</th>
                    <th scope="col">Icon 7</th>
                    <th scope="col">Icon 8</th>
                    <th scope="col">Icon 9</th>
                    <th scope="col">Icon 10</th>
                    <th scope="col">Icon 11</th>
                    <th scope="col">Icon 12</th>
                    <th scope="col">Icon 13</th>
                    <th scope="col">Icon 14</th>
                    <th scope="col">Icon 15</th>  
                </tr>
            </thead>
            <tfoot>
                <tr>
                    <td colspan="5">Total: 15 Icons</td>
                </tr>
            </tfoot>
            <tbody>
                <tr>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                    <td><img src='http://sandbox.yoyogames.com/extras/user/image/san1/977/138977/thumb/man.png?1283087523' /></td>
                </tr>


            </tbody>
        </table>

    </div>
</div>
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文