diff --git a/htdocs/filefunc.inc.php b/htdocs/filefunc.inc.php
index a9357c6b8df..89d473db495 100755
--- a/htdocs/filefunc.inc.php
+++ b/htdocs/filefunc.inc.php
@@ -28,7 +28,7 @@
* \file htdocs/filefunc.inc.php
* \ingroup core
* \brief File that include conf.php file and functions.lib.php
- * \version $Id$
+ * \version $Id: filefunc.inc.php,v 1.16 2011/06/26 18:53:16 eldy Exp $
*/
define('DOL_VERSION','3.1.0-alpha'); // Also defined in htdocs/install/inc.php (Ex: x.y.z-alpha, x.y.z)
@@ -125,9 +125,9 @@ $real_dolibarr_main_document_root=str_replace('\\','/',realpath($dolibarr_main_d
$pathroot=$_SERVER["DOCUMENT_ROOT"];
$paths=explode('/',str_replace('\\','/',$_SERVER["SCRIPT_NAME"]));
$concatpath='';
-foreach($paths as $path)
+foreach($paths as $tmppath)
{
- if ($path) $concatpath.='/'.$path;
+ if ($tmppath) $concatpath.='/'.$tmppath;
//print $real_$dolibarr_main_document_root.'-'.realpath($pathroot.$concatpath).'
';
if ($real_dolibarr_main_document_root == realpath($pathroot.$concatpath))
{
diff --git a/htdocs/langs/en_US/members.lang b/htdocs/langs/en_US/members.lang
index cf0bb020a66..ada92b09834 100644
--- a/htdocs/langs/en_US/members.lang
+++ b/htdocs/langs/en_US/members.lang
@@ -76,6 +76,7 @@ EditMember=Edit member
SubscriptionEndDate=Subscription's end date
MembersTypeSetup=Members type setup
NewSubscription=New subscription
+NewSubscriptionDesc=This form allows you to record your subscription as a new member of the foundation. If you want to renew your subscription being already a member, please contact foundation board instead.
Subscription=Subscription
Subscriptions=Subscriptions
SubscriptionLate=Late
@@ -182,3 +183,4 @@ NewMemberForm=New member form
SubscriptionsStatistics=Statistics on subscriptions
NbOfSubscriptions=Number of subscriptions
AmountOfSubscriptions=Amount of subscriptions
+TurnoverOrBudget=Turnover (for a company) or Budget (for a foundation)
\ No newline at end of file
diff --git a/htdocs/langs/fr_FR/members.lang b/htdocs/langs/fr_FR/members.lang
index 75a4406ea45..82a83d39d36 100644
--- a/htdocs/langs/fr_FR/members.lang
+++ b/htdocs/langs/fr_FR/members.lang
@@ -77,6 +77,7 @@ EditMember=Édition adhérent
SubscriptionEndDate=Date de fin adhésion
MembersTypeSetup=Configuration des types d'adhérents
NewSubscription=Nouvelle adhésion
+NewSubscriptionDesc=Ce formulaire permet de vous enregistrer comme nouvel adhérent de l'association. Pour un renouvellement si vous êtes déjà adhérent, contacter plutôt l'association.
Subscription=Adhésion/cotisation
Subscriptions=Adhésions/cotisations
SubscriptionLate=En retard
@@ -182,4 +183,5 @@ NewMemberbyWeb=Nouvel Adherent ajoute. En attente de validation
NewMemberForm=Nouvel Adherent form
SubscriptionsStatistics=Statistiques sur les cotisations
NbOfSubscriptions=Nombre de cotisations
-AmountOfSubscriptions=Montant de cotisations
\ No newline at end of file
+AmountOfSubscriptions=Montant de cotisations
+TurnoverOrBudget=Chiffre affaire (pour société) ou Budget (asso ou collectivité)
\ No newline at end of file
diff --git a/htdocs/lib/company.lib.php b/htdocs/lib/company.lib.php
index e41af0b7c39..2f7ef32b660 100644
--- a/htdocs/lib/company.lib.php
+++ b/htdocs/lib/company.lib.php
@@ -24,7 +24,7 @@
* \file htdocs/lib/company.lib.php
* \brief Ensemble de fonctions de base pour le module societe
* \ingroup societe
- * \version $Id$
+ * \version $Id: company.lib.php,v 1.119 2011/06/26 18:53:16 eldy Exp $
*/
/**
@@ -208,7 +208,7 @@ function societe_admin_prepare_head($object)
/**
- * Return country translated from an id or a code
+ * Return country label, code or id from an id or a code
* @param id Id or code of country
* @param withcode 0=Return label, 1=Return code + label, 2=Return code from id
* @param dbtouse Database handler (using in global way may fail because of conflicts with some autoload features)
diff --git a/htdocs/public/members/new.php b/htdocs/public/members/new.php
index e216b11ad5c..0619c14342b 100644
--- a/htdocs/public/members/new.php
+++ b/htdocs/public/members/new.php
@@ -22,7 +22,7 @@
* \file htdocs/public/members/new.php
* \ingroup member
* \brief Example of form to add a new member
- * \version $Id$
+ * \version $Id: new.php,v 1.27 2011/06/26 18:54:23 eldy Exp $
*/
define("NOLOGIN",1); // This means this output page does not require to be logged.
@@ -32,6 +32,8 @@ require("../../main.inc.php");
require_once(DOL_DOCUMENT_ROOT."/adherents/class/adherent.class.php");
require_once(DOL_DOCUMENT_ROOT."/adherents/class/adherent_type.class.php");
require_once(DOL_DOCUMENT_ROOT."/core/class/extrafields.class.php");
+require_once(DOL_DOCUMENT_ROOT."/core/class/html.formcompany.class.php");
+require_once(DOL_DOCUMENT_ROOT."/lib/company.lib.php");
// Security check
if (empty($conf->adherent->enabled)) accessforbidden('',1,1,1);
@@ -43,176 +45,206 @@ $langs->load("companies");
$langs->load("install");
$langs->load("other");
+// Init vars
+$errmsg='';
+$num=0;
+$error=0;
+$backtopage=GETPOST('backtopage');
+$action=GETPOST('action');
+
+
// Function for page HTML header
-function llxHeaderVierge($title, $head = "")
+function llxHeaderVierge($title, $head="", $disablejs=0, $disablehead=0, $arrayofjs='', $arrayofcss='')
{
- global $user, $conf, $langs;
+ global $user, $conf, $langs, $mysoc;
+ top_htmlhead($head, $title, $disablejs, $disablehead, $arrayofjs, $arrayofcss); // Show html headers
+ print '