Ten steps to learn CSS positioning

1. position:static

The default positioning for all elements is position:static, which means the element is not positioned and occurs where it normally would in the document.

Normally you wouldn’t specify this unless you needed to override a positioning that had been previously set.

#div-1 {
 position:static;
}

2. position:relative

If you specify position:relative, then you can use top or bottom, and left or right to move the element relative to where it would normally occur in the document.

Let’s move div-1 down 20 pixels, and to the left 40 pixels:

#div-1 {
 position:relative;
 top:20px;
 left:-40px;
}

Notice the space where div-1 normally would have been if we had not moved it: now it is an empty space. The next element (div-after) did not move when we moved div-1. That’s because div-1 still occupies that original space in the document, even though we have moved it.

It appears that position:relative is not very useful, but it will perform an important task later in this tutorial.

3. position:absolute

When you specify position:absolute, the element is removed from the document and placed exactly where you tell it to go.

Let’s move div-1a to the top right of the page:

#div-1a {
 position:absolute;
 top:0;
 right:0;
 width:200px;
}

Notice that this time, since div-1a was removed from the document, the other elements on the page were positioned differently: div-1b, div-1c, and div-after moved up since div-1a was no longer there.

Also notice that div-1a was positioned in the top right corner of the page. It’s nice to be able to position things directly the page, but it’s of limited value.

What I really want is to position div-1a relative to div-1. And that’s where relative position comes back into play.

Footnotes

  • There is a bug in the Windows IE browser: if you specify a relative width (like “width:50%”) then the width will be based on the parent element instead of on the positioning element.

4. position:relative + position:absolute

If we set relative positioning on div-1, any elements within div-1 will be positioned relative to div-1. Then if we set absolute positioning on div-1a, we can move it to the top right of div-1:

#div-1 {
 position:relative;
}
#div-1a {
 position:absolute;
 top:0;
 right:0;
 width:200px;
}

5. two column absolute

Now we can make a two-column layout using relative and absolute positioning!

#div-1 {
 position:relative;
}
#div-1a {
 position:absolute;
 top:0;
 right:0;
 width:200px;
}
#div-1b {
 position:absolute;
 top:0;
 left:0;
 width:200px;
}

One advantage to using absolute positioning is that we can position the elements in any order on the page, regardless of the order they appear in the HTML. So I put div-1b before div-1a.

But wait – what happened to the other elements? They are being obscured by the absolutely positioned elements. What can we do about that?

6. two column absolute height

One solution is to set a fixed height on the elements.

But that is not a viable solution for most designs, because we usually do not know how much text will be in the elements, or the exact font sizes that will be used.

#div-1 {
 position:relative;
 height:250px;
}
#div-1a {
 position:absolute;
 top:0;
 right:0;
 width:200px;
}
#div-1b {
 position:absolute;
 top:0;
 left:0;
 width:200px;
}

7. float

For variable height columns, absolute positioning does not work, so let’s come up with another solution.

We can “float” an element to push it as far as possible to the right or to the left, and allow text to wrap around it. This is typically used for images, but we will use it for more complex layout tasks (because it’s the only tool we have).

#div-1a {
 float:left;
 width:200px;
}

8. float columns

If we float one column to the left, then also float the second column to the left, they will push up against each other.

#div-1a {
 float:left;
 width:150px;
}
#div-1b {
 float:left;
 width:150px;
}

9. float columns with clear

Then after the floating elements we can “clear” the floats to push down the rest of the content.

#div-1a {
 float:left;
 width:190px;
}
#div-1b {
 float:left;
 width:190px;
}
#div-1c {
 clear:both;
}

10. Disclaimer & Resources

These examples are extremely simplified and do not trigger some of the CSS bugs in the Windows IE browser (of which there are many).

CSS transparency settings for all browsers

Transparency is one of those weird things that is treated completely differently in all browsers. To cover all your bases, you need four separate CSS statements. Fortunately they don?t interfere with each other really, so using them all every time you wish to add transparency is no big hassle and worry-free. Here they are, and are currently set to 50% transparency:

.transparent_class {
	filter:alpha(opacity=50);
	-moz-opacity:0.5;
	-khtml-opacity: 0.5;
	opacity: 0.5;
}

Here is what each of those CSS properties is for:

  • opacity: 0.5; This is the ?most important? one because it is the current standard in CSS. This will work in most versions of Firefox, Safari, and Opera. This would be all you need if all browsers supported current standards. Which, of course, they don?t.
  • filter:alpha(opacity=50); This one you need for IE.
  • -moz-opacity:0.5; You need this one to support way old school versions of the Mozilla browsers like Netscape Navigator.
  • -khtml-opacity: 0.5; This is for way old versions of Safari (1.x) and for other browsers using the rendering engine referred to as KTHML.
