Skip to main content

Home/ PHP Programming/ Group items tagged www

Rss Feed Group items tagged

Sarah HL

10 Principles of the PHP Masters | Internet Resources | Cpworld2000.com - 0 views

  • 1. Use PHP Only When You Need it – Rasmus Lerdorf
  • PHP was created out of a need to solve web development problems
  • Lerdorf is the first to admit that PHP is really just a tool in your toolbox, and that even PHP has limitations.
  • ...9 more annotations...
  • 2. Use Many Tables With PHP and MYSQL for Scalability – Matt Mullenweg
  • 3. Never, ever trust your users – Dave Child
  • 4. Invest in PHP Caching – Ben Balbo
  • 5. Speed up PHP Development with an IDE, Templates and Snippets – Chad Kieffer
  • 6. Make Better Use of PHP’s Filter Functions – Joey Sochacki
  • 7. Use a PHP Framework – Josh Sharp
  • 8. Don’t use a PHP Framework – Rasmus Lerdorf
  • 9. Use Batch Processing – Jack D. Herrington
  • 10. Turn on Error Reporting Immediately – David Cummings
Sarah HL

Learning JavaScript from PHP - a Comparison | Lullabot - 0 views

  • In PHP, all variables are local in scope unless declared as global. JavaScript is opposite, and all variables are global unless declared with the var keyword.
  • Both PHP and JavaScript are loosely typed
  • JavaScript is a bit mixed concerning undeclared variables, if you attempt to modify or compare with an undeclared variable, the script will break entirely, but you can check the variable status using typeof() or in conditional statements containing only that variable.
  • ...6 more annotations...
  • JavaScript only recognizes the keyword true in all lowercase. PHP accepts both uppercase and lowercase
  • PHP is not case-sensitive in function or class declarations, but JavaScript is case sensitive for these also.
  • The key difference between PHP and JavaScript is that JavaScript does not have associative arrays.
  • JSON strings having become very popular as a faster alternative to XML, and can be read and created with the PHP functions json_encode() and json_decode().
  • Let's take one more look at defining an object in JavaScript and see how it can be used to compensate for the lack of associative arrays in JavaScript.
  • // Note that variables should always be// prefixed with "var" to define a local scope.for (var n = 0; n < 10; n++) {  alert(n);}
jdr santos

atomik framework | micro PHP5 framework for small to medium websites - 0 views

  •  
    Atomik is a free, open-source, micro framework for PHP5. Atomik is built for small web applications that do not need heavy frameworks but still want powerful features. It is build with the KISS principle in mind as well as speed and security. Atomik is also an ideal introduction for beginners to the world of web development frameworks.
jdr santos

Tekuna.org - MVC Microframework for PHP - 0 views

shared by jdr santos on 01 Sep 09 - Cached
  •  
    Tekuna is a compact framework for web-based applications. It provides a stable basis and a generic infrastructure for your projects. Tekuna has a very small footprint and will not pollute your codebase with unnecessary stuff.
Sarah HL

Rasmus Lerdorf: PHP Frameworks? Think Again. - 0 views

  • Rasmus Lerdorf is the creator of PHP and still continues as a core developer to the PHP project.
  • heavy Twitter mashup that he created. This does a lot of database calls and a lot of behind the scenes work. By hand-tuning it he was able to get on the order of 280 req/sec.
  • "Any script based language is simply not fast enough".
  • ...2 more annotations...
  • So, are there any frameworks that don’t suck? Rasmus did mention that he liked CodeIgniter because it is faster, lighter and the least like a framework.
  • It all starts with “I don’t need a framework.” 2. Then you create 7 classes. 3. Now you have a small library of classes. 4. Then you create an application that uses your library. 5. It works and it’s fast, hurray! 6. Then someone asks you to extend the functionality of your application. 7. And they keep asking for more, and more, and more and more… 8. Now you have 43 classes. 9. You’ve learn so much in the last 2 years. Design patterns, security, performance, testing… 10. What once was a small library is now a big, ugly, un-tested, un-documented, scary framework. 11. Then you change jobs. 12. And you create another 7 classes… This has been happening for the last 30 years.
sloansteddi

Secure File Upload with PHP - 0 views

  •   $ext = substr($filename, strrpos($filename, '.') + 1);
  • ($ext == "jpg")
  • $_FILES["uploaded_file"]["type"] the MIME type of the uploaded file (if the browser provided the type)
Jungle Jar

