@ -385,7 +385,7 @@ if ($action == 'edit' || $action == 'updateedit')
|
||||
}
|
||||
else
|
||||
{
|
||||
print '<img height="30" src="'.DOL_URL_ROOT.'/theme/common/nophoto.jpg">';
|
||||
print '<img height="30" src="'.DOL_URL_ROOT.'/public/theme/common/nophoto.jpg">';
|
||||
}
|
||||
print '</td></tr></table>';
|
||||
print '</td></tr>';
|
||||
|
||||
@ -5122,19 +5122,22 @@ class Form
|
||||
}
|
||||
else
|
||||
{
|
||||
$nophoto='/theme/common/nophoto.jpg';
|
||||
$nophoto='/public/theme/common/nophoto.jpg';
|
||||
if (in_array($modulepart,array('userphoto','contact'))) // For module thar are "physical" users
|
||||
{
|
||||
$nophoto='/theme/common/user_anonymous.png';
|
||||
if ($object->gender == 'man') $nophoto='/theme/common/user_man.png';
|
||||
if ($object->gender == 'woman') $nophoto='/theme/common/user_woman.png';
|
||||
$nophoto='/public/theme/common/user_anonymous.png';
|
||||
if ($object->gender == 'man') $nophoto='/public/theme/common/user_man.png';
|
||||
if ($object->gender == 'woman') $nophoto='/public/theme/common/user_woman.png';
|
||||
}
|
||||
|
||||
if (! empty($conf->gravatar->enabled) && $email)
|
||||
{
|
||||
/**
|
||||
* @see https://gravatar.com/site/implement/images/php/
|
||||
*/
|
||||
global $dolibarr_main_url_root;
|
||||
$ret.='<!-- Put link to gravatar -->';
|
||||
$ret.='<img class="photo'.$modulepart.'" alt="Photo found on Gravatar" title="Photo Gravatar.com - email '.$email.'" border="0"'.($width?' width="'.$width.'"':'').($height?' height="'.$height.'"':'').' src="http://www.gravatar.com/avatar/'.dol_hash($email,3).'?s='.$width.'&d='.urlencode(dol_buildpath($nophoto,2)).'">'; // gravatar need md5 hash
|
||||
$ret.='<img class="photo'.$modulepart.'" alt="Gravatar avatar" title="'.$email.' Gravatar avatar" border="0"'.($width?' width="'.$width.'"':'').($height?' height="'.$height.'"':'').' src="https://www.gravatar.com/avatar/'.dol_hash(strtolower(trim($email)),3).'?s='.$width.'&d='.urlencode(dol_buildpath($nophoto,2)).'">'; // gravatar need md5 hash
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
29
htdocs/public/theme/common/index.php
Normal file
@ -0,0 +1,29 @@
|
||||
<?php
|
||||
/* Copyright (C) 2009 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2015 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
/**
|
||||
* \file htdocs/public/theme/common/index.php
|
||||
* \ingroup core
|
||||
* \brief A redirect page to an error
|
||||
* \author Laurent Destailleur
|
||||
*/
|
||||
|
||||
require '../../../master.inc.php';
|
||||
|
||||
header("Location: ".DOL_URL_ROOT.'/public/error-404.php');
|
||||
|
||||
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 16 KiB After Width: | Height: | Size: 16 KiB |
|
Before Width: | Height: | Size: 19 KiB After Width: | Height: | Size: 19 KiB |
|
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 24 KiB |
29
htdocs/public/theme/index.php
Normal file
@ -0,0 +1,29 @@
|
||||
<?php
|
||||
/* Copyright (C) 2009 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2015 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
/**
|
||||
* \file htdocs/public/theme/index.php
|
||||
* \ingroup core
|
||||
* \brief A redirect page to an error
|
||||
* \author Laurent Destailleur
|
||||
*/
|
||||
|
||||
require '../../master.inc.php';
|
||||
|
||||
header("Location: ".DOL_URL_ROOT.'/public/error-404.php');
|
||||
|
||||
@ -173,7 +173,7 @@ else // Open and return file
|
||||
// This test is to avoid error images when image is not available (for example thumbs).
|
||||
if (! dol_is_file($original_file))
|
||||
{
|
||||
$original_file=DOL_DOCUMENT_ROOT.'/theme/common/nophoto.jpg';
|
||||
$original_file=DOL_DOCUMENT_ROOT.'/public/theme/common/nophoto.jpg';
|
||||
/*$error='Error: File '.$_GET["file"].' does not exists or filesystems permissions are not allowed';
|
||||
dol_print_error(0,$error);
|
||||
print $error;
|
||||
|
||||