示例#1
0
 function XedReplaceForm()
 {
     parent::MailForm();
     $this->parseSettings('inc/app/xed/forms/replace/settings.php');
     $this->widgets['find']->setValue(session_get('xed_source_find'));
     $this->widgets['replace']->setValue(session_get('xed_source_replace'));
 }
示例#2
0
 function show()
 {
     if (!$this->editable) {
         return;
     }
     return parent::show();
 }
示例#3
0
 function SiteblogEditForm()
 {
     parent::MailForm();
     global $cgi;
     $refer = $_SERVER['HTTP_REFERER'];
     $this->parseSettings('inc/app/siteblog/forms/edit/settings.php');
     $this->widgets['refer']->setValue($refer);
     //if add is true, we're creating a blog post, otherwise we're editing a blog post
     $add = isset($cgi->_key) && !empty($cgi->_key) ? false : true;
     $this->widgets['status']->setValues(array('Live', 'Not Live'));
     $cats = db_pairs('select id, title from siteblog_category where status = "on"');
     if ($add) {
         page_title('Adding a Blog Post');
         $this->widgets['author']->setValue(session_username());
         unset($this->widgets['icategory']);
         $this->widgets['category']->setValues($cats);
     } else {
         loader_import('cms.Versioning.Rex');
         $rex = new Rex('siteblog_post');
         $document = $rex->getCurrent($cgi->_key);
         page_title('Editing a Blog Post');
         //populate fields
         $this->widgets['subject']->setValue($document->subject);
         $this->widgets['author']->setValue($document->author);
         $this->widgets['status']->setValue($document->status);
         unset($this->widgets['category']);
         $catname = db_shift('select title from siteblog_category where id = ?', $document->category);
         $this->widgets['icategory']->setValue($catname);
         $this->widgets['oldcat']->setValue($document->category);
         $this->widgets['body']->setValue($document->body);
     }
 }
