Gossamer Forum
Home : Products : Links 2.0 : Discussions :

How do put in a space?

Quote Reply
How do put in a space?
Small problem on my main page, when it lists the category followed by the number of links in that category, there are no spaces in between -- where would I add that? I thought subcategory.html but if so, I can't find anywhere to add it.

As you can see below, I need a space so it reads Products space (11)



Products
(11) Name of products, types of products



I'd like to be alone in a room, and enjoy the company.
Quote Reply
Re: [hairy] How do put in a space? In reply to
In site_html_templates.pl, try changing;

Code:
$output .= qq|<dl><dt><strong><a class="link" href="$url">$category_name</a></strong> <small class="numlinks">($numlinks)</small> |;

to

Code:
$output .= qq|<dl><dt><strong><a class="link" href="$url">$category_name</a></strong>&nbsp;&nbsp;<small class="numlinks">($numlinks)</small> |;

,... then do a rebuild...

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] How do put in a space? In reply to
Almost -- didn't do everything I wanted but it's my fault

I would like Products space (11)space name of product

right now it says Products(11) space name of product



I'd like to be alone in a room, and enjoy the company.
Quote Reply
Re: [hairy] How do put in a space? In reply to
If what you want is from the 'description' field, change this code [site_html_templates.pl]:

# Then we print out the name linked, new if it's new, and popular if its popular.
$output .= qq|<dl><dt><strong><a class="link" href="$url">$category_name</a></strong> <small class="numlinks">($numlinks)</small> |;
$output .= qq|<small><sup class="new">new</sup></small>| if (&days_old($mod) < $db_new_cutoff);
$output .= qq|</dt>|;
$output .= qq|<dd><span class="descript">$description </span></dd>| if (!($description =~ /^[\s\n]*$/));
$output .= qq|</dl>|;
}

to like this:

# Then we print out the name linked, new if it's new, and popular if its popular.
$output .= qq|<strong><a class="link" href="$url">$category_name</a></strong> <small class="numlinks">($numlinks)</small> |;
$output .= qq|<small><sup class="new">new</sup></small>| if (&days_old($mod) < $db_new_cutoff);
$output .= qq| <span class="descript">$description </span>| if (!($description =~ /^[\s\n]*$/));
$output .= qq|<br /><br />|;
}

You may need to change or remove the CSS refs, not sure what this will look like, but it will put the link, numlink, and description on one line.


Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] How do put in a space? In reply to
I guess I'm not explaining myself clearly.

It's not that I want things on one line, but I want spaced between the category name and number of links.



I'd like to be alone in a room, and enjoy the company.
Quote Reply
Re: [hairy] How do put in a space? In reply to
*bump*

Hey, I'm still broken over here!

Still need that space added -- HELP!



I'd like to be alone in a room, and enjoy the company.
Quote Reply
Re: [hairy] How do put in a space? In reply to
Well, a week later and no one can help?

I emailed support with no response either



I'd like to be alone in a room, and enjoy the company.
Quote Reply
Re: [hairy] How do put in a space? In reply to
The lack of response is, I think, due to the fact that the fix for your problem has been posted here. Andy replied to your question; did that not do what you want? Should have... If not, you can post that code from your site and let us see it. What we need to see id from site_html_templates.pl:

# Then we print out the name linked, new if it's new, and popular if its popular.
$output .= qq|<dl><dt><strong><a class="link" href="$url">$category_name</a></strong> <small class="numlinks">($numlinks)</small> |;
$output .= qq|<small><sup class="new">new</sup></small>| if (&days_old($mod) < $db_new_cutoff);
$output .= qq|</dt>|;
$output .= qq|<dd><span class="descript">$description </span></dd>| if (!($description =~ /^[\s\n]*$/));
$output .= qq|</dl>|;
}


Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] How do put in a space? In reply to
Nope, what he posted was not what I asked. The file that needed editing was subcategory.html, and I had to pay someone to tell me how to fix it. "Tech support" never responded, either.



I'd like to be alone in a room, and enjoy the company.
Quote Reply
Re: [hairy] How do put in a space? In reply to
Oh yeah, you're using non-standard templates, right? The stock Links download does not have a subcategory.html. This explains our confusion! Tongue


Leonard
aka PerlFlunkie
Quote Reply
Re: [PerlFlunkie] How do put in a space? In reply to
Wow, I didn't even know that! The guy (from this forum) who has been helping me must have set it up that way. I edit everything in the templates ... which if you remember, I didn't do at first :)

In case anyone else gets stuck with this (oddly enough, when I installed this on another domain, the space was there, but after he tweaked it, the space disappeared there, too) here was the fix:

" For the space, just edit the subcategory.html template. In this template, just add a space between <%category_name%> and (<%numlink%>) variable."



I'd like to be alone in a room, and enjoy the company.