18 require_once SQ_CORE_PACKAGE_PATH.
'/page/page_edit_fns.inc';
43 parent::__construct();
44 $this->static_screens[
'details'][
'force_unlock'] = FALSE;
61 require_once SQ_LIB_PATH.
'/html_form/html_form.inc';
62 $write_access = $asset->writeAccess(
'menu');
65 text_box($prefix.
'_poll_name',
'', 50);
87 if (!$asset->writeAccess(
'menu'))
return FALSE;
89 $poll_name = array_get_index($_POST, $prefix.
'_poll_name',
'');
90 $poll_name = trim($poll_name);
92 if ($poll_name ==
'')
return FALSE;
95 $GLOBALS[
'SQ_SYSTEM']->am->includeAsset(
'poll_question');
97 $initial_link = Array(
'asset' => &$asset,
'link_type' => SQ_LINK_TYPE_2,
'value' =>
'',
'sort_order' => 0,
'is_dependant' => 0);
98 $poll_question->setAttrValue(
'name', $poll_name);
100 if (!$poll_question->create($initial_link)) {
101 trigger_localised_error(
'CMS0021', E_USER_WARNING);