News
Welcome to NeoRHDN! This place is still a work-in-progress, so pardon the construction...

Chat on Discord
Views: 800,592
Sections: Documents | Utilities | ROM Hacks | Games | Translations | Homebrew | Fonts | Community
Site: Main | Rules/FAQ | Discord | Memberlist | Latest posts | Stats | Ranks | Online users
12-03-24 05:17 PM
Guest: Register | Login

0 users currently in Meta | 1 guest | 2 bots

Main - Meta - Basic Guide to Post Layouts on NeoRHDN (6)


Oz74
Posted on 09-01-24 04:04 PM, in (rev. 3 of 09-14-24 09:58 PM by Oz74) Link | ID: 605

Level: 9

Posts: 14/39
EXP: 2544
Next: 618

Since: 08-16-24
From: Erebonia

Last post: 9 days
Last view: 9 days
Table of contents:
1. Introduction to Post Layouts
2. Basic Example
3. Common HTML on the Board
4. Classes in Your Posts
5. A Small CSS Glossary
6. Tips and Tricks
7. Special Considerations



1. Introduction to Post Layouts
Acmlmboard software has a slew of personalization features. One of the coolest flairs you can add is a post layout. These decorate your entire post and give you a unique presence! It does require HTML and CSS knowledge. Markup (your HTML) is decorated by the stylesheet (your CSS) and the bulk of this tutorial covers the some of the various CSS declarations that are useful for an Acmlmboard post layout.

The first thing you'll want to do is save your profile page to work offline, since at time of writing, NeoRHDN does not feature a "preview post layout" option, and when it does, if your login session expires while you're previewing, you're going to lose your progress. Open your offline HTML page in a good text editor - syntax highlighting for HTML will help you see it easily! CTRL+F and find text you know is in the sample post, and there you'll find all the pieces you can edit. Anything named in tags or any names of classes can be modified, but it is important that you use the box names that have your userid as a parent to ensure your modifications are unique to your own posts (this will be elaborated on later.)

Your post is a table is divided into quadrants. The table cells in a row are going to be the same size as whichever the largest is, unlike divs, which require more CSS input to control size and will otherwise default to ending immediately after the content. Inside your post body, you can add more HTML. It's a lot easier IMO to keep your layout's CSS in its own external file. To use it, put <style type="text/css">@import url ("filename.css");</style>. When you edit the file, any CSS changes will show in your post.



2. Basic Example
For a single new box around your post, you can add a <div> in the header and close with a </div> in the footer. If you want another box around your signature, you can open another <div> and put your signature in here, then close it with another </div>. But wait, did you notice how the two boxes are touching? Giving them classes lets you modify the divs differently, and you can add a margin-top to give your boxes space in between.

Let's say our divs' classes are "mypost" and "mysig". We want 8px of padding within and all around them, we want them both to be black with light grey text and neon green borders, and we want the main post background to be dark green, so to make this happen, the CSS file should contain:

