Re: Need someone with a fresh mind on tacking thisarrayproblem...
| From: | Lars Torben Wilson | Date: | Wed, 18 Jun 2003 18:57:18 +0000 |
| Subject: | Re: Need someone with a fresh mind on tacking thisarrayproblem... | ||
| References: | 1 2 3 4 5 6 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-152048@lists.php.net to get a copy of this message | ||
On Wed, 2003-06-18 at 11:45, Scott Fletcher wrote:
> Bingo!! I did some PHP re-arrangement and I also do what you were saying
> about taking out the quote. It doesn't work with the quote inside and it
> work without the quote. What so interesting is that the year is actually a
> string so I figured that putting it in a sting will work, but I guess not...
>
> Thanks,
> Scott
Glad to hear it works! The reason the variable was not being
interpreted is that it was single-quoted, not double-quoted; variables
are only interpolated inside double-quoted strings (and heredocs, but
that's another story). You could also have replaced the single-quotes
with double quotes, but it would be pointless and isn't recommended.
For more information, check out:
http://www.php.net/manual/en/language.types.string.php
And:
http://www.php.net/manual/en/language.types.array.php
I have just done some fairly hefty work on this last page; however, it
won't appear online until the next time the manual is generated.
Good luck,
Torben
--
Torben Wilson <torben@php.net> +1.604.709.0506
http://www.thebuttlesschaps.com http://www.inflatableeye.com
http://www.hybrid17.com http://www.themainonmain.com
-----==== Boycott Starbucks! http://www.haidabuckscafe.com ====-----