الثلاثاء، 22 أبريل 2014


As you browse the web, browsers can remember lots of information such as the website you have visited, files you have downloaded and other more, such information are called browsing history. Most of the web browsers stores information on their browsing history, if you are using public computer or a shared computer and want to delete browsing history from computer, can do it with different methods. Here I have explained different methods for deleting browsing history from different browsers
.

Deleting Browsing History From Control Panel



1. Go to control panel from start button. If you are viewed by category option, Click on Network and Internet option. 

Deleting Browsing History From Control Panel




















2. On the internet option, click on 'Delete Browsing History and Cookies'.


Deleting Browsing History From Control Panel

OR,  On the view by icon option, click on 'Internet Options'. On the browsing history of general tab, click on Delete button.

Deleting Browsing History From Control Panel

Check mark on the options for which you want to delete and click on delete button.



Deleting Browsing History From Chrome Browser




Deleting Browsing History From Chrome Browser
1. Click on 'Customize and control Google Chrome' icon on the top right corner and click on History option.

2. Click on 'Clear browsing data...' button.

3. On the new window check the options and click on  'Clear browsing data...'  button.

Deleting Browsing History From Chrome Browser



















Deleting Browsing History From Mozilla Firefox



1. Click on Firefox button on top left corner, mouse over on 'History' option and click on 'Clear recent history'.

Deleting Browsing History From Mozilla Firefox

2. Select the time range to clear and click on 'Clear Now' button.

Deleting Browsing History From Mozilla Firefox


Deleting Browsing History From Internet Explorer



1. On the Tools options, click on Internet Options. 

Deleting Browsing History From Internet Explorer

2. On the browsing history of general tab, click on Delete button. On the new window, check mark on the options for which you want to delete and click on delete button as given above.

Deleting Browsing History From Internet Explorer



Related Posts


How to Delete Browsing History From Browser ?

Posted at  1:50 ص - by mego almasry 0


As you browse the web, browsers can remember lots of information such as the website you have visited, files you have downloaded and other more, such information are called browsing history. Most of the web browsers stores information on their browsing history, if you are using public computer or a shared computer and want to delete browsing history from computer, can do it with different methods. Here I have explained different methods for deleting browsing history from different browsers
.

Deleting Browsing History From Control Panel



1. Go to control panel from start button. If you are viewed by category option, Click on Network and Internet option. 

Deleting Browsing History From Control Panel




















2. On the internet option, click on 'Delete Browsing History and Cookies'.


Deleting Browsing History From Control Panel

OR,  On the view by icon option, click on 'Internet Options'. On the browsing history of general tab, click on Delete button.

Deleting Browsing History From Control Panel

Check mark on the options for which you want to delete and click on delete button.



Deleting Browsing History From Chrome Browser




Deleting Browsing History From Chrome Browser
1. Click on 'Customize and control Google Chrome' icon on the top right corner and click on History option.

2. Click on 'Clear browsing data...' button.

3. On the new window check the options and click on  'Clear browsing data...'  button.

Deleting Browsing History From Chrome Browser



















Deleting Browsing History From Mozilla Firefox



1. Click on Firefox button on top left corner, mouse over on 'History' option and click on 'Clear recent history'.

Deleting Browsing History From Mozilla Firefox

2. Select the time range to clear and click on 'Clear Now' button.

Deleting Browsing History From Mozilla Firefox


Deleting Browsing History From Internet Explorer



1. On the Tools options, click on Internet Options. 

Deleting Browsing History From Internet Explorer

2. On the browsing history of general tab, click on Delete button. On the new window, check mark on the options for which you want to delete and click on delete button as given above.

Deleting Browsing History From Internet Explorer



Related Posts


الخميس، 3 أبريل 2014


Best Online Back-link Checker Tools ListI have already posted the most effective tips for your link building success on my previous post, you can achieve best backlinks for your websites only by applying most effective and successful link building strategies. While gaining quality backlinks for your website, you have to find out and analyze the links you have gained. By using these best online backlink checker tools which I have listed here, you can discover your or your competitors websites backlink from the reports or information generated by them.  



List of Best Online Backlink Checker Tools




MajesticSEO.com# 1) MajesticSEO.com: It is one of the best online backlink checker tool and provides free as well as paid service to analyze your website. It provides the basic URL information such as number of external backlinks, referring domains, referring IPs etc. History chart also shows external backlinks and referring domains over the last 90 days. You can get detailed report about backlinks and anchor text from the respective tabs.


OpenSiteExplorer.org
# 2) OpenSiteExplorer.org: Open Site Explorer is another tool to discover links linking to your website provided by MOZ.com. Using this tool, you can compare up to 5 sites to compare to your competitor sites. You can explore inbound links, Top pages, Anchor text and other more features. To overcome the daily limits you have to register and log in using MOZ account.



Ahrefs.com# 3) Ahrefs.com: It provides more detailed report in the free service also provides paid service for more features. On the main window, it provides URL Rank, Ahrefs Domain Rank, Total number of backlinks and referring domains. It also provides total referring pages, total referring domains and new and lost backlinks on chart.


RankSignals.com
# 4) RankSignals.com: It is free to use backlink checker tool to discover SEO links and traffic sources of your website and your competitors. It provides the list of title and URL of linking page, link anchor text and its page rank.


