Description
About: this is a basic 3-column-layout using display:inline-block and relative block-sizes.
Someone asked me in a note to fill the blank space left and right of a thumb which was centeres in a journal with text.
When using is, don't write blanks/new lines between and the following as this blank/new line will also be shown between the columns.
As the CSS is pretty simple I just mention the vertical-align-property: it sets how a div is vertically aligned to it's neighbor text/div elements. "top" will align the top-lines, bottom the bottom-lines, middle will vertically center this element. it doesn't affect the div's content.
HTML::
this is a test.
If you see this, I made the mistake of submitting.
This should be the first collumn. e.g. Requests are open:
Isn't that a nice thumb? well, I'm just writing random text, so I can see this example... Well... what else to say... I just hope this text will preceed the normal text-height of this row, so you/I can see the overflow-behavior.
CSS::
.firstColumn{width:20%;display:inline-block;text-align:right;vertical-align: top;}
.secondColumn{width:50%;display:inline-block;text-align:center;vertical-align: top;}
.thirdColumn{width:20%;display:inline-block;text-align:left;vertical-align: top;}
Edit: For Non-Core members there is a nice description here:
www.deviantart.com/simplysilenβ¦
Summary:
Two-Column way:
You can change -70 in the class name to one out of 70, 65, 60, 35. switch -ll and -rr to switch column sizes left and right. Leave out the split-x part to get 50%
To make 3 columns, nest them:
Comments: 10
Jack-the-Shinigami [2019-03-27 22:04:12 +0000 UTC]
This isn't working for me (probably bc it was posted a long time ago).
I'm not sure if you're still active, but do you have any new, working code to make 3 collumns?
π: 0 β©: 1
Dediggefedde In reply to Jack-the-Shinigami [2019-04-04 22:48:41 +0000 UTC]
Hi! I still try to maintain all my scripts and codes.
However, I have some phases where I just stay away from deviantart for a year or two occassionally.
luckily I get e-mail notifications about comments.
I think you need to have a core membership in order to use it.
Otherwise custom classes and custom CSS wouldn't work.
Also because of dA's whitelist tag system, there is little that can be done.
Best bet would be to scan through dA code, identify an element that has some floating CSS properties and grab it's class name for the journal... though that will also most likly look ugly. ^^
If you have tried it with a core membership account, please tell me.
π: 0 β©: 1
Jack-the-Shinigami In reply to Dediggefedde [2019-04-05 05:04:45 +0000 UTC]
I didn't find a way to make 3-parted columns, but I found one to make 4 (without core). xD
I put two 50/50 column codes into the columns of one 50/50 column code.
Resulting in 25/25/25/25.
Here's the result, because that probably explains it better then what I just said:
Intro Jack
The top line is still outside of the columns.
The two outer side lines are column 1 & 4 and in between, in column 3&4 I split up text and pictures.
It's a bit restricted size-wise, but it worked for what I was trying.
Thanks for your help, tho!
π: 0 β©: 1
Dediggefedde In reply to Jack-the-Shinigami [2019-05-06 19:54:02 +0000 UTC]
Did you see this solution?
In principle you can make a 50% column division inside the 70% column division to get a 35%-35%-30%.
An example would be:
UntitledLorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.
Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dol
π: 0 β©: 1
Dediggefedde In reply to Jack-the-Shinigami [2019-05-07 17:31:41 +0000 UTC]
There might be a misunderstanding about how the code works.
Non-core users cannot use custom CSS, but they can use classes for their div tags.
These tricks utilize classes that are already used somewhere in DeviantArt's page layout.
For example, if you look at the code of the "submit comment" button, you see
< a class="smbutton smbutton-green comment-submit smbutton-big post" > Submit Comment a >
if you want a green button in your journal, then you can use the code (without blanks around the < >)
However, this means you can only use existing classes.
Simply changing the number in the class name does not change the width in the CSS code.
In this case, the CSS is listed here: st.deviantart.net/css/deviantaβ¦
Somewhere in the middle, it says
.mods-hh.split-70 .mods-column-ll{width:70%}.mods-hh.split-70 .mods-column-rr{width:30%}.mods-hh.split-65 .mods-column-ll{width:65%}.mods-hh.split-65 .mods-column-rr{width:35%}.mods-hh.split-60 .mods-column-ll{width:60%}.mods-hh.split-60 .mods-column-rr{width:40%}.mods-hh.split-35 .mods-column-ll{width:35%}.mods-hh.split-35 .mods-column-rr{width:65%}
There you can see, that only 70%, 65%, 60%, 35% are available for .mods-hh.split-. 50% can be done by leaving the class out, since it's the default.
π: 0 β©: 1