pMachine User Manual |
Ver 1.1.0 |
Copyright |
pMachine - © copyright 2001 - Rick Ellis - All Rights Reserved.
LICENSE |
Use of this software indicates acceptance of this license agreement. pMachine reserves the right to alter
this Agreement at any time, for any reason.
Publication Date: January 1, 2002
Requirements |
Your site must be hosted on a server with PHP version 4 or higher and mySQL 3.23.x or higher installed.
Installation |
PLEASE NOTE: If your server requires a different extension than .php, proceed FIRST to the next section which describes the process of renaming your files.
pMachine is installed in four steps:
The PHP Extension |
Similar to HTML pages which must end in .html, PHP pages must end in .php You'll notice that virtually every pMachine
page ends this way. Some hosting providers may require a slightly different extension, like .php4. If this applies to you,
you'll have a bit of file renaming on your hands.
To change pMachine to a different extension:
Your Home Page |
What's New in Version 1.1 |
pMachine Overview |
This table provides a quick overview of the pMachine files and directories. An in-depth discussion is found
at the very end of the manual. There is a lot of information regarding how pMachine works contained in that
discussion, so you'll want to read through it at some point.
|
THE CONTROL PANEL
YOUR WEBLOG
PREFERENCES
CREATING YOUR WEB PAGES
pMACHINE TAGS
TEMPLATES
TEMPLATES SETS
VARIABLES
SUMMARY
Weblog Entries |
Once your site is set up, you'll spend most of your time creating and managing weblog entries. To create a new entry click "Create a new entry". You'll be presented with a form where you'll enter the information.
The "subject" and "body" fields are required, the "more" field is optional. If you do not put anything in the "more" field, pMachine will not create the link to your more page in that particular entry.
At the time of creation, you can choose whether the entry is "open" or "closed". Open entries are displayed on your weblog page, closed entries are not.
Images are added to your entry by clicking the "Upload image" link at the top of the form.
Upon clicking it, the link opens a small window which enables you to upload an image.
In your preferences you can optionally pre-define HTML formatting which will be applied to all uploaded images.
If you have multiple weblogs, you can choose the destination of your new entry with the "display in" pull-down menu. You can also
specify a default weblog to post in at the bottom of your profile page so you don't have to manually choose.
Once you've entered all the information, click "submit" to add it to the database, or "preview" to preview it on a page.
In your preferences you can also specify how HTML submitted in your entries should be handled. Read the section on pMcode
for more information.
View/edit entries:
The "view/edit entries" page lets you see a list of all the entries you've created listed by subject along with other relevant
information about your entry like the date it was created, the author, whether the entry is open or closed, and how many comments
have been submitted for each entry.
To view a weblog entry click the title of that entry. To edit an entry, click the word "edit". To view the comments visitors
have submitted, click the word "comments". To flip the status of an entry from open to closed, or vice versa, click the word "open" or "closed".
Search for an entry.
pMachine allows you to do keyword searches to quickly find old entries. You can submit a single word, or multiple words separated by spaces.
Weblog Categories |
pMachine lets you create a list of categories (Rock, Jazz, Blues, Metal, etc.). Then, every time you create a weblog entry you
can assign it to one of your categories. Visitors of your site can then view entries from a specific category.
Categories are defined in your control panel by clicking "Weblog Categories". You can "add", "edit", and "delete"
categories from this page.
Once you've defined the categories, you can choose one from the list every time you create a new weblog entry.
In order for your visitors to browse your entries by category, they'll need to see a list of them - a "category menu".
pMachine will generate two different types of menus: 1. A list of text links. 2. A "drop down" menu. If you choose
the "drop down" menu, it can either have a submit button, or not. You'll have to put a couple lines of JavaScript in your
page header if you choose to use the buttonless version.
TEXT VERSION
To display the "text links" version of the menu, place the following tag on your page wherever you want the list to
appear:
<?php weblog_categories("weblog","text"); ?>
Note: If you have more than one weblog, you'll need to change the word "weblog" to match the name of the weblog
being shown on that page.
DROP DOWN VERSION
To display the "drop down" version of the menu, place this tag on your page wherever you want the list to appear:
<?php weblog_categories("weblog","drop"); ?>
As with the previous tag, change the word "weblog" if you are displaying the menu in something other than your main weblog.
By default, the "drop-down" version does not have a "submit" button since most people (we think) will prefer the cleaner
look. Because of that, you'll have to put the following JavaScript function in the header of the page where the menu is
being displayed (or you can place it in an external .js file).
<script language="JavaScript">
<!--
function gotoCategory(index) {
document.categories.submit()
}
//-->
</script>
CUSTOMIZING THE DROP DOWN MENU
In order to customize the look of the drop-down menu, or make the submit button appear, do the following:
Using a text editor like NotePad or SimpleText, open the file called "category_fns.php", located in your "lib" directory.
Near the top of the page you'll see a few configuration options that you can change.
Notes:
There is a template which defines the message that will appear if a visitor tries to view a category for which there
are no entries assigned. It is in the same page as the "weblog multi-entry templates".
Category list variable: You will find the following variable in the "collective weblog form templates": %%categorylist%%. This variable allows the
list of categories to appear in the form that people use to submit entries.
Member Privileges |
As far as pMachine is concerned, the only difference between a registered member who can post comments on your site, and you, as the "superuser", is access privilege. You have the highest level of privilege, normal members do not. Both are stored in the same database. If you choose to, you can "promote" members to higher access levels.
There are seven levels of access privileges for members. The first three levels determine general access to your site, the last four grant varying levels of access to your control panel. The levels are as follows:
The Post Office |
The post office enables you to send individual email to anyone, as well as send personalized email en-mass to selected groups of members.
The Post Office is where you'll also send email to everyone in your mailing list.
If you are sending email to members, you can place the following tag in title or the body of the message and it will be replaced
with the name of the member:
<<name>>
You'll also notice a box at the bottom of the email forms that lets you select how many emails at once to send. You can either select
"all", or specify a range, like 1 through 50. You might need to use the "range" feature if you have a very large number of emails to
send, more than a couple hundred or so, since there could be server "time out" issues.
pMcode |
pMcode is our own adaptation of the now famous UBB code. pMcode lets members add "style" or "formatting" to their entries
which would normally require HTML. It's a good security practice not to allow your visitors to submit HTML into your database.
pMcode allows some formatting options without the security risk.
pMachine goes one step further by looking for allowed HTML tags
and automatically replacing them with pMcode. pMachine will also automatically turn URL's and email addresses
into "click-able" links, and even image tags if you allow them. You'll have to enable these features in your preferences.
There are, in fact, four different preferences which determine how HTML and pMcode is handled in weblog entries and comments.
A description of those preferences is found in the next to each preference in the control panel.
Bookmarklet |
A bookmarklet allows you to add entries to your weblog without being
logged into the control panel. A bookmarklet gives you the convenience of "one click" publishing while surfing the internet.
You can additionally highlight text on a web site, then when you launch your bookmarklet the text will be added to
the form (highlighting only works on non-framed pages). Since the highlighted text is passed through the URL (URL encoded),
you can't highlight a very large section of text. It works well with a couple paragraphs, or so.
To set up your bookmarklet, Click on the bookmarklet menu in the control panel. You'll see a link,
which you'll drag to your "favorites" menu.
IP Banning |
pMachine allows you to ban IP addresses to prevent users from registering and logging-in.
Banning IP's is not foolproof because many users, especially those using dial-up accounts are
assigned a different IP address each time they access the internet.
The good news is that the numbers assigned to those users usually fall within a range of numbers.
Since pMachine allows you to ban partial IP's, you can prevent an entire range of numbers from having access.
You must exercise caution when doing this since you could inadvertently ban someone you did not intend to.
To ban a partial IP, you'll need to look at all the IP addresses associated with a particular person to try to figure
out the best approach. If you see that all the IP's are
identical you can simply ban that one address. If you find the IP's are different, you'll need to find the point in the
IP address where they start to become different.
Let's say a member has these three IP's:
176.45.37.9
176.45.34.5
176.45.44.6
Since the first five numbers are the same, you can ban 176.45 and be reasonably confident that the member will be totally banned.
Unfortunately there is a small chance that another member with the same provider could share the same first five numbers.
pMachine logs the IP address each time someone posts a comment, or weblog entry. If you require membership it's especially easy
to find all the IP addresses for a particular person. Just find the person's profile in the control panel and click the
"view all IP's" link at the bottom of the page. You'll be given the option of banning all IP addresses assigned to that member.
If you are banning someone's IP addresses it is also recommended that you revoke all access privileges. You could, of course,
delete the member as well.
If you do not require membership, it'll take a little more "leg work" to find all the IP addresses. You'll have to find all the
entries posted by that person and copy their IP addresses manually to the ban list.
Security Issues |
There is always a security risk associated with allowing people to submit information through forms on your site. A malicious individual, for example, instead of submitting a harmless comment, could use the comment form to submit a script designed to damage your files.
pMachine takes security issues seriously and has many built-in features to prevent these kinds of situations. For example, pMachine "filters" all information submitted through forms, allowing only "clean" information to get to the databases.
However, because pMachine allows flexibility in it's configuration, security issues can be greater of lesser. As the administrator of your site, there are a number of things you can do to increase security.
Intro to pBlocks |
Introduction:
Creating a pBlock |
Adding Members to Your pBlock |
Displaying Your pBlock |
pBlock Behavior Cookies |
Multiple Instances of the Same pBlock |
1. Place a "master" pBlock tag at the top of your page, just below the "include" tag. This master tag looks like this:
<?php $name_of_your_pBlock = pblock("name_of_your_pBlock","multi"); ?>
You'll replace "name_of_your_pBlock" with the name you gave your pblock. If your pBlock is called "pictures", the tag
will look like this:
<?php $pictures = pblock("pictures","multi"); ?>
Notice the word "multi" in the tag. This is important.
Here is what the top of your page will look like with the above tag:
<?php include("pm_include.php"); ?>
<?php $pictures = pblock("pictures","multi"); ?>
<html>
<head>
Collective Weblogs |
pMachine allows you to designate any weblog as "collective". A collective weblog is one in which your site visitors can submit
entries. Sort of like a discussion forum. Your visitors can submit entries, then other visitors can submit comments to those
entries. You can even set up multiple collective weblogs - like a forum with different categories. Not as full-featured as a real forum, of course,
but it does allows for a lot more dialog on your site. If you do set up more than one, you might want to use
the same template set for all of them so that they will all look identical.
Depending on whether your require membership or not, pMachine will dynamically create the correct version of the entry form.
You'll find templates for both in the control panel, which you can modify to your liking.
There are a few things you need to do to set up a collective weblog. We've done this as a safety mechanism to keep you from
inadvertently enabling this if you don't want to.
The first step is to go to the "Weblog Management" page and click "preferences" for the weblog you want to make collective.
Look for the menu item that says "Is this a collective weblog?". Set it to yes. While you're on that page, you should also
set your HTML options. It's recommended that you DO NOT allow HTML in entries, and possibly not images as well for security
reasons.
The next step is to decide whether you want the entry form on the same page as your weblog entries, or a separate page.
Once you decide, you'll to place a pMachine tag wherever you want the form to appear.There are two ways to set up the pMachine tag to cover a couple
different scenarios:
If you have multiple collective weblogs and your want them to all share the same entry form on a separate page, you'll
use the linking method. If you only have one collective weblog, or you want the entry form on the
same page as your entries, you'll use the reference method
Linking Method:
This is the tag you'll use:
<?php collective_weblog_entry_form($which); ?>
This is a generic tag that has no way of knowing which weblog you want the entries submitted into. Because of that,
you must make a link to the entry page with a URL that looks like this:
name_of_your_entry_page.php?which=weblog
In the above tag you'll replace "name_of_your_entry_page" with the name of the page, and "weblog" with the name of the weblog.
For example. If your weblog is called "talkpage" and the entry page is called "newentry.php", this is how the tag will look:
newentry.php?which=talkpage
You'll make links like this for every weblog that is collective.
Reference Method
The reference method lets you specify within the tag itself which weblog you want to submit entries into. This is the tag you'll use:
<?php collective_weblog_entry_form("name_of_your_weblog"); ?>
Of course you need to replace "name_of_your_weblog" with the actual name. Make sure and leave the quotes.
Multiple Weblogs/News pages |
pMachine allows the creation of multiple weblogs. pMachine, by default, installs with one weblog (called "weblog"), but as
many as you require can be created.
Multiple weblogs can be used whenever you need to separate your information into more specific groupings. If,
for example, you want separate weblogs for different authors. You could create a "Bob's weblog", "Jill's weblog,
and "Fred's weblog, and have each appear on it's own page with it's own look and preferences.
You don't have to think of weblogs strictly as weblogs. Using a little ingenuity you can use additional weblogs to manage
all kinds of content. For example, you could create a mini newspaper with "news", "sports", and "politics" categories.
In this scenario, each category would be a separate weblog. You could even place the
three categories together on the same page, each in it's own column. There is a lot of flexibility
in what you can do with weblogs.
When you create a new weblog, a new set of preferences for that weblog is created, allowing you to customize
it independently of other weblogs. You can, for example, allow comments in one weblog, but disallow them
in another. Or display one in ascending order and the other in descending. Once you create your new weblog,
a new set of preferences will appear for it in the "preferences" menu.
CREATING A NEW WEBLOG
To create a new weblog, click on the "Weblog Management" menu in the control panel. You'll see a form
where you can submit the name of your new weblog set. The name of your weblog set must be one word with no spaces.
You've created a new weblog, now what?
First, go to the preferences page. You'll see a set of preferences for your new weblog. The first four sets of
preferences are the names of your new pages.
You'll need to create four pages with these names (or with whatever name you'd like as long as you change
the preferences accordingly). On the very first line of your new pages, just like all your other
pages, you must place the following line of code:
<?php include("pm_inc.php"); ?>
You can place these new pages in their own directory if you'd like. If you do, you MUST make a copy of the page called:
pm_inc.php and put it in the directory with the new pages. You might also have to open this page and change the path
information if the path to the "lib" and "admin" directories has changed.
Once you've created your new pages, you'll you'll need to place pMachine tags in them.
Please note: Some pMachine tags require the name of the weblog in the tag. This one for example:
<?php weblog_entries($id,"weblog"); ?>
You'll have to change the word "weblog" to the name of your new weblog.
ADDING ENTRIES TO YOUR NEW WEBLOG
Entries are added the way you currently add entries; by clicking the "create new entry" link. In the form
you'll see a "pull-down" menu where you can select the weblog you want your entry to appear in.
In your member profile you can also assign which weblog you'd like the "create new entry" form to default to.
Multiple Template Sets |
Since pMachine allows you to create multiple weblogs, it also allows you to create multiple sets of the weblog templates. That way, each weblog can be assigned it's own template set, and appear on it's own set of pages, allowing total flexibility in the presentation of information.
You should note that templates and weblogs operate independently of one another.
You can have multiple weblogs all sharing a single template set. Before creating an additional template set,
make sure you need it. If you've gone to a lot of trouble to customize the look of your existing templates, you can
just assign the same set to your new weblog. Of course, if you need your new weblog to look completely different, you'll
want to create a new template set.
CREATING A NEW TEMPLATE SET
To create a new set of templates, click on the "Template Sets" menu in the control panel.
At the top of the page you'll click a link called "Create New".
Once there, you'll see a form where you can submit the name of your new template set.
The name of your template set must be one word with no spaces.
When creating a new set you are given the option of duplicating an existing set
in it's current state, or creating a copy of the set originally installed with pMachine. If you've spent a lot of time
customizing your templates you don't need to start from scratch.
Once you've created your new set, you need to assign it to a specific weblog. You do this in the
"Weblog Management" preferences page.
To modify your new templates, click to the "Template Sets" menu in the control panel.
Timestamp Overview |
Every weblog entry and comment is timestamped. This timestamp can be displayed
in many different ways using the codes below. Each letter of the code applies a particular format.
For example, if we use this code: M d, y
Our timestamp would be formatted like this: Jan 21, 2001
The letter "M" formats formats the month in "textual short format". The letter "d" formats the day. The letter "y" is the
year in "four digit" format, and the comma is just a comma.
We could also add the time to the above example by doing this:
M d, y - g:i a
Our timestamp would then be formatted like this:
Jan 21, 2001 - 5:22 pm
Notice we used a comma between the day and the year, and a dash between the year and the time,
and a colon to separate the hour from the minutes. You are allowed to add alpha-numeric,
and punctuation characters between the formatting codes.
Here's a more complex example to illustrate this:
j\t\h o\f\ F Y | g:i a
This would return: 15th of December | 5:22 am
What are all the backslashes ("\") for?
If you want characters to be treated as text, rather than timestamp codes,
you'll have to "escape" them (add the backslash). Otherwise pMachine has no way to know
if you intended the letter to be a formatting code or just a letter.
Note: Make sure to use a backslash "\", NOT a forward slash "/". Also, be sure to escape single quotes (')
and double quotes (") if you use them.
Timestamp Codes |
a - "am" or "pm"s
A - "AM" or "PM"
B - Swatch Internet time
d - day of the month, 2 digits with leading zeros ("01" to "31")
D - day of the week, textual, 3 letters ("Fri")
F - month, textual, long ("January")
g - hour, 12-hour format without leading zeros ("1" to "12")
G - hour, 24-hour format without leading zeros ("0" to "23")
h - hour, 12-hour format ("01" to "12")
H - hour, 24-hour format ("00" to "23")
i - minutes ("00" to "59")
I (capital i) - "1" if Daylight Savings Time, "0" otherwise.
j - day of the month without leading zeros ("1" to "31")
l (lowercase 'L') - day of the week, textual, long ("Friday")
L - boolean for whether it is a leap year ("0" or "1")
m - month ("01" to "12")
M - month, textual, 3 letters ("Jan")
n - month without leading zeros ("1" to "12")
r - RFC 822 formatting ("Thu, 21 Dec 2000 16:01:07 +0200")
s - seconds ("00" to "59")
S - English ordinal suffix, 2 characters; ("th", "nd")
t - number of days in the given month ("28" to "31")
T - Timezone setting of this machine ("MDT")
U - seconds since the epoch
w - day of the week, numeric - "0" (Sunday) to "6" (Saturday)
Y - year, 4 digits ("1999")
y - year, 2 digits ("99")
z - day of the year ("0" to "365")
Z - timezone offset in seconds ("-43200" to "43200").
The offset for timezones west of UTC is always negative, and for those east of UTC is always positive.
pMachine Tags |
<?php member_login_navbar($member); ?>
Displays the member navigation bar (login, logout, members, profile, register and calendar).
In the control panel, you'll
find two templates that define the look of these links: pMachine displays one template if a member is logged-in,
the other if a member is logged-out.
You don't have to use the "nav bar" look if you don't want to. You can even loose the
concept completely and just put "static" links to the various pages on your site. You can also get creative and put a lot more
than just the nav bar in the two templates: perhaps two versions of the entire header to your site, which changes depending
on whether someone is logged in or not.
<?php weblog_entries($id,"weblog"); ?>
This is a multi-function tag which will display a number of different things depending on
how the page containing the tag is accessed.
<?php weblog_entry_ind($id,"weblog"); ?>
Displays a single weblog entry. You'll normally place this tag on your "comments" page or on your "more" page.
As with the previous tag, if you create a additional weblogs, change the word "weblog" in the tag to match the name of your new weblog.
<?php weblog_headlines("weblog","3","30"); ?>
Weblog headlines are short excerpts from your most recent entries. Headlines can appear on a different page than your weblog.
If, for example, the main page of your site is not your weblog, you could place the most recent "headlines" on the page
as a "teaser" to your weblog. There is a template in the control panel which allows you to customize the look of the
headlines. You can format your headlines as titles only, or include some of the text of the entry.
You'll notice two numbers in the above tag. These let you set two options:
Number of headlines. The FIRST number ("3") in the above tag specifies how many headlines will be displayed.
Number of words. The SECOND number ("30") in the above tag specifies how many words from your weblog entry you want
to show. This allows you to limit the headline if you don't want your entire entry to appear. Note: If you DO NOT want to
limit the entry text, just leave off the last number in the tag, like this:
<?php weblog_headlines("weblog","3"); ?>
<?php archive_month_names("weblog"); ?>
Creates the links (month name and year) to your archive page. pMachine lets you specify whether your monthly archives are displayed
on your main weblog page, or on a separate "archive" page. You'll specify this in the preferences.
You can also define how these links look and how they format the name of the month and year in the templates page.
<?php previous_weblog_entry($id); ?> and <?php next_weblog_entry($id); ?>
Both of these tags are designed to go on your comments page. They dynamically show the title of your
next and previous weblog entries as links. These links allows your visitors to cycle forward or backward
one entry at a time. These links work in a loop. When the "next" link gets to the last entry, it will link to
the very first entry. The "previous" link works in reverse.
<?php weblog_entries($id,"weblog"); ?>
Displays your archives entries. This tag is identical to the one described above. Note: If you create an additional
weblog, you'll need to change the word "weblog" in the tag to match the name of your new weblog.
<?php archive_heading($id,"weblog"); ?>
You can place this tag on your archives page. It will display the name of the month and year of the
archives currently being viewed. There is a template to format the output of this tag.
Note: If you create an additional weblog, you'll need to change the word "weblog" in the tag to
match the name of your new weblog.
<?php weblog_titles(); ?>
This tag will create a list of titles from every weblog entry you've ever written. Each title will be formatted as a link
which your visitors can click to see any particular entry. You can use this tag on a "master" archives page, or any other
page you'd like.
By default, the list is formatted with your newest entry at the
top of the list.
You can optionally specify an order in which the titles should be sorted. The options are:
"oldest" Oldest entry is at the top of the list.
"newest" Newest entry is at the top of the list
"alpha" Sorted alphabetically
To specify a sorting order, place the option in the tag like this:
<?php weblog_titles("oldest"); ?>
You can also limit the list to show only titles from a specific weblog, like this:
<?php weblog_titles("newest","weblog"); ?>
Please note: If you decide to specify which weblog to show titles from, you MUST include the display order as well or you'll
get a database error.
<?php weblog_comments($id); ?>
Displays the comments for a particular weblog entry.
<?php weblog_comment_form($id);
Displays the form that visitors use to submit a comment. There are two versions of the form depending of whether
your require membership to post or not. pMachine will automatically display the correct version
based on your preference settings. The difference between the two forms is this:
The non-registration version has fields for the person's name, email and location as well as checkboxes to
choose whether to display their email, and whether to set a cookie to remember them.
The registration version has only the textarea box, since all of the member information is stored in the database.
<?php return_to_weblog_or_archives_link($id); ?>
This tag can be used on either the comments page, or the "more" page. It dynamically creates a link that takes visitors back
to either your weblog page, or to the archives page, depending on where they came from.
There are two templates which allows you to define what the link says. There is one template for the link back to the archives page
and one to the link back to the weblog page. pMachine automatically knows which one to use.
This link also will intelligently
return visitors to a particular "nested" weblog page. This "nested" feature won't be of any use if you display all of your weblog
entries on one page. If you set up your preferences to limit the number of entries per page, you might find this link useful.
Here's an example to illustrate how this link works
Let's say you decide to only display 10 weblog entries on a single page. Once you've created more than 10 entries,
a "next page" link will appear at the bottom of your weblog. If you've written 100 entries, visitors will have to
navigate through 10 pages to see all the entries.
Now, what if you decide to only display 10 comments per page as well? The same principal applies.
If there are 100 comments for a given entry, there will be 10 pages to travel through.
As you can see, it's possible to end up with pretty nested pages. Using the above example, a visitor would have to
travel through 20 pages to get the the last comment for the last entry.
Here, then, is our dilemma: If the above visitor was on weblog page 10 when he or she jumped to the comments page, we need a way to
return them back to that page. In an attempt to solve this dilemma, we've created
this link. pMachine applies some logic to where the link points to.
<?php homepage_link(); ?>
Displays a link to your main weblog page. It uses the name and url from your preferences to create the link.
<?php simple_search_form(); ?>
Displays the simple version of the search form that people use to do keyword searches of your weblog with.
If you have multiple weblogs, the search script will search through all weblogs.
<?php simple_search_form("where"); ?>
If you have more than one weblog, you can optionally specify which one you want the search conducted in. That way visitors can
search each weblog independently.
The word "where" must be replaced with the name of the weblog you want to search.
<?php advanced_search_form(); ?>
Displays the advanced version of the search form which visitors can use to do more refined searches. You probably don't need to
use this tag since the advanced search form is generated automatically by the tag below.
<?php show_search_results($weblog,$keywords,$criteria,$where); ?>
This tag goes on the search page specified in your search preferences. This tag serves a dual purpose:
1. It generates the search results which are displayed on the search page. 2. If the search page
is accessed by itself, not as a result of a search, it displays the advanced search form.
<?php show_calendar($year,$month); ?>
This tag displays the calendar. By default this tag shows member birthdays, as well as a link on every day where you have
posted weblog entries. You can turn off the birthday feature by placing the word "no" in the tag as follows:
<?php show_calendar($year,$month,"no"); ?>
Notice the comma before the word "no". Make sure and use quotes.
If you do not require membership, there's no reason for the calendar to run the birthday script, since there won't be any
birthdays. You could also make the calendar very small and use it on your weblog page.
<?php mini_calendar("weblog"); ?>
This tag displays the "mini" version of the calendar, which you can place on your weblog page. You must specify the name of your
weblog (if you only have one, leave it as "weblog") so that the calendar will know which weblog to create links to.
These tags are only necessary if you require membership.
<?php activate_member($id); ?>
Performs the member activation routine, assuming you require member activation (specified in your preferences).
This tag goes on the "activation" page. By default, this page is called "activate.php" and is located in the member directory.
Here's how this tag works: When a member registers, they are sent an email with a link to your activation page. This link
also contains an activation code. When the member goes to the activation page, pMachine will automatically activate their account.
If a person tries to access this page without a valid activation code, instead the page will display the "activation form". The
person can use this form to submit their email address to have pMachine send them a new email with the activation instructions
and code.
<?php member_email_form($id); ?>
Displays the email form that members can use to email other members directly from your site with. This feature requires
member registration.
Since members can specify whether to accept email, or not, this feature works on a member-by-member basis. The form also does
not reveal the address of the member who is being sent an email to the member sending the email.
<?php member_forgot_pw_form(); ?>
Displays the "forgotten password form" that members can use to request their username and password.
<?php member_login_form(); ?>
Displays the member login form.
<?php member_messages($number,$info); ?>
This tag goes on the "member messages" page (messages.php). The purpose of this page to display messages that users might encounter
while using your site. Generally these are error messages, like "The login information you submitted is incorrect". There are
over 60 messages covering every conceivable situation. pMachine automatically re-directs members to this page whenever they do
something requiring a message.
<?php member_edit_profile_form(); ?>
Displays the form members use to edit the information in their profile. By default this tag is on a page called "profile_edit.php".
The link to this page in in the "member nav bar", covered previously.
<?php show_all_members($id); ?>
Displays a list of all registered members. By default this tag is on a page called "profile_view_all.php".
<?php view_member_profile($id); ?>
Displays an individual member's publicly viewable profile. Not the private one mentioned earlier.
By default this tag is on a page called "profile_view_ind.php".
<?php view_member_update($id); ?>
If a member edits their profile, this tag shows the updated information. By default this tag appears on a
page called "profile_view_update.php".
<?php member_register_form(); ?>
Displays the member registration form appearing in "register.php".
<?php contact_form(); ?>
Displays a "contact" form that visitors can use to send email to the site admin. The email message is sent to the address
listed under "admin email" in the preferences page.
To change the look of the form you'll modify the "contact form template" in the control panel. Note: you do not have to
add opening and closing <form> tags since pMachine generates these automatically.
You can also specify a default subject that will appear in the subject field by adding it as an argument as follows:
<?php contact_form("Place your subject here like this"); ?>
Make sure and use quotes as shown.
<?php mailinglist_form(); ?>
Displays a form that visitors will use to subscribe to your mailing list.
<?php hit_counter(); ?>
Displays the hit-counter. In your preferences you can choose whether you want to display
a graphic-based, or text-based hit counter. The graphic-based counter pulls images out of
the images/digits/ directory to create the display.
To make your own digits: Create a set of ten images. One image for each number 0-9.
These can be any image format - jpeg, gif, png - since you define the image type in the preferences.
Name these images 0.x - 9.x
where x is the image type.
These tags display the statistics for your site:
<?php show_stats("weblog"); ?>
Total number of weblog entries. If you have multiple weblogs, change the word "weblog"
to whatever your additional weblog is called.
<?php show_stats("comments"); ?>
Total number of comments in the database.
<?php show_stats("members"); ?>
Total number of registered members.
Description of All pMachine Files and Directories |
WEBLOG PAGES:
ADMIN DIRECTORY
DOCS DIRECTORY
IMAGES DIRECTORY
LIB DIRECTORY
MEMBERS DIRECTORY