Home | News | Projects | Releases
Bugs | RFE | Repositories | Help
Incorrect link fixed.
[kiriwrite/.git] / Documentation / English (British) / developer-chapter1-kiriwritevariablecheck.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">\r
2 <html>\r
3         <head>\r
4                 <link href="style.css" REL="stylesheet" TYPE="text/css" MEDIA="screen">\r
5                 <meta http-equiv="Content-Type" content="text/html;charset=UTF-8">\r
6                 <title>Kiriwrite Documentation - Developer Documentation - 1.31: kiriwrite_variablecheck</title>\r
7         </head>\r
8         <body>\r
9                 <div class="menubarback">\r
10                         <div class="menubar">\r
11                                 <span class="apptitle">Kiriwrite</span>\r
12                                 <a href="index.html">Index</a> | <a href="user.html">User \r
13 Documentation</a> | <a href="tutorial.html">Tutorial Documentation</a> | \r
14 <a href="developer.html">Developer Documentation</a>\r
15                         </div>\r
16                 </div>\r
17                 <div class="pageinformation">\r
18                         <span class="pagetitle">1.31 kiriwrite_variablecheck</span><br><br>\r
19 \r
20 kiriwrite_variablecheck checkes variables that are passed to it to see if the content of that variable is valid and returns an error if it isn't. All the parameters are needed each time the subroutine is called and If the noerror parameter is set to 1 then a value is returned when an error occurs otherwise a standard error message will be given.<br><br>\r
21 \r
22 <span class="heading">Parameters:</span><br><br>\r
23 \r
24 <div class="code">\r
25     kiriwrite_variablecheck(variable, type, option, noerror);\r
26 </div>\r
27 \r
28 <br>\r
29 \r
30 <span class="heading">Usage:</span><br><br>\r
31 \r
32 <div class="code">\r
33     kiriwrite_variablecheck(&quot;Test 123&quot;, &quot;lettersnumbers&quot;, &quot;&quot;, 0);<br>\r
34     $letters_letnum_check = kiriwrite_variablecheck(&quot;Test 123&quot;, &quot;lettersnumbers&quot;, &quot;&quot;, 1);\r
35 </div>\r
36 \r
37 <br>\r
38 \r
39 variable<br>\r
40 Specifies the variable to check.<br><br>\r
41 \r
42 type<br>\r
43 Specifies the test to check the variable with.<br><br>\r
44 \r
45 <table class="infotable">\r
46     <tr>\r
47         <td class="tableheading">Value</td>\r
48         <td class="tableheading">Description</td>\r
49     </tr>\r
50     <tr>\r
51         <td class="tabledata">numbers</td>\r
52         <td class="tabledata">Check if the variable given only contains numbers.</td>\r
53     </tr>\r
54     <tr>\r
55         <td class="tabledata">lettersnumbers</td>\r
56         <td class="tabledata">Check if the variable given only contains letters and numbers.</td>\r
57     </tr>\r
58     <tr>\r
59         <td class="tabledata">maxlength</td>\r
60         <td class="tabledata">Check if the variable given does not exceed the specific length given.</td>\r
61     </tr>\r
62     <tr>\r
63         <td class="tabledata">blank</td>\r
64         <td class="tabledata">Check if the variable given is blank.</td>\r
65     </tr>\r
66     <tr>\r
67         <td class="tabledata">filename</td>\r
68         <td class="tabledata">Check if the variable given is a valid filename.</td>\r
69     </tr>\r
70     <tr>\r
71         <td class="tabledata">filenameindir</td>\r
72         <td class="tabledata">Check if the variable given is a valid filename in a directory.</td>\r
73     </tr>\r
74     <tr>\r
75         <td class="tabledata">datetime</td>\r
76         <td class="tabledata">Check if the variable given is a valid date and time format.</td>\r
77     </tr>\r
78     <tr>\r
79         <td class="tabledata">directory</td>\r
80         <td class="tabledata">Check if the variable given is a valid directory name.</td>\r
81     </tr>\r
82     <tr>\r
83         <td class="tabledata">language_filename</td>\r
84         <td class="tabledata">Check if the variable given is a valid language filename.</td>\r
85     </tr>\r
86     <tr>\r
87         <td class="tabledata">page_filename</td>\r
88         <td class="tabledata">Check if the variable given is a valid page filename.</td>\r
89     </tr>\r
90     <tr>\r
91         <td class="tabledata">module</td>\r
92         <td class="tabledata">Check if the variable given is a valid module name.</td>\r
93     </tr>\r
94     <tr>\r
95         <td class="tabledata">utf8</td>\r
96         <td class="tabledata">Check if the variable given is a correctly formatted UTF-8 string.</td>\r
97     </tr>\r
98     <tr>\r
99         <td class="tabledata">serverprotocol</td>\r
100         <td class="tabledata">Check if the variable given is a valid server protocol.</td>\r
101     </tr>\r
102     <tr>\r
103         <td class="tabledata">port</td>\r
104         <td class="tabledata">Check if the variable given is a valid server port number.</td>\r
105     </tr>\r
106 </table>\r
107 \r
108 <br>\r
109 \r
110 option<br>\r
111 Specifies the setting to be used with the test.<br><br>\r
112 \r
113 noerror<br>\r
114 Specifies if noerror message should be returned but a value should be returned so that a more specific error message can be created.<br><br>\r
115 \r
116 For more information on what values are returned, please look at the kiriwrite_error subroutine in the Kiriwrite source code.\r
117                 </div>\r
118         </body>\r
119 </html>\r
Xestia Software Development
Yn Maystri
© 2006 - 2019 Xestia Software Development
Software

Xestia Address Book
Xestia Calendar
Development

Xestia Gelforn
Everything else

About
News
Privacy Policy