Gossamer Forum
Home : Products : Links 2.0 : Discussions :

SSI call to get total # of links?

Quote Reply
SSI call to get total # of links?
Anyone knows how I can achieve that so that I can abstract the information to be place on another page?
Quote Reply
Re: SSI call to get total # of links? In reply to
You do not need an SSI call for that. The variable, $grand_total, contains the total number of links in the database. It is available for use on any page built by links.

I hope this helps.
Quote Reply
Re: SSI call to get total # of links? In reply to
Although if you want it for a non Link generated page, and assuming you are using version 2.0, you can get it by using:

<!--#include file="/path/to/admin/data/hits/index.count"-->

which has the total number of hits.

Actualy, Hmmm... will Apache let you include a file in a protected directory? Let me know if it works!

Cheers,

Alex
Quote Reply
Re: SSI call to get total # of links? In reply to
Hi Alex, thanx but it doesn't allow that.
thanx at least i know which file to use. Smile
Quote Reply
Re: SSI call to get total # of links? In reply to
Try unix ln command. I don't know the syntax, but it allows you to share a link to the same file...

The syntax should be something like 'ln /orig/file/in/protected/dir/something.ext /orig/file/in/nonprotected/dir/soething.ext'

This way you'll be able to access this file... i think....
Quote Reply
Re: SSI call to get total # of links? In reply to
 
Quote:
The syntax should be something like 'ln /orig/file/in/protected/dir/something.ext
/orig/file/in/nonprotected/dir/soething.ext'

The correct syntax is:

Quote:
ln -s path/to/file/to/link/filename symbolic/link/filename

where "path/to/file/to/link/filename" is the full (or relative) path to the file you want to link to and "symbolic/link/filename" is the name you want to give it in the directory you are located in. If you are not located in the right directory, change that to the full (or relative) path to the directory/filename where you want to put it.

For example:

Quote:
ln -s /home/bobsie/cgi/goodstuff/admin/data/hits/index.count /home/bobsie/web/goodstuff/index.count

That would create an index.count file in my goodstuff web directory (which is unprotected) that symbolically points to the file by the same name in my cgi protected directory. The SSI call would then be:

Quote:
<!--#include file="/home/bobsie/web/goodstuff/index.count"-->

I hope this is clear. Smile

[This message has been edited by Bobsie (edited March 09, 1999).]