1: <?php
2: /**
3: * QForm is defined in this file
4: *
5: * @package Controls
6: * @filesource
7: */
8:
9: /**
10: * QForm is one of the most important parts of QCubed - it is what ultimately creates the web page
11: *
12: * QForm is based on QFormBase class and is supposed to be used against QForm. The reason for such
13: * recommendation is - QFormBase is a lengthy, confusing and <b>very</b> important file. If you want
14: * to modify any behavior or QFormBase, please override the corresponding method here. If you want to
15: * add a new feature, add it as a method in this class.
16: *
17: * @package Controls
18: * @author Qcubed
19: */
20: abstract class QForm extends QFormBase {
21: ///////////////////////////
22: // Form Preferences
23: ///////////////////////////
24:
25: /**
26: * If you wish to encrypt the resulting formstate data to be put on the form (via
27: * QCryptography), please specify a key to use. The default cipher and encrypt mode
28: * on QCryptography will be used, and because the resulting encrypted data will be
29: * sent via HTTP POST, it will be Base64 encoded.
30: *
31: * @var string EncryptionKey the key to use, or NULL if no encryption is required
32: */
33: public static $EncryptionKey = null;
34:
35: /**
36: * The QFormStateHandler to use to handle the actual serialized form.
37: * Please refer configuration.inc.php file (in includes/configuration directory) to learn more
38: * about what __FORM_STATE_HANDLER__ does. Though you can change it here,
39: * try to change the __FORM_STATE_HANDLER__ in the configuration file alone.
40: *
41: * It overrides the default value in the QFormBase Class file
42: *
43: * @var string FormStateHandler the classname of the FormState handler to use
44: */
45: public static $FormStateHandler = __FORM_STATE_HANDLER__;
46:
47: // TODO: Improve explanation here.
48: /**
49: * These are the list of core QForm JavaScript files, or JavaScript files needed by
50: * a QControl, which QForm should IGNORE trying to load during a RenderBegin() or RenderAjax() call.
51: *
52: * It is used in the ProcessJavaScriptList function in the QFormBase class.
53: * @var array
54: */
55: protected $strIgnoreJavaScriptFileArray = array();
56: /* protected $strIgnoreJavaScriptFileArray = array(
57: 'date_time_picker.js',
58: 'treenav.js'); */
59:
60: /**
61: * This should be very rarely used.
62: *
63: * This mechanism acts similarly to the strIgnoreJavascriptFileArray, except it applies to StyleSheets.
64: * However, any QControl that specifies a StyleSheet file to include is MEANT to have that property
65: * be modified / customized.
66: *
67: * Therefore, there should be little to no need for this attribute. However, it is here anyway, just in case.
68: * Also note that QFormBase does not implement its feature. It is there if you (a developer building
69: * your application using QCubed) want to use it.
70: *
71: * @var array
72: */
73: protected $strIgnoreStyleSheetFileArray = array();
74: // protected $strIgnoreStyleSheetFileArray = array('datagrid.css', 'calendar.css', 'textbox.css', 'listbox.css');
75: }