# 5) Backlinkwatch.com: It also a free tool to get complete detailed information about quality and quantity of backlinks pointing to your website. You can find anchor text, page rank, total outbound links on the page along with no-follow tag for no-follow links.
Backlinkwatch.com


# 6) SmallSeoTools.com: Backlink checker tool of Small SEO Tools provides total number of backlinks, page URL that contain your website's links, website PR, Page PR, Anchor text and flag used in link with 10 results at a time.
SmallSeoTools.com


# 7) MonitorBacklinks.com: It also provides free as well as paid service for advanced options. You can find out total backlinks, unique domain, unique IPs, number of no-follow links, .edu and .gov links. If your registered for this site, can monitor up to 2 domains and manage up to 500 links.

MonitorBacklinks.com


Digibacklink.com# 8) Digibacklink.com: It is a free to use website backlink checker tool, which provides total number of backlinks along with link flag, target, page rank and Moz Rank. You can see more back-links up to 1000, if connected using Facebook.



# 9) AnalyzeBacklinks.com: By using this backlink checker tool, you can find out linked URLs, Anchor text, total links, outbound links, title of the page and text found on the link.
AnalyzeBacklinks.com

# 10) LinkDiagnosis.com: It is a free tool to check backlinks for your website. It uses SEO Moz engine to analyze and generate reports.




Related Posts




Best Online Backlink Checker Tools List

Posted at  11:25 م - by mego almasry 0


Best Online Back-link Checker Tools ListI have already posted the most effective tips for your link building success on my previous post, you can achieve best backlinks for your websites only by applying most effective and successful link building strategies. While gaining quality backlinks for your website, you have to find out and analyze the links you have gained. By using these best online backlink checker tools which I have listed here, you can discover your or your competitors websites backlink from the reports or information generated by them.  



List of Best Online Backlink Checker Tools




MajesticSEO.com# 1) MajesticSEO.com: It is one of the best online backlink checker tool and provides free as well as paid service to analyze your website. It provides the basic URL information such as number of external backlinks, referring domains, referring IPs etc. History chart also shows external backlinks and referring domains over the last 90 days. You can get detailed report about backlinks and anchor text from the respective tabs.


OpenSiteExplorer.org
# 2) OpenSiteExplorer.org: Open Site Explorer is another tool to discover links linking to your website provided by MOZ.com. Using this tool, you can compare up to 5 sites to compare to your competitor sites. You can explore inbound links, Top pages, Anchor text and other more features. To overcome the daily limits you have to register and log in using MOZ account.



Ahrefs.com# 3) Ahrefs.com: It provides more detailed report in the free service also provides paid service for more features. On the main window, it provides URL Rank, Ahrefs Domain Rank, Total number of backlinks and referring domains. It also provides total referring pages, total referring domains and new and lost backlinks on chart.


RankSignals.com
# 4) RankSignals.com: It is free to use backlink checker tool to discover SEO links and traffic sources of your website and your competitors. It provides the list of title and URL of linking page, link anchor text and its page rank.


# 5) Backlinkwatch.com: It also a free tool to get complete detailed information about quality and quantity of backlinks pointing to your website. You can find anchor text, page rank, total outbound links on the page along with no-follow tag for no-follow links.
Backlinkwatch.com


# 6) SmallSeoTools.com: Backlink checker tool of Small SEO Tools provides total number of backlinks, page URL that contain your website's links, website PR, Page PR, Anchor text and flag used in link with 10 results at a time.
SmallSeoTools.com


# 7) MonitorBacklinks.com: It also provides free as well as paid service for advanced options. You can find out total backlinks, unique domain, unique IPs, number of no-follow links, .edu and .gov links. If your registered for this site, can monitor up to 2 domains and manage up to 500 links.

MonitorBacklinks.com


Digibacklink.com# 8) Digibacklink.com: It is a free to use website backlink checker tool, which provides total number of backlinks along with link flag, target, page rank and Moz Rank. You can see more back-links up to 1000, if connected using Facebook.



# 9) AnalyzeBacklinks.com: By using this backlink checker tool, you can find out linked URLs, Anchor text, total links, outbound links, title of the page and text found on the link.
AnalyzeBacklinks.com

# 10) LinkDiagnosis.com: It is a free tool to check backlinks for your website. It uses SEO Moz engine to analyze and generate reports.




Related Posts




الخميس، 27 مارس 2014


Best Online Sitemap Generators List
Sitemap is a most important part of any website or blog. A Sitemap is an XML file that lists URLs for a site along with additional metadata about each URL when it was last updated, how often it usually changes, and how important it is, relative to other URLs in the site, so that search engines can more intelligently crawl the site. Sitemap makes any website more SEO friendly and helps to index on search engines easily and also helps the visitors to find out the contents on the website. Here are some list of best online sitemap generator tools along with their descriptions, you can use up them to create, place on your website or blog and to submit on search engines like Google, Yahoo, Bing, Ask, AOL etc




List of Online Sitemap Generators 




1. xml-sitemaps.comIt is one of the best online sitemap generator tool. It provides free as well as paid or pro service for sitemap creation. By using a free service maximum 500 pages will be indexed in sitemap. Along with XML sitemap, you can create text and HTML sitemaps for the list of webpage on your website.

