How to move the column content in css?

css columns
css column break
3 column layout css responsive
column-gap css
column-count css
css grid
css columns responsive
html columns

I am working on a website in which I want to move the text towards the left-side bottom in css. Below is the screenshot what I want to do.

As shown in the screenshot above, I want to move the Outburst text towards the left-side bottom (Aligned below character O). The above screenshot is present in this link.

I have created the fiddle as well for the above link.

The HTML code used in the fiddle is generated through the following php code:

<ul id="shows-list" class="shows-list cf js-list-active">
    <?php foreach ( $alpha_programs as $title => $permalink ) :
        $title_char = substr( $title, 0, 1 ); ?>
        <li class="shows-list__letter">
        <?php
        if ( $title_char !== $prev_title_char ) : $prev_title_char = $title_char; ?>
            <h1 class="shows-list__letter-title"><?php echo esc_html( $title_char ) ?></h1>
        <?php endif;?>
            <a class="shows-list__link" href="<?php echo esc_url( $permalink ); ?>"><h2 class="shows-list__title"><?php echo esc_html( $title ); ?></h2>
            </a>
        </li>
    <?php
    endforeach;
    ?>
</ul>

Problem Statement:

I am wondering what changes I need to make in the php code above or in the css code here in the fiddle so that outburst text moves towards the left-side bottom

Easiest way to do this.

<body>
<table>
<tr>your content</tr>
<tr>your content</tr>
</table>
</body>

CSS columns property, Tutorials, references, and examples are constantly reviewed to avoid errors, but we cannot warrant full correctness of all content. While using this site, you agree to� You can use two values top and left along with the position property to move an HTML element anywhere in the HTML document. Move Left - Use a negative value for left. Move Right - Use a positive value for left. Move Up - Use a negative value for top.

i have checked your code and it seems you got it a little bit wrong here :

<ul id="shows-list" class="shows-list cf js-list-active">
 <li class="shows-list__letter">
  <h1 class="shows-list__letter-title">B</h1>
  <a class="shows-list__link" href="http://www.cpac.ca/en/programs/beyond-politics/"><h2 class="shows-list__title">Beyond Politics</h2></a>
 </li>
 <li class="shows-list__letter">
  <a class="shows-list__link" href="http://www.cpac.ca/en/programs/british-prime-ministers-question-time/"><h2 class="shows-list__title">British Prime Minister’s Question Time</h2></a>
 </li>
 <li class="shows-list__letter">
  <a class="shows-list__link" href="http://www.cpac.ca/en/programs/builders-of-canada/"><h2 class="shows-list__title">Builders of Canada</h2></a>
 </li>
</ul>

List for links are in the same list as the alphabet. You should make a new list for links inside the alphabets lists. Like this :

<ul id="shows-list" class="shows-list cf js-list-active">
 <li class="shows-list__letter">
  <h1 class="shows-list__letter-title">B</h1>
  <ul class="shows-list__letter_list">
   <li class="shows-list__letter_inside">
    <a class="shows-list__link" href="http://www.cpac.ca/en/programs/beyond-politics/"><h2 class="shows-list__title">Beyond Politics</h2></a>
   </li>
   <li class="shows-list__letter_inside">
    <a class="shows-list__link" href="http://www.cpac.ca/en/programs/british-prime-ministers-question-time/"><h2 class="shows-list__title">British Prime Minister’s Question Time</h2></a>
   </li>
   <li class="shows-list__letter_inside">
    <a class="shows-list__link" href="http://www.cpac.ca/en/programs/builders-of-canada/"><h2 class="shows-list__title">Builders of Canada</h2></a>
   </li>
  </ul>
 </li>
</ul>

What I did is, all the links for an alphabet is put in a new list tag inside the alphabet list. Sorry for my bad English. You can check this fiddle for better understanding.

CSS Multiple Columns, First, let's create a simple CSS grid with one row and three columns. Grid items without overflow. In the HTML, we create a bunch of divs where� column-width; column-count; The column-width part will define the minimum width for each column, while the column-count part will define the maximum number of columns. By using this property, the multi-column layout will automatically break down into a single column at narrow browser widths, without the need of media queries or other rules.

I'd suggest you try using flexbox maybe it could work like this:

ul #shows-list {
   display: flex;
   flex-direction: column;
 }

Maybe you'll want to add:

justify-content: center;

property to center the lis once they're under each other.

CSS column-fill property, Setting position: absolute on an element lets you use the CSS properties top , bottom , left , and right to move the element around the page to exactly where you want it. For example, setting top: 1em move the element so its top is 1em from the top of the page. That will display like this. We’ll want to put some space in between each of the columns to help break up the content. We can accomplish this by putting horizontal padding on each of the columns. This works well; however, when two columns are sitting next to one another, the width of the space between them will be double that of the space from the outside columns to the edge of the row.

CSS column-rule property, Moving items to the left or right also depends on the then you set justify-content , otherwise if it's set to column you set� With CSS grid layout, the grid itself within its container as well as grid items can be positioned with the following 6 properties: justify-items, align-items, justify-content, align-content, justify-self and align-self.

CSS column-span property, In the image below, the left side depicts CSS column rules being applied to the second paragraph to transform just that content into columns. A modern way of creating two columns, is to use CSS Flexbox. However, it is not supported in Internet Explorer 10 and earlier versions. However, it is not supported in Internet Explorer 10 and earlier versions.

Moving Items in CSS Grid Layout [Guide], See the Pen [7] CSS Columns, column-span by Katy DeCorah (@katydecorah) on CodePen. column-fill. To change how the content fills the columns, declare column-fill. Currently, this property is only available in Firefox. When height is added to a columned element, Firefox behaves differently than the other browsers.

Comments
  • Cause of the problem is that the HTML divides the <li> tags into 2 columns equally (each column has similar/equal number of items), without respecting the context (the grouping of first character of each content). To solve this problem, the easiest way is to first group the contents of each character into 1 <div> or <li> (your choice, doesn't really matter, as long as you style them properly using CSS), then use flexbox to allow automatic re-arranging of layout. Last for SEO sake, it's improper to use multiple <h1> in the same page; try to use <h2> to <h6> instead.
  • @Raptor The html which I have included here is generated at run-time through php above. There is some changes I need to do in php 1st.
  • No no, absolutely no. It's 2019 now. Using table is against responsive design.
  • I am wondering if you can update it in the fiddle. In that way, it would be easily to visualize.
  • I tried to make changes in the fiddle here but it doesn't seem to work.