My Postcards Platinum Web Application (ver.4) 

  User Guide // Administration 

 Stats central 

Coming soon - you'll get update separately.

 Cardadmin (card cleaner) 

Program for cleaning old card datafiles is "SCRIPT_DIR/cardadmin.cgi". Requires magic-conf.txt to be present in same directory.

It cab be run from telnet command prompt by typing ./cardadmin.cgi

Or if you have busy cardshop you can write cron job for scheduled daily evocation of this program. See sample cronjob below.

Notice for webby hosting clients. We run daily centralized cron for card cleanups. You need to adjust only settings in magic-conf.txt and nothing else.

You can define card cleanup parameters in magic-conf.txt


those parameters define the limit of days of cards storage (KEEP_PICK - for already picked cards, KEEP_NO_PICK - for not picked cards), values must be integers.

Card admin program browses all cards, selects and deletes those matching 2 parameters above. This program is not connected with any other

 For sysadmin only!!!  

The following section is useful for webserver administrators only and requires knowledge of UNIX server administration basics. If you are afraid of telnet - skip this completely. The only usage for this section is to forward his page to your ISPs sysadmin in case of some problems.

 Shell scripts  

There are 3 UNIX shell scripts required for Platinum ver. 4 functioning. All located in SCRIPT_DIR. You can modify any of these IF YOU KNOW WHAT YOU ARE DOING!!! We will not repair your screwups for free.

Very fast (milliseconds) simple short script calling executable "later.cgi" and printing preformatted file with dates "later.txt" to specified dir. It should be run daily preferably at midnight.

Script for distribution of e-mails sent with QUEUE mode or in case multi-send plugin is purchased - cards scheduled for today's delivery to multiple recipients. We usually set it for hourly execution with cron. Script cleans e-mail sources from the disk after sending.

Script for distribution of e-mails scheduled for later delivery. It checks if directory with notification e-mails for given day exists, sends out all it's content and removes directory. Due to timezone differences, cached pages, etc. you may need to execute this script several times a day to make sure no e-mails will be neglected. See sample cronjob with typical settings below.

 ASAP/QUEUE mail delivery 

If you don't have high-traffic cardshop (at least 10.000-15.000 cards sent daily) you don't need this altogether.

MODE parameter in magic-conf.txt determines e-mail sending mode. If set to ASAP (default) it sends e-mail notices immediately after user had submitted form or picked up postcard (with only exception of cards scheduled for later delivery).

However in events of overloaded servers and traffic peaks you can normalize load by changing this parameter to QUEUE. Then e-mails will not be sent immediately, but in batches according to your cronjob settings (e.g. hourly). All texts for e-mails will be printed to /ROOT_DIR/queue/output/ .Shell script sending those cards is SCRIPT_DIR/

You may also use this parameter in case of network outages when popular mail servers (e.g., or major backbones become unavailable. Then you can store all outgoing emails and send them with SCRIPT_DIR/ (disabling this script in cron beforehand) when network conditions will become normal.

Since bounced e-mails are very possible it would be best idea not to run those scripts from root, but either run them from user or setup separate account for this e-mail sender. It's very bad idea to redirect contents of this sender's mailbox to /dev/null since sometimes you can find there useful info about server performance, DNS setup and network conditions.

Normal ratio of bounced mails for well-functioning cardshop in good network weather is 0,2-1% of all outgoing e-mail traffic.

 Sample cronjob 

1 0,6,12 * * * /SCRIPT_DIR/ 2>/dev/null
20 * * * * /SCRIPT_DIR/ 2>/dev/null
1 0 * * * /SCRIPT_DIR/
0 2 * * * cd /SCRIPT_DIR; ./cardadmin.cgi > cardadmin.log

 // index // setup // customize // reference // admin // support // license //  

 My Postcards Platinum Web Application