2. web-site-map.com: It is best free to use online sitemap generator tool. You can index up to 3500+ pages on sitemap file. After generating XML sitemap, you can validate by using W3C Markup Validation Service. If you want the free tool for sitemap generation I recommended this site.

3. sitemapdoc.com: Sitemapdoc.com is the another site for generating different formats of sitemaps. You can create XML sitemap, Text sitemap, HTML sitemap and RSS feed. You can check for the image and check website for viruses using AVG, Norton, McAfee, Google etc.

4. addme.comHere you can generate the sitemap with providing your website URL, Frequency, Priority, Last date modified, Name and Email address. After generating sitemap it will be emailed to you on the given email address.

5. freesitemapgenerator.comBy using this tool you can index up to 5000 pages on sitemap. After successfully generating the XML sitemap, can download the compressed folder. To generate sitemap you have to create an account first.

6. auditmypc.comIt is also the free tool to generate XML sitemaps. You can provide different filters, rules and options while generating sitemap files. You can include or exclude URLs and contents as filter.

7. xmlsitemapgenerator.orgUsing this tool you can easily create HTML, RSS and XML Sitemaps online for free. Sitemap generated by this tool is Compatible with major search engines including Google and Bing. Sitemaps tell search engines when and how often pages are updated, and their relative importance.

8. sitemaps-builder.com:  Using this free tool for generating sitemap maximum 1000 pages will be indexed at the Site. After successfully generated you have to download the sitemap file at results page and upload it to the root directory your website.

9. sitemapxml.netAfter Simply entering your website URL, selecting the frequency of website change and providing the last modified date, this free tool generates sitemaps in XML, ROR and TEXT format that can be instantly submitted to Search engines such as Google, Yahoo and MSN.

10. xsitemap.comAfter just providing website URL, Last modified date, Change frequency and Priority, XML sitemap can be created after few minutes. After successfully generated you have to download the sitemap file and upload it to the root directory your website.






Best Online Sitemap Generators List

Posted at  6:18 ص - by mego almasry 0


Best Online Sitemap Generators List
Sitemap is a most important part of any website or blog. A Sitemap is an XML file that lists URLs for a site along with additional metadata about each URL when it was last updated, how often it usually changes, and how important it is, relative to other URLs in the site, so that search engines can more intelligently crawl the site. Sitemap makes any website more SEO friendly and helps to index on search engines easily and also helps the visitors to find out the contents on the website. Here are some list of best online sitemap generator tools along with their descriptions, you can use up them to create, place on your website or blog and to submit on search engines like Google, Yahoo, Bing, Ask, AOL etc




List of Online Sitemap Generators 




1. xml-sitemaps.comIt is one of the best online sitemap generator tool. It provides free as well as paid or pro service for sitemap creation. By using a free service maximum 500 pages will be indexed in sitemap. Along with XML sitemap, you can create text and HTML sitemaps for the list of webpage on your website.

2. web-site-map.com: It is best free to use online sitemap generator tool. You can index up to 3500+ pages on sitemap file. After generating XML sitemap, you can validate by using W3C Markup Validation Service. If you want the free tool for sitemap generation I recommended this site.

3. sitemapdoc.com: Sitemapdoc.com is the another site for generating different formats of sitemaps. You can create XML sitemap, Text sitemap, HTML sitemap and RSS feed. You can check for the image and check website for viruses using AVG, Norton, McAfee, Google etc.

4. addme.comHere you can generate the sitemap with providing your website URL, Frequency, Priority, Last date modified, Name and Email address. After generating sitemap it will be emailed to you on the given email address.

5. freesitemapgenerator.comBy using this tool you can index up to 5000 pages on sitemap. After successfully generating the XML sitemap, can download the compressed folder. To generate sitemap you have to create an account first.

6. auditmypc.comIt is also the free tool to generate XML sitemaps. You can provide different filters, rules and options while generating sitemap files. You can include or exclude URLs and contents as filter.

7. xmlsitemapgenerator.orgUsing this tool you can easily create HTML, RSS and XML Sitemaps online for free. Sitemap generated by this tool is Compatible with major search engines including Google and Bing. Sitemaps tell search engines when and how often pages are updated, and their relative importance.

8. sitemaps-builder.com:  Using this free tool for generating sitemap maximum 1000 pages will be indexed at the Site. After successfully generated you have to download the sitemap file at results page and upload it to the root directory your website.

9. sitemapxml.netAfter Simply entering your website URL, selecting the frequency of website change and providing the last modified date, this free tool generates sitemaps in XML, ROR and TEXT format that can be instantly submitted to Search engines such as Google, Yahoo and MSN.

10. xsitemap.comAfter just providing website URL, Last modified date, Change frequency and Priority, XML sitemap can be created after few minutes. After successfully generated you have to download the sitemap file and upload it to the root directory your website.






الثلاثاء، 4 مارس 2014


How to Display Date Format in JavaScript?You can display different date format using Date object in JavaScript for your webpage or web application.The different date format may be year only (YYYY), year and month (YYYY-MM), complete date (YYYY-MM-DD), complete day with day name (YYYY-MM-DD DayName) and date with different time format. Different methods are available in date object to manipulate date in JavaScript. The Date object automatically hold the current date and time as its initial value. You can extract Year, Month, Day along with Hours, Minutes and Seconds from it. Here I have given very simple codes for printing different date formats, you can use respective codes for displaying that format of date on your web page.



