Seite 3 von 5

Verfasst: 13.03.2003 00:43
von Candy
Dazu müsste ich doch nur (soweit ich das unter deinem geposteten link verstanden habe) das:

Code: Alles auswählen

$user_first_pc_from = $d_first_pc.$m_first_pc.$y_first_pc; 
damit ersetzen:

Code: Alles auswählen

$user_first_pc_from = strtotime($d_first_pc.$m_first_pc.$y_first_pc); 
Soweit richtig?Aber wie kann ich das dann "zerlegen" um es einzeln verfügbar zu machen?

Grüße Candy

Verfasst: 13.03.2003 17:34
von Candy
Hi,
hab was vergessen diesen teil:

Code: Alles auswählen

$s_d_first_pc = '<select name="d_first_pc" size="1" class="gensmall" size="1"> 
   <option value="0">-</option> 
   <option value="1">1</option> 
   <option value="2">2</option> 
   <option value="3">3</option> 
     </select>&nbsp;&nbsp;'; 
$s_d_first_pc = str_replace("value=\"".$user_first_pc_from."\">", "value=\"".$user_first_pc_from."\" SELECTED>" ,$s_d_first_pc); 

$s_m_first_pc = '<select name="m_first_pc" size="1" class="gensmall" size="1"> 
   <option value="0">-</option> 
   <option value="1">1</option> 
   <option value="2">2</option> 
   <option value="3">3</option> 
     </select>&nbsp;&nbsp;'; 
$s_m_first_pc = str_replace("value=\"".$user_first_pc_from."\">", "value=\"".$user_first_pc_from."\" SELECTED>" ,$s_m_first_pc); 

$s_y_first_pc = '<select name="y_first_pc" size="1" class="gensmall" size="1"> 
   <option value="0">-</option> 
   <option value="1">1</option> 
   <option value="2">2</option> 
   <option value="3">3</option> 
     </select>&nbsp;&nbsp;'; 
$s_y_first_pc = str_replace("value=\"".$user_first_pc_from."\">", "value=\"".$user_first_pc_from."\" SELECTED>" ,$s_y_first_pc); 
habe ich damit ersetzt:

Code: Alles auswählen

$s_d_first_pc = '<select name="d_first_pc" size="1" class="gensmall" size="1">
   <option value="0">&nbsp;-&nbsp;</option>
	<option value="01">&nbsp;1&nbsp;</option>
	<option value="02">&nbsp;2&nbsp;</option>
	<option value="03">&nbsp;3&nbsp;</option>
	<option value="04">&nbsp;4&nbsp;</option>
	<option value="05">&nbsp;5&nbsp;</option>
	<option value="06">&nbsp;6&nbsp;</option>
	<option value="07">&nbsp;7&nbsp;</option>
	<option value="08">&nbsp;8&nbsp;</option>
	<option value="09">&nbsp;9&nbsp;</option>
	<option value="10">&nbsp;10&nbsp;</option>
	<option value="11">&nbsp;11&nbsp;</option>
	<option value="12">&nbsp;12&nbsp;</option>
	<option value="13">&nbsp;13&nbsp;</option>
	<option value="14">&nbsp;14&nbsp;</option>
	<option value="15">&nbsp;15&nbsp;</option>
	<option value="16">&nbsp;16&nbsp;</option>
	<option value="17">&nbsp;17&nbsp;</option>
	<option value="18">&nbsp;18&nbsp;</option>
	<option value="19">&nbsp;19&nbsp;</option>
	<option value="20">&nbsp;20&nbsp;</option>
	<option value="21">&nbsp;21&nbsp;</option>
	<option value="22">&nbsp;22&nbsp;</option>
	<option value="23">&nbsp;23&nbsp;</option>
	<option value="24">&nbsp;24&nbsp;</option>
	<option value="25">&nbsp;25&nbsp;</option>
	<option value="26">&nbsp;26&nbsp;</option>
	<option value="27">&nbsp;27&nbsp;</option>
	<option value="28">&nbsp;28&nbsp;</option>
	<option value="29">&nbsp;29&nbsp;</option>
	<option value="30">&nbsp;30&nbsp;</option>
	<option value="31">&nbsp;31&nbsp;</option>
     </select>&nbsp;&nbsp;';
$s_d_first_pc = str_replace("value=\"".$user_first_pc_from."\">", "value=\"".$user_first_pc_from."\" SELECTED>" ,$s_d_first_pc);

$s_m_first_pc = '<select name="m_first_pc" size="1" class="gensmall" size="1">
    <option value="0">&nbsp;-&nbsp;</option>
