- This topic has 6 replies, 3 voices, and was last updated 7 years, 2 months ago by Leo.
-
AuthorPosts
-
January 28, 2017 at 7:09 pm #270940Tully
Hi there,
I am using so html to create tables in a section. And using the following code to set the table column widths:
<col width=”50%”>
<col width=”50%”>It works for a little bit, but then seems to disappear from the code altogether?
Thanks
January 28, 2017 at 7:17 pm #270941LeoStaffCustomer SupportHi Tully,
I would use GP’s built in grid system. Do something like this:
<div class="grid-50 tablet-grid-50 mobile-grid-100"> Left side content </div> <div class="grid-50 tablet-grid-50 mobile-grid-100"> Right side content </div>
Let me know.
January 28, 2017 at 7:46 pm #270948TomLead DeveloperLead DeveloperOr use a plugin which uses the same grid: https://wordpress.org/plugins/lightweight-grid-columns/
Also, the WP editor will strip HTML if it’s empty.
For example, it would strip this:
<span></span>
As there’s nothing in there.
But if you add an HTML comment inside, it will leave it alone:
<span><!-- empty element -->
January 29, 2017 at 5:43 pm #271488TullyHi Leo and Tom,
Thanks for the help. However I really do want to use a table not columns. I am not using the table to layout a page, but as a table, so would like to find a way to set the column width of the table.
Not sure why the html I put in works for a while and then dissappears? Is the html in error or something? Here is the full code:
<h2><span style=”color: #000000;”>The handler’s position – in control, or out of control? -</span><span style=”color: #000080;”> COMING SOON</span></h2>
<table>
<col width=”50%”> THIS IS THE CODE THAT WORKS FOR A BIT THEN DISSAPPEARS.
<col width=”50%”> THIS IS THE CODE THAT WORKS FOR A BIT THEN DISSAPPEARS.
<tbody>
<tr>
<td>Overview: Knowing where to position yourself, and what to do in that position in order to influence the pup in the way you desire, is vital in becoming a good sheepdog (and livestock) handler.In this episode, Tully explains how to keep yourself in a position where you can control the pup and influence its behaviour, rather than being out of position and allowing the pup to run riot!</td>
<td rowspan=”3″></td>
</tr>
<tr>
<td>Pre-requisites:None</td>
</tr>
<tr>
<td>Recommended viewing:</td>
</tr>
</tbody>
</table>
Thanks
January 29, 2017 at 5:47 pm #271489LeoStaffCustomer SupportAhh I see. I would recommend using a plugin like TablePress:
https://en-ca.wordpress.org/plugins/tablepress/January 29, 2017 at 5:50 pm #271490TullyHi guys, the following css seems to have done it:
td, th {
width: 50%;
}unless there are any reasons that isn’t a good idea?
January 29, 2017 at 5:57 pm #271494LeoStaffCustomer SupportNope you should be good.
GP doesn’t use those element in default settings.
-
AuthorPosts
- You must be logged in to reply to this topic.