JavaScript Date Format YYYY (year only)


<script type="text/javascript">
function displayDate(){
var now = new Date();
var year=now.getFullYear();
date.innerHTML=year
}
window.onload=displayDate;
</script>
<div id="date"></div>

It prints Year only. i.e. 2014


JavaScript Date Format YYYY-MM or MM-YYYY (year and month) 


<script type="text/javascript">
function displayDate(){
var now = new Date();
var month=now.getMonth();
var monthName=new Array(12)
monthName[0]="January";
monthName[1]="February";
monthName[2]="March";
monthName[3]="April";
monthName[4]="May";
monthName[5]="June";
monthName[6]="July";
monthName[7]="August";
monthName[8]="September";
monthName[9]="October";
monthName[10]="November";
monthName[11]="December";
var year=now.getFullYear(); 
date.innerHTML=monthName[month]+", "+year
}
window.onload=displayDate;
</script>
<div id="date"></div>

It prints Year and Month. i.e. February, 2014

JavaScript Date Format YYYY-MM-DD (complete date)


<script type="text/javascript">
function displayDate(){
var now = new Date();
var today=now.getDate();
var month=now.getMonth();
var monthName=new Array(12)
monthName[0]="January";
monthName[1]="February";
monthName[2]="March";
monthName[3]="April";
monthName[4]="May";
monthName[5]="June";
monthName[6]="July";
monthName[7]="August";
monthName[8]="September";
monthName[9]="October";
monthName[10]="November";
monthName[11]="December";
var year=now.getFullYear();
var day=now.getDay();
date.innerHTML=monthName[month]+today+ ", "+year
}
window.onload=displayDate;
</script>
<div id="date"></div>

It prints Year, Month and Day. i.e. February21, 2014


JavaScript Date Format YYYY-MM-DD-DayName (date with day name)


<script type="text/javascript">
function displayDate(){
var now = new Date();
var today=now.getDate();
var month=now.getMonth();
var monthName=new Array(12)
monthName[0]="January";
monthName[1]="February";
monthName[2]="March";
monthName[3]="April";
monthName[4]="May";
monthName[5]="June";
monthName[6]="July";
monthName[7]="August";
monthName[8]="September";
monthName[9]="October";
monthName[10]="November";
monthName[11]="December";
var year=now.getFullYear();
var day=now.getDay();
var dayName=new Array(7)
dayName[0]="Sunday";
dayName[1]="MOnday";
dayName[2]="Tuesday";
dayName[3]="Wednesday";
dayName[4]="Thrusday";
dayName[5]="Friday";
dayName[6]="Saturday";
date.innerHTML=monthName[month]+today+ ", "+year+" "+dayName[day]
}
window.onload=displayDate;
</script>
<div id="date"></div>

It prints Year, Month and Day with Day Name. i.e. February21, 2014 Friday

JavaScript Date Format YYYY-MM-DD hh:mm (date with hour and minute)


<script type="text/javascript">
function displayDate(){

var now = new Date();
var today=now.getDate();
var month=now.getMonth();
var h=now.getHours()
var m=now.getMinutes()
var s=now.getSeconds()

m=checkTime(m)
s=checkTime(s)

var monthName=new Array(12)
monthName[0]="January";
monthName[1]="February";
monthName[2]="March";
monthName[3]="April";
monthName[4]="May";
monthName[5]="June";
monthName[6]="July";
monthName[7]="August";
monthName[8]="September";
monthName[9]="October";
monthName[10]="November";
monthName[11]="December";

var year=now.getFullYear();
var day=now.getDay();

var dayName=new Array(7)
dayName[0]="Sunday";
dayName[1]="MOnday";
dayName[2]="Tuesday";
dayName[3]="Wednesday";
dayName[4]="Thrusday";
dayName[5]="Friday";
dayName[6]="Saturday";

date.innerHTML=monthName[month]+today+ ", "+year+" "+h+":"+m
}
function checkTime(i)
{
if (i<10)
{ i="0" + i}
return i
}
window.onload=displayDate;
</script>
<div id="date"></div>

It prints Year, Month and Day with Hour and Minute. i.e. February21, 2014 9:18

To include other time formats refer to the previous post: How to Create a Digital Clock in JavaScript?


Related Posts


How to Display Date Format in JavaScript?

Posted at  6:47 ص - by mego almasry 0


How to Display Date Format in JavaScript?You can display different date format using Date object in JavaScript for your webpage or web application.The different date format may be year only (YYYY), year and month (YYYY-MM), complete date (YYYY-MM-DD), complete day with day name (YYYY-MM-DD DayName) and date with different time format. Different methods are available in date object to manipulate date in JavaScript. The Date object automatically hold the current date and time as its initial value. You can extract Year, Month, Day along with Hours, Minutes and Seconds from it. Here I have given very simple codes for printing different date formats, you can use respective codes for displaying that format of date on your web page.



JavaScript Date Format YYYY (year only)


<script type="text/javascript">
function displayDate(){
var now = new Date();
var year=now.getFullYear();
date.innerHTML=year
}
window.onload=displayDate;
</script>
<div id="date"></div>

It prints Year only. i.e. 2014


