Book Image

RESS Essentials

Book Image

RESS Essentials

Overview of this book

RESS is a new methodology in the world of web design and development. It attempts to solve the problems that accompany the RWD (responsive web design) approach to web design. RESS is still in its infancy, but it is growing at an exponential rate. RESS Essentials shows you how to make server-side applications smarter and more aware of a visitor's environment limitations (device, screen size, and browser). This allows you to create faster and more reliable websites. Through this book, you will build a solid base of knowledge on RESS-related technologies, while the step-by-step tutorials will help you to create your own RESS system. This book is an introduction to RESS alchemy and gives you an incentive to build your own RESS lab. It will give you a broad overview of the multiple techniques used to code responsive websites in responsible ways. Beginning with an overview of RWD, you will learn the steps involved in setting up RWD for client-side development. You will then learn how to scale images using client- and server-side technology. By the end of this book, you will have learned about the implementation of RESS application patterns, browser feature detection, and various RESS architectures. RESS Essentials will also teach you how to use jQuery with some RWD design patterns and how to employ REST API for RWD pages.
Table of Contents (15 chapters)
RESS Essentials
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Preface

RESS is a new methodology in the world of web design and development. It attempts to solve the problems that accompany the Responsive Web Design (RWD) approach to web design. RESS is still in its infancy, but it is growing at an exponential rate.

RESS Essentials shows you how to make server-side applications smarter and more aware of a visitor's environment limitations (device, screen size, and browser). This allows you to create faster and more reliable websites. Through this book, you will build a solid base of knowledge on RESS-related technologies, while the step-by-step tutorials will help you to create your own RESS system.

This book is an introduction to the RESS alchemy and gives you an incentive to build your own RESS lab. It will give you a broad overview of the multiple techniques used to code responsive websites in responsible ways. Beginning with an overview of RWD, you will learn the steps involved in setting up RWD for client-side development. You will then learn how to scale images using client and server-side technology. By the end of this book, you will have learned about the implementation of RESS application patterns, browser feature detection, and various RESS architectures. This book will also teach you how to use jQuery with some RWD design patterns and how to employ REST API for RWD pages.

What this book covers

Chapter 1, Why Does RWD Change the Internet?, is a brief description of Responsive Web Design history, its benefits, and the controversies it caused among web developers. It also gives a brief introduction to RESS.

Chapter 2, Sample RWD Setup for Client-Side Development, describes creating a sample responsive HTML document with the help of Twitter's Bootstrap framework and Gridpak tool.

Chapter 3, Server Side Setup – Device Detection Libraries, covers using WURF (OnSite and Cloud versions) and Dave Olsen's Detector library to detect device features.

Chapter 4, Sample RESS Page, explains four complete RESS solutions to get a device's information that can be used to build an appropriate version of an HTML document within server-side application.

Chapter 5, Responsive Images Client- and Server-Side Approaches, talks about several ways to deliver resolution-dependent images, such as the script from adaptive-images.com, the <picture> element polyfill, or the RESS solution from the previous chapter.

Chapter 6, Performance, explains optimization strategies and useful tools.

Chapter 7, Extending with jQuery, starts by integrating the Twitter Bootstrap carousel component with our RESS test system. Next it covers creating the jQuery plugin from scratch to make the table responsive by converting it into an accordion component below the screen width defined with the media query.

Chapter 8, Employing a REST API for RWD, explains how to create a REST API with a Slim PHP framework and an AJAX application integrated with our RESS module, which we created before.

What you need for this book

To run some examples from this book you need to have some kind of AMP (Apache, mySQL, PHP) environment. For those using Windows, the easiest way to go is to use the WAMP server in the default configuration. Links to the respective packages for other systems can be found at http://en.wikipedia.org/wiki/List_of_Apache–MySQL–PHP_packages.

Who this book is for

This book is aimed primarily at web developers interested in writing applications that leverage both client-and server-side code to optimize content for various devices.

Conventions

In this book, you will find a number of styles of text that distinguish between different kinds of information. Here are some examples of these styles, and an explanation of their meaning.

Code words in text are shown as follows: "We can include other contexts through the use of the include directive."

A block of code is set as follows:

<picture alt="">
  <source media="(min-width: 45em)"
    srcset="large-1.jpg 1x, large-2.jpg 2x">
  <source media="(min-width: 18em)"
    srcset="med-1.jpg 1x, med-2.jpg 2x">
  <source srcset="small-1.jpg 1x, small-2.jpg 2x">
  <img src="small-1.jpg">
</picture>

New terms and important words are shown in bold. Words that you see on the screen, in menus or dialog boxes for example, appear in the text like this: "In the JavaScript components section, do not select any checkbox."

Note

Warnings or important notes appear in a box like this.

Tip

Tips and tricks appear like this.

Reader feedback

Feedback from our readers is always welcome. Let us know what you think about this book—what you liked or may have disliked. Reader feedback is important for us to develop titles that you really get the most out of.

To send us general feedback, simply send an e-mail to , and mention the book title via the subject of your message.

If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, see our author guide on www.packtpub.com/authors.

Customer support

Now that you are the proud owner of a Packt book, we have a number of things to help you to get the most from your purchase.

Downloading the example code

You can download the example code files for all Packt books you have purchased from your account at http://www.packtpub.com. If you purchased this book elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.

Errata

Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you find a mistake in one of our books—maybe a mistake in the text or the code—we would be grateful if you would report this to us. By doing so, you can save other readers from frustration and help us improve subsequent versions of this book. If you find any errata, please report them by visiting http://www.packtpub.com/submit-errata, selecting your book, clicking on the errata submission form link, and entering the details of your errata. Once your errata are verified, your submission will be accepted and the errata will be uploaded on our website, or added to any list of existing errata, under the Errata section of that title. Any existing errata can be viewed by selecting your title from http://www.packtpub.com/support.

Piracy

Piracy of copyright material on the Internet is an ongoing problem across all media. At Packt, we take the protection of our copyright and licenses very seriously. If you come across any illegal copies of our works, in any form, on the Internet, please provide us with the location address or website name immediately so that we can pursue a remedy.

Please contact us at with a link to the suspected pirated material.

We appreciate your help in protecting our authors, and our ability to bring you valuable content.

Questions

You can contact us at if you are having a problem with any aspect of the book, and we will do our best to address it.