Adrian World Design
  • Services
    • Website Consulting
    • Startup Consulting
    • Zend Development
  • Portfolio
    • My Framework
  • Knowledge
    • Web Standards
    • PHP bare-bones
    • Zend Framework
    • Zend Framework 2
    • Git - Github
    • Search Engine Optimization
    • Web Hosting
    • Linux
    • Microsoft Windows
    • Web Browsers
    • Mobile Devices
  • About
    • Business
    • Professionally
    • Personally
  • Contact
    • Contact Form
    • Phone
    • Email
    • Messaging

Knowledge Base Overview

Background image in web site

Knowledge ⇒ Zend Framework ⇒ OAQ - Occasionally asked questions ⇒ Background image in web site
Tweet
Share on Tumblr

Created: Oct 9, 2011, 3:46:04 PM CDTLast updated: Aug 8, 2012, 9:24:23 AM CDT

If you are a seasoned developer in Zend Framework you will say that this is a rather silly question "How to put background image in web site in Zend Framework".

Surprisingly many people ask me how to add images in Zend Framework so maybe you like to know how to do that, too.

Add background images

Well, unfortunately for you the short answer is: No, you cannot add images somehow magically in Zend Framework because the framework is not designed for this. The Zend Framework is designed for the development process and not content management. Images are content.

I think there is a little bit of a misconception or misunderstanding about what the Zend Framework is and what it can do. The framework is not a finished web site management system (like WordPress, Joomla or even Drupal to some degree) where you just point and click and it does things by magic.

Zend Framework is more like what I call PHP on steroids. As such and for me as a developer it does what PHP does but faster and most of the time better. Most importantly, I don't have to reinvent the wheel for many things.

PHP by itself, and with a few exceptions, is "only" a script language and doesn't do much in terms of HTML or creating a web page. That's where the framework steps in and helps you create things you usually have to do for many web pages over and over again.

The main focus here is managing data and layouts. You manage data with controllers, handle data with models and layouts with views. That's what is known as the Model-View-Controller pattern, MVC for short. The result are HTML web pages.

Content, Style, Behavior

Content, style and behavior are the key pillars of good web design. Content is usually represented by HTML, style by CSS and behavior by JavaScript (jscript).

Unfortunately, a background image in a web site is not (should not be) part of a HTML web page because you should handle it with CSS, cascading style sheets.

Your focus with the Zend Framework is not handling style or behavior—only content. With Zend Framework you concentrate on creating and managing the content. What you can do easily as well is add CSS or JavaScript to your layout. However, if you like to manage the styles or behavior you have to create your own management for these.

Application Management

If you have a web application (web site) build with the Zend Framework and somehow know that there is a way you can handle the background image then it is part of that particular web application build with the Zend Framework but not somehting that Zend Framework does by itself. In other words, somebody build a module or model that is capable of managing your styles and the background image.

So, the original question might be quite legitimate but it is not the framework's responsibility and cannot be done directly with framework.

blog comments powered by Disqus
Prev
Next

Powered by FeedBurner Load our "Knowledge Base" feed in your RSS feeder

Follow us on Twitter
Follow us on Facebook
Follow us on LinkedIn
Follow us on Google+

All rights reserved, Adrian World Design ©2009–2022 Powered by Wejas Framework

Jump to Top