JavaScript Date Format YYYY-MM or MM-YYYY (year and month) 


<script type="text/javascript">
function displayDate(){
var now = new Date();
var month=now.getMonth();
var monthName=new Array(12)
monthName[0]="January";
monthName[1]="February";
monthName[2]="March";
monthName[3]="April";
monthName[4]="May";
monthName[5]="June";
monthName[6]="July";
monthName[7]="August";
monthName[8]="September";
monthName[9]="October";
monthName[10]="November";
monthName[11]="December";
var year=now.getFullYear(); 
date.innerHTML=monthName[month]+", "+year
}
window.onload=displayDate;
</script>
<div id="date"></div>

It prints Year and Month. i.e. February, 2014

JavaScript Date Format YYYY-MM-DD (complete date)


<script type="text/javascript">
function displayDate(){
var now = new Date();
var today=now.getDate();
var month=now.getMonth();
var monthName=new Array(12)
monthName[0]="January";
monthName[1]="February";
monthName[2]="March";
monthName[3]="April";
monthName[4]="May";
monthName[5]="June";
monthName[6]="July";
monthName[7]="August";
monthName[8]="September";
monthName[9]="October";
monthName[10]="November";
monthName[11]="December";
var year=now.getFullYear();
var day=now.getDay();
date.innerHTML=monthName[month]+today+ ", "+year
}
window.onload=displayDate;
</script>
<div id="date"></div>

It prints Year, Month and Day. i.e. February21, 2014


JavaScript Date Format YYYY-MM-DD-DayName (date with day name)


<script type="text/javascript">
function displayDate(){
var now = new Date();
var today=now.getDate();
var month=now.getMonth();
var monthName=new Array(12)
monthName[0]="January";
monthName[1]="February";
monthName[2]="March";
monthName[3]="April";
monthName[4]="May";
monthName[5]="June";
monthName[6]="July";
monthName[7]="August";
monthName[8]="September";
monthName[9]="October";
monthName[10]="November";
monthName[11]="December";
var year=now.getFullYear();
var day=now.getDay();
var dayName=new Array(7)
dayName[0]="Sunday";
dayName[1]="MOnday";
dayName[2]="Tuesday";
dayName[3]="Wednesday";
dayName[4]="Thrusday";
dayName[5]="Friday";
dayName[6]="Saturday";
date.innerHTML=monthName[month]+today+ ", "+year+" "+dayName[day]
}
window.onload=displayDate;
</script>
<div id="date"></div>

It prints Year, Month and Day with Day Name. i.e. February21, 2014 Friday

JavaScript Date Format YYYY-MM-DD hh:mm (date with hour and minute)


<script type="text/javascript">
function displayDate(){

var now = new Date();
var today=now.getDate();
var month=now.getMonth();
var h=now.getHours()
var m=now.getMinutes()
var s=now.getSeconds()

m=checkTime(m)
s=checkTime(s)

var monthName=new Array(12)
monthName[0]="January";
monthName[1]="February";
monthName[2]="March";
monthName[3]="April";
monthName[4]="May";
monthName[5]="June";
monthName[6]="July";
monthName[7]="August";
monthName[8]="September";
monthName[9]="October";
monthName[10]="November";
monthName[11]="December";

var year=now.getFullYear();
var day=now.getDay();

var dayName=new Array(7)
dayName[0]="Sunday";
dayName[1]="MOnday";
dayName[2]="Tuesday";
dayName[3]="Wednesday";
dayName[4]="Thrusday";
dayName[5]="Friday";
dayName[6]="Saturday";

date.innerHTML=monthName[month]+today+ ", "+year+" "+h+":"+m
}
function checkTime(i)
{
if (i<10)
{ i="0" + i}
return i
}
window.onload=displayDate;
</script>
<div id="date"></div>

It prints Year, Month and Day with Hour and Minute. i.e. February21, 2014 9:18

To include other time formats refer to the previous post: How to Create a Digital Clock in JavaScript?


Related Posts


الثلاثاء، 18 فبراير 2014


How to Create a Digital Clock in JavaScript?In JavaScript, Date Object is used to work with date and time. You can create a digital clock in JavaScript for your web page manipulating date object easily.  The Date object automatically hold the current date and time as its initial value. You can extract Hours, Minutes and Seconds from it, to create and display time on Digital Clock. I have presented here a simple and  easy to use JavaScript code to make a digital clock program. Feel free to use this code to add a digital clock on your web page or your web application.


Here I have defined a Date object with the new  keyword, new Date() to define the date object and extracted Hours, Minutes and Seconds using functions getHours(), getMinutes() and getSeconds() respectively and given codes for a simple clock having 24 hours format and a clock along with AM or PM.


JavaScript code for creating a simple digital clock


<script type="text/javascript">
function startTime()
{
var today=new Date()
var h=today.getHours()
var m=today.getMinutes()
var s=today.getSeconds()


//to add a zero in front of numbers<10

m=checkTime(m)
s=checkTime(s)

document.getElementById('clock').innerHTML=h+":"+m+":"+s
t=setTimeout('startTime()', 500)
}

function checkTime(i)
{
if (i<10)
{ i="0" + i}
return i
}

window.onload=startTime;

</script>
<div id="clock" style="font-size:35px;color:#00aaff;text-shadow:2px 2px 2px blue;
border:3px groove blue;background-color:#aaffaa; width:195px; height:40px"></div>