SOURCE: css-tricks.com

10 Needful Steps to Help Cut Costs in the Slow Economy

There’s no escaping the slowing economy. Layoffs are being announced and companies are in cost cutting mode. Whether you are a tech at a big company or a small one man operation it’s time to cut the fat before you get cut out of work. Unnecessary expenses have to go and inefficient ways of working need to be analyzed and improved.

If done right, the use of some technologies can greatly reduce costs and make us more efficient.

Here are ten technologies every techie should consider to help cut costs in this slow economy:

1) Open Source
Dump the high cost proprietary systems for equivalent open source systems where you can. There are many operating systems, databases, content management systems, communications tools, networking and administration tools that are open source and free to use. Choose mature products with a strong community following and plenty of available support options either via developers or third party support offerings.

2) Software as a Service
Instead of spending money on time on developing complex in-house solutions to CRM, support and project management use SaaS providers such as Sales Force, Google, 37Signals and Right Now . Not only do you save money by using these third party tools by cutting development costs, but you also reduce costs on specialized hardware to run similar in-house solutions. Many SaaS solutions can also be integrated via the providers API’s.

3) Virtualization
Do you have multiple servers and workstations handling different tasks? Combine them into one machine. With virtualization suites such as ones offered by VMware you can take one machine and turn into multiple virtual machines. One machine can act as your web server, your network share and your exchange server. Each virtual machine will work independent of the other and optimize utilization of hardware resources.

4) Thin Clients
Employees no longer need to use expensive machines for light computing work such as emailing and using basic office work. Low powered thin-clients connected to a single multi-core system with x64 architecture and virtualization can power the work of multiple employees. Besides better utilization of hardware and energy, you also introduce efficiency for IT managers by reducing the # of systems they have to manage.

5) Enterprise 2.0
Get your organization connected and sharing information. Use intranet systems with built in messaging, voice messages, wikis, profiles and contact information. Keeping your employees connected and sharing information about your business can keep the organization from making costly decisions.

6) Digital Documents
Move as much of your company’s paper usage to digital as you can. Not only do you save money with printing you also save money on office space to store all that paperwork. Other ways to save more on printed costs is move to email for memos and letters. Also consider e-fax services as an alternative to fax machines.

7) Fast Efficient Networks
Using all these cost savings technologies will require a fast internal network and fast bandwidth coming in. These days companies and individuals can subscribe to fiber-optic bandwidth providers. With higher bandwidth network such as fiber lines, you can also server voice and video through the same connection. Internally make sure you’ve upgraded as much of your hardware to gigabit speeds. Newer networking gear tends to be more energy efficient and capable of handling faster network speeds. A fast network means less waiting for employees and more working.

8 ) Data Storage
Storing as much of your company’s data and information on the network keeps it accessible for employees and staff to use at any time from any location. This saves employees from physically having to search for the required data or information. The time savings will make your staff more efficient. Saving data on cheap mass storage hard drives saves you office space for storing documents and paper work.

9) Wireless
With wireless connectivity employees can work from anywhere. They are no longer stuck to their desk and their mobile systems such as laptops can move with them from meetings to conference areas. An added benefit of wireless systems are the savings in running wire for hard networking.

10) Virtual Office
Cut the overhead costs of keeping employees on site by allowing them to work from home. Virtual offices reduce the amount of resources required for equipment and office space. Many companies have already instituted virtual office policies and have realized great results from doing so. With virtual offices upfront investments in secure networking will be required. Setting up VPNs and access to other network resources for employees will be a must.

Copied from bytes.com

71 Links Help You To Learn Webdesign

General

Programs

HTML

CSS

Design

Continue reading

Some Popular CSS Frameworks for Web Development

A CSS framework is a library that is meant to allow for easier, more standards-compliant styling of a webpage using the Cascading Style Sheets language. Just like programming and scripting language libraries, CSS frameworks package a number of ready-made options for designing and outlaying a webpage…

Below is a roundup of the various CSS frameworks out there and a short description from the authors of each framework.

960 Framework

Description from Nathan Smith: The 960 Grid System is an effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. There are two variants: 12 and 16 columns, which can be used separately or in tandem. Blueprint CSS Framework

Blueprint CSS framework

Blueprint is a CSS framework, which aims to cut down on your CSS development time. It gives you a solid CSS foundation to build your project on top of, with an easy-to-use grid, sensible typography, and even a stylesheet for printing.

Elements CSS Frameworks

Description from Project Designs: Elements is a down to earth CSS framework. It was built to help designers write CSS faster and more efficient. Elements goes beyond being just a framework, it’s its own project workflow.It has everything you need to complete your project, which makes you and your clients happy.

