FAQs

General questions

Why another PHP framework?

I don't use PHP but sometimes I need it for little web sites of few pages, written in tight amount of time for hostings that supports only PHP. There is also another reason, I hate prefabricated templates so I don't want to learn how to design for Drupal, Joomla and so on for only a small site: it take more time and the results are less maintenables. Phraw is born for this reason, a bigger framework/CMS require more time and more maintenance if you need only few pages.

No, really, why you have developed it?

It is fun and I have to use it for my job.

What can I do with Phraw?

Just some examples:

  • Lightweight web sites: when you have a short amount of time and you want to use only pure HTML, CSS, JavaScript and little hacks of PHP code without the hassle to learn a new CMS or heavy frameworks.
  • When you want to start a new fantastic PHP application (like a forum, a better WordPress clone or whatever else) and you need performances and a lot of flexibility, Phraw gives you a good bootstrap environment.
  • Little custom administration scripts.
  • Little web services that requires performances (like a redirect tool or a image resizer).
  • A CMS.
  • Very fast API services that query a database.

Phraw is thin, so it's easy to learn. You can use the libraries that you prefer. You can customize the "Controller" part of the MVC pattern in order to have maximum flexibility on your projects.

Is it fast?

Yes, a lot.

Are you using a fat CMS or a heavy framework for a simple web site? Search engines counts on loading speed for rankings, but also users because delays after 200ms impact business metrics. Phraw is very fast and may be the right solution for your case: you will get a decluttered and faster framework for higher rankings and better user satisfaction.

Are you building web API services? An API service have to be fast in order to response to many requests per second. More is fast and more developers will use it. Phraw helps you to build, in less time, a REST service with the higher speed as possible.

Is it ready for commercial sites?

Yes, you can use it for developing web sites for your clients.

How does it scale?

Phraw is fast because is very simple, so it can serve a lot of requests more than bigger frameworks.
But Phraw is too simple for medium or big sites like Facebook because bigger sites needs higher complexity. These applications needs custom frameworks. Phraw may help you to build the prototype.

You can scale to an unlimited number of flat pages and to an enough numer of dynamic pages (like 80% of web sites) but, if you don't need customizations, I suggest you to use a bigger famework if you want to build more complex sites because they gives standard modules ready to use.

For example, this framework is good for you if you need static pages with a news archive, some forms, a simple payment system, a simple product catalog and so on. It is also very useful for little web services like a micro-blog, an URL shortener, a download counter, a REST service etc.

What is the origin of the name?

Phraw is a descendant of Fraw, a bigger framework that I written several years ago.

Is it "green"?

Phraw consumes less RAM and less hard disk space than big CMSs or frameworks. It is also faster so you can pack more web sites on a single server, or less servers if you need to scale up.

Installation troubles

I changed the templates but I don't see the differences on the browser

Probably your site have is caching the pages for more speed. Read the officiale documentation of the template engine that you are using.

For reset the cache simply remove all the files from the cache directory (default "resources/cached/") and the compiled templates (default "resources/compiled/").