Tag Info

Hot answers tagged

60

You implemented a totally new process and you expected it to be perfect on the first try? I would be shocked if everything was even marginal on the first pass. Calm down and go over what you see with the other developers. They may have questions and you may have not explained things very well to begin with. Also remember that concepts like "Business ...


28

Zend Framework is hard. It wasn't built as an entry level framework, knowledge of the concepts involved is assumed1. That said, the first requirement for Zend Framework 2.0 is to make it a little bit easier: Ease the learning curve In late 2009, we did a survey of framework users to determine what they use, what environments they use, and what ...


17

I'd always use an off-the-shelf framework. There is almost never a good reason to build your own from the ground up. You'll spend a lot more time with the plumbing work and bug fixing writing your own than relying on tested and optimized methods already existing in the OS packages. Most of the frameworks have built in methods to extend them if needed and if ...


15

I was in a somewhat similar situation to yours, and my solution was mentoring via pair programming sessions. Take time to sit down with each developer for a couple of hours, to do some development together. Lead them through implementing some small feature the TDD way using MVC properly. Discuss any questions which come up. Ideally, repeat a couple of times ...


11

I've written virtually all of my sites from scratch. In my case, the reason is primarily because I enjoy creating things and that's also a great way to learn. It's much less fun for me to spend time trying to learn someone else's code than creating my own. But that's just a personal reason. If you find a nice off-the-shelf package that does exactly what you ...


10

Generally speaking, your app should live in either: 1) C:\Program Files\your_app_name 2) C:\Program Files (x86)\your_app_name For 32 bit OSs such as XP, use #1. For 64 bit OSs use #1 if your app is 64 bit. Use #2 if your app is 32 bit. Also take a look at MS's Developer Guidelines


8

PHP was originally created and released by Rasmus Lerdorf. Andi Gutmans and Zeev Suraski were the driving force behind the PHP2 -> PHP3 rewrite. The company, Zend Technologies, and the virtual machine powering PHP4+, the Zend Engine, derive their names from Zeev and Andi. While there's a lot of Zend in PHP, and Rasmus, Andi and Zeev are all involved at ...


7

Without having read the article in question, certainly you should avoid multiplexing functionality in methods - authentication and authorization are very different things. So on that basis alone, there's good reason. his would make the code more readable ...not sure if this is reason enough. As I've been spending years telling people, we do not write ...


7

I didn't like the lack of discoverability when I started using the Zend Framework, too many classes rely on arrays and you have to lookup what keys you can/need to define. There is nothing at all wrong with having clear set methods or named params, it would, imo go a long way to helping with discoverability. The Yii framework is even worse with this sort ...


7

The trick to understanding a large code base is to not try to understand all of it. After a certain size, you can't hold a mental model in your head of the entire thing. You start with an anchor point that makes sense for whatever task you need to work on first, then branch from there, learning only the parts you need and trusting that the rest of it works ...


7

Zend Framework Is a PHP source code library that allows you to write PHP web applications. It includes a MVC framework, handles dispatching of requests and contains useful utilities that most PHP programmers need. It does not depend upon a specific web server and can run under any web server running a compatible version of PHP. Zend Server Is a ...


5

The solution is both simple and hard: Set and Enforce High Standards - Do not accept code that has minor defects. Define your development process and enforce it - It your process says that all tests will be created prior to actual code development, do not allow code development until all of the tests are complete and accepted. That you had a bad first ...


5

Zend can have a steep learning curve and the documentation takes some getting used to but if you plan to move into development professionally you should really take the plunge now rather than leaving it. I can't recall the last contract I had which didn't use Zend. With Zend it is probably a good idea to read a book before taking the plunge into the docs. ...


5

As a full time PHP Developer, I have never had anybody ask if I was Zend certified. I have not taken the certification exam, and I don't foresee myself taking it in the future. While it may give you one up on your competition in an interview, I think the same thing can be achieved by simply knowing your craft. By all means, take the exam if you like, but I ...


5

the basic difference between php global functions and their python counterpart is in their scope: python top-level functions are part of the module where they are defined. when they are imported, they are called with defining_module.function_name() therefore there is less risk of conflicting names. php 'global' functions are really global, iirc, no matter ...