示例#4
0
    function SitefaqEditForm()
    {
        parent::MailForm();
        global $page, $cgi;
        $this->extra = 'id="cms-edit-form"';
        // get copy from repository
        loader_import('cms.Versioning.Rex');
        $rex = new Rex($cgi->_collection);
        // default: database, database
        $_document = $rex->getCurrent($cgi->_key);
        $widgets = $rex->getStruct();
        if (!$widgets) {
            $widgets = array();
        }
        // edit widgets go here
        $this->widgets = array_merge($this->widgets, $widgets);
        foreach ($this->widgets as $k => $v) {
            if (isset($_document->{$k})) {
                $this->widgets[$k]->setValue($_document->{$k});
            }
        }
        $w =& $this->addWidget('hidden', '_key');
        $w =& $this->addWidget('hidden', '_collection');
        $w =& $this->addWidget('hidden', '_return');
        if ($rex->isVersioned) {
            $t =& $this->addWidget('textarea', 'changelog');
            $t->alt = intl_get('Change Summary');
            $t->rows = 3;
            $t->labelPosition = 'left';
            $t->extra = 'id="changelog"';
        }
        // submit buttons
        $w =& $this->addWidget('msubmit', 'submit_button');
        $b =& $w->getButton();
        $b->setValues(intl_get('Save'));
        $b =& $w->addButton('submit_button', intl_get('Cancel'));
        $b->extra = 'onclick="return cms_cancel (this.form)"';
        $this->error_mode = 'all';
        if ($rex->info['Collection']['singular']) {
            page_title(intl_get('Editing') . ' ' . $rex->info['Collection']['singular'] . ': ' . $_document->{$rex->key});
        } else {
            page_title(intl_get('Editing Item') . ': ' . $_document->{$rex->key});
        }
        // the SiteFAQ additions:
        if (appconf('user_anonymity')) {
            unset($this->widgets['name']);
            unset($this->widgets['email']);
            unset($this->widgets['url']);
            unset($this->widgets['ip']);
            unset($this->widgets['member_id']);
        }
        $admin_roles = session_admin_roles();
        $this->widgets['assigned_to']->setValues(db_pairs('select username, concat(lastname, ", ", firstname, " (", username, ")")
				from sitellite_user
				where role in("' . join('", "', $admin_roles) . '")
				order by lastname, firstname, username'));
        if (!$_document->assigned_to) {
            $this->widgets['assigned_to']->setValue(session_username());
        }
    }
示例#5
0
    function SiteglossaryEditForm()
    {
        parent::MailForm();
        $this->parseSettings('inc/app/siteglossary/forms/edit/settings.php');
        global $cgi;
        page_title(intl_get('Editing Glossary Term') . ': ' . $cgi->_key);
        page_add_script('
			function cms_cancel (f) {
				if (arguments.length == 0) {
					window.location.href = "/index/cms-app";
				} else {
					if (f.elements["_return"] && f.elements["_return"].value.length > 0) {
						window.location.href = f.elements["_return"].value;
					} else {
						window.location.href = "/index/siteglossary-app";
					}
				}
				return false;
			}
		');
        // add cancel handler
        $this->widgets['submit_button']->buttons[1]->extra = 'onclick="return cms_cancel (this.form)"';
        $res = db_single('select * from siteglossary_term where word = ?', $cgi->_key);
        foreach (get_object_vars($res) as $k => $v) {
            $this->widgets[$k]->setValue($v);
        }
    }
示例#6
0
 function EntryAddForm()
 {
     parent::MailForm();
     $this->parseSettings('inc/app/timetracker/forms/entry/add/settings.php');
     $res = db_fetch('select username, firstname, lastname from sitellite_user order by lastname asc');
     if (!$res) {
         $res = array();
     } elseif (is_object($res)) {
         $res = array($res);
     }
     $users = array();
     foreach ($res as $row) {
         if (!empty($row->lastname)) {
             $users[$row->username] = $row->lastname;
             if (!empty($row->firstname)) {
                 $users[$row->username] .= ', ' . $row->firstname;
             }
             $users[$row->username] .= ' (' . $row->username . ')';
         } else {
             $users[$row->username] = $row->username;
         }
     }
     $this->widgets['users']->setValues($users);
     $this->widgets['users']->setDefault(session_username());
     $this->widgets['users']->addRule('not empty', 'You must select at least one user.');
     $this->widgets['started']->setDefault(date('Y-m-d H:i:s'));
     $this->widgets['ended']->setDefault(date('Y-m-d H:i:s'));
     global $cgi;
     $this->widgets['proj_name']->setValue(db_shift('select name from timetracker_project where id = ?', $cgi->project));
     $this->widgets['submit_button']->buttons[1]->extra = 'onclick="history.go (-1); return false"';
 }
示例#7
0
 function SiteblogBrowseForm()
 {
     parent::MailForm();
     $this->parseSettings('inc/app/siteblog/forms/browse/settings.php');
     echo '<h2> Search for Posts </h2>';
     $years = array();
     $years[] = 'All Years';
     $currYear = date('Y');
     for ($i = 2000; $i <= $currYear + 1; $i++) {
         $years[$i] = $i;
     }
     $months = array(0 => 'All Months', 1 => 'January', 2 => 'February', 3 => 'March', 4 => 'April', 5 => 'May', 6 => 'June', 7 => 'July', 8 => 'August', 9 => 'September', 10 => 'October', 11 => 'November', 12 => 'December');
     $authors[] = 'All Users';
     foreach (db_shift_array('select distinct author from siteblog_post') as $a) {
         $authors[$a] = $a;
     }
     $cats = db_fetch_array('select * from siteblog_category');
     $newcats = array();
     foreach ($cats as $c) {
         $newcats[$c->id] = $c->title;
     }
     $this->widgets['author']->setValues($authors);
     $this->widgets['month']->setValues($months);
     $this->widgets['year']->setValues($years);
     $this->widgets['category']->setValues($newcats);
 }
示例#8
0
    function UsradmCacheForm()
    {
        parent::MailForm(__FILE__);
        page_add_style('
			td.label {
				width: 200px;
			}
			td.field {
				padding-left: 7px;
				padding-right: 7px;
			}
		');
        $cache = ini_parse('inc/conf/cache.php');
        foreach ($cache['Cache'] as $k => $v) {
            $this->widgets[$k]->setValue($v);
        }
        $cacheable = '';
        foreach ($cache['Cacheable'] as $k => $v) {
            if (in_array($k, $this->ignore)) {
                continue;
            }
            if ($v) {
                $cacheable .= $k . " = yes\n";
            } else {
                $cacheable .= $k . " = no\n";
            }
        }
        $this->widgets['cacheable']->setValue($cacheable);
    }
示例#9
0
 function SiteblogPropertiesForm()
 {
     parent::MailForm();
     global $cgi;
     if (empty($cgi->blog)) {
         return;
     }
     $this->parseSettings('inc/app/siteblog/forms/properties/settings.php');
     page_title('Editing Category Properties: ' . $cgi->blog);
     $category = db_single('select * from siteblog_category where id = ?', $cgi->blog);
     $set = array();
     if ($category->comments == 'on') {
         $set[] = 'Enable Comments';
     }
     if ($category->poster_visible == 'yes') {
         $set[] = 'Author Visible';
     }
     if ($category->display_rss == 'yes') {
         $set[] = 'Include RSS Links';
     }
     if ($category->status == 'on') {
         $set[] = 'Enabled';
     }
     $this->widgets['blog_properties']->setValue($set);
     $this->widgets['blog']->setValue($cgi->blog);
     $this->widgets['refer']->setValue($_SERVER['HTTP_REFERER']);
 }
示例#10
0
 function CmsMessagesCategoryEditForm()
 {
     parent::MailForm();
     $this->parseSettings('inc/app/cms/forms/messages/category/edit/settings.php');
     global $cgi;
     $this->widgets['name']->setDefault($cgi->category);
 }
示例#11
0
 function AppdocTranslationAddForm()
 {
     parent::MailForm();
     $this->parseSettings('inc/app/appdoc/forms/translation/add/settings.php');
     page_title(intl_get('Add Language'));
     global $cgi;
     if ($cgi->appname == 'GLOBAL') {
         $this->_file = 'inc/lang/languages.php';
     } else {
         $this->_file = 'inc/app/' . $cgi->appname . '/lang/languages.php';
     }
     $list = array('no' => 'None');
     $info = ini_parse($this->_file);
     foreach ($info as $k => $v) {
         $list[$k] = $v['name'];
     }
     $this->widgets['fallback']->setValues($list);
     $this->widgets['default']->setValues(array('yes' => 'Yes', 'no' => 'No'));
     if (count($list) == 1) {
         $this->widgets['default']->setDefault('yes');
     } else {
         $this->widgets['default']->setDefault('no');
     }
     $this->widgets['submit_button']->buttons[1]->extra = 'onclick="window.history.go (-1); return false"';
 }
示例#12
0
    function SitepresenterEditSlideForm()
    {
        parent::MailForm();
        $this->parseSettings('inc/app/sitepresenter/forms/edit/slide/settings.php');
        page_add_script('
			function cms_cancel (f) {
				if (arguments.length == 0) {
					window.location.href = "/index/cms-app";
				} else {
					if (f.elements["_return"] && f.elements["_return"].value.length > 0) {
						window.location.href = f.elements["_return"].value;
					} else {
						window.location.href = "/index/sitepresenter-app";
					}
				}
				return false;
			}
		');
        $this->widgets['submit_button']->buttons[1]->extra = 'onclick="return cms_cancel (this.form)"';
        global $cgi;
        page_title(intl_get('Adding Slide to Presentation') . ': ' . db_shift('select title from sitepresenter_presentation where id = ?', $cgi->presentation));
        $res = db_single('select * from sitepresenter_slide where id = ?', $cgi->id);
        foreach (get_object_vars($res) as $k => $v) {
            $this->widgets[$k]->setValue($v);
        }
    }
示例#13
0
 function SitetemplateNewtplForm()
 {
     parent::MailForm();
     global $cgi;
     $this->parseSettings('inc/app/sitetemplate/forms/newtpl/settings.php');
     if (@file_exists('inc/app/xed/lib/Widget/Linker.php')) {
         $this->link_chooser = true;
     }
     $mode = 'html';
     $name = 'new file';
     $set = $cgi->set_name;
     $sname = $set;
     session_set('imagechooser_path', site_prefix() . '/inc/html/' . $set . '/pix');
     if (@file_exists('inc/html/' . $set . '/config.ini.php')) {
         $info = parse_ini_file('inc/html/' . $set . '/config.ini.php');
         if (isset($info['set_name'])) {
             $sname = $info['set_name'];
         }
     }
     page_title(intl_get('Editing New Template in') . ': ' . $sname);
     $set = str_replace('/' . $mode . '.' . $name . '.' . $ext, '', $cgi->path);
     //$this->widgets['edit_buttons']->data = array ('mode' => strtoupper ($mode), 'name' => ucfirst ($name), 'link_chooser' => $this->link_chooser);
     //$this->widgets['body']->setValue (join ('', file ('inc/html/' . $sname)));
     $this->widgets['submit_buttons']->data = array('set' => $set);
     $this->widgets['path']->setValue($set);
 }
示例#14
0
 function EditForm()
 {
     parent::MailForm();
     global $cgi, $_helpdoc;
     $this->addWidget('hidden', 'appname');
     $this->addWidget('hidden', 'lang');
     $this->addWidget('hidden', 'helpfile');
     $w =& $this->addWidget('text', 'filename');
     $w->alt = intl_get('File Name (ie. 001-about-myApp)');
     $w->addRule('not empty', intl_get('You must specify a file name.'));
     $w->addRule('not contains ".."', intl_get('Your file name contains invalid characters.'));
     $w->setValue($cgi->helpfile);
     $w =& $this->addWidget('text', 'title');
     $w->alt = intl_get('Title');
     $w->addRule('not empty', intl_get('You must specify a title.'));
     $w->setValue($_helpdoc->title);
     session_set('imagechooser_path', 'inc/app/' . $cgi->appname . '/pix');
     $this->extra = 'onsubmit="xed_copy_value (this, \'body\')"';
     $w =& $this->addWidget('xed.Widget.Xeditor', 'body');
     $w->setValue($_helpdoc->body);
     $w =& $this->addWidget('msubmit', 'submit_button');
     $b =& $w->getButton();
     $b->setValues(intl_get('Save'));
     $b =& $w->addButton('submit_button');
     $b->setValues(intl_get('Cancel'));
     $b->extra = 'onclick="window.location.href = \'' . site_prefix() . '/index/appdoc-helpdoc-action?appname=' . $cgi->appname . '&lang=' . $cgi->lang . '\'; return false"';
 }
示例#15
0
 function SitetemplateEditsetForm()
 {
     parent::MailForm();
     global $cgi;
     $set = $cgi->set;
     $this->parseSettings('inc/app/sitetemplate/forms/editset/settings.php');
     $settings = array();
     if (file_exists('inc/html/' . $set . '/config.ini.php')) {
         $settings = ini_parse('inc/html/' . $set . '/config.ini.php', false);
     }
     $name = $settings['set_name'];
     if (!$name) {
         $name = $set;
     }
     $settings['set'] = $set;
     //put form values into respective forms
     foreach ($settings as $k => $v) {
         $this->widgets[$k]->setDefault($v);
     }
     if (@file_exists('inc/html/' . $set . '/modes.php')) {
         $this->widgets['modes']->setDefault(@join('', @file('inc/html/' . $set . '/modes.php')));
     } else {
         $this->widgets['modes']->setDefault($modesd);
     }
     $this->widgets['submit_button']->buttons[1]->extra = 'onclick="history.go (-1); return false"';
     page_title(intl_get('Editing Properties') . ': ' . $name);
 }
示例#16
0
 function DeadlinesAddForm()
 {
     parent::MailForm();
     $this->parseSettings('inc/app/deadlines/forms/add/settings.php');
     page_title('Deadlines - Add Item');
     $this->widgets['ts']->setDefault(date('Y-m-d H:i:s'));
 }
示例#17
0
 function BoxchooserSettingsForm()
 {
     parent::MailForm();
     page_title(intl_get('Box Settings'));
     //set(array('title'=>'Add a Box'));
     global $cgi;
     //set
     if (!$cgi->box) {
         echo 'Missing parameter: box';
         exit;
     }
     ini_add_filter('ini_filter_split_comma_single', array('rule 0', 'rule 1', 'rule 2', 'rule 3', 'rule 4', 'rule 5', 'rule 6', 'rule 7', 'rule 8', 'button 0', 'button 1', 'button 2', 'button 3', 'button 4', 'button 5', 'button 6', 'button 7', 'button 8'));
     $this->_box_settings = ini_parse('inc/app/' . $cgi->app . '/boxes/' . $cgi->box . '/settings.php');
     ini_clear();
     unset($this->_box_settings['Meta']);
     if (count($this->_box_settings) === 0) {
         $this->onSubmit((array) $cgi);
         return;
     }
     foreach ($this->_box_settings as $k => $v) {
         $this->createWidget($k, $v);
     }
     $this->addWidget('hidden', 'app');
     $this->addWidget('hidden', 'box');
     $this->addWidget('hidden', 'name');
     $w =& $this->addWidget('submit', 'sub');
     $w->setValues(intl_get('Done'));
 }
示例#18
0
 function SitetemplateEditForm()
 {
     parent::MailForm();
     global $cgi;
     $this->parseSettings('inc/app/sitetemplate/forms/edit/settings.php');
     if (@file_exists('inc/app/xed/lib/Widget/Linker.php')) {
         $this->link_chooser = true;
     }
     list($set, $tpl) = explode('/', $cgi->path);
     list($mode, $name, $ext) = preg_split('|\\.|', basename($cgi->path));
     if (@file_exists('inc/html/' . $set . '/config.ini.php')) {
         $info = parse_ini_file('inc/html/' . $set . '/config.ini.php');
         if (isset($info['set_name'])) {
             $sname = $info['set_name'];
         } else {
             $sname = $set;
         }
     } else {
         $sname = $set;
     }
     session_set('imagechooser_path', site_prefix() . '/inc/html/' . $set . '/pix');
     page_title(intl_get('Editing Template') . ': ' . $sname . ' / ' . strtoupper($mode) . ' / ' . ucfirst($name));
     $set = str_replace('/' . $mode . '.' . $name . '.' . $ext, '', $cgi->path);
     $this->widgets['edit_buttons']->data = array('mode' => strtoupper($mode), 'name' => ucfirst($name), 'link_chooser' => $this->link_chooser);
     $this->widgets['body']->setValue(join('', file('inc/html/' . $cgi->path)));
     $this->widgets['submit_buttons']->data = array('set' => $set);
 }
示例#19
0
 function DevtoolsTplForm()
 {
     parent::MailForm();
     $this->parseSettings('inc/app/devtools/forms/tpl/settings.php');
     page_title(intl_get('Create a New Template Set'));
     $this->widgets['submit_button']->buttons[1]->extra = 'onclick="window.location.href = \'' . site_prefix() . '/index/devtools-app\'; return false"';
 }
示例#20
0
    function SitepresenterAddForm()
    {
        parent::MailForm();
        global $page, $cgi;
        $this->parseSettings('inc/app/sitepresenter/forms/add/settings.php');
        page_title(intl_get('Adding Presentation'));
        loader_import('ext.phpsniff');
        $sniffer = new phpSniff();
        $this->_browser = $sniffer->property('browser');
        // include formhelp, edit panel init, and cancel handler
        page_add_script(site_prefix() . '/js/formhelp.js');
        page_add_script(CMS_JS_FORMHELP_INIT);
        page_onload('cms_init_edit_panels ()');
        page_add_script('
			function cms_cancel (f) {
				if (arguments.length == 0) {
					window.location.href = "/index/cms-app";
				} else {
					if (f.elements["_return"] && f.elements["_return"].value.length > 0) {
						window.location.href = f.elements["_return"].value;
					} else {
						window.location.href = "/index/sitepresenter-app";
					}
				}
				return false;
			}
		');
        // add cancel handler
        $this->widgets['submit_button']->buttons[1]->extra = 'onclick="return cms_cancel (this.form)"';
    }
示例#21
0
 function SiteblogCommentForm()
 {
     parent::MailForm();
     global $cgi;
     $this->parseSettings('inc/app/siteblog/forms/comment/settings.php');
     if (isset($cgi->_key) && !empty($cgi->_key)) {
         //edit a comment
         page_title('Editing Comment');
         $comment = db_single('select * from siteblog_comment where id = ?', $cgi->_key);
         $this->widgets['name']->setValue($comment->author);
         $this->widgets['email']->setValue($comment->email);
         $this->widgets['url']->setValue($comment->url);
         $this->widgets['body']->setValue($comment->body);
     } elseif (!isset($cgi->post)) {
         header('Location: ' . site_prefix() . '/index');
         exit;
     } else {
         if (session_valid()) {
             $this->widgets['name']->setValue(session_username());
             $user = session_get_user();
             $this->widgets['email']->setValue($user->email);
             $this->widgets['url']->setValue($user->website);
         }
         $this->widgets['post']->setValue($cgi->post);
         //page_title ('Post a Comment');
     }
     if (!appconf('comments_security')) {
         unset($this->widgets['security_test']);
     }
 }
示例#22
0
 function ComposeForm()
 {
     parent::MailForm();
     $t =& $this->addWidget('hidden', 'response_id');
     $t =& $this->addWidget('text', 'subject');
     $t->alt = intl_get('Subject');
     $t->addRule('not empty', intl_get('You must enter a subject line.'));
     $t->attr('size', 50);
     $t =& $this->addWidget('cms.Widget.Recipients', 'recipients');
     $t->alt = intl_get('Send To');
     $t->addRule('not empty', intl_get('You must enter at least one recipient.'));
     $t =& $this->addWidget('select', 'priority');
     $t->setValues(array('normal' => intl_get('Normal'), 'high' => intl_get('High'), 'urgent' => intl_get('Urgent')));
     $t->alt = intl_get('Priority');
     $t =& $this->addWidget('xed.Widget.Xeditor', 'body');
     $this->extra = 'onsubmit="xed_copy_value (this, \'body\')"';
     $t->addRule('not empty', intl_get('You must enter a message to be sent.'));
     $t =& $this->addWidget('msubmit', 'submit_button');
     $b =& $t->getButton();
     $b->setValues(intl_get('Send'));
     $b->extra = 'onclick="cms_recipient_select_all (this.form)"';
     $b =& $t->addButton('cancel_button');
     $b->setValues(intl_get('Cancel'));
     $b->extra = 'onclick="window.location.href = \'' . site_prefix() . '/index/cms-cpanel-action\'; return false"';
     $this->error_mode = 'all';
 }
示例#23
0
 function RealtyAddForm()
 {
     parent::MailForm();
     $w =& $this->addWidget('hidden', 'collection');
     $w =& $this->addWidget('hidden', '_return');
     global $cgi;
     loader_import('cms.Versioning.Rex');
     $rex = new Rex($cgi->collection);
     $widgets = $rex->getStruct();
     if (!$widgets) {
         die($rex->error);
     }
     $this->widgets = array_merge($this->widgets, $widgets);
     foreach (array_keys($this->widgets) as $k) {
         if (strtolower(get_class($this->widgets[$k])) == 'mf_widget_xeditor') {
             $this->extra = 'onsubmit="xed_copy_value (this, \'' . $k . '\')"';
         }
     }
     if (isset($rex->info['Collection']['singular'])) {
         page_title(intl_get('Adding') . ' ' . $rex->info['Collection']['singular']);
     } else {
         page_title(intl_get('Adding Item'));
     }
     $w =& $this->addWidget('msubmit', 'submit_button');
     $b =& $w->getButton();
     $b->setValues(intl_get('Create'));
     $b =& $w->addButton('submit_button', intl_get('Cancel'));
     $b->extra = 'onclick="return cms_cancel (this.form)"';
 }
示例#24
0
 function ExampleContactForm()
 {
     parent::MailForm();
     // load settings file
     $this->parseSettings('inc/app/example/forms/contact/settings.php');
     // set the page title
     page_title(intl_get('Contact Us'));
 }
示例#25
0
 function PetitionSignForm()
 {
     parent::MailForm(__FILE__);
     $this->action = site_prefix() . '/index/petition-sign-form';
     global $cgi;
     $this->widgets['id']->setValue($cgi->id);
     $this->widgets['submit_button']->setValues(intl_get('Submit now'));
 }
示例#26
0
 function SitewikiSettingsForm()
 {
     parent::MailForm(__FILE__);
     $settings = ini_parse('inc/app/sitewiki/conf/settings.php', false);
     foreach ($settings as $k => $v) {
         $this->widgets[$k]->setValue($v);
     }
 }
示例#27
0
 function SiteeventSubmissionsForm()
 {
     parent::MailForm();
     $this->parseSettings('inc/app/siteevent/forms/submissions/settings.php');
     page_title(intl_get('Submit An Event'));
     $this->widgets['date']->setValue(date('Y-m-d'));
     $this->widgets['loc_city']->setDefault(appconf('default_city'));
     $this->widgets['loc_province']->setDefault(appconf('default_province'));
     $this->widgets['loc_country']->setDefault(appconf('default_country'));
 }
示例#28
0
 function SitelliteExportForm()
 {
     parent::MailForm(__FILE__);
     $user = session_get_user();
     $groups = array('' => '- All -');
     foreach (db_pairs('select id, name from sitellite_form_type order by name asc') as $k => $v) {
         $groups[$k] = $v;
     }
     $this->widgets['group']->setValues($groups);
     page_title(intl_get('Export Contacts'));
 }
示例#29
0
 function SiteinvoiceEditClientForm()
 {
     parent::MailForm();
     $this->parseSettings('inc/app/siteinvoice/forms/edit/client/settings.php');
     global $cgi;
     page_title('SiteInvoice - Editing Client: ' . $cgi->id);
     $client = db_single('select * from siteinvoice_client where id = ?', $cgi->id);
     foreach (get_object_vars($client) as $k => $v) {
         $this->widgets[$k]->setValue($v);
     }
 }
示例#30
0
 function DeadlinesEditForm()
 {
     parent::MailForm();
     $this->parseSettings('inc/app/deadlines/forms/edit/settings.php');
     page_title('Deadlines - Edit Item');
     global $cgi;
     $res = db_single('select * from deadlines where id = ?', $cgi->id);
     foreach ((array) $res as $k => $v) {
         $this->widgets[$k]->setValue($v);
     }
 }