I have got a php script where people can add there birthday.
I wanne use this script in my forum because in my forum it is not possible to do that automatic.
The problem of this script is the way the results are showing
now the results are showing down under each other, example: ikke1 ikke2 ikke3
The problem is that is not nice in my forum. I wanne have the results in one line. Between the results there must be a ,,
example: ikke1, ikke2, ikke3
I also wanne start this line with:: todays birtday
example: todays birtday: ikke1, ikke2, ikke3
Last question: How can I change the lettersize of the results that are showing??
Till now I tried to do something by myself like changing the 100% in a lower size but I get a problem in my forum with that.
I hope there is somebody who wanne help me with making this changings in this script part.
/*
Get todays's birthday in three steps
Thanks to Leon Atkinson <leon@leonatkinson.com>
Created by Ridder Roeland
Part of BirthSys 2.0
*/
// First: set the current day
$date = date( "d" );
// Second: get the right month and translate to used monthnames in MySQL table
$currentMonth = date( "n" );
$monthName = array(1=> "01", "02", "03",
"04", "05", "06", "07", "08",
"09", "10", "11", "12");
$month=("$monthName[$currentMonth]");
// Third: get the value from the MySQL database and put in a nice table
?>
/*
Get todays's birthday in three steps
Thanks to Leon Atkinson <leon@leonatkinson.com>
Created by Ridder Roeland
Part of BirthSys 2.0
*/
// First: set the current day
$date = date( "d" );
// Second: get the right month and translate to used monthnames in MySQL table
$currentMonth = date( "n" );
$monthName = array(1=> "01", "02", "03",
"04", "05", "06", "07", "08",
"09", "10", "11", "12");
$month=("$monthName[$currentMonth]");
// Third: get the value from the MySQL database and put in a nice table
?>
i think that will work, basically, put the table stuff like <TD> outside where the results are printed.
What happening in your script theres a new row being made per result, you want them all in the one row.
i think that will work, basically, put the table stuff like <TD> outside where the results are printed.
What happening in your script theres a new row being made per result, you want them all in the one row.
yea it will probably work but.. no offense but few things here that didnt seem to fit imo. why use elseif when the only possibility after $result is false is that its false.. that is a compare that doesint need to be there.. and well.. why use table for one cell?? but anyways.. i like trying to optimize code for performance.. specially with easy ones
Thank you Perleo that works.
But where is the text when there is no birthday.
I put in now to testnames and that works but when there is nobody birthday the text is gone!!!!
I want to put this in my forum with an iframe, first i try to do that with include,
<?php include("http://www.kellystart.com/birthsys3php/date.php");?>
But people say when you wanne use include the server from the forum and the server from this script must be the same.
Is there another way???
I want to put it in my forum (http://50308.forum.onetwomax.de)
in the line: Welcome to our new member: sanclauds, Ho can I get the same lettersize as that text (also color black/blue black = today birtday, blue=names.
I hope there is somebody who wanne help me one more time.
/*
Get todays's birthday in three steps
Thanks to Leon Atkinson <leon@leonatkinson.com>
Created by Ridder Roeland
Part of BirthSys 2.0
*/
// First: set the current day
$date = date( "d" );
// Second: get the right month and translate to used monthnames in MySQL table
$currentMonth = date( "n" );
$monthName = array(1=> "01", "02", "03",
"04", "05", "06", "07", "08",
"09", "10", "11", "12");
$month=("$monthName[$currentMonth]");
// Third: get the value from the MySQL database and put in a nice table
?>
i also added the mysql_close() to close the connection to mysql for optimizie
now if theres no birthday it will print Sorry, no birthday's today
you can change it if you want but you get the gist.
<?Willie?>
i use
PHP Code:
elseif(!$result)
as a form as error checking really, we all have our different ways.
I dont know why theres a table in the script, keep it tidy I suppose.
I have put in the script part you said (Perleo) but still no text.
I have put it in my forum totaly on the end of the page. http://50308.forum.onetwomax.de/
Last question the lettersize is to big in stead of the rest of the forum how do I change that??