18 require_once SQ_FUDGE_PATH.
'/general/file_system.inc';
19 require_once SQ_CORE_PACKAGE_PATH.
'/system/triggers/trigger_action/trigger_action.inc';
48 parent::__construct($assetid);
70 public static function execute($settings, &$state)
73 if (empty($settings[
'ipbsdk_path']) || !file_exists($settings[
'ipbsdk_path'])) {
79 if (empty($state[
'asset'])) {
81 if (empty($state[
'assetid'])) {
84 $state[
'asset'] =& $GLOBALS[
'SQ_SYSTEM']->am->getAsset($state[
'assetid']);
89 if (!file_exists($settings[
'ipbsdk_path'].
'/ipbsdk_class.inc.php')) {
90 trigger_localised_error(
'IPB0001', E_USER_WARNING);
93 require_once $settings[
'ipbsdk_path'].
'/ipbsdk_class.inc.php';
97 $old_reporting_level = error_reporting(0);
100 error_reporting($old_reporting_level);
117 public static function getInterface($settings, $prefix, $write_access=FALSE)
119 $ipbsdk_path = array_get_index($settings,
'ipbsdk_path',
'');
124 <td valign=
"top"><b><?php echo translate(
'ipb_path_to_ipbsdk'); ?></b></td>
125 <td valign=
"top" style=
"padding-bottom: 10px;"><?php
128 echo text_box($prefix.
'[ipbsdk_path]', $ipbsdk_path,
'50');
130 echo $ipbsdk_path.
' ';
133 <br /><b>Note:</b> Please make sure the IPB SDK version is compatible with the installed IPB.
134 <br />For more information, please visit <a href=
"http://ipbsdk.sourceforge.net/">the IPBSDK website</a>
141 return ob_get_clean();
159 $ipbsdk_path = array_get_index($request_data,
'ipbsdk_path',
'');
160 $ipbsdk_path = trim($ipbsdk_path);
161 if ($ipbsdk_path ==
'') {
162 trigger_localised_error(
'IPB0002', E_USER_WARNING);
165 $settings[
'ipbsdk_path'] = $ipbsdk_path;
181 public static function getLocks($settings, &$state)
184 $state[
'assetid'] => Array(