<option value="01">&nbsp;January&nbsp;</option>
<option value="02">&nbsp;February&nbsp;</option>
<option value="03">&nbsp;March&nbsp;</option>
<option value="04">&nbsp;April&nbsp;</option>
<option value="05">&nbsp;May&nbsp;</option>
<option value="06">&nbsp;June&nbsp;</option>
<option value="07">&nbsp;July&nbsp;</option>
<option value="08">&nbsp;August&nbsp;</option>
<option value="09">&nbsp;September&nbsp;</option>
<option value="10">&nbsp;October&nbsp;</option>
<option value="11">&nbsp;November&nbsp;</option>
<option value="12">&nbsp;December&nbsp;</option>
     </select>&nbsp;&nbsp;';
$s_m_first_pc = str_replace("value=\"".$user_first_pc_from."\">", "value=\"".$user_first_pc_from."\" SELECTED>" ,$s_m_first_pc);

$s_y_first_pc = '<select name="y_first_pc" size="1" class="gensmall" size="1">
   <option value="0">-</option>
   <option value="2003">2003</option>
   <option value="2004">2004</option>
   <option value="2005">2005</option>
<option value="2006">2006</option>
<option value="2007">2007</option>
<option value="2008">2008</option>
<option value="2009">2009</option>
<option value="2010">2010</option>
     </select>&nbsp;&nbsp;';
$s_y_first_pc = str_replace("value=\"".$user_first_pc_from."\">", "value=\"".$user_first_pc_from."\" SELECTED>" ,$s_y_first_pc);
Grüße Candy

Verfasst: 14.03.2003 21:50
von Candy
Sonst wer ne idee die mir weiterhelfen könnte? :-? :cry:

Grüße Candy

Verfasst: 16.03.2003 02:09
von Candy
Also ich habe jetzt 2 tage lang alles probiert aber ohne erfolg wenn doch noch jemand ne idee hat bitte posten :x

Ca...

Verfasst: 16.03.2003 02:37
von Mister_X
:oops: hab das Thema hier gerade erst wieder in meinen *Links die du noch abgrasen musst* entdeckt

Suche

Code: Alles auswählen

$user_first_pc_from = $d_first_pc.$m_first_pc.$y_first_pc;
und ersetze dies mit

Code: Alles auswählen

$user_first_pc_from = strtotime ("$y_first_pc-$m_first_pc-$d_first_pc 00:00:00-0000");
Suche

Code: Alles auswählen

$s_d_first_pc = str_replace("value=\"".$user_first_pc_from."\">", "value=\"".$user_first_pc_from."\" SELECTED>" ,$s_d_first_pc);
und ersetze dies mit

Code: Alles auswählen

$s_d_first_pc = str_replace("value=\"".date("d","$user_first_pc_from")."\">", "value=\"".date("d","$user_first_pc_from")."\" SELECTED>" ,$s_d_first_pc);
Suche

Code: Alles auswählen

$s_m_first_pc = str_replace("value=\"".$user_first_pc_from."\">", "value=\"".$user_first_pc_from."\" SELECTED>" ,$s_m_first_pc);
und ersetze dies mit

Code: Alles auswählen

$s_m_first_pc = str_replace("value=\"".date("m","$user_first_pc_from")."\">", "value=\"".date("m","$user_first_pc_from")."\" SELECTED>" ,$s_m_first_pc);
Suche

Code: Alles auswählen

$s_y_first_pc = str_replace("value=\"".$user_first_pc_from."\">", "value=\"".$user_first_pc_from."\" SELECTED>" ,$s_y_first_pc);
und ersetze dies mit

Code: Alles auswählen

$s_y_first_pc = str_replace("value=\"".date("Y","$user_first_pc_from")."\">", "value=\"".date("Y","$user_first_pc_from")."\" SELECTED>" ,$s_y_first_pc);
Keine Funktionsgarantie, falls Fehler auftauchen bitte ein Link zu deiner *.php Datei (aber so dass ich mir den Quelltext anschauen kann) und die genaue Fehlermeldung.

