---
description: >-
  https://taxifamilycar.com/?fbclid=IwAR3sEkJBJ4cJyoxVxZTi0D3ptOV--VvQOjzRSn48OQkD3bi-EQWF6iQOXzE
---

# Script distance, khoảng cách (ok)

![](https://2494213435-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LYjAG13rAPdbArSfRyB%2Fuploads%2F7noyfsRoW2WnS07R8e0t%2FScreenshot_1.png?alt=media\&token=6d6a7304-2c06-4082-8715-267c0549d102)

{% embed url="https://maps.googleapis.com/maps-api-v3/api/js/47/3/intl/vi_ALL/common.js" %}

{% embed url="https://maps.googleapis.com/maps-api-v3/api/js/47/3/intl/vi_ALL/util.js" %}

{% embed url="https://maps.googleapis.com/maps-api-v3/api/js/47/3/intl/vi_ALL/distance_matrix.js" %}

{% embed url="https://maps.googleapis.com/maps-api-v3/api/js/47/3/intl/vi_ALL/places_impl.js" %}

[https://maps.googleapis.com/maps-api-v3/api/js/47/3/intl/vi\_ALL/controls.js](https://maps.googleapis.com/maps-api-v3/api/js/47/3/intl/vi_ALL/controls.js)

```

<!DOCTYPE html>
<html>
<meta http-equiv="content-type" content="text/html;charset=UTF-8" />
<head>
    <!-- Google Tag Manager -->
    <script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
    new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
    j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
    'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
    })(window,document,'script','dataLayer','GTM-WH52LJZ');</script>
    <!-- End Google Tag Manager -->
   
    <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no"/>
    <title>Taxi Family Car</title>
    <meta http-equiv="content-type" content="text/html; charset=utf-8" />
    <meta charset="UTF-8">
    <meta name="keywords" content="taxi đường dài, taxi di tinh, taxi chieu ve, taxi đường dài giá rẻ, taxi sân bay, taxi san bay, taxi sân bay giá rẻ, TAXI FAMILY CAR, taxi tân sân nhất." />
    <meta name="author" content="Dua Don Noi Bai" />
    <meta name="description" content="Taxi Nội Bài giá rẻ chỉ từ 160.000đ, Taxi Sân Bay giá rẻ nhất. Ứng dụng đặt xe taxi đường dài giá rẻ chỉ 5000đ/km, Taxi Nội Bài giá rẻ nhất. Tổng đài 0345688359." />
    <link href="img/favicon.ico" rel="shortcut icon" type="image/vnd.microsoft.icon" />
    <link rel="stylesheet" href="maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
    <link rel="stylesheet" href="maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap-theme.min.css">
    <script type="text/javascript" src="js/home/jquery.min.js"></script>    
    <script src="maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
    <link rel="stylesheet" type="text/css" href="css/home/banner.css"/>    
    <link rel="stylesheet" type="text/css" href="css/home/banner2.css"/>    
    <link rel="stylesheet" type="text/css" href="css/home/loadding.css"/>    
    <script type="text/javascript" src="js/home/jssor.min.js"></script>    
    <link rel="stylesheet" type="text/css" href="css/jquery.datetimepicker.css"/>    
    <script type="text/javascript" src="js/jquery.datetimepicker.js"></script>    
    <script type="text/javascript" src="js/bootstrap-toolkit.js"></script>    
    <script src="code.jquery.com/ui/1.12.1/jquery-ui.js"></script>
    <link rel="stylesheet" href="code.jquery.com/ui/1.12.1/themes/smoothness/jquery-ui.css">
    <link rel="stylesheet" type="text/css" href="css/home/init_autocomplete_service.css"/>     
    <script type="text/javascript" src="js/jquery.placepicker.js"></script>    
    <link rel="stylesheet" href="css/style_index.css">
    <link rel="stylesheet" href="css/slide_index.css">
    <link rel="stylesheet" type="text/css" href="css/home/assets2.css"/>    
    <link rel="stylesheet" type="text/css" href="css/home/font-awesome.min.css"/>    
    <link rel="stylesheet" type="text/css" href="css/home/swiper.min.css"/>    
    <link rel="stylesheet" type="text/css" href="css/home/swiper.css"/>    
    <link rel="stylesheet" type="text/css" href="css/home/index.css"/>    
    <link rel="stylesheet" type="text/css" href="css/home/index_set1.css"/>
    <link rel="stylesheet" type="text/css" href="css/style.css">
<script type="text/javascript" src="https://maps.googleapis.com/maps/api/js?key=AIzaSyDi-dB6ZoS8B9F_UogzuqqS13DdSzwzF1I&libraries=places&region=vn&language=vi"></script>
</head>
<body>
    <!-- Google Tag Manager (noscript) -->
    <noscript><iframe src="https://www.googletagmanager.com/ns.html?id=GTM-WH52LJZ"
    height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
    <!-- End Google Tag Manager (noscript) --><header>
   	<nav class="navbar" role="navigation">
   		<div class="container">
   			<div class="navbar-header nav-head">
   				<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
   					<img src="images/icon-menu.png" id="icon-menu">
   				</button>
   				<a class="navbar-brand" href="index.php"><img id="logo" src="images/logo.png"></a>
   			</div>
   			<div id="navbar" class="navbar-collapse collapse" aria-expanded="false" style="height: 1px;">
   				<ul class="nav navbar-nav">
   					<li><a href="index.php">Đặt xe sân bay</a></li>
   					<li ><a href="index.php">Đặt xe đường dài</a></li>
   					<li ><a href="index.php">Thuê xe Tour</a></li>
   					<li ><a href="index.php">Thuê liên tỉnh</a></li>
   					<li ><a href="index.php">Thuê cưới hỏi</a></li>
   					<li>
   						<img src="images/hotline.png" id="hotline-menu" style="min-width: 160px;">
   					</li>
   				</ul>
   			</div><!--/.nav-collapse -->
   		</div>
   	</nav>    
</header><section id="yt_slideshow" class="block" style="background: url('images/bg-banner.jpg');">
    <div class="container">
        <div class="row">
            <div class="banner" >
                                    <div class="col-md-6 col-xs-12 div_slogan" id="slogan-khauhieu">
                        <div class="slogan_taxigo">
                            <h2>Nền tảng đặt xe, Thuê xe Tour trực tuyến</h2>
                            <h4 style="font-style: italic;margin-top: 0;">Kết nối Bạn với hàng nghìn xe nhàn rỗi</h4>
                            <p style="margin-top: 20px;"><span><i class="fa fa-arrow-circle-o-right" aria-hidden="true"></i></span> An toàn, Sang trọng</p>
                            <p><span><i class="fa fa-arrow-circle-o-right" aria-hidden="true"></i></span> Gía trọn gói, không phát sinh</p>
                            <p><span><i class="fa fa-arrow-circle-o-right" aria-hidden="true"></i></span> Nền tảng thuê xe 4,7,16 chỗ lớn nhất Việt Nam</p>
                        </div>
                    </div>
                                <!-- form dat xe -->
                <div class="col-md-6 col-xs-12 div_slogan giadatxe" id="giaxeform">
                    <div class="col-md-6 col-xs-6 img-oto" style="text-align:center;">
                        <img src="images/7cho.jpg" class="img-circle" id="icon-datxe">
                        <span class="price-car" id="xemgia"></span>
                    </div>
                    <div class="col-md-6 col-xs-6 content-car">
                        <b class="name-car" id="datxe-loai_xe">Xe 4 Chỗ</b>
                        <div class="customer-rating">
                            <span class="fa fa-star" aria-hidden="true"></span>
                            <span class="fa fa-star" aria-hidden="true"></span>
                            <span class="fa fa-star" aria-hidden="true"></span>
                            <span class="fa fa-star" aria-hidden="true"></span>
                            <span class="fa fa-star" aria-hidden="true"></span>
                        </div>
                        <div class="order-oto">
                            <input type="submit" value="Đặt xe" id="datxecss" onclick="SendTour(this)">
                        </div>
                        
                    </div>
                    <div class="col-md-12 col-xs-12">
                        <form action="khachhang.php" method="POST" id="sendformdatxe">
                            <div class="form-group row">
                                <hr>
                                <b>Điền Thông Tin Người Đặt Xe</b>
                            </div>
                            <div class="form-group row">
                                <input type="text" class="form-control" name="FullName" value="" placeholder="Họ và tên Người Đặt Xe" id="txtFullName">
                            </div>
                            <div class="form-group row">
                                <input type="number" class="form-control" name="Phone" value="" placeholder="Số điện thoại Người Đặt Xe" required="" id="txtPhone">
                            </div>
                            <div class="form-group row">
                                <textarea class="form-control" rows="4" placeholder="Nội dung yêu cầu: VJ6868 - Mã chuyến bay (nếu có), Tài xế lịch sự, giao tiếp tiếng anh" name="Note"></textarea>
                            </div>
                            <input type="hidden" name="diem_don" id="diem_don">
                            <input type="hidden" name="diem_den" id="diem_den">
                            <input type="hidden" name="gio_don" id="gio_don">
                            <input type="hidden" name="loai_xe" id="loai_xe">
                            <input type="hidden" name="dich_vu" id="dich_vu">
                            <input type="hidden" name="gia_tien" id="gia_tien">
                            <input type="submit" id="submitformdatxe" style="display: none;">
                        </form>
                    </div>
                </div>
                <!-- form dat xe -->
                <style type="text/css">
                    .img-oto img {
                        max-width: 100%;
                    }
                    .giadatxe, .thongtinchuyenxe, .thongtinkhachhang {
                        border-radius: 15px;
                        background: #F9F9F9;
                        margin: 0px 0px 0px 0px;
                        border: 5px solid #00AD57;
                        padding: 10px;
                        margin-top: 20px;
                    }
                    .order-oto input {
                        border-radius: 5px 5px 5px 5px;
                        color: #fff;
                        padding: 10px 20px;
                        text-transform: uppercase;
                        font-weight: bold;
                        background: #009355;
                        border: 1px solid #009355;
                    }
                    #giaxeform{
                        display: none;
                    }
                    #size_id {
                        height: 38px;
                    }
                </style>

                <!-- thong tin chuyen xe -->
                           <!-- thong tin chuyen xe -->

           <div class="col-md-6 col-xs-12">
            <div id="content-booking">
                <div id="booking-car" style="border: 5px solid #00AD57;">
                    <ul class="nav nav-tabs" id="label-booking">
                        <li class="nav-item active">
                            <a class="nav-link active" id="home-tab" data-toggle="tab" href="#home" role="tab" aria-controls="home" aria-selected="true">ĐẶT XE</a>
                        </li>
                        <div class="tab-content" id="myTabContentCar">
                            <div class="tab-pane fade in active" id="home" role="tabpanel" aria-labelledby="home-tab">
                                <form action="" method="POST" id="distance_form">
                                    <input type="hidden" value="" id="km_input" name="km">
                                    <div class="form-group col-md-12 ">
                                        <label>Điểm đón</label>
                                        <div class="input-group append_pick_address_here pick_start" >
                                            <span class="input-group-addon"><i class="fa fa-map-marker mpick" aria-hidden="true"></i></span>
                                            <span class="custom-combobox" id="dat-xe-ngay">
                                                <input value="" id="from_places"  title="Điểm đón" class="custom-combobox-input ui-widget ui-widget-content ui-state-default ui-corner-left ui-autocomplete-input ui-autocomplete-loading" autocomplete="off" data-original-title="" placeholder="Nhập điểm đón"   name="PlaceStart" class="el-input"  autocomplete="off" required>
                                                <span class="pick-icon-start" onclick="clearInputStart()"><i class="fa fa-times" aria-hidden="true"></i></span>
                                                <input id="origin" name="origin" required="" type="hidden" />
                                                <input type="hidden" value="" id="lat_start" name="LatStart" />
                                                <input type="hidden" value="" id="long_start" name="LongStart" />
                                            </span>
                                        </div>
                                    </div>

                                    <div class="form-group col-md-12">
                                        <label>điểm đến</label>
                                        <div class="input-group append_drop_address_here pick_end">
                                            <span class="input-group-addon"><i class="fa fa-map-marker mdrop" aria-hidden="true"></i></span>
                                            <span class="custom-combobox">
                                                <input value="" id="to_places"  title="điểm đến" class="custom-combobox-input ui-widget ui-widget-content ui-state-default ui-corner-left ui-autocomplete-input" autocomplete="off" data-original-title="" placeholder="Nhập điểm đến" name="PlaceFinish" required>
                                                <span class="pick-icon-end" onclick="clearInputEnd()"><i class="fa fa-times" aria-hidden="true"></i></span>
                                                <input id="destination" name="destination" required="" type="hidden" />
                                                <input type="hidden" value="" id="lat_end" name="LatFinish" />
                                                <input type="hidden" value="" id="long_end" name="LongFinish" />
                                            </span>
                                            <span class="input-group-addon swap-address">
                                                <svg class="jss1 swap-icon" focusable="false" viewBox="0 0 24 24" aria-hidden="true" role="presentation">
                                                    <path d="M16 17.01V10h-2v7.01h-3L15 21l4-3.99h-3zM9 3L5 6.99h3V14h2V6.99h3L9 3z"></path>
                                                    <path fill="none" d="M0 0h24v24H0z"></path>
                                                </svg>
                                            </span>
                                        </div>
                                    </div>

                                    <div class="form-group col-md-6">
                                        <label>Dịch vụ</label>
                                        <div class="input-group append_pick_address_here">
                                            <span class="input-group-addon"><i class="fa fa-paper-plane-o" aria-hidden="true"></i></span>
                                            <span class="custom-combobox">
                                                <select name="service_id" class="form-control" id="service_id">
                                                    <option value="1">1 chiều</option>
                                                    <option value="3">2 chiều xe ở lại phục vụ</option>
                                                    <option value="2">2 chiều đưa đi đón về</option>
                                                </select>
                                            </span>
                                        </div>
                                    </div>
                                    <div class="form-group col-md-6">
                                        <label>Loại xe</label>

                                        <div class="input-group append_pick_address_here">
                                            <span class="input-group-addon"><i class="fa fa-car" ></i></span>
                                            <span class="custom-combobox">
                                                <select name="size_id" class="form-control" id="size_id">
                                                    <option value="1">Xe 4 chỗ</option>
                                                    <option value="2">Xe 7 chỗ</option>
                                                    <option value="3">Xe 16 chỗ</option>
                                                </select>
                                            </span>
                                        </div>
                                    </div>
                                    <div class="form-group col-md-12">
                                        <label>Thời gian đón</label>
                                        <div class="input-group gender_datetimeinput_here">
                                            <span class="input-group-addon"><i class="fa fa-calendar" aria-hidden="true"></i></span>
                                            <div class="controls input-append date form_datetime">
                                                <input size="16" name="date_start"  id="date_start"  type="text" value="18/12/2021 16:03"  class="form-control flatpickr-input flatpickr-input" style="border: 1px solid #bbb;" readonly>
                                                <span class="add-on"><i class="icon-th"></i></span>
                                            </div>

                                            <!-- Modal -->
                                            <div class="modal fade datetimeModal" id="startTimeModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
                                                <div class="modal-dialog">
                                                    <div class="modal-content">
                                                        <div class="modal-header">
                                                            <label>Chọn thời gian</label>
                                                            <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>

                                                        </div>
                                                        <div class="modal-body">
                                                            <div class="controls input-append date form_datetime" data-date-format="dd MM yyyy - HH:ii p" data-link-field="dtp_input1">
                                                                <input size="16" name="date_start_tmp"  type="text" value="18/12/2021 16:03"  class="form-control flatpickr-input flatpickr-input" style="    border: 1px solid #bbb;">
                                                                <span class="add-on"><i class="icon-th"></i></span>
                                                            </div>
                                                        </div>

                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="form-group col-md-6" id="date_end_row">
                                        <label>Thời gian về</label>
                                        <div class="input-group gender_datetimeinput_here">
                                            <span class="input-group-addon"><i class="fa fa-calendar-o" aria-hidden="true"></i></span>
                                            <div class="controls input-append date form_datetime" data-date-format="dd MM yyyy - HH:ii p" data-link-field="dtp_input1">
                                                <input size="16" name="date_end"  id="date_end"  type="text" value="18/12/2021 16:03"  class="form-control flatpickr-input flatpickr-input" style="    border: 1px solid #bbb;">
                                                <span class="add-on"><i class="icon-th"></i></span>
                                            </div>
                                            <div class="modal fade datetimeModal" id="endTimeModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
                                                <div class="modal-dialog">
                                                    <div class="modal-content">
                                                        <div class="modal-header">
                                                            <label>Chọn thời gian</label>
                                                            <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>

                                                        </div>
                                                        <div class="modal-body">
                                                            <div class="controls input-append date form_datetime" data-date-format="dd MM yyyy - HH:ii p" data-link-field="dtp_input1">
                                                                <input size="16" name="date_start_tmp"  type="text" value="18/12/2021 16:03"  class="form-control flatpickr-input flatpickr-input" style="    border: 1px solid #bbb;">
                                                                <span class="add-on"><i class="icon-th"></i></span>
                                                            </div>
                                                        </div>

                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="form-group" id="send">
                                        <input class="btn btn-primary" type="submit" value="Xem Giá" style="width: 100%;margin-top: 10px;color: white;font-weight: bold;font-size: 20px;background: #009355;" />
                                    </div>
                                </form>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
</section>
<script type="text/javascript">
    function clearInputStart() {
        $('#from_places').val('')
    }

    function clearInputEnd() {
        $('#to_places').val('')
    }
    jQuery(".swap-address").click(function(){
        let from_places = jQuery("#from_places").val();
        let lat_start = jQuery("#lat_start").val();
        let long_start = jQuery("#long_start").val();

        let to_places = jQuery("#to_places").val();
        let lat_end = jQuery("#lat_end").val();
        let long_end = jQuery("#long_end").val();

        jQuery("#from_places").val(to_places);
        jQuery("#to_places").val(from_places);

        jQuery("#lat_start").val(lat_end);
        jQuery("#lat_end").val(lat_start);

        jQuery("#long_start").val(long_end);
        jQuery("#long_end").val(long_start);
    });
</script>
<script type="text/javascript" src="js/timeinput.js"></script>

<script type="text/javascript">
    // script do khoang cach
    jQuery(function() {
        // add input listeners
        google.maps.event.addDomListener(window, 'load', function () {
            var from_places = new google.maps.places.Autocomplete(document.getElementById('from_places'));
            var to_places = new google.maps.places.Autocomplete(document.getElementById('to_places'));

            google.maps.event.addListener(from_places, 'place_changed', function () {
                var from_place = from_places.getPlace();
                var from_address = from_place.formatted_address;
                $('#origin').val(from_address);
            });

            google.maps.event.addListener(to_places, 'place_changed', function () {
                var to_place = to_places.getPlace();
                var to_address = to_place.formatted_address;
                $('#destination').val(to_address);
            });

        });
        // calculate distance
        function calculateDistance() {
            var origin = $('#origin').val();
            var destination = $('#destination').val();
            var service = new google.maps.DistanceMatrixService();
            service.getDistanceMatrix(
            {
                origins: [origin],
                destinations: [destination],
                travelMode: google.maps.TravelMode.DRIVING,
                    unitSystem: google.maps.UnitSystem.IMPERIAL, // miles and feet.
                    // unitSystem: google.maps.UnitSystem.metric, // kilometers and meters.
                    avoidHighways: false,
                    avoidTolls: false
                }, callback);
        }
        // get distance results
        function callback(response, status) {
            if (status != google.maps.DistanceMatrixStatus.OK) {
                $('#result').html(err);
            } else {
                var origin = response.originAddresses[0];
                var destination = response.destinationAddresses[0];
                if (response.rows[0].elements[0].status === "ZERO_RESULTS") {
                    $('#result').html("Better get on a plane. There are no roads between "  + origin + " and " + destination);
                } else {
                    var distance = response.rows[0].elements[0].distance;
                    var duration = response.rows[0].elements[0].duration;
                    var distance_in_kilo = distance.value / 1000; // the kilom


                    // ket qua tra ve
                    var service_id = document.getElementById("service_id").value; // var service_id = 1;

                    var price_service = 1;
                    if(service_id == 2) {
                       price_service = 1.5;
                   }  else if(service_id == 3) {
                       price_service = 1.75;
                   }  else if(service_id == 4) {
                       price_service = 2;
                   }
                   var size_car = document.getElementById("size_id").value;

                   var gia_default = 1;

                  
                 if(size_car == 1) {
                    if (distance_in_kilo < 10) {
                      gia_default = 0 * price_service;
                  } else if(distance_in_kilo >= 10 && distance_in_kilo < 30) {
                      gia_default = 0 * price_service;
                  } else {
                      gia_default = 13 * price_service;
                  }
              }  else if(size_car == 2) {
                 if (distance_in_kilo < 10) {
                    gia_default = 0 * price_service;
                } else if(distance_in_kilo >= 10 && distance_in_kilo < 30) {
                    gia_default = 0 * price_service;
                } else {
                    gia_default = 16 * price_service;
                }
            } else {
                if (distance_in_kilo < 10) {
                  gia_default = 0 * price_service;
              } else if(distance_in_kilo >= 10 && distance_in_kilo < 30) {
                  gia_default = 0 * price_service;
              } else {
                  gia_default = 18 * price_service;
              }
          }


                    // if (distance_in_kilo < 10) {
                    //  price_size_car = price_size_car * 1.364;
                    // } else if(distance_in_kilo >= 10 && distance_in_kilo < 30) {
                    //  price_size_car = price_size_car * 1.091;
                    // } else {
                    //  price_size_car = price_size_car * 0.94;
                    // }
                    var gia_tien = Math.round(distance_in_kilo * gia_default) * 1000;

                    Number.prototype.format = function(n, x, s, c) {
                      var re = '\\d(?=(\\d{' + (x || 3) + '})+' + (n > 0 ? '\\D' : '$') + ')',
                      num = this.toFixed(Math.max(0, ~~n));

                      return (c ? num.replace('.', c) : num).replace(new RegExp(re, 'g'), '$&' + (s || ','));
                  };
                  var string_gia_tien = gia_tien.format() + "đ";
                    // string_gia_tien = (gia_tien).toLocaleString('it-IT', {
                    //  style: 'currency',
                    //  currency: 'VND',
                    // });
                    if (document.getElementById('xemgia') !=null && distance_in_kilo > 30) {
                        document.getElementById("xemgia").innerHTML = string_gia_tien;
                    } else {
                        document.getElementById("xemgia").innerHTML = 'dưới 30km<br>Giá thảo thuận';
                    }
                    if (document.getElementById('slogan-khauhieu') !=null) {
                      document.getElementById("slogan-khauhieu").style.display = "none";
                  }
                  if (document.getElementById('thongtinchuyenxe') !=null) {
                    document.getElementById("thongtinchuyenxe").style.display = "none";
                }

                document.getElementById("giaxeform").style.display = "block";

                var string_loaixe = 'xe 4 chỗ';
                if (size_car == 2) {
                  document.getElementById('icon-datxe').src='images/7cho.jpg';
                  string_loaixe = 'xe 7 chỗ';
              } else if(size_car == 3){
                  document.getElementById('icon-datxe').src='images/16cho.png';
                  string_loaixe = 'xe 16 chỗ';
              } else {
                  document.getElementById('icon-datxe').src='images/4cho.jpg';
              }
              if (document.getElementById('datxe-loai_xe') !=null) {
                document.getElementById("datxe-loai_xe").innerHTML = string_loaixe;
            }
            document.getElementById("diem_den").value = document.getElementById("to_places").value;
            document.getElementById("diem_don").value = document.getElementById("from_places").value;
            document.getElementById("gio_don").value = document.getElementById("date_start").value;
            document.getElementById("dich_vu").value = document.getElementById("service_id").value;
            document.getElementById("loai_xe").value = document.getElementById("size_id").value;
            if (distance_in_kilo > 10) {
                document.getElementById("gia_tien").value = gia_tien/1000;
            } else {
               document.getElementById("gia_tien").value = 0;
           }
           

           document.body.scrollTop = 0;
           document.documentElement.scrollTop = 0;


                    // ket qua tra ve

                    // var distance_in_mile = distance.value / 1609.34; // the mile
                    // var duration_text = duration.text;
                    // var duration_value = duration.value;
                    // $('#in_mile').text(distance_in_mile.toFixed(2));
                    // $('#in_kilo').text(distance_in_kilo.toFixed(2));
                    // $('#duration_text').text(duration_text);
                    // $('#duration_value').text(duration_value);
                    // $('#from').text(origin);
                    // $('#to').text(destination);
                }
            }
        }
        // print results on submit the form
        $('#distance_form').submit(function(e){
            e.preventDefault();
            calculateDistance();
        });

    });
// script do khoang cach
</script>

<script type="text/javascript">
    function SendTour(e) {
        if($('#txtFullName').val().trim().length == 0) {
            alert("Quý khách vui lòng nhập tên");
        } else if($('#txtPhone').val().trim().length == 0) {
            alert("Quý khách vui lòng nhập số điện thoại");
        } else {
            $('.giadatxe').hide();
            $('.thongtinchuyenxe').show();
            $('#sendformdatxe').submit();
        }
    }
</script>



<div class="container">
    <div class="form-title">
        <h2 class="padding40">GIÁ TRỊ TAXI FAMILY CAR MANG LẠI</h2><span>&nbsp;</span>
    </div>

    <div class="row giatrimanglai">
        <div class="col-md-3">
            <img src="images/icon1.png" >
            <p class="title-sumenh">TIẾT KIỆM 50%</p>
            <p class="description-sumenh">Tiết kiệm được từ <span class="note-sumenh">30% đến 50%</span> chi phí</p>
        </div>
        <div class="col-md-3">
            <img src="images/icon2.png" >
            <p class="title-sumenh">TRỌN GÓI</p>
            <p class="description-sumenh">Khách hàng <span class="note-sumenh">luôn biết trước chi phí trọn gói</span>, không phát sinh cho mỗi chuyến đi</p>
        </div>
        <div class="col-md-3">
            <img src="images/icon3.png" >
            <p class="title-sumenh">CHẤT LƯỢNG</p>
            <p class="description-sumenh">Lái xe <span class="note-sumenh">an toàn và sang trọng</span> hơn.</p>
        </div>
        <div class="col-md-3">
            <img src="images/icon4.png" style="width: 112px;">
            <p class="title-sumenh">NHANH CHÓNG &  LINH HOẠT<p>
            <p class="description-sumenh">Gọi xe <span class="note-sumenh">nhanh chóng</span>, di chuyển <span class="note-sumenh">linh hoạt</span> hơn.</</p>
        </div>
    </div>

</div>
<div class="container ">
    <div class="row row-download-app">
        <div class="download-app">
            <div class="col-md-12 said">
                <p class="said-sm">"Sứ mệnh của chúng tôi là giải quyết đột phá các vấn đề về giá cả, chất lượng dịch vụ và sự tiện ích cho khách hàng. Giúp khách hàng tiết kiệm 20-50% giá trị chuyến đi so với thông thường."</p>
            </div>
        </div>
    </div>
</div><div class="container">
	<div class="form-title">
		<h2 class="padding40">ĐIỂM ĐI PHỔ BIẾN</h2><span>&nbsp;</span>
	</div>
	<div class="hot-place hot-place_domestic">
		<div class="grid">
			<figure class="effect-layla col-md-4 col-xs-6" >
				<img style="width: 100%;" src="images/3edb68c46e6f9731ce7e.png" alt="img06">
				<figcaption>
					<h2>Hồ Chí Minh - Bình Dương</h2>
					<p>Xe riêng, sang trọng, giá trên chưa bao gồm phí cao tốc</p>
				</figcaption>
			</figure>
			<figure class="effect-layla col-md-4 col-xs-6">
				<img style="width: 100%;" src="images/170fcffbc5503c0e6541.png" alt="img03">
				<figcaption>
					<h2>Hồ Chí Minh - Vũng Tàu</h2>
					<p>Xe riêng, sang trọng, giá trên chưa bao gồm phí cao tốc</p>
					<a href="index.php">View more</a>
				</figcaption>
			</figure>
			<figure class="effect-layla col-md-4 col-xs-6">
				<img style="width: 100%;" src="images/sapa.jpg" alt="img03">
				<figcaption>
					<h2>Sân Bay - Cần Thơ</h2>
					<p>Xe riêng, sang trọng, giá trên chưa bao gồm phí cao tốc</p>
				</figcaption>
			</figure>
			<figure class="effect-layla col-md-4 col-xs-6">
				<img style="width: 100%;" src="images/du-lich-tay-ninh.png" alt="img06">
				<figcaption>
					<h2>Hồ Chí Minh - Tây Ninh</h2>
					<p>Xe riêng, sang trọng, giá trên chưa bao gồm phí cao tốc</p>
				</figcaption>
			</figure>
			<figure class="effect-layla col-md-4 col-xs-6">
				<img style="width: 100%;" src="images/mui-ne.jpg" alt="img03">
				<figcaption>
					<h2>TP.Hồ Chí Minh - Mũi Né</h2>
					<p>Xe riêng, sang trọng, giá trên chưa bao gồm phí cao tốc</p>
				</figcaption>
			</figure>
			<figure class="effect-layla col-md-4 col-xs-6">
				<img style="width: 100%;" src="images/640c38f93252cb0c9243.png" alt="img03">
				<figcaption>
					<h2>Sài Gòn - VũngTàu</h2>
					<p>Xe riêng, sang trọng, giá trên chưa bao gồm phí cao tốc</p>
				</figcaption>
			</figure>
		</div>
	</div>

	<div class="form-title">
		<h2 class="padding40">BẠN CẦN THUÊ XE Ở ĐÂU</h2><span>&nbsp;</span>
	</div>
	<div class="hot-place2 ">
		<div class="grid2">
			<div class="col-md-8 col-xs-12 col-apolo-left">
				<figure class="effect-apollo effect-apollo1 col-md-12 col-xs-12">
					<img style="width: 100%;" src="images/hanoitaxigo.png" alt="img18">
					<figcaption>
						<h2>Hà Nội</h2>
					</figcaption>
				</figure>
				<figure class="effect-apollo effect-apollo2 col-md-6 col-xs-12">
					<img style="width: 100%;" src="images/du-lich-da-nang.png" alt="img18">
					<figcaption>
						<h2>Đà Nẵng</h2>
					</figcaption>
				</figure>
				<figure class="effect-apollo effect-apollo3 col-md-6 col-xs-12">
					<img style="width: 100%;" src="images/Vinpearl_Nhatrang_1.png" alt="img18">
					<figcaption>
						<h2>Nha Trang</h2>
					</figcaption>
				</figure>
			</div>
			<figure class="effect-apollo effect-apollo4 col-apolo-right col-md-4 col-xs-12" style="">
				<img style="width: 100%;" src="images/4729_1484731281-148473104557641-vietnam.png" alt="img22">
				<figcaption>
					<h2>TP. Hồ Chí Minh</h2>
				</figcaption>
			</figure>

		</div>
	</div>
	<div class="form-title">
		<h2 class="padding40">TRUYỀN THÔNG NÓI VỀ CHÚNG TÔI</h2><span>&nbsp;</span>
	</div>
	<div class="row doitac" >
		<div class="col-md-3 col-xs-6">
			<a href="index.php">
				<img src="images/doitac2.png" class="img-thumbnail">
			</a>
		</div>
		<div class="col-md-3 col-xs-6">
			<a href="index.php">
				<img src="images/doitac1.png" class="img-thumbnail">
			</a>
		</div>
		<div class="col-md-3 col-xs-6">
			<a href="index.php">
				<img src="images/doitac3.png" class="img-thumbnail">
			</a>
		</div>
		<div class="col-md-3 col-xs-6">
			<a href="index.php">
				<img src="images/logo_cj_solutions.jpg" class="img-thumbnail">
			</a>
		</div>
	</div>
</div><footer>
    <div class="container">
        <div class="row">
            <div class="col-md-6 col-xs-12 introduce">
                <p>Taxi Tân Sân Nhất giá rẻ là dịch vụ sân bay trọn gói giá rẻ của công ty CP dịch vụ vận tải hành khách Liên Minh. Công ty cam kết dịch vụ Taxi Sân Bay, đi tỉnh đường dài, du lịch bằng dòng xe đầu từ mới 100%, dòng xe 4,7,16,29,25 chỗ sang trọng với chính sách giá cam kết rẻ nhất và chất lượng phục vụ tốt nhất.</p>
                <div class="col-lg-6 col-md-6 ">
                    <a href="index.php" target="_blank"><img src="images/bo-cong-thuong.png" alt="Taxi Nội Bài" width="200" /></a>
                </div>

                <div class="col-lg-6 col-md-6 ">
                    <ul>
                        <li>
                            <a class="logo-appstore" href="index.php"></a>
                        </li>
                        <li class="vntrip-app-right">
                            <a class="logo-googleplay" href="index.php"></a>
                        </li>
                    </ul>
                </div>
            </div>
            <div class="col-md-3 col-xs-6">
                <h3>Dịch vụ</h3>
                <ul>
                    <li>
                        <i class="glyphicon glyphicon-circle-arrow-right"></i> 
                        <a href="index.php">Taxi tiện chuyến</a>
                    </li>
                    <li>
                        <i class="glyphicon glyphicon-circle-arrow-right"></i> 
                        <a href="index.php">Thuê xe Tour</a>
                    </li>
                    <li>
                        <i class="glyphicon glyphicon-circle-arrow-right"></i> 
                        <a href="index.php">Taxi sân bay</a>
                    </li>
                    <li>
                        <i class="glyphicon glyphicon-circle-arrow-right"></i> 
                        <a href="index.php">Taxi cưới hỏi</a>
                    </li>
                </ul>
            </div>
            <div class="col-md-3 col-xs-6">
                <h3>Đặt Xe</h3>
                <ul>
                    <li>
                        <i class="glyphicon glyphicon-circle-arrow-right"></i> 
                        <a href="index.php">Taxi đường dài giá rẻ</a>
                    </li>
                    <li>
                        <i class="glyphicon glyphicon-circle-arrow-right"></i> 
                        <a href="index.php">Taxi Tân Sân Nhất</a>
                    </li>
                    <li>
                        <i class="glyphicon glyphicon-circle-arrow-right"></i> 
                        <a href="index.php">Taxi Liên Tỉnh</a>
                    </li>
                    <li>
                        <i class="glyphicon glyphicon-circle-arrow-right"></i> 
                        <a href="index.php">Sài Gòn</a>
                    </li>
                </ul>
            </div>
        </div>
        <div class="row">
            <div class="col-md-4 col-xs-12" class="intro-li">
                <ul class="intro-ul" >
                    <li><i class="glyphicon glyphicon-circle-arrow-right"></i> Địa chỉ: 32 Trường Sơn, Phường 2, Tân Bình, Thành phố Hồ Chí Minh </li>
                </ul>

            </div>
            <div class="col-md-5">
                <p><i class="glyphicon glyphicon-circle-arrow-right"></i> Điện thoại : 03456.88.359</p>
                <p><i class="glyphicon glyphicon-circle-arrow-right"></i> Email : quanglinh19nd@gmail.com</p>
            </div>

            <div class="col-md-3"></div>
        </div>
    </div>

</footer>

<section class="block ck1" id="ck">
    <div class="container">
        <div class="head-camket">
            <h3>GIỮ LIÊN LẠC THƯỜNG XUYÊN NHÉ</h3>
        </div>
        <div class="content-lienlac">
            <img alt="Taxi Nội Bài" alt="Taxi Nội Bài"src="images/battay.png" id="bat-tay">
            <ul class="lienlac">
                <li><img alt="Taxi Nội Bài" alt="Taxi Nội Bài"src="images/face.png"></li>
                <li><img alt="Taxi Nội Bài" alt="Taxi Nội Bài"src="images/twiter.png"></li>
                <li><img alt="Taxi Nội Bài" alt="Taxi Nội Bài"src="images/insta.png"></li>
                <li><img alt="Taxi Nội Bài" alt="Taxi Nội Bài"src="images/youtube.png"></li>
                <li><img alt="Taxi Nội Bài" alt="Taxi Nội Bài"src="images/google.png"></li>
            </ul>
        </div>
    </div>
</section>
<a href="#" id="goTop" class="bd-circle t-center"><i class="glyphicon glyphicon-chevron-up"></i><br> Top</a>


</div>
<style>
    .mobile-hotline-left a:focus {
        text-decoration: none;
    }
</style>
<div class="lienhe_f text-right">
    <a href="http://zalo.me/0345688359" target="_blank">
        <img class="alo-ph-img-circle" src="img/icon-zalo-fix.png">
    </a><br>
      <a href="tel:0345688359" target="_blank" class="hotline-f">
        <span class="icon"><i class="fa fa-phone alo-ph-img-circle" aria-hidden="true"></i></span>
        <span>03456 88 359</span>
      </a>
</div>
<style type="text/css">
    .hotline-f {
        position: relative;
        border: 2px solid #ed1c24;
        padding: 5px 20px!important;
        font-size: 18px;
        font-weight: 600;
        background-color: #fff;
        color: #ed1c24;
        border-radius: 18px;
        padding-left: 50px;
        display: inline-block;
        margin-top: 10px;
    }
    .lienhe_f {
        position: fixed;
        left: 10px;
        bottom: 10px;
        text-align: left;
    }
    
    .zalo-f {
        border-color: #0069ad;
        color: #0069ad;
        font-size: 14px;
        padding-right: 35px;
    }
    .zalo-f .icon {
        background-color: #fff;
        border: 2px solid #0069ad;
        width: 30px;
        height: 30px;
        line-height: 24px;
    }
    .zalo-f .icon img {
        height: 15px;
    }
</style>
<a href="tel:0345688359"></a>
<script type="text/javascript">
    $(document).ready(function(){
        $(window).scroll(function(){
            if ($(this).scrollTop() > 100) {
                $('#goTop').fadeIn();
            } else {
                $('#goTop').fadeOut();
            }
        });
        $('#goTop').click(function(){
            $("html, body").animate({ scrollTop: 0 }, 600);
            return false;
        });
    });
</script>

</body>
</html>
```
