Quantcast

Use Zend without MVC

classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Use Zend without MVC

Alomon
Hello,

I will probably have to make a little PHP application and use a Framework, but I really do not think I will use MVC, as the application is for a local use and will be made up of only 4 pages. in fact, I do not personnaly think a Framework is useful, but my boss does :D

Anyway, I did not manage to find any tutorial on how tu use Zend without MVC. It is the first time I will use a Framework, and it is not really easy, so I really want to begin with a tutorial, or a simple application.

Could someone give me a link showing how to use Zend without MVC?

Thank you in advance.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

Sudheer Satyanarayana
Alomon wrote:

> Hello,
>
> I will probably have to make a little PHP application and use a Framework,
> but I really do not think I will use MVC, as the application is for a local
> use and will be made up of only 4 pages. in fact, I do not personnaly think
> a Framework is useful, but my boss does :D
>
> Anyway, I did not manage to find any tutorial on how tu use Zend without
> MVC. It is the first time I will use a Framework, and it is not really easy,
> so I really want to begin with a tutorial, or a simple application.
>
> Could someone give me a link showing how to use Zend without MVC?
>
> Thank you in advance.
>  
I think you can use the Zend Framework reference manual minus MVC
components and those that integrate with it.

Regards,

--

With warm regards,
Sudheer. S
Business: http://binaryvibes.co.in, Community http://lampcomputing.com, Personal: http://sudheer.net

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

Jack Sleight
In reply to this post by Alomon
All the ZF components are (fairly) standalone, if you don't want to use
the MVC components then it's as simple as not using them, just use the
components you do need. ZF is less of a "framework" in the traditional
sense (like Cake or Symphony) and more of a component library, from
which you can select the parts you need.

Alomon wrote:

> Hello,
>
> I will probably have to make a little PHP application and use a Framework,
> but I really do not think I will use MVC, as the application is for a local
> use and will be made up of only 4 pages. in fact, I do not personnaly think
> a Framework is useful, but my boss does :D
>
> Anyway, I did not manage to find any tutorial on how tu use Zend without
> MVC. It is the first time I will use a Framework, and it is not really easy,
> so I really want to begin with a tutorial, or a simple application.
>
> Could someone give me a link showing how to use Zend without MVC?
>
> Thank you in advance.
>  

--
Jack
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

Alomon
In reply to this post by Sudheer Satyanarayana
OK. I will try then... I will get back to you if I have some questions, you are very quick, thank you very much! ;)
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

jasonistaken
In reply to this post by Jack Sleight

This is one of the many reasons why I'm an advocate of the Zend
Framework. Its architecture doesn't restrict you; its flexibility allows
you to use it however you desire.

Jack Sleight wrote:

> All the ZF components are (fairly) standalone, if you don't want to use
> the MVC components then it's as simple as not using them, just use the
> components you do need. ZF is less of a "framework" in the traditional
> sense (like Cake or Symphony) and more of a component library, from
> which you can select the parts you need.
>
> Alomon wrote:
>> Hello,
>>
>> I will probably have to make a little PHP application and use a
>> Framework,
>> but I really do not think I will use MVC, as the application is for a
>> local
>> use and will be made up of only 4 pages. in fact, I do not personnaly
>> think
>> a Framework is useful, but my boss does :D
>>
>> Anyway, I did not manage to find any tutorial on how tu use Zend without
>> MVC. It is the first time I will use a Framework, and it is not really
>> easy,
>> so I really want to begin with a tutorial, or a simple application.
>>
>> Could someone give me a link showing how to use Zend without MVC?
>>
>> Thank you in advance.
>>  
>

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

Matthew Ratzloff
In reply to this post by Alomon
in fact, I do not personnaly think a Framework is useful, but my boss does :D

You should listen to your boss.  :-)

-Matt

On Mon, Sep 22, 2008 at 5:57 AM, Alomon <[hidden email]> wrote:

Hello,

I will probably have to make a little PHP application and use a Framework,
but I really do not think I will use MVC, as the application is for a local
use and will be made up of only 4 pages. in fact, I do not personnaly think
a Framework is useful, but my boss does :D

Anyway, I did not manage to find any tutorial on how tu use Zend without
MVC. It is the first time I will use a Framework, and it is not really easy,
so I really want to begin with a tutorial, or a simple application.

Could someone give me a link showing how to use Zend without MVC?

Thank you in advance.
--
View this message in context: http://www.nabble.com/Use-Zend-without-MVC-tp19607442p19607442.html
Sent from the Zend Framework mailing list archive at Nabble.com.


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

Alomon
Matthew Ratzloff wrote
You should listen to your boss.  :-)

-Matt
Actually, after the day of today, I am really asking myself about the advantages of using Zend without MVC instead of Smarty for such a little website (only 5 pages with 4 little tables in a database)... You have an answer to this, don't you?

Thanks ;)
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

Alexander Johannesen
On 23/09/2008, Alomon <[hidden email]> wrote:
> Actually, after the day of today, I am really asking myself about the
> advantages of using Zend without MVC instead of Smarty for such a little
> website (only 5 pages with 4 little tables in a database)... You have an
> answer to this, don't you?

Well, tell us what the appication is all about, what it does and so
forth. The answer should follow from the spec, I reckon.


