Category Archives: Uncategorized

All about Usability and Accessibility of Model Window in Web Design


Model window is the most essential element of the web page in modern days, as it provides extra real estate on the screen and serving contextual content ultimately. Despite its usefulness, we never think of its user experiences, usability, and accessibility for instance, through keyboard keys, instead of mouse.


For web and mobile designers, popup, nag screen, interstitial, etc. are devil creations and enemies of better user experiences, against the user friendly and useful model windows, created with great care. In fact, model windows offer unprecedented advantages for developers like delivering contextual info, notifications, actions in contexts of current screen, and most importantly some extra space for content or short forms to fill up quickly.

Ignorance of Model Windows

Despite their essential and usefulness, developers often ignore them during designing and programming, particularly at the usability, accessibility, and user experiences point of views in modern responsive web designing. For instance, if any user is favoring navigation of your website through keyboard instead of pointing device like mouse, she will get frustrations when a model windows popup immediately in contexts of some actions or anyway.

Yes, there are frustrations because dealing with model windows always need mouse pointer to take some actions on button or activate the input fields on the model windows. If user wants to ignore it and close it, she again has to use mouse pointer to click the ‘X’ close button on the model windows anywhere.

Of course, there are alternatives to use keyboard shortcuts like tab-key or alter-tab keys, but they are not universal and applicable in all OS or versions of OS. If, user is reaching on the model windows there is no guarantee that Esc key shortcut will work to close the model windows.

Need Attentions

In short, we can say that we need some programming hacks to make model windows accessible and usable in all sorts of use cases of website, be it on desktop or on the handheld devices. Let’s see how we can improve the semantics of the markup of model windows in this post.

Improvements in Semantic

Generally, when we code for model windows, we give it an id in div tags and state a hovering action to close it. Thus, this simple div element of model window has nothing in sense of semantic meaning when any user wishes to use it or closes it through keyboard or screen reader actions.

In order to understand this, if we take one code example of a model window, we can see how improvement in coding is possible.

<div id="modal_overlay">
<div id="modal_close" onClick="modalClose()">

Now in this code, if we correct the semantic of the above code by writing markup for the button instead of simple div element as well as adding an AIRA label for screen reader.

<div id="modal_overlay">
<button type="button" class="btn-close" id="modal_close" aria-label="close">

This way we address our two targeted issues: keyboard action through tab key and focused state through AIRA label for screen readers. As button can be tabbed and this action falls in convention on the web, our both purposes, usability and accessibility through keyboard have solved.

If you want to take user experiences at the next level, some more efforts through CSS and JavaScript are essential. Let’s check them one-by-one in code examples.

Adding focus states

We grab attention of users through some effects like shadow towards the button so they can know that it is active element and will respond through keyboard actions too. We can do this way:

:focus {
box-shadow: 0 0 3px rgba(0,0,0,.75);

Generally, when model window appears, its background freezes and user begins focusing on the model window. However, this phenomenon never happens automatically and you have to first save the last active element on the screen through coding and in next step, you need to code to shift the focus of user on the model window. Thus, you have to add code for both action through following ways.

Save the Background

You can save background element by adding variable and executing it through function.

var lastFocus;
function modalShow () {
lastFocus = document.activeElement;
function modalClose () {
lastFocus.focus(); // place focus on the saved element

Shift the Focus

You can do this by giving that element an id and set attributes for keyboard action:

var modal = document.getElementById('your-modal-id-here');
function modalShow () {
modal.setAttribute('tabindex', '0');

Closing Model Window

We can do this simply by using Escape key as it used as standard convention in digital world.

function modalClose ( e ) {
if ( !e.keyCode || e.keyCode === 27 ) {
// code to close modal goes here
document.addEventListener('keydown', modalClose);

There are more usability steps, but expert and dedicated web developers at Lujayn, always using those advance steps in certain contexts and in favor of its patrons.

Check Performance Metrics across Form Factors In Google Analytics

Enabling Form Factors in Universal GA
Enabling Form Factors in Universal GA


With the evaluation of responsive web designing, we need to advance our analytics too. We have techniques and tools to know the content breakpoints, but we are devoid of the form-factors based breakpoints. Let’s have a try to include them in our GA.


When we design for responsive website, we not design for devices, but for the different form factors means we have to address various form factors by deciding their performance metrics. This is very true in case of UX designing because we want to accelerate and optimize the user experiences for a particular device or set of devices.

Form Factors

Unfortunately, we can’t address each device individually or set of devices one-by-one due to big fragmentation issues on hardware and OS fronts, whether it is iOS and iOS devices or Android OS or Android devices. However, we can address common form factors of the every device and can categorizing them according to their form factors. We can categorize form factors by identifying device experiences in following ways:

  • Through usage or posture
  • Through input methods
  • Through output or screen

These form factors enable us to use Google Analytics and other web and mobile analytics in our responsive designing and give perfect clues to iterate design in ongoing projects or through regular updates.

Form Factors in GA

There are WURFL.js used in the GA to measure its given form factors and we have to include it in to the source code of our responsive websites. Once we introduce WURFL.js into the page code, it creates a global object that you can access through JavaScript in GA and measure various form factors given by it like…

  • App
  • Smartphone
  • Tablet
  • Feature Phone
  • Other Mobiles
  • Desktop
  • Smart TV
  • Robot
  • Other Non-Mobile Devices including wearable

Thus, your Universal GA code would be…

/* Define the custom dimensions */

ga('send', 'pageview', {

'dimension1': WURFL.complete_device_name,

'dimension2': WURFL.form_factor,

'dimension3': WURFL.is_mobile


Once you write or re-write GA code in website template you have to go to GA account where you have to define custom dimensions in admin panel

Admin>Custom Definitions>Custom Dimensions

Enabling Form Factors in Universal GA

Now, Google server will collect the data and you need to analyze them through your GA account in your browser so you have to make some customization of your dashboard. Now, click on

Audience>Custom>Custom Variables

For Universal GA, your custom dimensions will available along with the other standard dimensions

By enabling form factor dimensions, we can measure bounce rate and pages per visit to get big picture of their behavior on the various devices. Thus, we can draw fine conclusions in our responsive web designing projects.

Creating Widgets

GA offers a best feature to get alerts when website performance changes for custom dimensions and that in form of Widgets on Dashboard. At first place we will create Pie-Chart widget to analyze how much your responsive website is being used by different form factors.

On Dashboard, click

Add Widget>Pie>Sessions>form factor>Custom Dimension

Here you will group sessions by the form factor variables one-by-one.

Secondly, create widgets for Visits and Bounce rate same the way. Thus, you will have big picture of changes in form factors that are taking place when you make any change in your website design or programming. Of course, you have to add some filters to standard metrics in these widgets and you can do is simply selecting timeline diagram and filter the data flow with your custom variables.

If you create one widget for each of your form factor, you need to watch, you will have good ideas for your responsive website design.

Lujayn has expert responsive web designers who have perfect knowledge of SEO and various SEO tools to use in their advance designing processes.

Let Us Comprehend CUBI—A User Experience Model Part 2

Content Layer in CUBI Model for UXWe have realized the pains of the UX designer due to lack of suitable model or framework to work on in the previous part 1. Moreover, we have seen that why we need CUBI model and what its ultimate purposes or benefits to the modern designers for the better UX? According to our CUBI model content is one of the core parts among the four components.

Content Layer

During the designing process for UX when we are going to incorporate content in the project do several activities and if we are going to depict those activities in the layer forms, we can place content types next to the core of content presentation. Then next layers would be content models, content treatments, content methods, and content architecture. Let’s check them one-by-one in this series.

Types of Content

Initially content has only one or two forms like texts and images in early web era. Today the types of content has all multimedia formats optimized for the web such as audio, video, graphics, data tables and data presentations/chart/graphs, and documents of many unimaginative formats. The more interesting thing is that these variations in content types are not stick with some standalone formats, but there are enough opportunities to combine available formats in various combination creatively and contextually to solve our problems of designing and UX.

For instance, infographics have super combinations of text and images where designers have free reigns to add data visualization techniques and illustration to go on storytelling styles. Pinterest like social media is solely based on such modern variants of the content types and their combinations.

Models of Content

As we have seen above that various combination of content are in use and if we arrange them logically, they become content models. In above example infographics is a sort of model. Similarly, recipe in cooking app or alike apps is a model consisting of different content including texts as instructions, ingredients as data, images of food or ingredients or food, and video describing the process are various content types in it.

Effects on Content

We treat content very different ways from screen to screen or apps such as we apply visual styles like 2D/3D effects on the images/photos to bring good aesthetics. Texts may have unique personality through various text styles. Graphics may have opportunities to reflect brands or personality through theme creation. Thus, UX designers have to learn and follow various content treatments feasible under the umbrella of contemporary styling practices or content treatments.

Methodology of Content

We can make content more interesting hence engaging through various presentation methods of content such as storytelling, metaphors, analogy, scenario creation, symbolism, and many other creative ways.

Architecture of Content

We know if all content types, models, methods, and effects are not in an organized manner or follow a definite structure, we can’t get good UX or solve the website’s problems/client’s problems. Therefore, information architecture or content architecture has great places in the web or mobile designing.

If you like to see the best examples of the roles of content in UX, please check the portfolio of Lujayn carefully.

Author Bio:

Shoaib Marfatiya is an eminent writer in web development industry and its verticals. He has contributed a lot by throwing light on very intricate issues of web and mobile development community.

Secure Positive ROI by Developing Appropriate CTMS Part 2

Maintaining patient registry through spreadsheet is old practice and today we have CTMS with modern technologies that allows us to feed patient data instantly using mobile devices quickly and accurately using various features and functionality of latest CTMS programming practices


As I have promised in Part 1 that we will check how we can streamline the workflow during the process of clinical trials using our ultramodern CTMS development technologies and out-of-box strategies for your CTMS programming project.


Extensive Help to Various Medical Fields

Today we are living in mobile era where cloud-computing technologies have eased our highly intricate and interactive tasks in all fields including medical and its allied industries or fields. For instance, our modern eClinical system or CTMS (Clinical Trial Management System) is capable to support extensive operations at independent research sites, SMOs, and site networks in order to help academic medical centers, CTSAs, various research hospitals including private and government run bodies as well as chronic disease centers including cancer.


No Spreadsheets At All

In olden days, we were solely rely on spreadsheets in our age old PCs and facing ample distractions to feed data quickly and accurately. Now, with tablets and smartphones we need not to go to computer room or office space located in our premises. Instead, we are capable to feed data spontaneously near the bed of patients or from the operation theater in some instances. Highly user-friendly UIs of tablets and smartphone or laptop and even of desktop have removed the needs of spreadsheets at all and you have suggestive and quickly filled input boxes that allow you to feed securely and accurately your patient registry data or clinical trials data by various level of permissions.


Secure and Qualitative Data

You don’t have any fear of loss of data or inconsistency of data as all data go directly to the web services or cloud computing services in real-time as well as stored in offline mode and updated later on. Different user permission level and comment entering tricks make data more reliable and valid at technical point of view. If we want to see the doctors’ comments on that data feed, we can check them in real-time, and get instant feedback on those data. This exercise not only reduce the errors in data and hence research, but also eliminate the fears of fraudulent practices and entry of wrong professionals in our filed.


Easy Schedule and Tracking of Subject Visit

In clinical research or patient registry programs, we have to spend considerable time to fix the next visits of our patients and push our imaginations to point down the needs and sketching the possible scenario on those future visits. If our CTMS has perfect calendar and UI that prompts various scenarios in advance by coordinating various data from various centers and from different professionals we can accurately fix the schedule of next visits as well as our trained staff can follow the schedule and remaindering relevant patients beforehand and before the appointment time.


Concluding Remark for the Part 2

This real-time updates of schedule not only ease the work of doctors, nurses, office staff, but also help researchers to set their own timetable accordingly and keep things or instruments ready for those fixed visits in our patient registry. In short, these sorts of CTMS solutions help us to get:

  • Automatic calendar with calculation abilities to schedule visits of the subjects of our research in clinical trials or in patient registry maintenance program
  • A central repository in order to maintain our protocols, patients/subjects, and data of visits in past as well as in future
  • Provide information to the doctors, staff, and patients themselves regarding to their previous visits and future visits and its schedules
  • Enable us to compute financial calculations regarding to the patient registry software or disease registry or device trials programs for labs, institutions, and pharmaceutical companies



Keep Track Of Stacking Contexts and Orders in CSS Using Z-Index


Usage of Z-index
Usage of Z-index

Since we have basic understandings of the concepts of Z-index in previous series, we know how to implement them in creative ways in modern responsive web designing. In CSS, we have different contexts in form of different sets of elements. Thus, we can arrange their stacking orders in relative to their own sets of contextual elements. In this post, I would like to mention something more than CSS alone like JavaScript and SASS or LESS.

Z-index for Dynamic Elements

JavaScript is use for dynamic purposes and Z-index can apply dynamically in JavaScript syntax, which is somewhat similar in format. In JavaScript Z-index properties, you have ot use “camel casing” instead of hyphenated CSS properties. Thus, your “z-index” will become “zIndex”. For instance, look at the code example below:

var myElement = document.getElementById("gold_box"); = "relative"; = "9";

Z-index for Sassy Elements

Today in cloud computing age, we are highly depending on SASS or LESS and the syntax of SASS is quite simple for stacking orders. They are call SASS list like:

$elements: project-covers, sorting-bar, modals, navigation;

Here the order of elements are deciding the stacking order in the appearance of the elements. In simple words, from lowest to highest z-index assign to each element in the order. For instance, in above example “project-cover” element will return “z-index: 1” and “navigation” would “z-index: 4”.

It is true that this simplification in order pave ways to add any element in between the other elements and z-index of all elements would automatically updated according to their new orders. For example, if we want to add user-tooltip just after the project-cover element, we simply have to add that class “.user-tooltip” in the SASS order in following ways.

$elements: project-covers, user-tooltip, sorting-bar, modals, navigation;

Thus, entire syntax would be:

.project-cover {
z-index: 1;
.user-tooltip {
z-index: 2;
.sorting-bar {
z-index: 3;
.modal {
z-index: 4;
.navigation {
z-index: 5;

Fortunately, we can go for many complex layouts using multiple contexts and stacking orders. This is possible due to possibilities to create a new stacking order for each stacking context by giving any children of the element a stacking order specific to its parents. For sake of better understanding, lets add children elements to the one of the main element of the list “modals” in following way.

$elements: project-covers, user-tooltip, sorting-bar, modals, navigation;

$modal-elements: fields, form-controls, errors, autocomplete-dropdown;

Therefore, resulting z-index would generate following ways in compiler:

.modal {
z-index: 4;
.modal .field {
z-index: 1;
.modal .form-controls {
z-index: 2;
.modal .error {
z-index: 3;
.modal .autocomplete-dropdown {
z-index: 4;

Thus, using hard-core values for z-index like 999 or 99999 may prove fatal in CSS so stacking order creation in SASS may prove beneficial for long-term integrity and collaboration if we save the above SASS file as “_zindex.scss” and call these global orders in your specific CSS files as per needs.

Show Creativity with Z-Index

There are many practical implementations of z-index properties of CSS such as:

  • In case of overlapping tabbed navigation
  • For CSS Tooltips
  • For light box
  • For drop-down menu
  • In photo gallery effects
  • In layered layout enhancements
  • For fancy social bookmarking boxes
  • To create perfect full page background image
  • And in many more innovative ways

Expert web programmers at Lujayn know how to go creatively using latest CSS technologies like z-index to create 3D effects dynamically.



Know Company Culture before Awarding Your Project Part 3

Extending thread from Part 2, I would like to keep discussion on opensource platform and we shall now jump from PHP to the next most popular opensource language JAVA today.

About Java Culture

Before a half decade Java become infamous against the rival opensource languages like PHP, Ruby, Python, etc. due to its rigidity on J2EE or Swing and Sun’s failure to be contemporary to focus on the growth rather than cash it in the market.

Android Infusing Oxygen

Fortunately, Google has revived its status again by posing Android based on it and established new trends to make the Java cool again through high quality libraries and augmentation of JVM to meet the recent challenges on the web and mobile sphere.

Notable Advantages

Although, Java has several advantages based on its philosophy attached such as it is highly portable language and derived from C or C++ class syntax with some automatic memory management features. Since modern era is of OOP Android and Java have object orientation inherently.

When you are going to select a suitable Java developers for you there would be a precautionary question that whether he or she is familiar with good IDE for Java or not because Java is not PHP so it needs a definite IDE like Eclipse to go smoothly and rapidly.

Java has one more advantage that threading is a way to go and have pretty JVM to manage many things in advance as well as secure code and environment for better security features. However, in practice today Java is becoming extinct against the rise of Android and its biggest rival PHP.

Python—A Well Established Language

Before PHP era, web and computer software developers were cherishing two main languages for dynamic programming and they were Ruby (Ruby On Rails) and Python. As per my experiences, Python is designed for seasoned developers to meet their end through a single straight way because in Python you can’t go outside the one defined way to do things. Therefore, Python is still famous for backend applications like NLP, Biotech, SOA, etc. elements

Pros & Cons of Python

Despite their dynamic nature Ruby and Python both suffering from some obvious drawbacks like failure on performance credentials and concurrency. However, some classic and some fresher still preferring coding in Python due to its quality to produce superb documents and its best libraries to tackle intricate problems custom ways. Python is great for teamwork as it is process oriented approaches are good enough for a good collaborative team. Therefore, it is favorite among the seasoned, pragmatic, experienced, and full-stack developers who are thriving for modern yet well-proven dynamic web development languages.