使用class + php [英] working with classes + php

查看:61
本文介绍了使用class + php的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不熟悉上课。我几乎是一个自学成才的php

程序员,它主要用于数据库输入和列表。我会想要扩大我的才能并开始上课。在网上有一个好的

教程,新手可以理解。我目前想要在我的现有网页上添加一个密码生成器类,我的帮助台是
。该课程位于PHPclasses.com

(class.password.generator.php)。感谢您提供的任何帮助。


A

解决方案

5月15日,3:09 pm,Auddog < wil ... @ hotmail.comwrote:


我不熟悉上课。我几乎是一个自学成才的php

程序员,它主要用于数据库输入和列表。我会想要扩大我的才能并开始上课。在网上有一个好的

教程,新手可以理解。我目前想要在我的现有网页上添加一个密码生成器类,我的帮助台是
。该课程位于PHPclasses.com

(class.password.generator.php)。感谢您提供的任何帮助。


A



我认为学习PHP中的OOP会导致不良习惯。不同的方法有太多

。如果你从Java这样的语言中学习,那么你将会很好地理解它。 PHP5具有许多功能

Java OOP(不是全部都是这样)。


如果你没有太多的时间和我需要学习更多的学习OOP的实用方法,在PHP中使用它,

PHP手册是最准确的学习方法。< > http://php.net/oop


-Mike PII


我认为在PHP中学习OOP会导致坏习惯。有太多


不同的方法。如果你从Java这样的语言中学习,那么你将会很好地理解它。 PHP5具有许多

Java OOP的功能(尽管不是全部)。



相反。 Java也有很多不需要的特性,因为它是一种OO语言。我同意埃菲尔将是一个更好的起点,

但它仍然是抽象的,因为它很难使用。此外,PHP程序员

也经常需要学习javascript,因此你可以理解

基于类和基于模板的面向对象。


我认为坏习惯从一开始就是一件好事。作为如何学习OO编程的资源,我还建议重构。通过

Martin Fowler。那本书中的例子可以教给你很多好的理论书。


我认为PHP为你提供了轻轻发现

对象的优点。事实上,很多人只需要实现像PHPMailer或FPDF这样的组件的功能来提供像

代码重用这样的抽象词。一个坚定的机构。


最好的问候


Dikkie Dik写道:

< blockquote class =post_quotes>
>我认为在PHP中学习OOP会导致坏习惯。有太多不同的方法可以做到这一点。如果您从Java这样的语言中学习,那么您肯定会很好地理解它。 PHP5具有许多Java OOP的功能(但不是全部)。




相反。 Java也有很多不需要的特性,因为它是一种OO语言。我同意埃菲尔将是一个更好的起点,

但它仍然是抽象的,因为它很难使用。此外,PHP程序员

也经常需要学习javascript,因此你可以理解

基于类和基于模板的面向对象。


我认为坏习惯从一开始就是一件好事。作为如何学习OO编程的资源,我还建议重构。通过

Martin Fowler。那本书中的例子可以教给你很多好的理论书。


我认为PHP为你提供了轻轻发现

对象的优点。事实上,很多人只需要实现像PHPMailer或FPDF这样的组件的功能来提供像

代码重用这样的抽象词。一个坚定的机构。


最好的问候



我不知道什么是不想要的特征 java有一个OO语言。

这是一个纯粹的OO实现。我同意迈克的观点 - 我认为Java

是学习OO编程的一种更好的语言。


我发现了坏习惯 ;一旦你进入他们,非常努力

打破。我不知道我有多少次C ++程序员通过面向对象编程错误地启动了
,结果是一个可怕的混乱OO和非OO代码。


Smalltalk也是一种学习OO的好语言,但它并没有用于

网页编程。 />

-

==================

删除 X"来自我的电子邮件地址

Jerry Stuckle

JDS计算机培训公司
js ******* @ attglobal.net

==================

I''m new to working with classes. I''m pretty much a self taught php
programmer that uses php mostly for database entry and listings. I would
like to expand my talents and start working with classes. Is there a good
tutorial out there on the web that a novice can understand. I currently
wanting to add a password generator class to one of my existing webpages at
my helpdesk. The class is located at PHPclasses.com
(class.password.generator.php). Thanks for any help that you can give.

A

解决方案

On May 15, 3:09 pm, "Auddog" <wil...@hotmail.comwrote:

I''m new to working with classes. I''m pretty much a self taught php
programmer that uses php mostly for database entry and listings. I would
like to expand my talents and start working with classes. Is there a good
tutorial out there on the web that a novice can understand. I currently
wanting to add a password generator class to one of my existing webpages at
my helpdesk. The class is located at PHPclasses.com
(class.password.generator.php). Thanks for any help that you can give.

A

I think learning OOP in PHP causes bad habits. There are too many
different ways to do it. If you learn from a language like Java, you
will certainly get it down very well. PHP5 has many of the features of
Java OOP (not all of them, though).

If you don''t have a plethora of time and need to go with the more
practical approach of learning OOP where you will be using it, in PHP,
the PHP manual is the most accurate way to learn it.

http://php.net/oop

-Mike PII


I think learning OOP in PHP causes bad habits. There are too many

different ways to do it. If you learn from a language like Java, you
will certainly get it down very well. PHP5 has many of the features of
Java OOP (not all of them, though).


On the contrary. Java also has quite a few unwanted characteristics as
an OO language. I agree that Eiffel would be a better place to start,
but it remains abstract, as it is hardly used. Also, PHP programmers
often have to learn javascript as well, so you gain an understanding of
both class-based and template-based object orientation.

I think the "bad habits" are a good thing to start from. As a resource
on how to learn OO programming, I would also recommend "Refactoring" by
Martin Fowler. The examples alone in that book can teach you as much as
a good theory book.

I think PHP offers you the opportunity of gently discovering the
advantages of objects. In fact, a lot of people only need to realize the
power of a component like PHPMailer or FPDF to give abstract words like
"code reuse" a firm body.

Best regards


Dikkie Dik wrote:

>I think learning OOP in PHP causes bad habits. There are too many
different ways to do it. If you learn from a language like Java, you
will certainly get it down very well. PHP5 has many of the features of
Java OOP (not all of them, though).



On the contrary. Java also has quite a few unwanted characteristics as
an OO language. I agree that Eiffel would be a better place to start,
but it remains abstract, as it is hardly used. Also, PHP programmers
often have to learn javascript as well, so you gain an understanding of
both class-based and template-based object orientation.

I think the "bad habits" are a good thing to start from. As a resource
on how to learn OO programming, I would also recommend "Refactoring" by
Martin Fowler. The examples alone in that book can teach you as much as
a good theory book.

I think PHP offers you the opportunity of gently discovering the
advantages of objects. In fact, a lot of people only need to realize the
power of a component like PHPMailer or FPDF to give abstract words like
"code reuse" a firm body.

Best regards

I don''t know what "unwanted characteristics" java has as an OO language.
It is a pure OO implementation. And I agree with Mike - I think Java
is a much better language to learn OO programming.

And I''ve found the "bad habits", once you get into them, are very hard
to break. I don''t know how many times I''ve had C++ programmers who got
off to the wrong start with OO programming and the result was a
horrendous mess of OO and non-OO code.

Smalltalk is also a great language for learning OO, but it''s not used in
web programming.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================


这篇关于使用class + php的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