checkTime() function is used here to add zero in front of numbers less then 10 and executed the function 'startTime()' using window.onload. Here is a inline css code to design the clock, you can change its values according to your wish. If you want to use the css in separate css file and link to your web page, you can write the css as follows on distinct css file.
#clock{

font-size:35px;
color:#00aaff;
text-shadow:2px 2px 2px blue;
border:3px groove blue;
background-color:#aaffaa;
width:195px;
height:40px;

}


JavaScript code for creating a digital clock with AM or PM


<script type="text/javascript">
function startTime()
{
var today=new Date()
var h=today.getHours()
var m=today.getMinutes()
var s=today.getSeconds()
var ap="AM";

//to add AM or PM after time

if(h>11) ap="PM";
if(h>12) h=h-12;
if(h==0) h=12;

//to add a zero in front of numbers<10

m=checkTime(m)
s=checkTime(s)

document.getElementById('clock').innerHTML=h+":"+m+":"+s+" "+ap
t=setTimeout('startTime()', 500)
}

function checkTime(i)
{
if (i<10)
{ i="0" + i}
return i
}

window.onload=startTime;

</script>

<div id="clock" style="font-size:35px;color:#00aaff;text-shadow:2px 2px 2px blue;
border:3px groove blue;background-color:#aaffaa; width:195px; height:40px"></div>


In the above code, variable ap is added to make the clock 12 hour format and to add "AM" or "PM" after the time and added this variable at innerHTML of clock element.


Preview of digital clock created with JavaScript







Related Posts


How to Create a Digital Clock in JavaScript?

Posted at  10:30 م - by mego almasry 0


How to Create a Digital Clock in JavaScript?In JavaScript, Date Object is used to work with date and time. You can create a digital clock in JavaScript for your web page manipulating date object easily.  The Date object automatically hold the current date and time as its initial value. You can extract Hours, Minutes and Seconds from it, to create and display time on Digital Clock. I have presented here a simple and  easy to use JavaScript code to make a digital clock program. Feel free to use this code to add a digital clock on your web page or your web application.


Here I have defined a Date object with the new  keyword, new Date() to define the date object and extracted Hours, Minutes and Seconds using functions getHours(), getMinutes() and getSeconds() respectively and given codes for a simple clock having 24 hours format and a clock along with AM or PM.


JavaScript code for creating a simple digital clock


<script type="text/javascript">
function startTime()
{
var today=new Date()
var h=today.getHours()
var m=today.getMinutes()
var s=today.getSeconds()


//to add a zero in front of numbers<10

m=checkTime(m)
s=checkTime(s)

document.getElementById('clock').innerHTML=h+":"+m+":"+s
t=setTimeout('startTime()', 500)
}

function checkTime(i)
{
if (i<10)
{ i="0" + i}
return i
}

window.onload=startTime;

</script>
<div id="clock" style="font-size:35px;color:#00aaff;text-shadow:2px 2px 2px blue;
border:3px groove blue;background-color:#aaffaa; width:195px; height:40px"></div>


checkTime() function is used here to add zero in front of numbers less then 10 and executed the function 'startTime()' using window.onload. Here is a inline css code to design the clock, you can change its values according to your wish. If you want to use the css in separate css file and link to your web page, you can write the css as follows on distinct css file.
#clock{

font-size:35px;
color:#00aaff;
text-shadow:2px 2px 2px blue;
border:3px groove blue;
background-color:#aaffaa;
width:195px;
height:40px;

}


JavaScript code for creating a digital clock with AM or PM


<script type="text/javascript">
function startTime()
{
var today=new Date()
var h=today.getHours()
var m=today.getMinutes()
var s=today.getSeconds()
var ap="AM";

//to add AM or PM after time

if(h>11) ap="PM";
if(h>12) h=h-12;
if(h==0) h=12;

//to add a zero in front of numbers<10

m=checkTime(m)
s=checkTime(s)

document.getElementById('clock').innerHTML=h+":"+m+":"+s+" "+ap
t=setTimeout('startTime()', 500)
}

function checkTime(i)
{
if (i<10)
{ i="0" + i}
return i
}

window.onload=startTime;

</script>

<div id="clock" style="font-size:35px;color:#00aaff;text-shadow:2px 2px 2px blue;
border:3px groove blue;background-color:#aaffaa; width:195px; height:40px"></div>


In the above code, variable ap is added to make the clock 12 hour format and to add "AM" or "PM" after the time and added this variable at innerHTML of clock element.


Preview of digital clock created with JavaScript







Related Posts


السبت، 15 فبراير 2014


Different Ways to Redirect Page in JavaScript
When you click on a link or type the URL to go to one page but sometimes it may go to another page internally due to page redirection on that page. There may be several reasons to redirect to a new page from the original page. The reasons you may want redirection are to redirect from your old domain to new domain, to redirect visitors from mobile device to the mobile site, to redirect to the visitors from different countries to their respective country level domain URL and many more.You can use temporary or permanent redirection methods to redirect from on page to another page. The permanent redirection is server side redirection and temporary redirection in client side redirection.

