diff --git a/htdocs/core/class/html.formwebsite.class.php b/htdocs/core/class/html.formwebsite.class.php
index 12ec3e7f5ad..6bb4e1d25f5 100644
--- a/htdocs/core/class/html.formwebsite.class.php
+++ b/htdocs/core/class/html.formwebsite.class.php
@@ -263,12 +263,15 @@ class FormWebsite
foreach($website->lines as $key => $valpage)
{
+ $valueforoption = '['.$valpage->type_container.' '.sprintf("%03d", $valpage->id).'] ';
+ $valueforoption.= $valpage->pageurl.' - '.$valpage->title;
+ if ($website->fk_default_home && $key == $website->fk_default_home) $valueforoption.=' ('.$langs->trans("HomePage").')';
+
$out.='';
}
}
diff --git a/htdocs/website/index.php b/htdocs/website/index.php
index c08ad6375b1..e5e738ff02c 100644
--- a/htdocs/website/index.php
+++ b/htdocs/website/index.php
@@ -82,6 +82,8 @@ if (GETPOST('createpagefromclone', 'alpha')) { $action='createpagefromclone'; }
if (empty($action) && $file_manager) $action='file_manager';
if (empty($action) && $replacesite) $action='replacesite';
+if (GETPOST('refreshsite') || GETPOST('refreshsite_x') || GETPOST('refreshsite.x')) $pageid = 0;
+
// Load variable for pagination
$limit = GETPOST('limit', 'int')?GETPOST('limit', 'int'):$conf->liste_limit;
$sortfield = GETPOST("sortfield", 'alpha');
@@ -2372,18 +2374,19 @@ if (! GETPOST('hide_websitemenu'))
print '';
print '';
- // @TODO Move this action into a combo list
+ // Set page as homepage
if ($object->fk_default_home > 0 && $pageid == $object->fk_default_home)
{
//$disabled=' disabled="disabled"';
//print '';
- print '';
+ //print '';
+ print '';
}
else
{
//$disabled='';
- //print 'ref.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("SetAsHomePage")).'">';
- print '';
+ //print '';
+ print 'ref.'&pageid='.$pageid.'" class="button bordertransp"'.$disabled.' title="'.dol_escape_htmltag($langs->trans("SetAsHomePage")).'">';
}
print '';
print '';