.mainbarUID {background: #030; padding: 8px}
.mainbarUID .mysig {margin-top: 8px}
.mainbarUID > div {color: #ccc; background: #000; border: #0f0 1px solid; padding: 8px}
"UID" will be your user ID from here to the end of the guide.

The post header will contain:
<style type="text/css">@import url ("filename.css");</style><div>
(Or you can write in what would be the contents if your stylesheet if you weren't hosting one.)

The post footer will contain:
</div><div class="mysig">This is my signature.</div>


And here's our post layout. After this is the footer:
This is my signature.



3. Common HTML on the Board
a is an anchor, most often used to create links. To change effects based on the status of the anchor, use a:link, a:visited, a:hover, a:active - in that order.
blockquote surrounds each quote.
code should be used for code.
div is a divider. It draws a box around content.
hr is a horizontal rule. i.e. a straight line across. These are baked into quoted content, before and after the quote content.
i italicizes. This is baked into quote headers.
img inserts an image
span deals with content from its start to finish and does not separate the content like div does.



4. Classes in Your Posts
Your unique classes:
topbarUID_1: This is the table cell containing your username.
topbarUID_2: This contains the time stamp and options for your post.
sidebarUID: This contains your avatar, level, post count, and last activities.
mainbarUID: This is your post body.

Relevant Acmlmboard classes in your posts:
cd appears around the code block and defines the background as #000 raw, so you'll have to use !important if you want to override it.
prettyprint is the main class of your code, while com, kwd, pln, pun, and str are spans that appear within for syntax highlighting.
spoiler1 decorates a spoiler before it is moused over.
spoiler2 decorates a spoiler after it is moused over.
quotedby is specifically the span used to head quotes.



5. A Small CSS Glossary
Here's a rundown of most of the stuff you'll want to consider when making your post layout. This glossary and set of examples might be enough for your intentions, but its aims are not to be a complete CSS tutorial. You can run live practice demonstrations and explore more fine tuning options at w3schools.

background - colors can be passed as hexadecimal (3 or 6-digit) or decimal. Transparency can be done with rgba(r,g,b,a) where rgb are 0-255 and a is decimal from 0 to 1. Pictures can be rolled into the background with url("...") and both anchoring, stretch, and tiling can be attributed per-picture. You can also use absolute positioning if relative positions aren't suitable for your needs. Multiple background images can be ascribed to a single HTML property by using a comma (,) instead of a semicolon (;) to itemize them, but you must use a semicolon on the final background property.
Example:
background: url("https://mypretendsite/koopa.png") center right no-repeat #88f;
will put your adorable Koopa Troopa to the center right of your blue post field.

border - width, color, and style. Common styles include solid, dotted, ridge, double.
Example:
border: #000 3px double;
will draw two black borders around your box.

border-image - draws a border using tiling sides with non-repeating corners. You can slice a source image into components to assign to the corners and sides. (Way back before CSS3 standardizations, we would draw table cells or use background anchoring to simulate this. I'm not going to lie - this one is alien to me because it was browser-specific and changing frequently when I was in practice.) This one gets deep really fast, so you might want to jump right into here to practice with it.

box-shadow - draws a shadow under that blurs with increased radius. x, y, size, and color.
Example:
box-shadow: 0px 8px 8px #000;
makes a drop shadow under your box.

color - assigns the text's color.

content - squeezes a piece of text or a picture into an otherwise baked-in thing. Look at my layout's CSS to see how I added a Unicode star to quotes.

font - assigns font-family and size. Fonts can also be itemized with a comma where each font in succession is a fallback for its previous font.

font-weight - how thick the font is. Bold or normal are generally all you'd care about.

display - useful if you want to mask some baked-in attributes you don't want.
Example:
.sidebar88 img {display: none !important}
This kills the homunculus.

margin - how much you want to offset this box from the property it's inside. You can do it from all four directions in the order of top, right, bottom, left.
Example:
margin: 8px 24px 8px 24px;
grants much more space on the left and right than top and bottom.

padding - how much you want to offset the contents within the box from the edges of the box. Like margin, you can also control all four directions in the same order.

text-align - the default is left, but you can align it to the center, right, or justify it.

text-decoration - Underline or none.

text-shadow - draws a shadow or glow around the text, with the same syntax as box-shadow.

text-style - the slant of the font. Italic or normal. Single argument.

transition - especially for mouse-over or clicking effects, fades in or out. Declared in decimal of seconds.
Example:
transition: 0.5s;
will cause content to fade in or out over the span of 0.5 seconds rather than suddenly appearing.



6. Tips and Tricks
  • The <i> in the quote heading can be turned off by declaring .mainbar_UID .quotedby i {text-style: normal}
  • You can override the mainbar border any other asset that Acmlmboard is pushy about on your post layout using !important. (e.g. border: none !important;}
    Any markup or specific classes you want sharing an attribute can be itemized before the attribute declaration. text colors and font family get inherited and don't need to be redeclared unless it's for changing.
  • Text-shadow can enhance readability, especially against detailed backgrounds.
  • :before and :after selectors can add a little flair to your quote boxes.
  • If you only want to draw a single box, background, margin setting etc. around all your nested quotes rather than a new box for each one, you can use > to select only the blockquotes that appear as a first child of the div or td that constitutes your post body.
  • ::selection modifies the highlighted text's attributes, which can be helpful when the browser's or web page's defaults make your text hard to read. For reasons I do not know, this function is not working in the post sidebar.



7. Special Considerations
  • Don't use someone else's userid for your CSS classes - doing so creates mischief by overriding their post settings. I won't complain if you do hide my avatar in this thread though.
  • Don't align your main post content to the right or center since it makes it harder to read.
  • Code's white-space is pre, text is monospaced, and the many classes give different color for readability as code. Modifying the code box should be done with extra care.
  • Acmlmboard's themes are mostly medium to dark. A layout can be very pretty on its own, but sudden sharp contrast changes on the screen create extra stress for the eyes of the reader.
  • Microtearing and microspacing at boundaries is going to happen on mobile phones no matter how pixel-perfect and seamless your images are, especially while using page zoom - it's unavoidable.
  • Sideboxes and side images are pretty cool but they're going to squish your post body a lot on smaller displays.
  • Though possible, it is forbidden to override your username with a custom color.
  • Keep a fallback font if you're using a new font. Some fonts are not installed on all systems. Sans-serif, Serif, and Monospace are safe fallbacks that will use whatever the viewer has set for their system defaults when they appear. If you don't do this, everyone who doesn't have your font installed will see Monospace. Post fallback should be Sans-serif or Serif, and code box fallbacks should be Monospace.
  • There is never a reason to use ids (#) in your CSS and HTML for the post layout portion because if you do, any attributes for it will only appear once per page.

NinCollin
Posted on 09-03-24 12:28 AM, in Link | ID: 641
Root Administrator

Red Koopa

Level: 15

Posts: 65/125
EXP: 14893
Next: 1491

Since: 08-12-24

Last post: 17 days
Last view: 17 days
Very nice! Gonna give this the ole sticky

Check out some of my websites!
imageimageimage

Yuri Bacon
Posted on 09-03-24 12:53 AM, in Link | ID: 644

Shyguy

Level: 13

Posts: 27/86
EXP: 8315
Next: 1952

Since: 08-16-24
From: MY MOM!

Last post: 16 days
Last view: 1 day
Congrats on the stick, your guide deserves it!

____________________
Build a man a fire, and he's warm for a night. Set a man on fire, and he's warm for the rest of his life.

Mattrizzle
Posted on 09-04-24 04:09 PM, in Link | ID: 680
Newcomer

Level: 4

Posts: 3/8
EXP: 239
Next: 40

Since: 08-13-24
From: United States

Last post: 29 days
Last view: 12 days
Noticed some errors:
Under 4. Classes in Your Posts, topbar1_UID and topbar2_UID should be topbarUID_1 and topbarUID_2, respectively.

This is still great!

____________________

Oz74
Posted on 09-04-24 04:11 PM, in Link | ID: 681

Level: 9

Posts: 19/39
EXP: 2544
Next: 618

Since: 08-16-24
From: Erebonia

Last post: 9 days
Last view: 9 days
Thank you - I'm gonna fix that right now!


Main - Meta - Basic Guide to Post Layouts on NeoRHDN (6)

Affiliates:


Acmlmboard v2.5.6+neo (2024-08-13)
© 2005-2024 Acmlm, Emuz, NinCollin, et al.

Page rendered in 0.067 seconds. (834KB of memory used)
MySQL - queries: 62, rows: 422/431, time: 0.055 seconds.