Using JavaScript you can do client side redirection, however it is not preferred method for page redirection, a search engine may ignore JavaScript redirection. Do not use this feature to spam the search engine, if such you may band from search engine. Here are given different redirection methods and their purpose to redirect from one page to another page in JavaScript, you may use any one of them according to your circumstance.


Simple JavaScript Redirection to Another Page


1. Using window.location method: Use these scripts to the head section of your page.

<script type="text/javascript">
window.location="http://www.newpage.com";
</script>

2. Using window.location.href method: Use these scripts to the head section of your page.

<script type="text/javascript">
window.location.href="http://www.newpage.com";
</script>

3. Using window.location.assign method: Use these scripts to the head section of your page.

<script type="text/javascript">
window.location.assign="http://www.newpage.com";
</script>

4. Using window.location.replace method: Use these scripts to the head section of your page.

<script type="text/javascript">
window.location.replace="http://www.newpage.com";
</script>


JavaScript Redirect to Another Page After 'x' Seconds


1. Using onLoad method: Use these scripts in body tag to redirect to another page after '5' seconds.

<body onLoad="setTimeout(location.href='http://www.newpage.com', '5000')">


2. Using Redirect function: Use these scripts in the head section to redirect to another page after '5' seconds with redirection message.

<script type="text/javascript">
 
function Redirect()
{
 window.location="http://www.newpage.com";
}
document.write("You will be redirected to a new page in 5 seconds");
setTimeout('Redirect()', 5000);
 
</script>
 
 


JavaScript Redirect to Another Page On Load



1. Using onLoad method: Use these scripts in body tag to redirect to another page on load.

<body onLoad="setTimeout(location.href='http://www.newpage.com', '0')">


2. Using a function: Use these scripts in the head section to redirect to another page on load.

<script type="text/javascript">
 
function Redirect()
{
 window.location="http://www.newpage.com";
}
setTimeout('Redirect()', 0);
 
</script>


JavaScript Redirect to Another Page On Click


1. Using a function: Use these scripts in the head and body section to redirect to another page on button click.

<head>
<script>
function myButton()
{
window.location="http://www.siteforinfotech.com";
}
</script>
</head>
<body>
<button onclick="myButton()">Click me</button>
</body>


JavaScript Redirect to Another Page Passing Variables


1. Using a function: Use these scripts in the body section to redirect to another page on button click with passing the value of text box.

<body>
<form action="/search">
Enter your search text: <input type="text" id="searchtext" name="q">
&nbsp;<input onclick="myFunction()" type="submit" value="Search It" /></form>
<script>
function myFunction()
{
var search = document.getElementById("searchtext").value;
window.location = '/search?q='+search;
}
</script>
</body>

Enter your search text:  



Related Posts


What are the Different Ways to Redirect Page in JavaScript?

Posted at  3:00 ص - by mego almasry 0


Different Ways to Redirect Page in JavaScript
When you click on a link or type the URL to go to one page but sometimes it may go to another page internally due to page redirection on that page. There may be several reasons to redirect to a new page from the original page. The reasons you may want redirection are to redirect from your old domain to new domain, to redirect visitors from mobile device to the mobile site, to redirect to the visitors from different countries to their respective country level domain URL and many more.You can use temporary or permanent redirection methods to redirect from on page to another page. The permanent redirection is server side redirection and temporary redirection in client side redirection.

Using JavaScript you can do client side redirection, however it is not preferred method for page redirection, a search engine may ignore JavaScript redirection. Do not use this feature to spam the search engine, if such you may band from search engine. Here are given different redirection methods and their purpose to redirect from one page to another page in JavaScript, you may use any one of them according to your circumstance.


Simple JavaScript Redirection to Another Page


1. Using window.location method: Use these scripts to the head section of your page.

<script type="text/javascript">
window.location="http://www.newpage.com";
</script>

2. Using window.location.href method: Use these scripts to the head section of your page.

<script type="text/javascript">
window.location.href="http://www.newpage.com";
</script>

3. Using window.location.assign method: Use these scripts to the head section of your page.

<script type="text/javascript">
window.location.assign="http://www.newpage.com";
</script>

4. Using window.location.replace method: Use these scripts to the head section of your page.

<script type="text/javascript">
window.location.replace="http://www.newpage.com";
</script>


JavaScript Redirect to Another Page After 'x' Seconds


1. Using onLoad method: Use these scripts in body tag to redirect to another page after '5' seconds.

<body onLoad="setTimeout(location.href='http://www.newpage.com', '5000')">


2. Using Redirect function: Use these scripts in the head section to redirect to another page after '5' seconds with redirection message.

<script type="text/javascript">
 
function Redirect()
{
 window.location="http://www.newpage.com";
}
document.write("You will be redirected to a new page in 5 seconds");
setTimeout('Redirect()', 5000);
 
</script>
 
 


JavaScript Redirect to Another Page On Load



1. Using onLoad method: Use these scripts in body tag to redirect to another page on load.

<body onLoad="setTimeout(location.href='http://www.newpage.com', '0')">


2. Using a function: Use these scripts in the head section to redirect to another page on load.

<script type="text/javascript">
 
function Redirect()
{
 window.location="http://www.newpage.com";
}
setTimeout('Redirect()', 0);
 
</script>


JavaScript Redirect to Another Page On Click


1. Using a function: Use these scripts in the head and body section to redirect to another page on button click.

