IdentifiantMot de passe
Loading...
Mot de passe oublié ?Je m'inscris ! (gratuit)
Navigation

Inscrivez-vous gratuitement
pour pouvoir participer, suivre les réponses en temps réel, voter pour les messages, poser vos propres questions et recevoir la newsletter

Langage PHP Discussion :

Affichage de 00x et eading Zéro [PHP 5.2]


Sujet :

Langage PHP

  1. #1
    Débutant Avatar de ETVigan
    Homme Profil pro
    Conseil - Consultant en systèmes d'information
    Inscrit en
    Avril 2010
    Messages
    660
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Gard (Languedoc Roussillon)

    Informations professionnelles :
    Activité : Conseil - Consultant en systèmes d'information
    Secteur : Finance

    Informations forums :
    Inscription : Avril 2010
    Messages : 660
    Points : 170
    Points
    170
    Par défaut Affichage de 00x et eading Zéro
    Bonjour,

    J'ai un souci dans l'affichage de zone qui contiennent des "leading" zero !

    Voici mon log.php et les parties importantes en gras....

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    PHP Notice:  display(2) => Date de naissance[20101112] in F:\WebSites\checkform\class\validation\date.php on line 125
    PHP Stack trace:
    PHP   1. {main}() F:\WebSites\checkform\index.php:0
    PHP   2. setScreen->execute() F:\WebSites\checkform\index.php:15
    PHP   3. Skeleton->execute() F:\WebSites\checkform\class\setScreen.php:154
    PHP   4. Skeleton->displayPage() F:\WebSites\checkform\class\newSkelt.php:313
    PHP   5. require_once() F:\WebSites\checkform\class\newSkelt.php:394
    PHP   6. require_once() F:\WebSites\checkform\config\myPage.php:181
    PHP   7. require_once() F:\WebSites\checkform\doc\do_index.php:79
    PHP   8. Date->display() F:\WebSites\checkform\config\formdef.php:123
    PHP   9. user_error() F:\WebSites\checkform\class\validation\date.php:125
    PHP Notice:  POST SUBMIT CATCHED in F:\WebSites\checkform\doc\do_index.php on line 58
    PHP Stack trace:
    PHP   1. {main}() F:\WebSites\checkform\index.php:0
    PHP   2. setScreen->execute() F:\WebSites\checkform\index.php:15
    PHP   3. Skeleton->execute() F:\WebSites\checkform\class\setScreen.php:154
    PHP   4. Skeleton->displayPage() F:\WebSites\checkform\class\newSkelt.php:313
    PHP   5. require_once() F:\WebSites\checkform\class\newSkelt.php:394
    PHP   6. require_once() F:\WebSites\checkform\config\myPage.php:181
    PHP   7. user_error() F:\WebSites\checkform\doc\do_index.php:58
    PHP Notice:  ===>getFormContent  in F:\WebSites\checkform\class\validate.php on line 376
    PHP Stack trace:
    PHP   1. {main}() F:\WebSites\checkform\index.php:0
    PHP   2. setScreen->execute() F:\WebSites\checkform\index.php:15
    PHP   3. Skeleton->execute() F:\WebSites\checkform\class\setScreen.php:154
    PHP   4. Skeleton->displayPage() F:\WebSites\checkform\class\newSkelt.php:313
    PHP   5. require_once() F:\WebSites\checkform\class\newSkelt.php:394
    PHP   6. require_once() F:\WebSites\checkform\config\myPage.php:181
    PHP   7. Form->getFormContent() F:\WebSites\checkform\doc\do_index.php:62
    PHP   8. user_error() F:\WebSites\checkform\class\validate.php:376
    PHP Notice:  ===>getFieldValue[   0 0 0] in F:\WebSites\checkform\class\validation\date.php on line 153
    PHP Stack trace:
    PHP   1. {main}() F:\WebSites\checkform\index.php:0
    PHP   2. setScreen->execute() F:\WebSites\checkform\index.php:15
    PHP   3. Skeleton->execute() F:\WebSites\checkform\class\setScreen.php:154
    PHP   4. Skeleton->displayPage() F:\WebSites\checkform\class\newSkelt.php:313
    PHP   5. require_once() F:\WebSites\checkform\class\newSkelt.php:394
    PHP   6. require_once() F:\WebSites\checkform\config\myPage.php:181
    PHP   7. Form->getFormContent() F:\WebSites\checkform\doc\do_index.php:62
    PHP   8. Date->getFieldValue() F:\WebSites\checkform\class\validate.php:383
    PHP   9. user_error() F:\WebSites\checkform\class\validation\date.php:153
    PHP Notice:  getFieldValue => Date de naissance[   0 0 0] in F:\WebSites\checkform\class\validation\date.php on line 159
    PHP Stack trace:
    PHP   1. {main}() F:\WebSites\checkform\index.php:0
    PHP   2. setScreen->execute() F:\WebSites\checkform\index.php:15
    PHP   3. Skeleton->execute() F:\WebSites\checkform\class\setScreen.php:154
    PHP   4. Skeleton->displayPage() F:\WebSites\checkform\class\newSkelt.php:313
    PHP   5. require_once() F:\WebSites\checkform\class\newSkelt.php:394
    PHP   6. require_once() F:\WebSites\checkform\config\myPage.php:181
    PHP   7. Form->getFormContent() F:\WebSites\checkform\doc\do_index.php:62
    PHP   8. Date->getFieldValue() F:\WebSites\checkform\class\validate.php:383
    PHP   9. user_error() F:\WebSites\checkform\class\validation\date.php:159
    PHP Notice:  ***** >SUBMIT Catched in F:\WebSites\checkform\doc\do_index.php on line 64
    PHP Stack trace:
    PHP   1. {main}() F:\WebSites\checkform\index.php:0
    PHP   2. setScreen->execute() F:\WebSites\checkform\index.php:15
    PHP   3. Skeleton->execute() F:\WebSites\checkform\class\setScreen.php:154
    PHP   4. Skeleton->displayPage() F:\WebSites\checkform\class\newSkelt.php:313
    PHP   5. require_once() F:\WebSites\checkform\class\newSkelt.php:394
    PHP   6. require_once() F:\WebSites\checkform\config\myPage.php:181
    PHP   7. user_error() F:\WebSites\checkform\doc\do_index.php:64
    PHP Notice:  display(2) => Date de naissance[1992 519] in F:\WebSites\checkform\class\validation\date.php on line 125
    PHP Stack trace:
    PHP   1. {main}() F:\WebSites\checkform\index.php:0
    PHP   2. setScreen->execute() F:\WebSites\checkform\index.php:15
    PHP   3. Skeleton->execute() F:\WebSites\checkform\class\setScreen.php:154
    PHP   4. Skeleton->displayPage() F:\WebSites\checkform\class\newSkelt.php:313
    PHP   5. require_once() F:\WebSites\checkform\class\newSkelt.php:394
    PHP   6. require_once() F:\WebSites\checkform\config\myPage.php:181
    PHP   7. require_once() F:\WebSites\checkform\doc\do_index.php:79
    PHP   8. Date->display() F:\WebSites\checkform\config\formdef.php:123
    PHP   9. user_error() F:\WebSites\checkform\class\validation\date.php:125
    J'ai essayé une fonction écrite par moi même,

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
     
    /**
    *	fill
    *	====
    */
    	function fill($str,$len)
    	{	//user_error("==> fill[".$str."]  <= [".strlen($str)."] < [".$len."]",E_USER_NOTICE) ;
    		for ($i = 0 ; strlen($str) < $len ; $i++)
    		{	//user_error("+" , E_USER_NOTICE) ;
    			$str = "0" . $str ;
    		}
    		//user_error("==> fill[".$str."] - [".$len."]",E_USER_NOTICE) ;
    		return($str) ;
    	}
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    preg_replace ($zone, " ", "0")
     
    str_replace(" ", "0",$zone)
     
    et une 4 ième dont je ne me souviens plus du nom, dsl.... ;)
    et toujours le même résultat.....

    Ma hiérarche de classe est la suivante: Kernet => Form => Date/String....

    Je vous mets un bout de "date" ici car il semble que ce soit la seule qui présente ce problème:

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    28
    29
    30
    31
    32
    33
    34
    35
    36
    37
    38
    39
    40
    41
    42
    43
    44
    45
    46
    47
    48
    49
    50
    51
    52
    53
    54
    55
    56
    57
    58
    59
    60
    61
    62
    63
    64
    65
    66
    67
    68
    69
    70
    71
    72
    73
    74
    75
    76
    77
    78
    79
    80
    81
    82
    83
    84
    85
    86
    87
    88
    89
    90
    91
    92
    93
    94
    95
    96
    97
    98
    99
    100
    101
    102
    103
    104
    105
    106
    107
    108
    109
    110
    111
    112
    113
    114
    115
    116
    117
    118
    119
    120
    121
    122
    123
    124
    125
    126
    127
    128
    129
    130
    131
    132
    133
    134
    135
    136
    137
    138
    139
    140
    141
    142
    143
    144
    145
    146
    147
    148
    149
    150
    151
    152
    153
    	function __construct($name, $must, $legend, $default, $debug=false)
    	{	$this->name   = $name ;
    		$this->must   = $must ;
    		$this->legend = $legend ;
    		$this->value  = (isset( $_POST["$this->name"] ) ) ? trim($_POST["$this->name"]) : NULL ;
    		$this->debug  = $debug ;
    
    		if (isset($default))
    			switch($default) 
    			{	case TODAY 	:	$this->date = date("Ymd") ; 
    								break ;
    								
    				default		: 	user_error("Invalid Date default", E_USER_ERROR) ;
    								break ;
    			}		
    		else
    			$this->date = date("Ymd") ; 
    // ==================================================================	20101109
    /*
    		$this->yy	= $this->fill(substr($this->date,0,4),4) ;		//	========
    		$this->mm	= $this->fill(substr($this->date,4,2),2) ;  	//	01234567	
    		$this->dd	= $this->fill(substr($this->date,6,2),2) ;  	// 	yyyymmdd
    
    		if ($this->debug)
    			var_dump("===> CONSTRUCT DATE =>: ",$this->date) ;
    */
    	}
    	
    	function __destruct()
    	{	}
    	
    	function execute()
    	{		}
    
    /**
    *	validate
    *	========
    */
    	function validate()
    	{	return( checkdate($this->fill($this->mm,2), $this->fill($this->dd,2),  $this->fill($this->yy,4) )  ? OK : ERRDATE) ;  }
    	
    /**
    *	pickup
    *	=======
    *
    */	
    	function pickup($start,$end,$len,$frmfld,$default)
    	{	echo "<select name='" . $frmfld . "' id='" . $frmfld . "'>\n";
    		for ($i = $start ; $i <= $end ; $i++)
    		{	$d = $this->fill($i,$len) ;
     			if (strcmp($default,$d) == 0)
    				echo '  <option value="' . $d . '" selected">' . $d. "</option>\n" ;
    			else
    				echo '  <option value="' . $d .           '">' . $d . "</option>\n" ;
    		}
    		echo "</select>\n" ;
    	}
    /**
    *	select
    *	=======
    *
    */	
    	function select($valarray,$frmfld,$default)
    	{	echo "<select name='" . $frmfld . "' id='" . $frmfld . "'>\n";
    		foreach ($valarray as $key => $value)
    		{	if (strcmp($default,$key) == 0)
    				echo '  <option value="' . $key . '" selected">' . $value . "</option>\n" ;
    			else
    				echo '  <option value="' . $key .           '">' . $value . "</option>\n" ;
    		}
    		echo "</select>\n" ;
    	}
    	
    /**
    *	display
    *	=======
    *
    */	
    	function display()
    	{	$this->dd = (isset($_POST["dd"])) ? $_POST["dd"] : date("d") ;
    		$this->mm = (isset($_POST["mm"])) ? $_POST["mm"] : date("m") ;  // format interne
    		$this->yy = (isset($_POST["yy"])) ? $_POST["yy"] : date("Y") ; 
    		
    //if ($this->debug)
    		var_dump("display(0) : => " ,$this->mm,$this->dd,$this->yy) ;
    	
    		echo "<fieldset><legend  class='form_lbl'>" ;
    		echo $this->legend ;
    		echo "</legend>" ;
    		echo '<span class="form_fld fieldset">' ;
    		$this->pickup(1,31,2, $name="dd",$default=$this->dd) ;
    		echo '</span>' ;    	
    		echo '<span class="form_bkg fieldset">' ;
    		echo "-" ;
    		echo '</span>' ;    	
    		echo '<span class="form_fld fieldset">'  ;
    		$this->select($this->month, $name="mm",$default=$this->mm) ; //array_search($this->mm, $this->month)) ;
    		echo '</span>' ;    	
    		echo '<span class="form_bkg">' ;
    		echo "-" ;
    		echo '</span>' ;    	
    		echo '<span class="form_fld">'  ;
    		$this->pickup(1920,2020,4, $name="yy",$default=$this->yy) ;
    		echo '</span>' ;    	
    		echo "</fieldset>" ;
    
    		$this->yy = (isset($_POST["yy"])) ? $_POST["yy"] : date("Y") ;		
    		$this->mm = (isset($_POST["mm"])) ? $_POST["mm"] : date("m") ;	  // format interne	
    		$this->dd = (isset($_POST["dd"])) ? $_POST["dd"] : date("d") ;		
     
    //if ($this->debug)
    	{	var_dump("display(1) => Date de naissance: ",$this->mm,$this->dd,$this->yy ) ;
    		$this->value = sprintf("%4d%2d%2d",$this->yy, $this->mm, $this->fill($this->dd,2)) ;
    		user_error("display(2) => Date de naissance[".$this->value."]", E_USER_NOTICE) ;
    	}
    	
    	}
    /**
    *	getFieldName
    *	============
    *
    */	
    	function getFieldName()
    	{	return($this->name) ; }
    	
    /**
    *	getFieldLegend
    *	==============
    *
    */	
    	function getFieldLegend()
    	{	return($this->legend) ; }
    	
    /**
    *	getFieldValue
    *	=============
    *
    */	
    	function getFieldValue()
    	{	//var_dump("getFieldValue => Date de naissance: ",$this->mm,$this->dd,$this->yy ) ;
    		$date = sprintf("%4d%2d%2d",$this->yy, $this->mm, $this->dd) ;  								//  20101109
    		user_error("===>getFieldValue[".$date."]", E_USER_NOTICE) ;
    																												//  ====--==
    																										//	0123456789
    	
    //if ($this->debug)
    	{	var_dump("getFieldValue => Date de naissance[",$this->mm,$this->dd,$this->yy,"]") ;
    		user_error("getFieldValue => Date de naissance[".$date."]", E_USER_NOTICE) ;
    	}
    	
    		return( $date ) ; 
    	}
    }
    Espérons que je vais trouver parmis vous :

  2. #2
    Expert éminent
    Avatar de Séb.
    Profil pro
    Inscrit en
    Mars 2005
    Messages
    5 200
    Détails du profil
    Informations personnelles :
    Âge : 46
    Localisation : France

    Informations professionnelles :
    Secteur : High Tech - Opérateur de télécommunications

    Informations forums :
    Inscription : Mars 2005
    Messages : 5 200
    Points : 8 425
    Points
    8 425
    Billets dans le blog
    17
    Par défaut
    Salut !
    Quel est le pb précisément ?
    Qu'obtiens-tu ? Que voudrais-tu obtenir ?
    A+

  3. #3
    Débutant Avatar de ETVigan
    Homme Profil pro
    Conseil - Consultant en systèmes d'information
    Inscrit en
    Avril 2010
    Messages
    660
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Gard (Languedoc Roussillon)

    Informations professionnelles :
    Activité : Conseil - Consultant en systèmes d'information
    Secteur : Finance

    Informations forums :
    Inscription : Avril 2010
    Messages : 660
    Points : 170
    Points
    170
    Par défaut Problème de classe Date
    Slt, J'obtiens 2010 2 1 pour le 2 jan 2010.

    J'ai essayé par x méthodes - masi pas la bonne sans doute - d'obtenir 20100102

    Voilà, merci Séb de ton aide

  4. #4
    Expert éminent
    Avatar de Séb.
    Profil pro
    Inscrit en
    Mars 2005
    Messages
    5 200
    Détails du profil
    Informations personnelles :
    Âge : 46
    Localisation : France

    Informations professionnelles :
    Secteur : High Tech - Opérateur de télécommunications

    Informations forums :
    Inscription : Mars 2005
    Messages : 5 200
    Points : 8 425
    Points
    8 425
    Billets dans le blog
    17
    Par défaut
    Pas tout lu car bcp de lignes, mais déjà ici je pressens un souci :

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    $date = sprintf("%4d%2d%2d",$this->yy, $this->mm, $this->dd);
    Je ne suis pas sûr que le chiffre après le % soit significatif avec un type d.
    Remplace les %d par %s, si tu veux forcer un padding avec 0 sur 2 caractères fais par exemple %02s.

  5. #5
    Débutant Avatar de ETVigan
    Homme Profil pro
    Conseil - Consultant en systèmes d'information
    Inscrit en
    Avril 2010
    Messages
    660
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Gard (Languedoc Roussillon)

    Informations professionnelles :
    Activité : Conseil - Consultant en systèmes d'information
    Secteur : Finance

    Informations forums :
    Inscription : Avril 2010
    Messages : 660
    Points : 170
    Points
    170
    Par défaut Problème de classe Date
    Cest con mais cela fonctionne.... Date de naissance[19920502]

    Merci Seb....

  6. #6
    Débutant Avatar de ETVigan
    Homme Profil pro
    Conseil - Consultant en systèmes d'information
    Inscrit en
    Avril 2010
    Messages
    660
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Gard (Languedoc Roussillon)

    Informations professionnelles :
    Activité : Conseil - Consultant en systèmes d'information
    Secteur : Finance

    Informations forums :
    Inscription : Avril 2010
    Messages : 660
    Points : 170
    Points
    170
    Par défaut Problème de classe Date
    Sèb,

    Dans le même ordre d'idée.... pourquoi le code ci-dessous me donne:

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    	function getFieldValue()
    	{	$date = sprintf("%04s%02s%02s",$this->yy, $this->mm, $this->dd) ;  								 
    		user_error("===>getFieldValue[".$date."]", E_USER_NOTICE) ;										 
    		return( $date ) ; 
    	}
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
     
    Notice:  ===>getFieldValue[00000000]
    Ce qui est loin de ce qui est recherché !

    ce qui fonctionne:
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
     
    $this->value = sprintf("%04s%02s%02s",$this->yy, $this->mm, $this->dd) ;
    et ce qui ne fonctionne pas....
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    $date = sprintf("%04s%02s%02s",$this->yy, $this->mm, $this->dd)
    ;

    Merci

  7. #7
    Débutant Avatar de ETVigan
    Homme Profil pro
    Conseil - Consultant en systèmes d'information
    Inscrit en
    Avril 2010
    Messages
    660
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Gard (Languedoc Roussillon)

    Informations professionnelles :
    Activité : Conseil - Consultant en systèmes d'information
    Secteur : Finance

    Informations forums :
    Inscription : Avril 2010
    Messages : 660
    Points : 170
    Points
    170
    Par défaut Problème de classe Date
    Sèb,

    Il y a comme une erreur de séquence dans ma classe que je ne pige pas !

    La méthode getFieldValue est appelée par la une propriété de la classe Form au moment de l'affichage de celle-ci par des balises PHP qui parsème ma forme en HTML.
    Je t'explique:

    HTML
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
        <td colspan="3" align="left">
        	<?php
    			echo $email->display() ;
    		?>    </td>
    qui fait appel au code PHP:
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    $email 	  		= new Email    (  "email"  		,  	MUST	, 	"Votre adressse Courrielle"			,	Mail 	, 8		, 30 		) 
     
    et à celui-ci
     
    /**
    * 	getFormContent 
    *	==============
    */	
    	function getFormContent()
    	{ 	$content = array() ;
    		user_error("===>getFormContent " , E_USER_NOTICE) ;
    		foreach ($this->form as $key => $value)
    		{	$this->class = get_class($this->form[$key]) ;
    			if (in_array($this->class,$this->firstLevel))
    				{	$this->field 	= $this->form[$key] ;
    					$this->name  	= $this->form[$key]->getFieldName()   ;
    					$this->legend  	= $this->form[$key]->getFieldLegend() ;
    					$this->value 	= $this->form[$key]->getFieldValue()  ;
    					$content[$this->name] = array($this->class,$this->legend,$this->value) ;
    				}
    		}
    		return($content) ;
    	}
    Qui en finalité fait appel à la classe string/email/etc....

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    19
    20
    21
    22
    23
    24
    25
    26
    27
    /**
    *	getFieldName
    *	============
    *
    */	
    	function getFieldName()
    	{	return($this->name) ; }
     
    /**
    *	getFieldLegend
    *	==============
    *
    */	
    	function getFieldLegend()
    	{	return($this->legend) ; }
     
    /**
    *	getFieldValue
    *	=============
    *
    */	
    	function getFieldValue()
    	{	$date = sprintf("%04s%02s%02s",$this->yy, $this->mm, $this->dd) ;  								 
    		user_error("===>getFieldValue[".$date."]", E_USER_NOTICE) ;										 
    		return( $date ) ; 
    	}
    }
    Cela fait pas mal d'appels en cascade mais c'est cela OOP, non ?

    Et bien, il semble sue dd, mm et yy sont == à 0 !
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
     
    otice:  ===>getFieldValueS[00000000]XX in F:\WebSites\checkform\class\validation\date.php on line 145
    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
    5
    	function getFieldValue()
    	{	$date = sprintf("%04s%02s%02s",$this->yy, $this->mm, $this->dd) ;  								 
    145==>		user_error("===>getFieldValueS[".$date."]" . $this->yy . "XX" . $this->dd, E_USER_NOTICE) ;										 
    		return( $date ) ; 
    	}
    Fichiers attachés Fichiers attachés

  8. #8
    Expert éminent
    Avatar de Séb.
    Profil pro
    Inscrit en
    Mars 2005
    Messages
    5 200
    Détails du profil
    Informations personnelles :
    Âge : 46
    Localisation : France

    Informations professionnelles :
    Secteur : High Tech - Opérateur de télécommunications

    Informations forums :
    Inscription : Mars 2005
    Messages : 5 200
    Points : 8 425
    Points
    8 425
    Billets dans le blog
    17
    Par défaut
    Dans le même ordre d'idée.... pkoi le code ci-dessous me donne:
    Je ne sais pas.
    Faudrait voir les valeurs de $this->yy|mm|dd et ce que tu fais de $this->value.

  9. #9
    Expert éminent
    Avatar de Séb.
    Profil pro
    Inscrit en
    Mars 2005
    Messages
    5 200
    Détails du profil
    Informations personnelles :
    Âge : 46
    Localisation : France

    Informations professionnelles :
    Secteur : High Tech - Opérateur de télécommunications

    Informations forums :
    Inscription : Mars 2005
    Messages : 5 200
    Points : 8 425
    Points
    8 425
    Billets dans le blog
    17
    Par défaut
    Cela fait pas mal d'appels en cascade mais c'est cela OOP, non ?
    Je ne vois rien de choquant, d'un autre côté je ne sais pas ce que tu veux faire exactement.
    Je jeterai un oeil tout à l'heure sur tes scripts.

  10. #10
    Débutant Avatar de ETVigan
    Homme Profil pro
    Conseil - Consultant en systèmes d'information
    Inscrit en
    Avril 2010
    Messages
    660
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Gard (Languedoc Roussillon)

    Informations professionnelles :
    Activité : Conseil - Consultant en systèmes d'information
    Secteur : Finance

    Informations forums :
    Inscription : Avril 2010
    Messages : 660
    Points : 170
    Points
    170
    Par défaut Problème de classe Date
    Merci Séb

    Demain je ne peux être là....

    Pas avant dimanche mais ce sera sans doute pour lundi.

  11. #11
    Débutant Avatar de ETVigan
    Homme Profil pro
    Conseil - Consultant en systèmes d'information
    Inscrit en
    Avril 2010
    Messages
    660
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Gard (Languedoc Roussillon)

    Informations professionnelles :
    Activité : Conseil - Consultant en systèmes d'information
    Secteur : Finance

    Informations forums :
    Inscription : Avril 2010
    Messages : 660
    Points : 170
    Points
    170
    Par défaut Problème de classe Date
    Sèb,
    je m'y remets après quelques jours d'interruption !

    As-tu eu l'occasion de regarder mes scripts?

    Je te rappelle le pb:

    Code : Sélectionner tout - Visualiser dans une fenêtre à part
    1
    2
    3
    4
     
    Si j'affiche la date Ok dans la forme, quand je la submits, 
    c'est la date du jour que je reçois....
    S'il te manque qlqchose, fais le moi savoir mais je ne crois pas....
    Merci d'avance

  12. #12
    Débutant Avatar de ETVigan
    Homme Profil pro
    Conseil - Consultant en systèmes d'information
    Inscrit en
    Avril 2010
    Messages
    660
    Détails du profil
    Informations personnelles :
    Sexe : Homme
    Localisation : France, Gard (Languedoc Roussillon)

    Informations professionnelles :
    Activité : Conseil - Consultant en systèmes d'information
    Secteur : Finance

    Informations forums :
    Inscription : Avril 2010
    Messages : 660
    Points : 170
    Points
    170
    Par défaut Problème de classe Date
    Problème de classe DATE non résolu, je vais m'y prendre autrement.

    Merci à tous

