Tag Archives: CSS

CSScaffold

CSScaffold is a CSS framework written in PHP. it uses PHP to extend CSS. The syntax looks and feels like CSS, except that you have some powerful abilities.

The best part is that all of this is done transparently. You can drop Scaffold into your site and you’ll instantly have access to all of its functionality. Scaffold requires a web server with PHP 5+ and Mod_rewrite should enabled if you want it work automatically .

Load page content based on menu using simple javascript

Here i have used a javascript function that will display blcok based on the menu that you clicked .
Paste the below given code in  page and load that so as to get a better idea of how it works . 

<script type=”text/javascript”>
function NextPage($pageID){
for($i=1;$i<=3;$i++){
if(Number($i)==Number($pageID))
document.getElementById(“page”+$i).style.display=’block’
else
document.getElementById(“page”+$i).style.display=’none’
}
}
</script>
<table>
<tr>
<td>
<a href=”javascript:NextPage(‘1’);”>Page1</a>
<a href=”javascript:NextPage(‘2’);”>Page2</a>
<a href=”javascript:NextPage(‘3’);”>Page3</a>
</td>
<td>
<div id=”page1″ style=”display:block”>
<strong> Page 1</strong> <br>
It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout. The point of using Lorem Ipsum is that it has a more-or-less normal distribution of letters, as opposed to using ‘Content here, content here’, making it look like readable English. Many desktop publishing packages and web page editors now use Lorem Ipsum as their default model text, and a search for ‘lorem ipsum’ will uncover many web sites still in their infancy. Various versions have evolved over the years, sometimes by accident, sometimes on purpose (injected humour and the like).

</div>

<div id=”page2″ style=”display:none”>
<strong> Page 2</strong> <br>
It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout. The point of using Lorem Ipsum is that it has a more-or-less normal distribution of letters, as opposed to using ‘Content here, content here’, making it look like readable English. Many desktop publishing packages and web page editors now use Lorem Ipsum as their default model text, and a search for ‘lorem ipsum’ will uncover many web sites still in their infancy. Various versions have evolved over the years, sometimes by accident, sometimes on purpose (injected humour and the like).

</div>

<div id=”page3″ style=”display:none”>
<strong> Page 3</strong> <br>
It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout. The point of using Lorem Ipsum is that it has a more-or-less normal distribution of letters, as opposed to using ‘Content here, content here’, making it look like readable English. Many desktop publishing packages and web page editors now use Lorem Ipsum as their default model text, and a search for ‘lorem ipsum’ will uncover many web sites still in their infancy. Various versions have evolved over the years, sometimes by accident, sometimes on purpose (injected humour and the like).

</div>
</td>
</tr>
</table>

Align divs horizontally – CSS

<div style=”float:left; width:300px;”>

<div style=”float:left; width:60px;”>Test 1</div>

<div style=”float:left; width:60px;”>Test 2</div>

<div style=”float:left; width:60px;”>Test 3</div>

<div style=”float:left; width:60px;”>Test 4</div>

<div style=”float:left; width:60px;”>Test 5</div>

</div>