FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » using same variable twice on same page
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: using same variable twice on same page [message #171310 is a reply to message #171270] Thu, 30 December 2010 09:24 Go to previous messageGo to previous message
The Natural Philosoph is currently offline  The Natural Philosoph
Messages: 993
Registered: September 2010
Karma:
Senior Member
Captain Paralytic wrote:
> On Dec 29, 10:53 pm, Tim Streater <timstrea...@waitrose.com> wrote:
>> In article <yzhlacpa809x....@evanplatt.sux>,
>>
>> richard <mem...@newsguy.com> wrote:
>>> Everything I have looked at so far talks of how to use one variable ONCE!
>>> Nothing I've seen even comes to close as to how to utilize the same
>>> variable in a different location on the same page.
>>> for instance:
>>> initial value of $year="1960"
>>> <div> <?php echo $year;?></div>
>>> <div> blah blah blah </div>
>>> <div> yada yada yada </div>
>>> Assume here we change $year to be "1961"
>>> <div> <?php if ($year="1961") echo $year; ?></div>
>> You have a typo in the line above.
> Not according to Richard. He says that it is php.net that is wrong. He
> can type whatever he likes. If the manual doesn't say that what he
> typed is correct, it is the manual's fault.

Took me over a day when I first tried to write assembler, to realise
that the (paper) manual had indented the code, but that the assembler
refused to accept any line beginning with white space and silently
ignored them.

I assumed from the manual, the white space was a necessary thing to
include...

This being 1982 or thereabouts, and the first micro anyone I knew had
ever seen, who could one ask?
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: AND in the if statement
Next Topic: login script using file, not mysql
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Tue Nov 26 06:06:59 GMT 2024

Total time taken to generate the page: 0.04770 seconds