Technology Insights

Zencart Show Accepted Credit Cards Images or Text

Its really easy to configure ZenCart to show the credit cards that you are going to accept to customers during their checkout. Not only could you display the text of these images similar to the below example but its also very easy to display images of the credit card types you will be accepting.

Example: We Accept: Visa, Mastercard, AmEx, Discover

The default text can be modified in the credit_cards.php languages file located in /includes/languages/english/ directory.

Technology Insights

Zencart: How to Add an Order Status Type

Zencart has four default order status types which are Pending(1), Processing(2), Delivered(3), and Update(4). The number in parenthesis represents the order in which the order type will be located in the drop down so by default the first type in the drop down is Pending.

To add a new order status type login to the Zencart admin, click on Localization in the top navigation, and then click Order Status. This will display the order status type admin page where you can add, modify, or delete order status types. If all you need to do is add a order status type that will be located in 5th or higher place then click the Insert button at the bottom and add the new order status type. The very next one you add will be 5th, then 6th, and so on. So if you added Out of Stock via the Insert button you would now have the following order status types: Pending(1), Processing(2), Delivered(3), Update(4), and Out of Stock(5).

Technology Insights

Restore One Table with psql from a pg_dump PostgreSQL Backup

Backing up and restoring PostgreSQL is fairly easy using pg_dump and psql. One more complicated scenario I have run into is doing a complete database backup with pg_dump and at some point down the road needing to just split out one table and restore it. This can be a pain because of how the pg_dump organizes the .sql file it outputs. I have found the best way to do this is to use pg_dump to backup one table to understand the format of what is needed for a restore. Then search the .sql file that was output from the full pg_dump output and split out the necessary data to restore into one table. Below I provide some examples as well as syntax to use for backing up and/or restoring PostgreSQL using pg_dump and psql.

Technology Insights

Postgres Table pg_stat_activity Table Fields Explained

The pg_stat_activity table will show you what activity is currently happening on your PostgreSQL database server. The information will detail the database the activity is occuring on, the username initiating the activity, the length of time the acitivy has been occuring for, and much more.

Below is example output from running a SELECT query against the pg_stat_activity table. The pg_stat_activity table is located by default in the postgres database and can be accessed as shown below.

Technology Insights

The Linux Kill Command Explained in Detail

The Linux kill command is used to kill PID’s or process ID’s. This command is beneficial for numerous reasons typically for run away processes, processes caught in some sort of loop, to kick users from a system, or any other number of reasons.

Typically kill is used in the below format with 12345 being the PID in this example.


  1. [root@server ~]# kill 12345

If the process will not die from using the above command the -9 switch can be added to force it to stop as shown below.