Gossamer Forum
Home : Products : Links 2.0 : Discussions :

Yahoo???... Table Seperator???

Quote Reply
Yahoo???... Table Seperator???
How can you put a TABLE Spadding between Colum Spanding??

Like

Spadding = 15
will make the 2 collums when you create a catergory serparated.. help me thanks
Quote Reply
Re: Yahoo???... Table Seperator??? In reply to
Thanks for your respond!

I understand... I even used Frontpage to help me figure out the solution...

I see it attached together when create NEW LISTING or MAIN Directory. I tried to fix it but it still the same...

Because We CANNOT EDIT that part... Reason because the HOME.HTML has this code <%category%> Therefore It calls when create NEW DIR..

IS THERE something deal with the SITE_HTML.pl(or)CGI???

How can I INSERT anything in the SITE_HTML.pl(or)CGI ???


There says something LIKE:
---------------------------------
$site_body = 'body';

$site_title = $build_site_title;

$site_menu = qq~
----------------------------------
what is "qq~" ???? I dont know..

Please Help me how to change this kind stuff..

GREATLY APPRECIATED when finished!

I will also let you guys see my SITE TOO (Later when complete)

THANKS TO ANYONE HELPS ME OUT!
CHEERS,
TRIJASON
Quote Reply
Re: Yahoo???... Table Seperator??? In reply to
cellpadding and cellspacing are parameters of the <table> tag. Cellpadding determines the borders inside each <td>. Cellspacing determines the distance between each <td>. All values specified are in pixels. For example:

Quote:
<table cellspacing=2 cellpadding=5>

I hope this helps.
Quote Reply
Re: Yahoo???... Table Seperator??? In reply to
I think what you need to do is have a looksy @ sub site_html_print_cat in site_html.pl. It should look something like this :
Code:
##########################################################
## Category Listings ##
##########################################################

sub site_html_print_cat {
# --------------------------------------------------------
# This routine determines how the list of categories will look.
# We now use a table to split the category name up into two columns.
# For each category you can use the following variables:
#
# $url : The URL to go to that category
# $category_name : The category name with _ and / removed.
# $category_descriptions{$subcat}: The category description (if any).
# $numlinks : The number of links inside that category (and subcategories).
# $mod : The newest link inside of that category.
#

my (@subcat) = @_;
my ($url, $numlinks, $mod, $subcat, $category_name, $description, $output, $i);
my ($half) = int (($#subcat+2) / 2);

# Print Header.
$output = qq~<div class="margin"><table width="95%" border="0" cellspacing="10" cellpadding="5"><tr><td width="50%" class="catlist" valign="top">\n~;

foreach $subcat (sort @subcat) {
($description) = @{$category{$subcat}}[2];

# First let's get the name, number of links, and last modified date...
$url = "$build_root_url/" . &urlencode($subcat) . "/";
if ($subcat =~ m,.*/([^/]+)$,) { $category_name = &build_clean($1); } else { $category_name = &build_clean($subcat); }
$numlinks = $stats{"$subcat"}[0];
$mod = $stats{"$subcat"}[1];

# We check to see if we are half way through, if so we stop this table cell
# and begin a new one (this lets us have category names in two columns).
if ($i == $half) {
$output .= qq~</td><td width="50%" class="catlist" valign="top">\n~;
}
$i++;


# Then we print out the name linked, new if it's new, and popular if its popular.
$output .= qq~<dl><dt><font face="arial" size="3"><a class="link" href="$url"><b>$category_name</b></a></font> <font face="arial" size="1">($numlinks)</font> ~;
my $days_old = &days_old($mod);
if ($days_old <= 0) { $output .= qq|<$new_1_graphic>|; }
elsif ($days_old <= 2) { $output .= qq|<$new_3_graphic>|; }
elsif ($days_old <= 6) { $output .= qq|<$new_7_graphic>|; }
else { }
$output .= qq~</dt>~;
$output .= qq~<dd><font size="2" face="arial">$description </font></dd>~ if (!($description =~ /^[\s\n]*$/));
$output .= qq~</dl>~;

}

# Don't forget to end the unordered list..
$output .= "</td></tr></table></div>\n";
return $output;
}

You want to edit the line
Code:
# Print Header.
$output = qq~<div class="margin"><table width="95%" border="0" cellspacing="10" cellpadding="5"><tr><td width="50%" class="catlist" valign="top">\n~;

Your lines should be similar to mine, but most likely not exactly the same. I have added a few mods. BTW I'm using links 2.0.

------------------
Regards,
Brian
mjordn12@aol.com
veggietales.virtualave.net/veggielink/ (MegaLinks2.0)

Quote Reply
Re: Yahoo???... Table Seperator??? In reply to
 
Code:
$site_menu = qq~
<p><center><font size="2" face="arial"><b>|
<a href="$build_root_url">Home</a> |
<a href="$build_new_url">What's New</a> |
<a href="$build_cool_url">What's Cool</a> |
<a href="$build_email_url">Email Updates</a> |
<a href="$build_jump_url?$db_key=random">Random Link</a> |
<a href="$build_search_url">Search</a> |</b></font></center></p>
~;

"$site_menu = qq~" starts it, and @ the end is "~;". Wherever $site_menu is insterted into site_html.pl, the text inbetween those two strings of text will be inserted.

Sorry if i wasn't too clear on my explanation, I'm really not a perl guru...that's all




------------------
Regards,
Brian
mjordn12@aol.com
veggietales.virtualave.net/veggielink/ (MegaLinks2.0)

Quote Reply
Re: Yahoo???... Table Seperator??? In reply to
I have Figured it out before you notified me..

BUT GREAT Thanks for your respond... I spot that section :0)....

Cuz I saved my web site and see what s up with the table cellspading... then I looked at the Code where it says Build Home Page. I only see <%Category%> I tried to look a little bit down ... I saw the section you mentioned.... SO I just added the "CellSpading=10" It s makes the table seperated... I m glad that I did it...

Thanks TO YOU TOO!

Peace!