Skip to content

Commit

Permalink
Merge pull request #288 from marcosgdf/style
Browse files Browse the repository at this point in the history
Little refactor to img_phone function
  • Loading branch information
hregis committed Aug 3, 2012
2 parents 236dbb8 + d30b280 commit 65bb19d
Showing 1 changed file with 16 additions and 13 deletions.
29 changes: 16 additions & 13 deletions htdocs/core/lib/functions.lib.php
Expand Up @@ -2048,22 +2048,25 @@ function img_mime($file, $alt = '')
}


/**
/**
* Show phone logo.
* Use img_picto instead.
*
* @param string $alt Text to show on alt image
* @param int $option Option
*
* @param string $alt Text to show on alt image
* @param int $option Option
* @return string Return img tag
* @deprecated
*/
function img_phone($alt = "default",$option=0)
{
global $conf,$langs;
if ($alt=="default") $alt=$langs->trans("Call");
$img='call_out';
if ($option == 1) $img='call';
return '<img src="'.DOL_URL_ROOT.'/theme/'.$conf->theme.'/img/'.$img.'.png" border="0" alt="'.dol_escape_htmltag($alt).'" title="'.dol_escape_htmltag($alt).'">';
* @deprecated
*/
function img_phone($alt = 'default', $option = 0)
{
global $conf,$langs;

if ($alt == 'default') $alt = $langs->trans('Call');

if ($option == 1) $img = 'call';
else $img = 'call_out';

return img_picto($alt, $img);
}


Expand Down

0 comments on commit 65bb19d

Please sign in to comment.