Tag Archives: JavaScript

How to use handlebars js

Here’s one example that summarizes a number of things you can do with handlebars. (I will post in the near future how to precompile template)

Posted in כללי | Tagged , , | Leave a comment

How to fetch data from facebook app version 1 using javascript

The data is about my friends https://bitbucket.org/a1shay1979/fetch-data-from-facebook-versin-1-using-javascript

Posted in כללי | Tagged , | Leave a comment

Opening hours tiny project using jquery mobile

In this project i read data from xml file and put him in table, i use jquery mobile to do that. the files on Bitbucket: https://bitbucket.org/a1shay1979/opening-hours

Posted in כללי | Tagged , , , | Leave a comment

How to fetch data from xml that on different domain using ajax

I have 3 file: 1- index.html on my server that made ajax call and fetch xml content. 2- openingHours.xml that hold the content (in the remote server). 3- xml.php the server file (in the remote server).

Posted in כללי | Tagged , , | Leave a comment

How to use ajax

first why ? The simplest explanation is for update part of your page with data that come from your server without refresh the page and Asynchronous. Let’s say we have two files 1 index.html that call to the second file … Continue reading

Posted in כללי | Tagged , , | Leave a comment

How to enter to fullscreen mode in smrtphone

in the past i post about a fullscreen in jquery . that was Good solution but with restrictions ,if you want to see the support browser http://caniuse.com/#feat=fullscreen (if you check this site At the planning stage, you can save lots … Continue reading

Posted in כללי | Tagged , | Leave a comment

How to read data from json that come from diffrent domain – cross domain solution – jsonp

In a situation where you develop app for mobile that all the files will be on the smrtphone and you want to read data from remote server(diffrent domain – you on the local,and the remote is someting else).

Posted in כללי | Tagged , | 1 Comment

How to read from json file

in the next Example there are two file. when you run the json.html you need to open the debugger in chrome and look in the consol tab to see the result.

Posted in כללי | Tagged , , | 1 Comment

How to refresh page after clicking Back button in the browser

<input type=”hidden” id=”refreshed” value=”no”> <script type=”text/javascript”> onload=function() { var e=document.getElementById(“refreshed”); if(e.value==”no”)e.value=”yes”; else{e.value=”no”;location.reload();} } </script>   just copy and past this script after head tag.

Posted in כללי | Tagged | Leave a comment

How to get location latitude and longitude by address in javascript

<!DOCTYPE html> <html> <head> <title></title> </head> <body> <script type=”text/javascript” src=”http://maps.google.com/maps/api/js?sensor=false”></script&gt; <script type=”text/javascript”> var geocoder = new google.maps.Geocoder(); var address = “נמל תל אביב”; geocoder.geocode( { ‘address’: address}, function(results, status) { if (status == google.maps.GeocoderStatus.OK) { var latitude = results[0].geometry.location.lat(); var … Continue reading

Posted in כללי | Tagged , | Leave a comment