Wednesday, 21 May 2014

opacity css for all browser

The following css code is for opacity :

opacity: .8; 
 /* For IE 5-7 */
filter: progid:DXImageTransform.Microsoft.Alpha(Opacity=80);
 /* For IE 8 *
 -MS-filter: "progid:DXImageTransform.Microsoft.Alpha(Opacity=80)";

Wednesday, 14 May 2014

how get the tablet device by javascript


Some times you may detect device by javascript.

if you want to detect tablet device by javascript code you will have to put the following code in script

var isMobile = window.matchMedia("(min-width: 760px) and (max-width: 959px)");

if(isMobile.matches)
{
   alert "i am in tablet";
}

same way for phone or ipad


How you will get the url of page in php


If you print  $_SERVER['HTTP_HOST'] you wll get the host address, suppose www.websnit.com

And if you print $_SERVER['REQUEST_URI'] you will get the last part of domain name.


I have used it in WordPress site to track the home page.

full address is :
"http://".$_SERVER['HTTP_HOST']. $_SERVER['REQUEST_URI'];





Bismillahir Rahmanir Rahim

In the name of Allah the most Merciful the most Beneficent. 

Now a days, IT is most prosperous sector in the world.
Several way you can contribute here. I will discuss about a open source language PHP and mysql here.

Keep touch with me to rich your knowledge. I am waiting for your reply also.

Firstly I want to tell about me.

I am Syed Nurul Islam From Bangladesh.

A Senior Software Engineer,  working in a web based software firm.