Verfasst: 16.03.2003 18:31
von Candy
Funktioniert super danke dir aber ein kleines kosmetisches Problem ist aufgetreten und zwar wenn ich zum ersten mal die profileinstellungen aufrufe (also bevor ich ein Datum ausgewählt und gespeichert habe ist trotzdem schon 1 January ausgewählt nur bei Jahr ist - ausgewählt :o

Denke das es irgendwo an diesem teil liegt:

Code: Alles auswählen

$s_d_first_pc = '<select name="d_first_pc" size="1" class="gensmall" size="1">
   <option value="0">&nbsp;-&nbsp;</option>
	<option value="01">&nbsp;1&nbsp;</option>
	<option value="02">&nbsp;2&nbsp;</option>
	<option value="03">&nbsp;3&nbsp;</option>
	<option value="04">&nbsp;4&nbsp;</option>
	<option value="05">&nbsp;5&nbsp;</option>
	<option value="06">&nbsp;6&nbsp;</option>
	<option value="07">&nbsp;7&nbsp;</option>
	<option value="08">&nbsp;8&nbsp;</option>
	<option value="09">&nbsp;9&nbsp;</option>
	<option value="10">&nbsp;10&nbsp;</option>
	<option value="11">&nbsp;11&nbsp;</option>
	<option value="12">&nbsp;12&nbsp;</option>
	<option value="13">&nbsp;13&nbsp;</option>
	<option value="14">&nbsp;14&nbsp;</option>
	<option value="15">&nbsp;15&nbsp;</option>
	<option value="16">&nbsp;16&nbsp;</option>
	<option value="17">&nbsp;17&nbsp;</option>
	<option value="18">&nbsp;18&nbsp;</option>
	<option value="19">&nbsp;19&nbsp;</option>
	<option value="20">&nbsp;20&nbsp;</option>
	<option value="21">&nbsp;21&nbsp;</option>
	<option value="22">&nbsp;22&nbsp;</option>
	<option value="23">&nbsp;23&nbsp;</option>
	<option value="24">&nbsp;24&nbsp;</option>
	<option value="25">&nbsp;25&nbsp;</option>
	<option value="26">&nbsp;26&nbsp;</option>
	<option value="27">&nbsp;27&nbsp;</option>
	<option value="28">&nbsp;28&nbsp;</option>
	<option value="29">&nbsp;29&nbsp;</option>
	<option value="30">&nbsp;30&nbsp;</option>
	<option value="31">&nbsp;31&nbsp;</option>
     </select>&nbsp;&nbsp;';
$s_d_first_pc = str_replace("value=\"".date("d","$user_first_pc_from")."\">", "value=\"".date("d","$user_first_pc_from")."\" SELECTED>" ,$s_d_first_pc);

$s_m_first_pc = '<select name="m_first_pc" size="1" class="gensmall" size="1">
<option value="0">&nbsp;-&nbsp;</option>
<option value="01">&nbsp;January&nbsp;</option>
<option value="02">&nbsp;February&nbsp;</option>
<option value="03">&nbsp;March&nbsp;</option>
<option value="04">&nbsp;April&nbsp;</option>
<option value="05">&nbsp;May&nbsp;</option>
<option value="06">&nbsp;June&nbsp;</option>
<option value="07">&nbsp;July&nbsp;</option>
<option value="08">&nbsp;August&nbsp;</option>
<option value="09">&nbsp;September&nbsp;</option>
<option value="10">&nbsp;October&nbsp;</option>
<option value="11">&nbsp;November&nbsp;</option>
<option value="12">&nbsp;December&nbsp;</option>
     </select>&nbsp;&nbsp;';
$s_m_first_pc = str_replace("value=\"".date("m","$user_first_pc_from")."\">", "value=\"".date("m","$user_first_pc_from")."\" SELECTED>" ,$s_m_first_pc);

$s_y_first_pc = '<select name="y_first_pc" size="1" class="gensmall" size="1">
   <option value="0">&nbsp;-&nbsp;</option>
   <option value="2003">2003</option>
   <option value="2004">2004</option>
   <option value="2005">2005</option>
     </select>&nbsp;&nbsp;';
$s_y_first_pc = str_replace("value=\"".date("Y","$user_first_pc_from")."\">", "value=\"".date("Y","$user_first_pc_from")."\" SELECTED>" ,$s_y_first_pc);
hab aber keine ahnung wo genau hast du vieleicht ne idee?

Nochmal Big thx für deine Hilfe ich war schon am verzweifeln weil es einfach net laufen wollte :)

Grüße Candy

Verfasst: 16.03.2003 18:54
von Mister_X
nur testhalber:
probiere mal bei

Code: Alles auswählen

<option value="0">&nbsp;-&nbsp;</option>
aus der 0 ein 00 zu machen, genauso auch beim Monat.
(ich hab keine Ahnung ob es daran liegt, aber probiers mal aus :))

Verfasst: 17.03.2003 18:18
von Candy
Hi,
das habe ich auch schon probiert aber es ist trotzdem ausgewählt :-?

Grüße Candy

Verfasst: 17.03.2003 19:20
von esperitox
Gib doch bei der tabellenspalte in der db 0 als Standard vor dann sollte auch beim ersten mal - ausgewählt sein ;)

esperitox

Verfasst: 17.03.2003 19:30
von Candy
Danke dir aber das funktioniert leider auch nicht :( Hat vieleicht sonst noch jemand ne idee?

Edit: Mir ist da noch was aufgefallen wenn ich etwas ausgewählt habe, das gespeichert habe und dann zurück ins profil gehe ist alles korrekt wieder ausgewählt aber wenn ich in die Avatar Gallery gehe einen Avatar auswähle und auf "Avatar auswählen" klicke werde ich ja zurückgeleitet zu den profil einstellungen dann sind die Drop Downs aber wieder zurückgesetzt und ich muss alles Neu auswählen :o Ich habe schon probiert in der usercp_avatar.php bei function display_avatar_gallery( nach &$attachsig &$user_first_pc_from einzufügen aber das funkt auch nicht :cry:

Grüße Candy