Code: Select all
tag when posting PHP (and format you code) *****[/color]
Hi,
I have some problem with return... probably in logic - it returns only one data, instead of list.
Class goes like this:Code: Select all
Class someCs {
//Some code
// and also function that I customised in extendSomeCs below:
function getDateLink()
}
Class extendSomeCs extends someCs {
function getDateLink($day, $month, $year){
//now I read from database and return list of dates (e.g. $array='2009-03-04,2009-13-14';)
// in string format as three variables
//$day
//$month
//$year
// if correct date is then i set link to "#" and return it:
$link = "";
if ($day == $tmp2[0] && $month == $tmp2[1] && $year == $tmp2[2]) {
$link = "#";
}
return $link;
}
}I now that logic is wrong but... cant see straight in this moment!
Does someone has some idea?
Thanks in advance!