You are here

function pet_insert in Previewable email templates 6

API call to insert a new PET into the database.

Parameters

$pet : PET object identical to the one returned by pet_load.

1 call to pet_insert()
pet_install in ./pet.install
Implementation of hook_install().

File

./pet.module, line 132
Previewable E-mail Template module.

Code

function pet_insert($pet) {
  db_query("INSERT INTO {pets} (name, title, subject, body, object_types, recipient_callback) VALUES ('%s', '%s', '%s', '%s', '%s', '%s')", $pet->name, $pet->title, $pet->subject, $pet->body, $pet->object_types, $pet->recipient_callback);
}