CwS CSS Framework

Description from Content with Style: If you’ve been creating sites with CSS for a while you may be getting frustrated with having to recreate and retest basic layouts on a regular basis. In this article I’m trying to illustrate a simple way of skipping the tedious startup on your average project, letting you get to the interesting stuff as quickly and efficiently as possible. I’ve not attempted to explain the layouts included here so it may not be suitable if you’re a CSS beginner. Sorry about that… Feel free to dissect them yourself if you’re interested; I’ve kept them as simple as possible.

YAML CSS Framework

Description from YAML.de: Yet Another Multicolumn Layout (YAML) is an (X)HTML/CSS framework for creating modern and flexible floated layouts. The structure is extremely versatile in its programming and absolutely accessible for end users.

YUI Grids CSS

Description from Yahoo!: The foundational YUI Grids CSS offers four preset page widths, six preset templates, and the ability to stack and nest subdivided regions of two, three, or four columns. The 4kb file provides over 1000 page layout combinations.

Boilerplate CSS Framework

Description from Nathan Borror: As one of the original authors of Blueprint CSS I’ve decided to re-factor my ideas into a stripped down framework which provides the bare essentials to begin any project. This framework will be lite and strive not to suggest un-semantic naming conventions. You’re the designer and your craft is important.

CleverCSS

CleverCSS is a small markup language for CSS inspired by Python that can be used to build a style sheet in a clean and structured way. In many ways it’s cleaner and more powerful than CSS2 is. The most obvious difference to CSS is the syntax: it is indentation based and not flat. While this is obviously against the Python Zen, it’s nonetheless a good idea for structural styles.

WYMstyle: a CSS framework

Description from WYMstyle: WYMstyle is a set of CSS files, that you can easily combine to very quickly create the layout of your web sites. WYMstyle aims to suppress the tedious compatibility testing across browsers for each created website, by providing CSS modules which are reliable and well-tested.

How to Optimise Flash Sites..a brief note…

If there is a really hot potato that divides SEO experts and Web designers, this is Flash. Undoubtedly a great technology to include sounds and picture on a Web site, Flash movies are a real nightmare for SEO experts. The reason is pretty prosaic – search engines cannot index (or at least not easily) the contents inside a Flash file and unless you feed them with the text inside a Flash movie, you can simply count this text lost for boosting your rankings. Of course, there are workarounds but until search engines start indexing Flash movies as if they were plain text, these workarounds are just a clumsy way to optimize Flash sites, although certainly they are better than nothing.

Why Search Engines Dislike Flash Sites?

Search engines dislike Flash Web sites not because of their artistic qualities (or the lack of these) but because Flash movies are too complex for a spider to understand. Spiders cannot index a Flash movie directly, as they do with a plain page of text. Spiders index filenames (and you can find tons of these on the Web), but not the contents inside.

Flash movies come in a proprietary binary format (.swf) and spiders cannot read the insides of a Flash file, at least not without assistance. And even with assistance, do not count that spiders will crawl and index all your Flash content. And this is true for all search engines. There might be differences in how search engines weigh page relevancy but in their approach to Flash, at least for the time beings, search engines are really united – they hate it but they index portions of it.

Continue reading

Some PHP AJAX Frameworks..for your development

Sajax:

Sajax is an open source tool to make programming websites using the Ajax framework — also known as XMLHTTPRequest or remote scripting — as easy as possible. Sajax makes it easy to call PHP, Perl or Python functions from your webpages via JavaScript without performing a browser refresh. The toolkit does 99% of the work for you so you have no excuse to not use it.
Official Site: Sajax

Xajax:

is an open source PHP class library that allows you to easily create powerful, web-based, Ajax applications using HTML, CSS, JavaScript, and PHP. Applications developed with xajax can asynchronously call server-side PHP functions and update content without reloading the page.
Official Site: xajax

Cake PHP:

Cake is a rapid development framework for PHP which uses commonly known design patterns like ActiveRecord, Association Data Mapping, Front Controller and MVC. Our primary goal is to provide a structured framework that enables PHP users at all levels to rapidly develop robust web applications, without any loss to flexibility.
Official Site:Cake PHP

Saja:

Saja is a lightweight, open-source AJAX scripting engine for PHP4/5, with optional secured data transfer. It is designed for the speedy creation of simple, secure, and maintainable AJAX applications, without the need to write any JavaScript.
Official Site:Saja

Ajason:

PHP 5 library and JavaScript client for AJAX. Fetch data asynchronously and develop interactive GUI-like Web applications. Call PHP functions and object methods from JavaScript and exchange even complex data types between client and server.
Official Site:ajason