+ Répondre à la discussion
Cette discussion est résolue.

Discussions similaires

  1. [CardLayout] Remise à zéro des inputs à l'affichage d'un Panel
    Par L0007 dans le forum Agents de placement/Fenêtres
    Réponses: 2
    Dernier message: 04/06/2008, 17h02
  2. Affichage des zéros inutiles
    Par bmasimo dans le forum Langage SQL
    Réponses: 9
    Dernier message: 15/04/2008, 12h58
  3. Affichage d'un chiffre avec zéros significatifs
    Par Trebor_ dans le forum Langage
    Réponses: 2
    Dernier message: 24/03/2008, 09h55
  4. Réponses: 4
    Dernier message: 06/11/2007, 21h47
  5. Affichage des zéros d'une date dans une légende
    Par grutfruh dans le forum Macros et VBA Excel
    Réponses: 4
    Dernier message: 04/08/2007, 11h05

Partager

Partager
  • Envoyer la discussion sur Viadeo
  • Envoyer la discussion sur Twitter
  • Envoyer la discussion sur Google
  • Envoyer la discussion sur Facebook
  • Envoyer la discussion sur Digg
  • Envoyer la discussion sur Delicious
  • Envoyer la discussion sur MySpace
  • Envoyer la discussion sur Yahoo