tngToday.php How2Use

Include script for use with TNG v11.x - The Next Generation of Genealogy Site Building
README.txt

TNG Today Discussion / Notes

DOWNLOAD NOW

** This documentation is incomplete while tngToday is in development (7/25/17) **

Today.php provides "DataBox" tags that, when included within php pages, produce boxes of data pulled from your TNG database. The purpose is to produce small lists of data to be included in your genealogy home page, or any other TNG genealogy page.

Today.php script *MUST* be included in display page for DataBox Tags to function.

<?php include '/[path to file]/today.php'; ?>
The path in the include statement must point to the location of the today.php file

example: <?php include '/gen/tngToday/today.php'; ?>


DataBox Tags available:
getBirthToday(), getMarriedToday(), getDeathsToday(), longestLived(), getStats() and diagToday().

Each DataBox Tag can use arguments; if no option is desired, then include a "z" for zero (eg: getBirthToday(z); ), default width is 100%)

tngToday CacheNew!
tngToday now can use CACHE to decrease server load and INCREASE speed.
All files ending in .cache must have permissions set to 666 or 777 depending on your servers' config.

Tree Overide ArgumentNew!
We have added the ability to define a specific tree within a single tag call, for example:

<?php getBirthToday('fx|SMIT'); ?>

includes the argument SMIT seperated by the pipe, this overides the default tree defined within the config file. Note, the value must be the treeID and not the tree name, it must be at the end of the argument string and must begin with the pipe. You may simply leave out this part and the tag will use the default tree as defined within the config. SMIT is the treeID for a specific tree on our test site, your treeID's will vary.

** ALL TAG CALLS NOW REQUIRE ARGUMENTS TO BE INCLOSED IN SINGLE QUOTES **

** Known issues: Currently, using multiple instances of dataTags for different trees can NOT be done while using cache **

See examples of use below.


<?php getBirthToday('xfnr'); ?>

Calling getBirthToday with arguments - Generates a list of family members with birthdays today.

Args available: x, r, f, n, q [z for zero options]

To override the default tree, append the argument
string with the treeID beginning with a pipe.

x = min width, default = full
r = relationship link results
f = display footer
q = display query (diag feature)
n = renew cache (use temporarily or you disable cache use)
<?php getBirthToday('xfn'); ?>
No cache used


<?php getBirthToday('xf'); ?>
Read from cache (notice period at end of footer)


<?php getMarriedToday('xn'); ?>

Calling getMarriedToday with arguments - Generates a list of families created today (Anniversaries)

Args available: x, n, q [z for zero options]

To override the default tree, append the argument
string with the treeID beginning with a pipe.

x = min width, default = full
q = display query (diag feature)
n = renew cache (use temporarily or you disable cache use)
<?php getMarriedToday('xn'); ?>
No cache used

getMarriedToday No Cache
<?php getMarriedToday('xn'); ?>
Read from cache (notice period at end of footer)

getMarriedToday from cache

<?php getDeathsToday('xrylsn'); ?>

Calling getDeathsToday adding arguments - Generates a list of family members who died on this day.

Args available: x, r, y, l, s, n, q [z for zero options]

To override the default tree, append the argument
string with the treeID beginning with a pipe.

x = width x=min, default = full
r = relationship link results
q = display query (diag feature)
y = display year
l = display burial location
s = display years ago column
n = renew the cache
<?php getDeathsToday('xrylsn'); ?>
No cache used

getDeathsToday no cache
<?php getDeathsToday('xryls'); ?>
Read from cache (notice period at end of footer)

getDeathsToday from cache

<?php longestLived('xrl'); ?>

Calling longestLived with no arguments - Generates a list of the Longest Living Family members in the database.

Args available: x, r, l, n, q [z for zero options]

To override the default tree, append the argument
string with the treeID beginning with a pipe.

x = width x=min, default = full
r = relationship link results
q = display query (diag feature)
l = display burial location
n = renew the cache
<?php longestLived('xrln'); ?>
No cache used

longestLived no cache
<?php longestLived('xrl'); ?>
Read from cache (notice period at end of footer)


<?php getStats('x|'); ?>

Calling getStats with no arguments - Generates a list of statistics from the database.

x removes width=100%

Args available: x, p, m, f, u, g, s, a, i, e, h, x, n [z for zero options]
To override the default tree, append the argument
string with the treeID beginning with a pipe.

p = Number of people
m = Number of males
f = Number of females
u = Number of unknown gender
g = Number of families
s = Number of surnames
a = Average lifespan
i = Number of Images (photos)
e = Earlies Birth
h = Display Horizonal format
x = width x=min, default = full
n = Renew the cache
<?php getStats('xnpmfugsaie'); ?>
No cache used - Default format

getStats Vertical no cache
<?php getStats('xpmfugsaie'); ?>
Read from cache - Default format

getStats Vertical from cache
<?php getStats('xpmfugsaieh'); ?>
Horizonal format - NO cache

getStats Horizonal no cache

<?php diagToday('z|'); ?>

Calling diagToday('z') with the zero argument generates a Diagnosis page showing some PHP, MySQL, TNG values and confirms successful connection to the database.
i includes PHP Config info and v includes Variable info

Args available: iv [z for zero options]

Copyright © 2006 - 2017 by lee herron - All rights reserved.