<head>
<script>
function myButton()
{
window.location="http://www.siteforinfotech.com";
}
</script>
</head>
<body>
<button onclick="myButton()">Click me</button>
</body>


JavaScript Redirect to Another Page Passing Variables


1. Using a function: Use these scripts in the body section to redirect to another page on button click with passing the value of text box.

<body>
<form action="/search">
Enter your search text: <input type="text" id="searchtext" name="q">
&nbsp;<input onclick="myFunction()" type="submit" value="Search It" /></form>
<script>
function myFunction()
{
var search = document.getElementById("searchtext").value;
window.location = '/search?q='+search;
}
</script>
</body>

Enter your search text:  



Related Posts


الخميس، 13 فبراير 2014


How to Detect Visitor's Browser Using JavascriptYou can detect which and what version of browser have used by your website visitors by using simple JavaScript codes. The navigator object in JavaScript contains information about the visitor's browser. It includes information about the visitor's browser name, browser version and more. It can be very useful to detect the visitor's browser type and version, and then serve up the appropriate information. By using this feature in JavaScript, it is easier to make your web pages smart enough to look one way to some browsers and another way to other browsers. But it may not be work for some browsers, specially for older browsers, which do not support JavaScript.

Here are some steps and codes for detecting visitor's browser using JavaScript, it may help you to apply this feature in your website.



Code for Detecting Visitor's Browser and Browser Version Using JavaScript


<script type="text/javascript">
var x=navigator

document.write("Name=" + x.appName)
document.write("<br/>")
document.write("Version=" + x.appVersion)
document.write("<br/>")
document.write("CookieEnabled=" + x.cookieEnabled)
document.write("<br/>")
document.write("BrowserLanguage=" + x.browserLanguage)
document.write("<br/>")
document.write("SystemLanguage=" + x.systemLanguage)
document.write("<br/>")
document.write("UserLanguage=" + x.userLanguage)
</script>

Where: 

  • appName - It holds the application name of the browser.
  • appVersion - It holds the version of the application and other things.
  • cookieEnabled - It checks whether or not cookie is enabled.
  • browserLanguage - It holds the browser Language.
  • systemLanguage - It holds the system Language.
  • userLanguage - It holds the user Language.



Output of the Code for Detecting Visitor's Browser and Browser Version 





Example: Alert user for older browser



You can alert or inform the visitor of  your website by using navigator object in JavaScript as the following. Here in the given code, the browsers below the version 4 are treated as older browser and displays the message. You can also add the links to download the latest version of browsers. 

<script type="text/javascript">

var browser= x.appName
var version = parseFloat(x.appVersion)

if((browser="Netscape" || browser=="Microsoft Internet Explorer") && (version>=4))

{document.write("Your browser is good enough!")
document.write("<br/>")}

else
{document.write("Your browser is old Update browser!")
document.write("<br/>")}

</script>

Output of the above Code  





Related Posts

How to Detect Visitor's Browser Using JavaScript?

Posted at  12:20 ص - by mego almasry 0


How to Detect Visitor's Browser Using JavascriptYou can detect which and what version of browser have used by your website visitors by using simple JavaScript codes. The navigator object in JavaScript contains information about the visitor's browser. It includes information about the visitor's browser name, browser version and more. It can be very useful to detect the visitor's browser type and version, and then serve up the appropriate information. By using this feature in JavaScript, it is easier to make your web pages smart enough to look one way to some browsers and another way to other browsers. But it may not be work for some browsers, specially for older browsers, which do not support JavaScript.

Here are some steps and codes for detecting visitor's browser using JavaScript, it may help you to apply this feature in your website.



Code for Detecting Visitor's Browser and Browser Version Using JavaScript


<script type="text/javascript">
var x=navigator

document.write("Name=" + x.appName)
document.write("<br/>")
document.write("Version=" + x.appVersion)
document.write("<br/>")
document.write("CookieEnabled=" + x.cookieEnabled)
document.write("<br/>")
document.write("BrowserLanguage=" + x.browserLanguage)
document.write("<br/>")
document.write("SystemLanguage=" + x.systemLanguage)
document.write("<br/>")
document.write("UserLanguage=" + x.userLanguage)
</script>

Where: 

  • appName - It holds the application name of the browser.
  • appVersion - It holds the version of the application and other things.
  • cookieEnabled - It checks whether or not cookie is enabled.
  • browserLanguage - It holds the browser Language.
  • systemLanguage - It holds the system Language.
  • userLanguage - It holds the user Language.



Output of the Code for Detecting Visitor's Browser and Browser Version 





Example: Alert user for older browser



You can alert or inform the visitor of  your website by using navigator object in JavaScript as the following. Here in the given code, the browsers below the version 4 are treated as older browser and displays the message. You can also add the links to download the latest version of browsers. 

<script type="text/javascript">

var browser= x.appName
var version = parseFloat(x.appVersion)

if((browser="Netscape" || browser=="Microsoft Internet Explorer") && (version>=4))

{document.write("Your browser is good enough!")
document.write("<br/>")}

else
{document.write("Your browser is old Update browser!")
document.write("<br/>")}

</script>

Output of the above Code  





Related Posts

Copyright © 2013 hello1. by Bloggertheme9 Powered by Blogger.
WP Theme-junkie converted by Blogger template