NineChime forum

Furry stuff, oekaki stuff, and other stuff.

You are not logged in.

Post a reply

Write your message and submit
Options
Humanity test

What is five + ten?

Go back

Topic review (newest first)

DC
10-28-2007 22:05:58

Ok.  I'll look into that later on.  Thanks again.

I'm trying to make my own custom template right now, looking at your "default" css file, which I found an error on (no closing bracket on hr with display: none).  Wish this was easier to figure out...

How much css is set to be usable in the templates?  Do you only have on certain css properties for each thing, or is there a variable for everything?

Waccoon
10-28-2007 01:52:35

You can't do this in the hacks file, because the it is parsed before the correct template is chosen.  It might appear to work for your account but other accounts would be broken.  Basically, the hacks file is for setting control values which are processed later.  Control logic should not be put into that file.

The easiest thing to do is comment out the entry in hacks.php (because you cannot redefine a constant later in the script), and modify boot.php with the new logic.  The new code should go after this line:

Code:

// If registered or non-registered

The name of the member's template (without the path or file extension) is $template

So, you could write something like this:

Code:

{
    // List of templates that should set FULL_AVATARS to 1
    $t_fix_list = array ('aoi', 'banana', 'blueness', 'etc');

    $t_fix_temp = 0;
    if (in_array ($template, $t_fix_list))
        $t_fix_temp = 1;

    define ('FULL_AVATARS', $t_fix_temp);
}
DC
10-25-2007 17:29:33

I was wondering...  Could I change up the hacks file so the avatar spacing is set depending on the template the users has on?

If this is the code:

    // Use full spacing between avatars (looks good on some templates)
    // (0-1) 0=Off, 1=On
    define ('FULL_AVATARS', 0);

...could one take that and make an if/else kinda thing and set it up so it's selective based on the template?  Something like this:

$banana == 0
$blue_ness == 1

etc...  Or otherwise, have those variable things inside the templates that tell whether to load the css change or not, or even if possible, just a php include (if it's that easy) that is in each template so one could set which style to load just by having it include the right css for whatever template you use?

I'm certain there must be some way to have it use the hack only on the templates that call for it... but it's way beyond me how to even approach that.  The only thing I know for php so far is php include, php chmod and php fileperms... and I've only used include so far.  Other than that, and looking at some php files and what all is possible, I have no idea.

DC
10-24-2007 21:01:19

Oh, OK, and I think you have the the opposite way around... for things with borders, it looks bad because the bottom border of one post runs right along the top border of the next post.  For posts without them, it'd look OK because in small posts, there would be equal space between the top of the avatar and the bottom of the comment title area and the bottom of the avatar and the top of the next post's comment area.

Thanks for the info, as I prefer it off.  I'll make the change! <^o^>

Seeya later!

Waccoon
10-24-2007 06:23:14

This is a hack to get rid of some space when using avatars.  The inline code simply overrides the CSS in the template.  For layouts with borders it looks better, for borderless layouts, it doesn't.  If you open up the "hacks.php" file, you'll see an option where you can turn this off.

I have no plans for a "proper" fix, because it's purely cosmetic.

DC
10-21-2007 19:51:47

I have something that's showing up in Wacintaki that really shouldn't be there.  When someone posts a comment while they currently have an avatar, this style="" info is being posted into the divs for the comments:

<div class="commentdata" style="padding-top: 0pt; padding-bottom: 0pt; margin-top: 0pt; margin-bottom: 0pt;">

Any comments made without an avatar, including ones made before a person had an avatar that was applied to the comment afterwards, show up right with just this:

<div class="commentdata">
This makes the bottom margin and padding show up right so there is a space between the comment boxes and the comment header of the next comment.

You'd only see the problem in a template with comment borders. It looks neater with the even spaces between comments. Also, this extra style data isn't applied to the first comment, whether they have an avatar or not, so it keeps it's margin space between the first and second comments.

EDIT:  Oh, and in the blue-ness style, it says this is supossed to be the margin applied to comment data: margin-bottom: 8px;

Board footer

Yep, still running PunBB
© Copyright 2002–2008 PunBB