Learn PHP knowing C++ [message #171702] |
Sun, 16 January 2011 21:35 |
Alexander
Messages: 4 Registered: December 2006
Karma: 0
|
Junior Member |
|
|
Hello. I know C++ well enough, and now I want to learn PHP. Is PHP
similar to C++ (not syntax, but concepts)? How difficult can it be?
Where should I start (after installing the server)? Thanks
|
|
|
Re: Learn PHP knowing C++ [message #171703 is a reply to message #171702] |
Sun, 16 January 2011 22:00 |
Bernd Schulz
Messages: 10 Registered: September 2010
Karma: 0
|
Junior Member |
|
|
Am 16.01.2011 22:35, schrieb Alexander:
> Hello. I know C++ well enough, and now I want to learn PHP. Is PHP
> similar to C++ (not syntax, but concepts)? How difficult can it be?
Yes.
Variables are more easy to use and no Memorymanagement.
> Where should I start (after installing the server)? Thanks
index.php:
<?PHP
echo "Hello world<br>";
?>
:-)
|
|
|
|
Re: Learn PHP knowing C++ [message #171706 is a reply to message #171703] |
Mon, 17 January 2011 03:23 |
The Natural Philosoph
Messages: 993 Registered: September 2010
Karma: 0
|
Senior Member |
|
|
Bernd Schulz wrote:
> Am 16.01.2011 22:35, schrieb Alexander:
>> Hello. I know C++ well enough, and now I want to learn PHP. Is PHP
>> similar to C++ (not syntax, but concepts)? How difficult can it be?
> Yes.
> Variables are more easy to use and no Memorymanagement.
Variables are harder to use because there is no typing that you can rely
on. Memory management is automatic so it will bite you one day.
Its interpreted so the order of things is important.
Variables are actually not declared, they are constructed.
>
>> Where should I start (after installing the server)? Thanks
> index.php:
> <?PHP
> echo "Hello world<br>";
> ?>
>
Juts pretend its C with $ in front of every variable till you get a
syntax error, then RTFM.
Read up the dot operator as well, and the way strings are handled and
their syntax: subtle differences.
> :-)
>
|
|
|
Re: Learn PHP knowing C++ [message #171707 is a reply to message #171706] |
Mon, 17 January 2011 09:19 |
Tim Streater
Messages: 328 Registered: September 2010
Karma: 0
|
Senior Member |
|
|
In article <ih0co7$6sv$1(at)news(dot)albasani(dot)net>,
The Natural Philosopher <tnp(at)invalid(dot)invalid> wrote:
> Bernd Schulz wrote:
>> Am 16.01.2011 22:35, schrieb Alexander:
>>> Hello. I know C++ well enough, and now I want to learn PHP. Is PHP
>>> similar to C++ (not syntax, but concepts)? How difficult can it be?
> on. Memory management is automatic so it will bite you one day.
In what way do you think memory management will bite you one day (apart
from the naive user, who, confronted with a 32kword IBM 7094, proceeded
to DIMENSION his FORTRAN array 1000x1000)?
--
Tim
"That excessive bail ought not to be required, nor excessive fines imposed,
nor cruel and unusual punishments inflicted" -- Bill of Rights 1689
|
|
|
Re: Learn PHP knowing C++ [message #171709 is a reply to message #171707] |
Mon, 17 January 2011 15:51 |
Goran
Messages: 38 Registered: January 2011
Karma: 0
|
Member |
|
|
On 17.1.2011 10:19, Tim Streater wrote:
> In article <ih0co7$6sv$1(at)news(dot)albasani(dot)net>,
> The Natural Philosopher <tnp(at)invalid(dot)invalid> wrote:
>
>> Bernd Schulz wrote:
>>> Am 16.01.2011 22:35, schrieb Alexander:
>>>> Hello. I know C++ well enough, and now I want to learn PHP. Is PHP
>>>> similar to C++ (not syntax, but concepts)? How difficult can it be?
>
>> on. Memory management is automatic so it will bite you one day.
>
> In what way do you think memory management will bite you one day (apart
> from the naive user, who, confronted with a 32kword IBM 7094, proceeded
> to DIMENSION his FORTRAN array 1000x1000)?
Like the man said, it will strike you one day...
|
|
|
Re: Learn PHP knowing C++ [message #171721 is a reply to message #171709] |
Tue, 18 January 2011 16:03 |
sheldonlg
Messages: 166 Registered: September 2010
Karma: 0
|
Senior Member |
|
|
On 1/17/2011 10:51 AM, Goran wrote:
> On 17.1.2011 10:19, Tim Streater wrote:
>> In article<ih0co7$6sv$1(at)news(dot)albasani(dot)net>,
>> The Natural Philosopher<tnp(at)invalid(dot)invalid> wrote:
>>
>>> Bernd Schulz wrote:
>>>> Am 16.01.2011 22:35, schrieb Alexander:
>>>> > Hello. I know C++ well enough, and now I want to learn PHP. Is PHP
>>>> > similar to C++ (not syntax, but concepts)? How difficult can it be?
>>
>>> on. Memory management is automatic so it will bite you one day.
>>
>> In what way do you think memory management will bite you one day (apart
>> from the naive user, who, confronted with a 32kword IBM 7094, proceeded
>> to DIMENSION his FORTRAN array 1000x1000)?
>
> Like the man said, it will strike you one day...
that didn't answer Tim's (an now my) specific question.
--
Shelly
|
|
|
|