]>
git.ipfire.org Git - thirdparty/cups.git/blob - scripting/php/phpcups.php
4 // "$Id: phpcups.php 3603 2003-04-11 18:42:52Z mike $"
6 // PHP test script for the Common UNIX Printing System (CUPS).
8 // Copyright 2007 by Apple Inc.
9 // Copyright 1997-2006 by Easy Software Products, all rights reserved.
11 // These coded instructions, statements, and computer programs are the
12 // property of Apple Inc. and are protected by Federal copyright
13 // law. Distribution and use rights are outlined in the file "LICENSE.txt"
14 // which should have been included with this file. If this file is
15 // file is missing or damaged, see the license at "http://www.cups.org/".
18 // Make sure the module is loaded...
19 if(!extension_loaded("phpcups"))
24 // Get the list of functions in the module...
26 $functions = get_extension_funcs($module);
28 print("Functions available in the $module extension:\n");
30 foreach ($functions as $func)
37 print("cups_get_dests:\n");
38 print_r(cups_get_dests());
40 print("cups_get_jobs(\"\", 0, -1):\n");
41 print_r(cups_get_jobs("", 0, -1));
43 print("cups_print_file(\"test\", \"../../test/testfile.jpg\", "
44 ."\"testfile.jpg\", ...):\n");
45 print_r(cups_print_file("test", "../../test/testfile.jpg", "testfile.jpg",
46 array("scaling" => "100",
47 "page-label" => "testfile.jpg")));
49 print("cups_print_files(\"test\", array(\"../../test/testfile.jpg\", "
50 ."\"../../test/testfile.ps\"), \"testfiles\", ...):\n");
51 print_r(cups_print_files("test", array("../../test/testfile.jpg",
52 "../../test/testfile.ps"),
54 array("scaling" => "100",
55 "page-label" => "testfile.jpg")));
58 // End of "$Id: phpcups.php 3603 2003-04-11 18:42:52Z mike $".