4

If you have a few years of experience with PHP and are familiar with MVC frameworks, then you shouldn't have a problem to be familiar with ZF in one week. You're not going to be a guru, but you'll be able to get things done. My plan (and what I actually did few years ago), would be to start with "ZF QuickStart", build the base of your application. Don't ...


4

I studied for it once, but decided it wasn't worth my time (back in PHP 5.0 days). As a recall, they have a number of ridiculous questions about the function parameters and results, which I didn't think should be on a certification exam. Anyway, I think Zend has a preparation book that will walk you through what to study. Personally, I don't think the exam ...


4

I'm not sure what exactly are you looking for - the high-level overview is the description of the implementation. The low-level is the implementation itself. I'll try to recap it shortly - A request arrives and is intercepted by the front controller. The request is encapsulated in a request object. (Default is Zend_Controller_Request_Http) A router is ...


4

Going 15 days without giving your developers feedback on how well they're learning the concept is a long time. A better way to approach this is probably to sit down with each developer often during the early part of introducing these concepts, and go over his code with him, so that he doesn't spend 15 days going off in the wrong direction before you can get ...


4

You should learn both, but I'd personally put more emphasis on ZF2. ZF2 is the package that will have the longest lifespan ahead of it, whilst ZF1 is probably going to go into maintained mode once ZF2 is generally available, so if you limit yourself to ZF1 you'll eventually have to learn ZF2 anyway if you want to maintain your employability. If you only ...


4

background processing (yep, it's quite ugly) <?php system("php background-process.php &"); putting php jobs (e.g. db maintenance?) into cron tables cgi processing in unsupported web servers linting before uploading php -l file.php fast checkup of daring language constructs php.exe -r "$a=array(1,6,9); array_splice($a,2,1,array(9,10,46)); ...


4

In general, it's a preference thing. "Static" in this context is just another word for "global", so although either way will get you some evil looks (particularly if you're only using classes as namespaces), it works. But: PHP can very easily be set up to autoload classes, making it so that static functions aren't loaded in til you have need of them (or ...


3

TDD, coding standards and MVC are all hard things to do if people are not used to them. Put them all together and you have a recipe for a very steep learning curve. This was never going to be a smooth ride. You might have been better off introducing these concepts one by one. The easiest is coding standards, so that's where I would have started. The way to ...


3

I'm not and currently have no reason to get certified, hasn't seemed to harm my ability to get interviews and contracts. I have a few years experience with Zend now so that also helps. If however you are new to the field it may be something worth getting to seperate you from the crowd.


3

While Zend Framework 1.x is a very powerful tool (and I use it frequently) I would not recommend it as a framework for learning best practice. If you're truly interested in learning the best practices and standards for PHP development then you're much better off working with the latest Zend Framework 2 builds, which will actually teach you current PHP 5.3 ...


3

My opinion is that you mock everything. You are making sure that the checks are acting correctly not the underlying logic in the function call that returns the true/false). Mocking this also removes understanding the logic behind the function calls in each of the conditions. And this test won't fail if/when that logic changes which would become a ...


2

I have found a web site that contain several answer and php training test http://www.php-certifications.com It covers all categorys of the Zend PHP 5.3 Certification : PHP Bases Streams and Network Programming Databases and SQL XML and Web Services Object Oriented Programming Security Strings and Patterns Web Features PHP 4/5 Differences Functions ...


2

I think it's a good idea to break up larger functions into logical components and from the names of your two methods it sounds very reasonable. Down the road you may need to be able to use that authorize method for something else without the call to authenticate and vice versa. That being said taking it to an extreme can be a bad thing too so be sensible! ...


2

Yes, you could write millions of proxies/wrappers/what-have-you (and you owe it to yourself to start doing so immediately), but you all have to name them. However, in the name of purity every conceivable and inconceivable effort is not only justified but obligating. There are even more subtle levels of coupling. For instance the coupling to common sense. ...



Only top voted, non community-wiki answers of a minimum length are eligible