php-general Digest 3 Oct 2008 14:32:33 -0000 Issue 5716
Topics (messages 281414 through 281421):
date_default_timezone_set and Time Zones
281414 by: Waynn Lue
281415 by: Per Jessen
281419 by: Waynn Lue
a link in php generated mail
281416 by: Sjef
281417 by: Richard Heyes
281418 by: Per Jessen
Create DLL of PHP class
281420 by: Manoj Singh
Re: SESSION array problems
281421 by: Nathan Rixham
Administrivia:
To subscribe to the digest, e-mail:
[EMAIL PROTECTED]
To unsubscribe from the digest, e-mail:
[EMAIL PROTECTED]
To post to the list, e-mail:
[EMAIL PROTECTED]
----------------------------------------------------------------------
--- Begin Message ---
I'm using date_default_timezone_set("America/Los_Angeles") in my code, then
I output it like
date("m/d/y, H:i:s, O", <some unix timestamp>);
But even though it's daylight savings time in Los Angeles, I get output like
[01/31/08, 23:00:00, -0800]
Shouldn't it instead be -0700? Am I misunderstanding how these timezones
work?
Waynn
--- End Message ---
--- Begin Message ---
Waynn Lue wrote:
> I'm using date_default_timezone_set("America/Los_Angeles") in my code,
> then I output it like
>
> date("m/d/y, H:i:s, O", <some unix timestamp>);
>
> But even though it's daylight savings time in Los Angeles, I get
> output like
>
> [01/31/08, 23:00:00, -0800]
>
> Shouldn't it instead be -0700? Am I misunderstanding how these
> timezones work?
Is it daylight savings time in LA on 31 January?
/Per Jessen, Zürich
--- End Message ---
--- Begin Message ---
>
> Is it daylight savings time in LA on 31 January?
>
Wow, yeah. That makes sense, for some reason I was thinking of it in terms
of today, but of course that can't be right. Thanks for that clarification,
not sure what I was thinking. :)
--- End Message ---
--- Begin Message ---
Hallo,
I have an link in a php generated email that does not work. I tried adding
http:// but with no result. It says the link is blocked. I created the mail
with html formatting.
I use pear email. Is there anything I have to consider to make this work?
Thanks, Sjef
--- End Message ---
--- Begin Message ---
> I have an link in a php generated email that does not work. I tried adding
> http:// but with no result. It says the link is blocked. I created the mail
> with html formatting.
> I use pear email. Is there anything I have to consider to make this work?
Set the content type of the email to text/html. You can then treat the
body as a simple HTML document. The exact header would be:
Content-Type: text/html
My advice would be however, to leave it as plain text and use simple
URLs in the body. Many email readers (GMail for example) will make
them clickable automatically.
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and Safari:
http://www.phpguru.org/RGraph
--- End Message ---
--- Begin Message ---
Sjef wrote:
> Hallo,
> I have an link in a php generated email that does not work. I tried
> adding http:// but with no result. It says the link is blocked. I
> created the mail with html formatting.
Who is "It" (in "It says the link is blocked.") and how does it say it
is blocked?
/Per Jessen, Zürich
--- End Message ---
--- Begin Message ---
Hello All,
I have the task to create DLL of PHP class.
Please advise how to do it.
Regards,
Manoj Kumar Singh
--- End Message ---
--- Begin Message ---
Micah Gersten wrote:
> You really should get up to speed on PHP 5.
Micah Gersten wrote:
I was referring to Nathan's examples which you cut out of the post.
function save_to_session( ) {
global $userids , $first , $last;
$_SESSION['user_id'] = &$userids;
$_SESSION['first_name'] = &$first;
$_SESSION['last_name']= &$last;
}
ahh I thought that but didn't want to assume; I am actually strictly
PHP5.2+/OO and flat out refuse to use globals (preference to static
class variables), and keep session usage to a minimum.
However the example I gave tedd was the only way in which I could create
code to replicate his error (explaining the passing a variable by
reference to session, the redefining of that referenced array as a
string within the for loop and so on).
This actually turned out to be register globals turned on; however it's
been so dang long since I used them, (and indeed anything pre-php5),
that I forget register globals even existed; thus replicated it's
functionality. [lol]
Regards!
--
nathan ( [EMAIL PROTECTED] )
{
Senior Web Developer
php + java + flex + xmpp + xml + ecmascript
web development edinburgh | http://kraya.co.uk/
}
--- End Message ---