JungleJar | Featured Web Application: PHPanywhere.net - 0 views

  •  
    This is an extremely cool and useful web application, and if it hasn't been thought of before, I'm absolutely shocked, because it makes so much sense. Essentially, PHPanywhere is a web based free Integrated Development Environment or IDE for the PHP language. In other words it is a web based application that provides PHP developers a PHP code editor that mocks a desktop application, and it does so very well.
jdr santos

PHPonTrax - P.O.T. that makes the web go round! - 0 views

  •  
    Php On Trax (formerly Php On Rails) is a web-application and persistance framework that is based on Ruby on Rails and includes everything needed to create database-backed web-applications according to the Model-View-Control pattern of separation.
qualitypoint Tech

array_slice function in php - 0 views

  •  
    array_slice function in php
Sarah HL

Les tests unitaires | Crossbow Labs - 0 views

  • Par rapport aux tests manuels évoqués précédemment, la granularité des tests unitaires est extrêmement fine
  • tests de recette, qui valident chaque fonctionnalité de l'application dans son ensemble et permettent ainsi de mesurer l'avancement du projet
  • La mise en place du contexte de test et la vérification du résultat sont le plus souvent très simples, et le coût d'écriture des tests est très réduit. Ils peuvent être exécutés très tôt dans le développement d'une tâche (les tests de recette ne peuvent être lancés que lorsque la fonctionnalité complète est implémentée). Ils peuvent être lancés à chaque compilation de la classe (les tests de recette ne peuvent être lancés que lorsque toute l'application est compilée).
  • ...2 more annotations...
  • Les tests unitaires apportent donc un feedback beaucoup plus rapide que les tests de recette, pour un coût nettement plus réduit.
  • Bien sûr, l'adoption de cette pratique n'est ni gratuite ni immédiate. Il faut d'abord apprendre à utiliser un framework de tests, et surtout ensuite apprendre à organiser son code pour le rendre testable unitairement.
  •  
    Très didactique pour expliquer le rôle des tests unitaires dans une application
Sarah HL

Dr. Dobb's | Extreme Testing | juin 1, 2003 - 0 views

shared by Sarah HL on 29 Jun 09 - Cached
  • First, you quickly add a test
  • TDD employs five basic steps
  • The second step involves running your tests
  • ...15 more annotations...
  • Third, you make a little change to your functional code
  • Next, you run the tests
  • In the optional fifth step, you refactor your code to remove any duplication.
  • two simple rules. First, you should write new business code only when an automated test has failed. Second, you should eliminate any duplication that you find.
  • Your designs must consist of highly cohesive
  • You write your own tests because you can’t wait
  • the running code providing feedback between decisions
  • Test-Driven Development (Addison-Wesley 2003)
  • a Smalltalk system with a completely test-driven approach that took four years and 40 person-years of effort
  • there’s far more to testing than unit tests, so you’ll still need other testing techniques such as functional testing, user acceptance testing, system integration testing and so on.
  • you have a clear measure of success
  • most programmers don’t read the written documentation for a system; instead, they prefer to dig right into the code.
    • Sarah HL
       
      Follow the "natural" tendance of the developers, a pro TDD
  • Your acceptance tests define exactly what your stakeholders expect of your system; therefore, they truly do determine a good portion of your requirements.
  • Bob Martin says it best: “The act of writing a unit test is more an act of design than of verification. It’s also more an act of documentation than of verification.
  • Side by Side: Comparing TDD and AMDD TDD shortens the programming feedback loop; AMDD abridges the modeling feedback loop. TDD provides detailed specification (tests), while AMDD provides traditional specifications (agile documents). TDD promotes the development of high-quality code; AMDD encourages high-quality communication between your stakeholders and other developers. TDD provides concrete evidence that your software works, whereas AMDD supports your entire team, including stakeholders, in working toward a common understanding. TDD provides finely grained, concrete feedback in minutes. However, concrete feedback requires developers to follow the practice Prove It With Code, and they may become dependent on non-AM techniques; AMDD lets you get verbal feedback in minutes. TDD ensures that your design is clean by focusing on creation of callable and testable operations; AMDD lets you think through larger design and architectural issues before you code. TDD isn’t visually oriented; AMDD is. Both techniques are new and therefore may be threatening to traditional developers. Both techniques support evolutionary development. —S. W. Ambler
« First ‹ Previous 241 - 260 of 362 Next › Last »
Showing 20 items per page