intval -> (int)

This commit is contained in:
Miles Lott 2003-12-20 18:26:24 +00:00
parent 5fc1996732
commit e51d3f26ab
5 changed files with 12 additions and 12 deletions

View File

@ -47,9 +47,9 @@
'lang_to_title' => lang('Select all %1 %2 for %3')
));
$start = intval(get_var('start',array('POST','GET'),0));
$start = (int)get_var('start',array('POST','GET'),0);
$filter = get_var('filter',array('POST','GET'),'none');
$cat_id = intval(get_var('cat_id',array('POST','GET'),0));
$cat_id = (int)get_var('cat_id',array('POST','GET'),0);
$query = get_var('query',array('POST','GET'));
$sort = get_var('sort',array('POST','GET'));
$order = get_var('order',array('POST','GET'));
@ -305,7 +305,7 @@
if ($inserted || $inserted === 0)
{
$GLOBALS['phpgw']->template->set_var('message','<b>'.
lang('%1 email addresses inserted',intval($_GET['inserted'])).'</b>');
lang('%1 email addresses inserted',(int)$_GET['inserted']).'</b>');
}
$GLOBALS['phpgw']->template->parse('out','addressbook_list_t',True);
$GLOBALS['phpgw']->template->p('out');

View File

@ -292,8 +292,8 @@
'name' => $this->db->f('app_name'),
'enabled' => True,
'status' => $this->db->f('app_enabled'),
'id' => intval($this->db->f('app_id')),
'order' => intval($this->db->f('app_order')),
'id' => (int)$this->db->f('app_id'),
'order' => (int)$this->db->f('app_order'),
'version' => $this->db->f('app_version')
);
}
@ -324,7 +324,7 @@
{
foreach($GLOBALS['phpgw_info']['apps'] as $appname => $app)
{
if(intval($app['id']) == intval($id))
if((int)$app['id'] == (int)$id)
{
return $appname;
}

View File

@ -135,7 +135,7 @@
{
$this->bocal = createobject('calendar.bocalendar');
}
if (!is_array($event) && (int) $event > 0)
if (!is_array($event) && (int)$event > 0)
{
$event = $this->bocal->read_entry($event);
}
@ -271,13 +271,13 @@
return $this->getId($name,$title,lang('Pattern for Search in Addressbook'),$id_name,$content,lang('use Button to search for Address'),$multiple);
}
function addr2email( $addr,$home='' )
function addr2email($addr,$home='')
{
if (!is_array($addr))
{
$home = substr($addr,-1) == 'h';
$contacts = createobject('phpgwapi.contacts');
list( $addr ) = $contacts->read_single_entry( intval($addr) );
list($addr) = $contacts->read_single_entry((int)$addr);
}
if ($home)
{

View File

@ -377,7 +377,7 @@
$_ver_str = @mysql_get_server_info();
$_ver_arr = explode(".",$_ver_str);
$_ver = $_ver_arr[1];
if(intval($_ver) < 23)
if((int)$_ver < 23)
{
$phpgw_baseline['lang']['fd']['message_id'] = array(
'type' => 'varchar',

View File

@ -377,7 +377,7 @@
$_ver_str = @mysql_get_server_info();
$_ver_arr = explode(".",$_ver_str);
$_ver = $_ver_arr[1];
if(intval($_ver) < 23)
if((int)$_ver < 23)
{
$GLOBALS['setup_info']['phpgwapi']['currentver'] = '0.9.13.016';
return $GLOBALS['setup_info']['phpgwapi']['currentver'];
@ -647,7 +647,7 @@
$GLOBALS['phpgw_setup']->oProc->query("SELECT * FROM old_preferences");
while ($GLOBALS['phpgw_setup']->oProc->next_record())
{
$owner = intval($GLOBALS['phpgw_setup']->oProc->f('preference_owner'));
$owner = (int)$GLOBALS['phpgw_setup']->oProc->f('preference_owner');
$prefs = unserialize($GLOBALS['phpgw_setup']->oProc->f('preference_value'));
if (is_array($prefs))