looking at the manual, getdate() is meant to be passed a unix time stamp,
so, you'll need to use strtotime() first thus:
$utime = strtotime(30-Nov-1971);
$dob = getdate($utime);
$dobnum = $dob['yday'];
print $dobnum;
Notice I changed the format of the date, when I tried using the original
Hi list,
I have PHP code to insert the result of a form into mysql. When I nedd to
made an update, I pass an id in the url and use it to make the update
query. The problem is after I click in the update button (input submit) my
page refresh and came back in the same state, to see the changes I
Hi =)
is it possible to pass a javascript array to php ???
thanks.
On Tue, 13 Nov 2001 19:53:48 -0300, fitiux wrote:
Hi =)
is it possible to pass a javascript array to php ???
by the time javascript comes into play, php has already done it's job
and left the building. If you mean can javascript pass variables to a
new request for php to handle, then sure.
try adding the nocache header() calls to the page to force the broswer to
refresh.
See how that goes
Martin T
-Original Message-
From: Rodrigo Peres [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 9:43 AM
To: PHP
Subject: [PHP] silly question
Hi list,
I have PHP code to
Sorry all, just to add a little info, the inpu hidden i've mentioned in the
other message is made if exist the id in the url!! it isn't all the time
there :-)
thks again
Rodrigo
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional
Hi =)
is it possible to pass a javascript array to php ???
by the time javascript comes into play, php has already done it's job
and left the building. If you mean can javascript pass variables to a
new request for php to handle, then sure.
Thanks for your reply. =)
I have a little
serialise the array and make the value of a hidden field this value.
Then in PHP unserialise it.
-Original Message-
From: fitiux [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 10:18 AM
To: PHP General
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] javascript to php ???
Hi
On Tue, 13 Nov 2001 20:17:32 -0300, fitiux wrote:
Hi =)
is it possible to pass a javascript array to php ???
by the time javascript comes into play, php has already done it's
job
and left the building. If you mean can javascript pass variables
to a
new request for php to handle, then
On Wed, 14 Nov 2001 10:16:42 +1100, Martin Towell wrote:
serialise the array and make the value of a hidden field this
value.
Then in PHP unserialise it.
that would work great if it were a php array, but I believe we're
talking about javascript arrays here. :)
-Original Message-
From:
Can anybody tell me if there is a way to build an array or some other
means of collecting the attributes from the Start Element Handler so I
can return them back to my main application?
Thanks for any help,
-Mike
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL
Why, sure!
In your FORM tag, use ACTION=test.php.
You can send your JavaScript variable as part of the form, in a hidden form
field such as INPUT TYPE=hidden VALUE=myValue. The value of the variable
will be available the next time test.php shows up as $myValue. You can
then manipulate it
That's why I put quotes around the words - obviously a function would be
need to be written to do the serialising and a corresponding php function
to retrieve the values and place them into an array again.
-Original Message-
From: Mark [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November
Thanks to all for help me..
=)
I hope to help someone soon.
--Patricio.
On Wed, 14 Nov 2001 07:21, Robert Miller wrote:
This problem took a while to figure out. I'm posting the solution so
that = other's may find this example. If you know of a better way,
please reply. =
:-)
Cheers,
Rob
Problem: Generate Future Dates:
Sub-Problem: Future Dates are
Hello,
Michael Harris wrote:
Can anybody tell me if there is a way to build an array or some other
means of collecting the attributes from the Start Element Handler so I
can return them back to my main application?
Maybe you would like to try this class that does exactly what you need.
Hi gang,
Any one tried to send mail through PHP using mail() through an smtp server
which requires authentication ?
Regards
R'twick
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the
Hi,
I've been happily using mysql_connect() for various scripts on a linux
box. Now I'd like to connect to a filemaker pro database using
odbc_connect(). However, the response I get is Call to undefined
function.
Do I need to compile odbc support? (I thought it was built in.)
Is there an
I have tried to implement your code Martin, and I do thank you VERY MUCH
for the help, but your code seems to have the same trouble as mine, it
doesn't matter what date I start with, I end up with 364 as the day of
the year, I am on win32 though I don't know if that matters.
Here is what I
Ok, I figured out that just using echo seems to be the best way to do this
under PHP. In ASP, you can end your code block and start in with HTML, but
I couldn't get that to work with PHP. However, I was able to just use the
echo statement to get the conditional HTML I wanted to show up when the
On Wed, 14 Nov 2001 10:51, Johannes Ambrose wrote:
Hi,
I've been happily using mysql_connect() for various scripts on a linux
box. Now I'd like to connect to a filemaker pro database using
odbc_connect(). However, the response I get is Call to undefined
function.
Do I need to compile odbc
On Wed, 14 Nov 2001 11:43, Brad Melendy wrote:
Ok, I figured out that just using echo seems to be the best way to do
this under PHP. In ASP, you can end your code block and start in with
HTML, but I couldn't get that to work with PHP. However, I was able to
just use the echo statement to
David's correct. The reason it wasn't working for you is that you didn't put
braces around the code you wanted executed in the if statement. Also, to
output large chunks of html in a simple manner with variables included, look
into here docs. They look like this:
echoEOF
This is html with a
On Tue, 13 Nov 2001 22:28, PACKER, Steffan wrote:
Thanks but I am still having problems, $DOCUMENT_ROOT does not seem to
work(I am using an NT4 server), I cannot use an absolute path as the
content management software that is running has a tendency to strip
them out!
It seems (to me) that
On Wed, 14 Nov 2001 04:26, Raymond wrote:
Hi!
I'm trying to send a mail with password to the new user of my website,
but . Does anyone know how to put the variable inside my mail?
I have tried this:
--
else {
// sende kundeopplysninger til databasen
$db
Take care to be sure that you make the update, before the rest of the
page loads, things happen in order, so it's almost like creating your
page backwards (I just had that problem).
I can elaborate if you like.
(C:
[EMAIL PROTECTED] wrote:
Hi list,
I have PHP code to insert the result of a
I am not going to mention which host I'm using for obvious reasons.
However, I'm wondering if it is just a mis-configuration, or if it is a
weakness in php.
With this host, you initially have the same database password to the MySQL
database as you do to the account. It is wise to change both,
This is what safe_mode addresses.
On Tue, 13 Nov 2001, Michael A. Peters wrote:
I am not going to mention which host I'm using for obvious reasons.
However, I'm wondering if it is just a mis-configuration, or if it is a
weakness in php.
With this host, you initially have the same
Hi gang,
Any one tried to send mail through PHP using mail() through an smtp server
which requires authentication ?
http://www.phpguru.org/scripts/10/
--
Richard Heyes
If you have any trouble sounding condescending,
find a Unix user to show you how it's done. - Scott Adams
--
PHP General
I'm running on WinNT4 w/ PHP 4.0.6 and the code I supplied came back with
333
and for today I get 317
dunno why you're getting 364
anyone, any eye-dears ??
-Original Message-
From: sundogcurt [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 12:14 PM
To: GENERAL PHP LIST
But what about the session? It get's registered... doesn't sessions also
need to send header information?
it gets registered... it just doesn't persist...
At 17:07 12/11/01 -0800, you wrote:
Your problem probably is including the miec.php from the .shtml
document. Does the .shtml document send
Sorry about asking a non-PHP question here, but I thought that since I've
been helping others recently, you'll give me a bit of lee-way.
In IE, to find out how far down a page is scrolled, you can do
document.body.scrollTop
what's the equivalent in Netscape 6 ?
Thanks in advance
Martin
I have a php script sending newsletter to a mailing list time by time,
but some emails are no longer exist, so I need to remove them manually.
Can php detect whether an email address is a valid one, then remove it
from the list automatically? no matter before or after the newsletter
has sent.
You can set the Error-To: header to some email address that runs a script
to remove the email address - other that that, no, not that I know of.
-Original Message-
From: Alex Chau [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 1:31 PM
To: [EMAIL PROTECTED]
Subject: [PHP]
Tyler Longren wrote:
Here's something interesting though. There's an id field that's set to
AUTO_INCREMENT.
Yep, and that's one thing I've been looking at. See, I find it strange
that you need an KEY idpass (id, passcode(245)) when the ID is
quaranteed to be unique in itself.
Funny...
OK, just found it!
window.pageYOffset
-Original Message-
From: Martin Towell [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 1:25 PM
To: [EMAIL PROTECTED]
Subject: [PHP] Non-PHP question
Sorry about asking a non-PHP question here, but I thought that since I've
been
Well, well. They got around the USMail fraud problem so this now only
violates several dozen laws.
-Original Message-
From: Saint [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, November 13, 2001 1:24 AM
To: [EMAIL PROTECTED]
Subject: [PHP] It doesn't cost you anything, why not try it!
Michael Hall wrote:
can't figure out how I'm going to maintain a session across the three
seperate HTML files in the frameset.
You don't! PHP and your browser will do it for you. It doesn't matter
whether you're in frames or not. All that matters is the cookie that is
automagically generated
Ah, OK. So I need to complain that their php is not compiled with the
--with-safe_mode option.
Thanks!
On Tue, 13 Nov 2001 18:09:41 -0800 (PST)
Rasmus Lerdorf [EMAIL PROTECTED] wrote:
This is what safe_mode addresses.
On Tue, 13 Nov 2001, Michael A. Peters wrote:
I am not going to
That or open_basedir. Both can be configured in the php.ini file. It's
not a compile-time thing.
-Rasmus
On Tue, 13 Nov 2001, Michael A. Peters wrote:
Ah, OK. So I need to complain that their php is not compiled with the
--with-safe_mode option.
Thanks!
On Tue, 13 Nov 2001 18:09:41
Do something like this:
function parseXML($xmlFile)
{
$theParser = xml_parser_create();
xml_set_element_handler($theParser, startElementHandler,
endElementHandler);
//parse your XML here
return $attributeArray;
}
function startElementHandler($theParser,
Oops, forgot a line:
On Tuesday, November 13, 2001, at 08:58 PM, Ben Gollmer wrote:
Do something like this:
function parseXML($xmlFile)
{
global $attributeArray;
$theParser = xml_parser_create();
xml_set_element_handler($theParser, startElementHandler,
Your login.php uses the POST method to send the username and password to
main.php. In general this is a good idea, because you do not want someone's
password available from the URL. If you used the GET method you would not
have a problem with the page expiring, but the password would be
Martin, are ya out there? Does anyone know anything about sessions? (An
post reply would be handy :)
I am using session_register. I have:
http://www.collegesherbrooke.qc.ca/languesmodernes/postcard/index.html
http://www.collegesherbrooke.qc.ca/languesmodernes/postcard/index.html.phps
Which
Ahh...
and the winner is empty().
Thanks Christian for this elusive answer and everyone else for their input.
Spunk
I need to check variables for blank values but it appears that is_null and
== return true if there is a space.
Any other suggestions?
Thanks
--
PHP General
In am HTML form, checkboxes NOT checked are not passed
to the PHP script called by the form.
Therefore, if $name_of_chechbox_3 is not passed but it's
used in the PHP script, it results in Warning:
Undefined Variable.
How can I avoid this?
Thanks!
A. F. Rodriguez
([EMAIL PROTECTED])
--
use : @$name_of_chechbox_3 to suppress warnings
or at the start of the file do :
if (!isset($name_of_chechbox_3)) $name_of_chechbox_3 = ;
or something similar
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 5:03 PM
To: [EMAIL
Hello,
Does anyone know of a way, that from within a function, you can determine
what line number and file the function was called on?
I did try:
function myfunc($lineno = __LINE__)
{
echo $lineno;
}
but this just outputted the very line that __LINE__ resides on.
This would be very
your error reporting must be set to E_ALL.
a very simple way is:
$checkbox_3 = isset($checkbox_3);
Now, $checkbox_3 will be either TRUE or FALSE with no errors!
-Jason Garber
IonZoft.com
At 06:03 AM 11/14/2001 +, [EMAIL PROTECTED] wrote:
In am HTML form, checkboxes NOT checked are not
define it :-))
boolean name_of_chechbox_3;
for example
J
[EMAIL PROTECTED] ha scritto nel messaggio
news:[EMAIL PROTECTED]
.net...
In am HTML form, checkboxes NOT checked are not passed
to the PHP script called by the form.
Therefore, if $name_of_chechbox_3 is not passed but it's
used in
I agree :-))
J
Jimmy Elab [EMAIL PROTECTED] ha scritto nel messaggio
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Michael Hall wrote:
can't figure out how I'm going to maintain a session across the three
seperate HTML files in the frameset.
You don't! PHP and your browser will do it for
get the mx record:
function checkmail ($mailtocheck) {
if (eregi(^[_\.0-9a-z-]+@([0-9a-z][-0-9a-z\.]+)\.([a-z]{2,3}$),
$mailtocheck, $check))
{
if (getmxrr($check[1]...$check[2],$temp))
{
return true;
}
return false; // kein mx gefunden
}
else
{
return false; // syntax fehler
}
}
Martin
You can do it like:
1) Have php send the email with a particulare return reply so that wrong
email addresses get sent back to it
2) Configure procmail to launch a php script when an email is received on
that account (the return one)
3) Write the php script (SCRIPT NOT WEB) to parse the email
I guess that is not possible with PHP yet.
Jason G. [EMAIL PROTECTED] wrote in message
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Hello,
Does anyone know of a way, that from within a function, you can determine
what line number and file the function was called on?
I did try:
function
101 - 154 of 154 matches
Mail list logo