Alex
--
---------------------------------------------------------------------------
 Project Wrangler, SOA, Information Alchemist, UX, RESTafarian, Topic Maps
------------------------------------------ http://shelter.nu/blog/ --------
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

Matthew Ratzloff
In reply to this post by Alomon
Unless I'm writing a simple console application, I always use an MVC pattern, regardless of the language.  Like object-oriented design, it seems to be the right solution in virtually every scenario I've encountered, except perhaps in cases where additional performance is necessary.

As for Smarty, I occasionally have to interact with it as part of my job and I am not terribly fond of it.

-Matt

On Tue, Sep 23, 2008 at 11:32 AM, Alomon <[hidden email]> wrote:


Matthew Ratzloff wrote:
>
> You should listen to your boss.  :-)
>
> -Matt
>

Actually, after the day of today, I am really asking myself about the
advantages of using Zend without MVC instead of Smarty for such a little
website (only 5 pages with 4 little tables in a database)... You have an
answer to this, don't you?

Thanks ;)
--
View this message in context: http://www.nabble.com/Use-Zend-without-MVC-tp19607442p19634038.html
Sent from the Zend Framework mailing list archive at Nabble.com.


Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

Alomon
In reply to this post by Alexander Johannesen
Alexander Johannesen wrote
Well, tell us what the appication is all about, what it does and so
forth. The answer should follow from the spec, I reckon.


Alex
OK, let's go ;)

The homepage contains only one form. One of the table of the DB is a 'user' table, with 3 users + 2 "admin" accounts. Each user can access to *one* page ; one of the admin to all 3 pages + another one ; and the other admin to this 'another page'.

So we have 5 pages and 5 accounts.

Each of the 3 "user" pages contains a form in order to send some data to the database, which are finally used to generate draws, displayed on the 'another page'.

And that's all. The website is used only where I work (soit is used mainly by 5 people over the world ) and is not made to be dispatched anywhere else.

I think you have all details to answer me; if not, do not hesitate to ask me what is missing ;)
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

Alexander Johannesen
On Tue, Sep 23, 2008 at 23:13, Alomon <[hidden email]> wrote:
> The homepage contains only one form. One of the table of the DB is a 'user'
> table, with 3 users + 2 "admin" accounts. Each user can access to *one* page
> ; one of the admin to all 3 pages + another one ; and the other admin to
> this 'another page'.

I'd ask you to draw me a diagram, but never mind. :)

> So we have 5 pages and 5 accounts.

So, a new forms that are somewhat similar but not quite for a number
of users of various roles.

> I think you have all details to answer me; if not, do not hesitate to ask me
> what is missing ;)

Well, I still have no idea what this thing does, but I have to say
upfront that I don't use MVC at all with the ZF. I'm a RESTafarian,
and so have created my own little RESTful system (no, the ZF Rest
class has nothing at all to do with REST :) and treat everything as
resources and access control. Makes life easier and more flexible. Not
sure how to apply this to your scenario, though, but ;

I always start out with rejecting a framework for simple applications
like this, yet always regret my own short-sightedness. These things
always gets that tad extra complicated (especially after you show you
tool to your peers) and messy as you hack on yet another insignificant
little feature. Frameworks are created because we've all been through
this cycle too many times and know that there's a bucketload of
mundane and simple stuff we shouldn't have to repeat all the time.

ZF is good in that it is more a library of great classes with a common
thinking rather than an integrated framework. I often mix and match ZF
with others, and it's really the best way to go forward.


Alex
--
---------------------------------------------------------------------------
 Project Wrangler, SOA, Information Alchemist, UX, RESTafarian, Topic Maps
------------------------------------------ http://shelter.nu/blog/ --------
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

Giorgio Sironi
2008/9/24 Alexander Johannesen <[hidden email]>:
> and so have created my own little RESTful system (no, the ZF Rest
> class has nothing at all to do with REST :) and treat everything as
> resources and access control. Makes life easier and more flexible. Not
> sure how to apply this to your scenario, though, but ;

It's an interesting approach, I also think REST : Lisp = MVC : Php...
How do you do PUT request by a browser? Encapsulate in POST? format
parameter? The same can be said for DELETE. Do you use javascript? I
have tried but not obtained a degradable approach...


--
Giorgio Sironi
Piccolo Principe & Ossigeno Scripter
http://www.sourceforge.net/projects/ossigeno
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: Use Zend without MVC

Alexander Johannesen
Hiya,

> How do you do PUT request by a browser? Encapsulate in POST? format
> parameter?

Yup, POST with a parameter called "method_override=PUT". Same for
DELETE as method_override=DELETE. (Although never ever use GET with
method_override, of course; I've specifically disallowed this in my
framework) From a browser there is no other option at the moment. But
REST is far more than just browser integration; I do a lot of REST on
the server2server side of things.

> The same can be said for DELETE. Do you use javascript? I
> have tried but not obtained a degradable approach...

I can use JavaScript, but I wouldn't necessary recomend it as exposing
it through JavaScript expose your infrastructure just a tad more to
the script-kiddies. :)


Alex
--
---------------------------------------------------------------------------
 Project Wrangler, SOA, Information Alchemist, UX, RESTafarian, Topic Maps
------------------------------------------ http://shelter.nu/blog/ --------
Loading...