get customer details in opencart 3

Add this code in PHP file

$this->load->model('account/customer');
$data['customer_firstname']=$this->customer->getFirstName();
		$data['customer_lastname'] = $this->customer->getLastName();
		$data['customer_email']=$this->customer->getEmail();
		$data['customer_telephone']=$this->customer->getTelephone();

Add this code in TWIG file

<div class="col-md-12">
        {{ customer_firstname }} {{ customer_lastname }}
        {{ customer_email }}
        {{ customer_telephone }}
      </div>

if else if in twig file opencart

<div class="tags-veg-non">
    {% if product.isbn == 'V' %}
        <div class="tag" title="vegetarians">
          <a href="#"><div class="veg-icon">V</div></a>
            
        </div>{% elseif product.isbn == 'N' %}
    
        <div class="tag" title="non vegetarian">
          <a href="#"><div class="non-veg-icon">N</div></a>
            
        </div>{% endif %}
    
</div>

remove old cart when login in opencart

Very easy method, replace existing code in /system/library/cart

$this->db->query("DELETE FROM " . DB_PREFIX . "cart WHERE (api_id > '0' OR customer_id = '0') AND date_added < DATE_SUB(NOW(), INTERVAL 1 HOUR)");

New Code

$this->db->query("DELETE FROM " . DB_PREFIX . "cart WHERE date_added < DATE_SUB(NOW(), INTERVAL 1 HOUR)");

get category id by product id in opencart

get category id by product id in opencart

$this->load->model('catalog/category');
$product_cat = $this->model_catalog_product->getCategories($product_id);		
		$category_id=$product_cat[0]['category_id'];
$product_cat_parent = $this->model_catalog_category->getCategory($product_cat[0]['category_id']);
print_r($product_cat[0]['category_id']);

get category id by product id in opencart

$data = array(
            'catid'  => '63',
            'sort'  => 'p.date_added',
            'order' => 'DESC',
            'start' => 0,
            'limit' => $setting['limit']
        );
$results = $this->model_catalog_product->getProducts($data);

How to Create BMI Calculator in Opencart 3.x

Step1: Create language file (catalog\language\en-gb\information\bmi_calculator.php)

<?php
// Heading
$_['heading_title']  = 'BMI Calculator';

Step2: Create controller file (catalog\controller\information\bmi_calculator.php)

<?php
class ControllerInformationBmiCalculator extends Controller {
	private $error = array();
private $bmi;
private $bmi_result;
	public function index() {
		$this->load->language('information/bmi_calculator');

		$this->document->setTitle($this->language->get('heading_title'));
		$data['btn_bmi'] ='';
		if (($this->request->server['REQUEST_METHOD'] == 'POST') && $this->validate()) {
			
			if (isset($this->request->post['btn_bmi'])) {
				$data['btn_bmi'] = $this->request->post['btn_bmi'];
			} 
		$height_feet=	$this->request->post['height_feet'];
		$height_inches=	$this->request->post['height_inches'];
		//$cm=($height_feet * 30.48)+($height_inches * 2.54);
		$m=($height_feet * 0.3048 )+($height_inches * 0.0254 );
		$weight_kg=	$this->request->post['weight_kg'];
		$gender=	$this->request->post['gender'];
		$age=	$this->request->post['age'];
		$activity_level=	$this->request->post['activity_level'];
		$height_feet=	$this->request->post['height_feet'];
		$bmi=round($weight_kg / ($m * $m),2);
		$data['m']=$m;
		$data['bmi']=$bmi;
		if($bmi < 16.0)
		{
$bmi_result="Severely Underweight";
$texth1="Your BMI is $bmi. A BMI of bellow 16 is considered severely underweight.";
$text1="You are within the normal weight range for your height. A healthy weight for you is between 9 st 11 lbs and 13 st 3 lbs. You should consider carefully whether you need to diet.";
$texth2="Daily calorie requirements";
$text2="Based on your height, weight, age and level of exercise we estimate that you will burn 2182 calories (kcal) per day. For a healthy weight loss of 1-2lbs per week you should eat around 1482 calories per day.";
$texth3="Following the Insta Diet plan";
$text3="Once you add your daily milk, fresh fruit, vegetables and carbohydrates to your Insta Diet meals and snacks, you’ll be consuming around 1,200 calories per day. Based on your BMI you should add an extra 282 calories per day to reach your target calorie intake to ensure a steady and sustainable weight loss.";
$text4="If you're looking to lose weight or maintain your healthy BMI, our lower calorie meal plans can help.";
		}else if($bmi >= 16.0 && $bmi <= 18.4)
		{
$bmi_result="Underweight";
$texth1="Your BMI is $bmi. A BMI of 16 - 18.4 is considered underweight.";
$text1="Your BMI is considered underweight. Keep in mind that an underweight BMI calculation may pose certain health risks. Please consult with your healthcare provider for more information about BMI calculations.";
$texth2="Daily calorie requirements";
$text2="Based on your height, weight, age and level of exercise we estimate that you will burn 2182 calories (kcal) per day. For a healthy weight loss of 1-2lbs per week you should eat around 1482 calories per day.";
$texth3="Following the Insta Diet plan";
$text3="Once you add your daily milk, fresh fruit, vegetables and carbohydrates to your Insta Diet meals and snacks, you’ll be consuming around 1,200 calories per day. Based on your BMI you should add an extra 282 calories per day to reach your target calorie intake to ensure a steady and sustainable weight loss.";
$text4="If you're looking to lose weight or maintain your healthy BMI, our lower calorie meal plans can help.";

		} else if($bmi >= 18.5 && $bmi <= 24.9)
		{
$bmi_result="Normal";
$texth1="Your BMI is $bmi. A BMI of 18.5 - 24.9 is considered normal.";
$text1="Your BMI is considered normal. This healthy weight helps reduce your risk of serious health conditions and means you’re close to your fitness goals.";
$texth2="Daily calorie requirements";
$text2="Based on your height, weight, age and level of exercise we estimate that you will burn 2182 calories (kcal) per day. For a healthy weight loss of 1-2lbs per week you should eat around 1482 calories per day.";
$texth3="Following the Insta Diet plan";
$text3="Once you add your daily milk, fresh fruit, vegetables and carbohydrates to your Insta Diet meals and snacks, you’ll be consuming around 1,200 calories per day. Based on your BMI you should add an extra 282 calories per day to reach your target calorie intake to ensure a steady and sustainable weight loss.";
$text4="If you're looking to lose weight or maintain your healthy BMI, our lower calorie meal plans can help.";
		}else if($bmi >= 25.0 && $bmi <= 29.9)
		{
$bmi_result="Overweight";
$texth1="Your BMI is $bmi. A BMI of 25 - 29.9 is considered overweight.";
$text1="Your BMI is considered overweight. Being overweight may increase your risk of cardiovascular disease. Consult with your healthcare provider and consider making lifestyle changes through healthy eating and fitness to improve your health.";
$texth2="Daily calorie requirements";
$text2="Based on your height, weight, age and level of exercise we estimate that you will burn 2182 calories (kcal) per day. For a healthy weight loss of 1-2lbs per week you should eat around 1482 calories per day.";
$texth3="Following the Insta Diet plan";
$text3="Once you add your daily milk, fresh fruit, vegetables and carbohydrates to your Insta Diet meals and snacks, you’ll be consuming around 1,200 calories per day. Based on your BMI you should add an extra 282 calories per day to reach your target calorie intake to ensure a steady and sustainable weight loss.";
$text4="If you're looking to lose weight or maintain your healthy BMI, our lower calorie meal plans can help.";
		}else if($bmi >= 30.0 && $bmi <= 34.9)
		{
$bmi_result="Moderately Obese";
$texth1="Your BMI is $bmi. A BMI of 30 - 34.9 is considered moderately obese.";
$text1="Your BMI is considered obese. People with obesity are at increased risk for many diseases and health conditions, including cardiovascular disease, high blood pressure (Hypertension), Type 2 diabetes, breathing problems and more. Consult with your healthcare provider and consider making lifestyle changes through healthy eating and fitness to improve your overall health and quality of life.";
$texth2="Daily calorie requirements";
$text2="Based on your height, weight, age and level of exercise we estimate that you will burn 2182 calories (kcal) per day. For a healthy weight loss of 1-2lbs per week you should eat around 1482 calories per day.";
$texth3="Following the Insta Diet plan";
$text3="Once you add your daily milk, fresh fruit, vegetables and carbohydrates to your Insta Diet meals and snacks, you’ll be consuming around 1,200 calories per day. Based on your BMI you should add an extra 282 calories per day to reach your target calorie intake to ensure a steady and sustainable weight loss.";
$text4="If you're looking to lose weight or maintain your healthy BMI, our lower calorie meal plans can help.";
		}else if($bmi >= 35.0 && $bmi <= 39.9)
		{
$bmi_result="Severely Obese";
$texth1="Your BMI is $bmi. A BMI of 35 - 39.9 is considered severely obese.";
$text1="Your BMI is considered underweight. Keep in mind that an underweight BMI calculation may pose certain health risks. Please consult with your healthcare provider for more information about BMI calculations.";
$texth2="Daily calorie requirements";
$text2="Based on your height, weight, age and level of exercise we estimate that you will burn 2182 calories (kcal) per day. For a healthy weight loss of 1-2lbs per week you should eat around 1482 calories per day.";
$texth3="Following the Insta Diet plan";
$text3="Once you add your daily milk, fresh fruit, vegetables and carbohydrates to your Insta Diet meals and snacks, you’ll be consuming around 1,200 calories per day. Based on your BMI you should add an extra 282 calories per day to reach your target calorie intake to ensure a steady and sustainable weight loss.";
$text4="If you're looking to lose weight or maintain your healthy BMI, our lower calorie meal plans can help.";
		}else if($bmi >= 40.0)
		{
$bmi_result="Morbidly Obese";
$texth1="Your BMI is $bmi. A BMI of above 40.0 is considered morbidly obese.";
$text1="Your BMI is considered underweight. Keep in mind that an underweight BMI calculation may pose certain health risks. Please consult with your healthcare provider for more information about BMI calculations.";
$texth2="Daily calorie requirements";
$text2="Based on your height, weight, age and level of exercise we estimate that you will burn 2182 calories (kcal) per day. For a healthy weight loss of 1-2lbs per week you should eat around 1482 calories per day.";
$texth3="Following the Insta Diet plan";
$text3="Once you add your daily milk, fresh fruit, vegetables and carbohydrates to your Insta Diet meals and snacks, you’ll be consuming around 1,200 calories per day. Based on your BMI you should add an extra 282 calories per day to reach your target calorie intake to ensure a steady and sustainable weight loss.";
$text4="If you're looking to lose weight or maintain your healthy BMI, our lower calorie meal plans can help.";
		}
		$data['m']=$m;
		$data['bmi']=$bmi;
		$data['bmi_result']=$bmi_result;
		$data['texth1']=$texth1;
		$data['text1']=$text1;
		$data['texth2']=$texth2;
		$data['text2']=$text2;
		$data['texth3']=$texth3;
		$data['text3']=$text3;
		$data['text4']=$text4;
		}

		$data['breadcrumbs'] = array();

		$data['breadcrumbs'][] = array(
			'text' => $this->language->get('text_home'),
			'href' => $this->url->link('common/home')
		);

		$data['breadcrumbs'][] = array(
			'text' => $this->language->get('heading_title'),
			'href' => $this->url->link('information/bmi_calculator')
		);

		if (isset($this->error['activity'])) {
			$data['error_activity'] = $this->error['activity'];
		} else {
			$data['error_activity'] = '';
		}

		if (isset($this->error['height_weight'])) {
			$data['error_height_weight'] = $this->error['height_weight'];
		} else {
			$data['error_height_weight'] = '';
		}
		
		if (isset($this->error['gender'])) {
			$data['error_gender'] = $this->error['gender'];
		} else {
			$data['error_gender'] = '';
		}
		if (isset($this->error['age'])) {
			$data['error_age'] = $this->error['age'];
		} else {
			$data['error_age'] = '';
		}
		if (isset($this->error['email'])) {
			$data['error_email'] = $this->error['email'];
		} else {
			$data['error_email'] = '';
		}

		if (isset($this->error['enquiry'])) {
			$data['error_enquiry'] = $this->error['enquiry'];
		} else {
			$data['error_enquiry'] = '';
		}

		$data['button_submit'] = $this->language->get('button_submit');

		$data['action'] = $this->url->link('information/bmi_calculator', '', true);

		$this->load->model('tool/image');

		if ($this->config->get('config_image')) {
			$data['image'] = $this->model_tool_image->resize($this->config->get('config_image'), $this->config->get('theme_' . $this->config->get('config_theme') . '_image_location_width'), $this->config->get('theme_' . $this->config->get('config_theme') . '_image_location_height'));
		} else {
			$data['image'] = false;
		}

		$data['store'] = $this->config->get('config_name');
		$data['address'] = nl2br($this->config->get('config_address'));
		$data['geocode'] = $this->config->get('config_geocode');
		$data['geocode_hl'] = $this->config->get('config_language');
		$data['telephone'] = $this->config->get('config_telephone');
		$data['fax'] = $this->config->get('config_fax');
		$data['open'] = nl2br($this->config->get('config_open'));
		$data['comment'] = $this->config->get('config_comment');

		$data['locations'] = array();

		$this->load->model('localisation/location');

		foreach((array)$this->config->get('config_location') as $location_id) {
			$location_info = $this->model_localisation_location->getLocation($location_id);

			if ($location_info) {
				if ($location_info['image']) {
					$image = $this->model_tool_image->resize($location_info['image'], $this->config->get('theme_' . $this->config->get('config_theme') . '_image_location_width'), $this->config->get('theme_' . $this->config->get('config_theme') . '_image_location_height'));
				} else {
					$image = false;
				}

				$data['locations'][] = array(
					'location_id' => $location_info['location_id'],
					'name'        => $location_info['name'],
					'address'     => nl2br($location_info['address']),
					'geocode'     => $location_info['geocode'],
					'telephone'   => $location_info['telephone'],
					'fax'         => $location_info['fax'],
					'image'       => $image,
					'open'        => nl2br($location_info['open']),
					'comment'     => $location_info['comment']
				);
			}
		}

		if (isset($this->request->post['height_feet'])) {
			$data['height_feet'] = $this->request->post['height_feet'];
		} else {
			$data['height_feet'] = '';
		}
		if (isset($this->request->post['height_inches'])) {
			$data['height_inches'] = $this->request->post['height_inches'];
		} else {
			$data['height_inches'] = '';
		}
		if (isset($this->request->post['weight_stone'])) {
			$data['weight_stone'] = $this->request->post['weight_stone'];
		} else {
			$data['weight_stone'] = '';
		}
		if (isset($this->request->post['weight_pounds'])) {
			$data['weight_pounds'] = $this->request->post['weight_pounds'];
		} else {
			$data['weight_pounds'] = '';
		}
		if (isset($this->request->post['weight_kg'])) {
			$data['weight_kg'] = $this->request->post['weight_kg'];
		} else {
			$data['weight_kg'] = '';
		}
		if (isset($this->request->post['age'])) {
			$data['age'] = $this->request->post['age'];
		} else {
			$data['age'] = '';
		}
		if (isset($this->request->post['gender'])) {
			$data['gender'] = $this->request->post['gender'];
		} else {
			$data['gender'] = '';
		}

		if (isset($this->request->post['activity_level'])) {
			$data['activity_level'] = $this->request->post['activity_level'];
		} else {
			$data['activity_level'] = '';
		}
		

		if (isset($this->request->post['email'])) {
			$data['email'] = $this->request->post['email'];
		} else {
			$data['email'] = '';
		}

		if (isset($this->request->post['enquiry'])) {
			$data['enquiry'] = $this->request->post['enquiry'];
		} else {
			$data['enquiry'] = '';
		}

		// Captcha
		if ($this->config->get('captcha_' . $this->config->get('config_captcha') . '_status') && in_array('contact', (array)$this->config->get('config_captcha_page'))) {
			$data['captcha'] = $this->load->controller('extension/captcha/' . $this->config->get('config_captcha'), $this->error);
		} else {
			$data['captcha'] = '';
		}

		$data['column_left'] = $this->load->controller('common/column_left');
		$data['column_right'] = $this->load->controller('common/column_right');
		$data['content_top'] = $this->load->controller('common/content_top');
		$data['content_bottom'] = $this->load->controller('common/content_bottom');
		$data['footer'] = $this->load->controller('common/footer');
		$data['header'] = $this->load->controller('common/header');

		$this->response->setOutput($this->load->view('information/bmi_calculator', $data));
	}

	protected function validate() {
		if ((trim(utf8_strlen($this->request->post['weight_kg'])) < 1) ) {
			$this->error['height_weight'] = $this->language->get('error_name');
		}
		/*if ((trim(utf8_strlen($this->request->post['weight_pounds'])) < 1) ) {
			$this->error['height_weight'] = $this->language->get('error_name');
		}
		if ((trim(utf8_strlen($this->request->post['weight_stone'])) < 1) ) {
			$this->error['height_weight'] = $this->language->get('error_name');
		}*/
		if ((trim(utf8_strlen($this->request->post['height_inches'])) < 1) ) {
			$this->error['height_weight'] = $this->language->get('error_name');
		}
		if ((trim(utf8_strlen($this->request->post['height_feet'])) < 1) ) {
			$this->error['height_weight'] = $this->language->get('error_name');
		}
		if ((trim(utf8_strlen($this->request->post['gender'])) < 1) ) {
			$this->error['gender'] = $this->language->get('error_name');
			
		}
		
		if ((trim(utf8_strlen($this->request->post['age'])) < 1) ) {
			$this->error['age'] = $this->language->get('error_name');
		}
		if ((trim(utf8_strlen($this->request->post['activity_level'])) < 1) ) {
			$this->error['activity'] = $this->language->get('error_name');
		}

		if (!filter_var($this->request->post['email'], FILTER_VALIDATE_EMAIL)) {
			$this->error['email'] = $this->language->get('error_email');
		}

		

		// Captcha
		if ($this->config->get('captcha_' . $this->config->get('config_captcha') . '_status') && in_array('contact', (array)$this->config->get('config_captcha_page'))) {
			$captcha = $this->load->controller('extension/captcha/' . $this->config->get('config_captcha') . '/validate');

			if ($captcha) {
				$this->error['captcha'] = $captcha;
			}
		}

		return !$this->error;
	}

	public function success() {
		$this->load->language('information/bmi_calculator');

		$this->document->setTitle($this->language->get('heading_title'));

		$data['breadcrumbs'] = array();

		$data['breadcrumbs'][] = array(
			'text' => $this->language->get('text_home'),
			'href' => $this->url->link('common/home')
		);

		$data['breadcrumbs'][] = array(
			'text' => $this->language->get('heading_title'),
			'href' => $this->url->link('information/bmi_calculator')
		);

		$data['continue'] = $this->url->link('common/home');

		$data['column_left'] = $this->load->controller('common/column_left');
		$data['column_right'] = $this->load->controller('common/column_right');
		$data['content_top'] = $this->load->controller('common/content_top');
		$data['content_bottom'] = $this->load->controller('common/content_bottom');
		$data['footer'] = $this->load->controller('common/footer');
		$data['header'] = $this->load->controller('common/header');

		$this->response->setOutput($this->load->view('common/success', $data));
	}
}

Step3: Create view file (catalog\view\theme\default\template\information\bmi_calculator.twig)

{{ header }}
<style>
.inner {
    position: relative;
    max-width: 1200px;
    width: 100%;
    margin: 30px auto;
}
  .bmi-results {
    background-color: #fff;
    position: relative;
    -webkit-box-shadow: 0px -10px 50px 0px rgba(0, 0, 0, 0.1);
    box-shadow: 0px -10px 50px 0px rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    /* display: none; */
}
 .bmi-results:before {
    top: -20px;
    content: '';
    display: block;
    width: 0;
    height: 0;
    border-right: 20px solid transparent;
    border-left: 20px solid transparent;
    border-bottom: 20px solid #fff;
    position: absolute;
    z-index: 1;
    left: 50%;
    margin-left: -20px;
    -webkit-transition: top 0.3s linear;
    transition: top 0.3s linear;
}
  .information-container {
    position: relative;
    z-index: 1;
  padding:5px 15px;
  background-color:white;
}
  .top h1 {
    padding-top: 10px;
}
  .information-container p {
    font-size: 16px;
    line-height: 1.5;
}
</style>
<div id="information-contact" class="container">
  <ul class="breadcrumb">
    {% for breadcrumb in breadcrumbs %}
    <li><a href="{{ breadcrumb.href }}">{{ breadcrumb.text }}</a></li>
    {% endfor %}
  </ul>
  <div class="row">{{ column_left }}
    {% if column_left and column_right %}
    {% set class = 'col-sm-6' %}
    {% elseif column_left or column_right %}
    {% set class = 'col-sm-9' %}
    {% else %}
    {% set class = 'col-sm-12' %}
    {% endif %}
    <div id="content" class="{{ class }}">{{ content_top }}
      <h1>{{ heading_title }}</h1>     
      
      <form action="{{ action }}" method="post" enctype="multipart/form-data" class="form-horizontal">
        <fieldset>
          <legend>{{ text_contact }}</legend>
          <div class="block calculator-container">
  <div class="bmi-calculator">
    <div class="bmi-calculator-inner">
      <div class="top panel-with-shadow">
        <div class="dial-icon-container"></div>
        <h3><strong>FREE</strong> BMI Calculator</h3>
      </div>
      <div class="form-container">
          <div class="bmi-row units-row block-container">
            <div class="input-container units block">
              <label> Height<br>
              </label>
              <div class="select-style">
                <select name="height_feet" id="id_height_feet" required="">
                  <option value="" selected="">ft</option>
                  <option value="3">3ft</option>
                  <option value="4">4ft</option>
                  <option value="5">5ft</option>
                  <option value="6">6ft</option>
                  <option value="7">7ft</option>
                </select>
              </div>
              <div class="select-style">
                <select name="height_inches" id="id_height_inches" required="">
                  <option value="" selected="">in</option>
                  <option value="0">0in</option>
                  <option value="1">1in</option>
                  <option value="2">2in</option>
                  <option value="3">3in</option>
                  <option value="4">4in</option>
                  <option value="5">5in</option>
                  <option value="6">6in</option>
                  <option value="7">7in</option>
                  <option value="8">8in</option>
                  <option value="9">9in</option>
                  <option value="10">10in</option>
                  <option value="11">11in</option>
                </select>
              </div>
            </div>
            <div class="input-container text-container units block">
              <label>Weight<br>
              </label>
            <!--  <div class="select-style">
                <select name="weight_stone" id="id_weight_stone" required="">
                  <option value="" selected="">st</option>
                  <option value="6">6st</option>
                  <option value="7">7st</option>
                  <option value="8">8st</option>
                  <option value="9">9st</option>
                  <option value="10">10st</option>
                  <option value="11">11st</option>
                  <option value="12">12st</option>
                  <option value="13">13st</option>
                  <option value="14">14st</option>
                  <option value="15">15st</option>
                  <option value="16">16st</option>
                  <option value="17">17st</option>
                  <option value="18">18st</option>
                  <option value="19">19st</option>
                  <option value="20">20st</option>
                  <option value="21">21st</option>
                  <option value="22">22st</option>
                  <option value="23">23st</option>
                  <option value="24">24st</option>
                  <option value="25">25st</option>
                  <option value="26">26st</option>
                  <option value="27">27st</option>
                  <option value="28">28st</option>
                  <option value="29">29st</option>
                  <option value="30">30st</option>
                </select>
              </div>
              <div class="select-style">
                <select name="weight_pounds" id="id_weight_pounds" required="">
                  <option value="" selected="">lbs</option>
                  <option value="0">0lbs</option>
                  <option value="1">1lbs</option>
                  <option value="2">2lbs</option>
                  <option value="3">3lbs</option>
                  <option value="4">4lbs</option>
                  <option value="5">5lbs</option>
                  <option value="6">6lbs</option>
                  <option value="7">7lbs</option>
                  <option value="8">8lbs</option>
                  <option value="9">9lbs</option>
                  <option value="10">10lbs</option>
                  <option value="11">11lbs</option>
                  <option value="12">12lbs</option>
                  <option value="13">13lbs</option>
                </select>
              </div>-->
             <input type="text" name="weight_kg" id="id_weight_kg" placeholder="Your weight in KG" size="15" required value="{{ weight_kg }}" >
            </div>
             {% if error_height_weight %}
              <div class="text-danger">{{ error_name }}</div>
              {% endif %}
          </div>
          <div class="bmi-row">
            <div class="input-container radios">
              <label class="pdl">Gender<br><br>
              </label>
              <label class="radio-style">
              <input type="radio" id="id_gender_M" value="M" name="gender">
              <span></span>
              <label for="id_gender_0">Male</label>
              </label>
              <label class="radio-style">
              <input type="radio" id="id_gender_F" value="F" name="gender" checked="">
              <span></span>
              <label for="id_gender_1">Female</label>
              </label>
            </div>
             {% if error_gender %}
              <div class="text-danger">{{ error_name }}</div>
              {% endif %}
          </div>
          <div class="bmi-row">
            <div class="input-container select-container">
              <label>Age<br>
              </label>
              <div class="select-style">
                <select name="age" id="id_age" required="">
                  <option value="" selected="">Age</option>
                  <option value="18">18</option>
                  <option value="19">19</option>
                  <option value="20">20</option>
                  <option value="21">21</option>
                  <option value="22">22</option>
                  <option value="23">23</option>
                  <option value="24">24</option>
                  <option value="25">25</option>
                  <option value="26">26</option>
                  <option value="27">27</option>
                  <option value="28">28</option>
                  <option value="29">29</option>
                  <option value="30">30</option>
                  <option value="31">31</option>
                  <option value="32">32</option>
                  <option value="33">33</option>
                  <option value="34">34</option>
                  <option value="35">35</option>
                  <option value="36">36</option>
                  <option value="37">37</option>
                  <option value="38">38</option>
                  <option value="39">39</option>
                  <option value="40">40</option>
                  <option value="41">41</option>
                  <option value="42">42</option>
                  <option value="43">43</option>
                  <option value="44">44</option>
                  <option value="45">45</option>
                  <option value="46">46</option>
                  <option value="47">47</option>
                  <option value="48">48</option>
                  <option value="49">49</option>
                  <option value="50">50</option>
                  <option value="51">51</option>
                  <option value="52">52</option>
                  <option value="53">53</option>
                  <option value="54">54</option>
                  <option value="55">55</option>
                  <option value="56">56</option>
                  <option value="57">57</option>
                  <option value="58">58</option>
                  <option value="59">59</option>
                  <option value="60">60</option>
                  <option value="61">61</option>
                  <option value="62">62</option>
                  <option value="63">63</option>
                  <option value="64">64</option>
                  <option value="65">65</option>
                  <option value="66">66</option>
                  <option value="67">67</option>
                  <option value="68">68</option>
                  <option value="69">69</option>
                  <option value="70">70</option>
                  <option value="71">71</option>
                  <option value="72">72</option>
                  <option value="73">73</option>
                  <option value="74">74</option>
                  <option value="75">75</option>
                  <option value="76">76</option>
                  <option value="77">77</option>
                  <option value="78">78</option>
                  <option value="79">79</option>
                  <option value="80">80</option>
                  <option value="81">81</option>
                  <option value="82">82</option>
                  <option value="83">83</option>
                  <option value="84">84</option>
                  <option value="85">85</option>
                  <option value="86">86</option>
                  <option value="87">87</option>
                  <option value="88">88</option>
                  <option value="89">89</option>
                  <option value="90">90</option>
                </select>
              </div>
               {% if error_age %}
              <div class="text-danger">{{ error_name }}</div>
              {% endif %}
            </div>
          </div>
          <div class="bmi-row">
            <div class="input-container select-container">
              <label>Activity Level<br>
              </label>
              <div class="select-style">
                <select name="activity_level" id="id_activity_level" required="">
                  <option value="" selected="">Activity level</option>
                  <option value="1">None or very little</option>
                  <option value="2">Light exercise 1-3 days a week</option>
                  <option value="3">Moderate exercise 3-5 days a week</option>
                  <option value="4">Hard exercise 6-7 days a week</option>
                  <option value="5">Very hard exercise and physical job</option>
                </select>                
              </div>
              {% if error_activity %}
              <div class="text-danger">{{ error_name }}</div>
              {% endif %}
            </div>
          </div>
          <div class="bmi-row">
            <div class="input-container text-container">
              <label for="id_email">Email Address<br>
              </label>
              <input type="email" name="email" id="id_email" placeholder="Your email address" size="15" required value="{{ email }}" >
              {% if error_email %}
              <div class="text-danger">{{ error_email }}</div>
              {% endif %}
              <span class="icon-i information-dropdown">
              <div class="dropdown">We'll email you a copy of your profile</div>
              </span> </div>
          </div>
         <div class="bmi-row">
            <div class="input-container radios">
              <label class="pdl">Send me diet tips &amp; offers<br><br>
              </label>
              <label class="radio-style">
              <input type="radio" id="diet_tips_0" value="1" name="diet_tips">
              <span></span>
              <label for="id_gender_0">Yes</label>
              </label>
              <label class="radio-style">
              <input type="radio" id="diet_tips_1" value="0" name="diet_tips" checked="">
              <span></span>
              <label for="id_gender_1">No</label>
              </label>
            </div>
          </div>
         
          <div class="bmi-row signup-row">
            <button class="button burgundy" type="submit" name="btn_bmi" value="{{ button_submit }}">Show my results</button>
          </div>
        
      </div>
    </div>
  </div>
</div>
          {{ captcha }}
        </fieldset>
        <!--<div class="buttons">
          <div class="pull-right">
            <input class="btn btn-primary" type="submit" value="{{ button_submit }}" />
          </div>
        </div>-->
      </form>
      <script>
          {% if height_feet %}
       $('#id_height_feet').val({{ height_feet }});
              {% endif %}
          {% if height_inches %}
       $('#id_height_inches').val({{ height_inches }});
              {% endif %}
          {% if weight_stone %}
       $('#id_weight_stone').val({{ weight_stone }});
              {% endif %}
        {% if weight_pounds %}
       $('#id_weight_pounds').val({{ weight_pounds }});
              {% endif %}
        {% if age %}
       $('#id_age').val({{ age }});
              {% endif %}
        {% if activity_level %}
       $('#id_activity_level').val({{ activity_level }});
              {% endif %}
         {% if gender %}
       $('#id_gender_{{ gender }}').prop("checked", true);
              {% endif %}
      </script>
       {% if btn_bmi %}
      <div class="inner bmi-results-container">
        <div class="bmi-results open">
          <div class="top panel-with-shadow"> <h1 class="text-center">Your BMI Result</h1></div>
          <div class="information-container">
            <h2>{{ texth1 }}</h2>
            <p>{{ text1 }}</p>
            <h2>{{ texth2 }}</h2>
            <p>{{ text2 }}</p>
            <h2>{{ texth3 }}</h2>
            <p>{{ text3 }}</p>
            <p>{{ text4 }}</p>
            
          </div>
        </div>
       
      </div>
              {% endif %}
      {{ content_bottom }}</div>
    {{ column_right }}</div>
</div>
{{ footer }}

How to change price according to option on product in opencart 3.x

Login into opencart admin, select theme editor from design sidebar menu. Then
1. choose your store -> Default
2. choose template -> Product
3. open file product.twig
and write this below code:

modify line number 186

and add javascript/jquery code below file

 var orgprice=$(".fprice").html().substring(1);
function CalcOption()
  {
  var symb=$(".fprice").html().substring(0,1);

   var value=0;
   $("input[type=radio]:checked").each(function() {
       value += parseFloat($(this).attr("id").substring(1).replace(",", ""));
   });
  value=parseFloat(orgprice)+parseFloat(value);
 $(".fprice").html(symb+value.toFixed(2));
  }

Soa Technology

Good news! Amazon India announces 20,000 seasonal jobs in customer service

Amazon India on Sunday said that it has opened close to 20,000 seasonal employment opportunities in its customer service organisation. Most of the positions are part of the firm’s virtual customer service programme that provides work from home options.

The new positions are open across 11 locations including Kolkata, Pune and Hyderabad.

The announcement comes a little over a month after Amazon created nearly 50,000 temporary job opportunities in the country across its fulfilment and delivery networks.

As coronavirus cases are surging in the country, consumers are increasingly resorting to online shopping to meet their consumption needs. After e-commerce firms resumed full operations in the country, companies registered a spike in consumer search for products like electronic items, home appliances, casual wear and other work-from-home enablers.

Launch of sale events by online firms may be an indicator of significant consumer demand. Amazon recently concluded a seven-day sale.

The creation of the fresh job roles come amidst expectations of a continued rise in demand going forward.

“We estimate that customer traffic will further scale up over the next six months with the onset of Indian and global holiday seasons,” said Akshay Prabhu, director at customer service, Amazon India.

Based on the candidates’ performance as well as business needs, a percentage of the present temporary positions are likely to be converted into permanent positions towards the end of the year, the company said.

Earlier this year, Jeff Bezos-led Amazon had announced that it plans to create 1 million new jobs in India by 2025 through continued investments in technology, infrastructure and its logistics network. Amazon’s investments have enabled nearly 700,000 jobs over the past seven years in India.

Falling Sales Despite of Rise of Internet Users

This year has not been a bed of roses for the start-ups across the country. A constant dip in the online sales has been evident throughout. It has been a constant struggle to figure out ways to make money, either through ads, by selling products and services or maybe content. Honestly speaking, nothing seems to work in the favour of the ecommerce companies. Now this is a serious issue which has to be dealt as soon as possible or else for all those tall claims by companies to attract the potential customers or users to the investors may seem worthless.

As per the Kleiner Perkins Caufield Byers report, (a Silicon Valley venture capital firm), there has been a 40% increase in number of Internet users in India. Though there is a surge in the number of internet users but we cannot say the same about online shoppers said investors and start-up executives. Although the huge internet base in India seems attractive but then making money from users is completely different route, they said.

According to executives at some of the top e-commerce firms, for the first time in many years, the online retail sales in April were at a lower level as compared to December of the previous year. Now coming to, the Gross e-commerce sales which included the discounts, it was at an annualized $15 billion in December, states the research and consultancy firm RedSeer Consulting.

As reported by Mint, Snapdeal and Flipkart, both haven’t seen much growth and are losing their market share to Amazon over the past 15 months. The E-commerce firms have started adopting a new route to raise fresh funds by cutting down the advertising spending and discounts. With the implementation of new FDI(Foreign Direct Investment) rules, online market places are prohibited from influencing the product prices. Thereby putting on hold the sales events, though things might change soon as they figure out a new method of discounting. 4G services by Reliance Jio Infocomm Ltd were supposed to boost to the  E-commerce industry but that will take time.

It won’t be an exaggeration referring to this chaos as a storm. Currently, e-commerce is in a perfect storm.

Rutvik Doshi, director, Inventus (India) Advisors, a venture capital firm said “It seems like investors and analysts have overestimated the growth of e-commerce.” Though e-commerce will definitely grow, but not at the same rapid pace that the investors expected.  With the growth of e-commerce, we can see simultaneously see the expansion of other internet businesses like advertising-led start-ups, he further added. .

“First, you have e-commerce and then advertising and then other businesses. Everyone has figured out by now that getting Indian Internet users to pay is very tough. Overall, I still think the Internet economy will grow fast, just not the speed at which people were expecting earlier,” Doshi said.

Flipkart and Snapdeal are yet to respond to the emails seeking answers and comment.

However, in an interview on 23 May, Flipkart chief executive officer Binny Bansal said that although the demand has been weak till now, yet he expects to see a significant leap in maybe the next six months.  

Mr. Bansal further added that there has been terrific growth in the last 24 months. The last 3-4months might show things a little differently but overall in the last 8 years, the market has seen a good growth. Innovation has paved way for high growth rate. And that Flipkart has changed the way cell phones were sold in the country. In the next 6 months one could witness many more such changes which will in turn lead to growth.

According to the spokesperson of the Amazon, the company has seen“tremendous growth in three years of our operations in India”. “In 2015, we grew by more than 250% YoY (year-on-year) and have grown over 150% YoY in Q1 2016 despite a larger base. Today, we are the most-visited e-commerce site and the most-downloaded shopping app in the country,” said the spokesperson through his email.

The report by UBS AG, a financial services firm that came out last April States that by 2020 online retail would see a huge growth, say about $48-60 billion from the $4.47 billion in the year 2014-15. There were speculations and assumptions that by June 2015, Reliance Industries Ltd would launch its 4G services. UBS didn’t respond to an email seeking comment on whether the firm was revising its estimates.

Now that investors have slowly seen signs of decline, lots of them have opted out of the projects that they had invested in. The estimated budget invested is about 9 million. The slowdown in funding has led the start-ups to try really hard to make their money from users through ads or by charging fees for the services they provide.

As per the documents by the Registrar of Companies, last year March, the sales generated by classifieds site Quikr India was Rs.24.78 crores. Though by then they had raised almost $200 million.

 “It’s not like there’s no potential for monetization in India but had we been in the West, the same 35 million users that we have would easily earn 3 or 4 times the revenue that we are earning in India,” said B.G. Mahesh, managing director and founder at Greynium Information Technologies Pvt. Ltd. He further said “Digital ad spending in India still needs to pick up for more monetization to happen.”

 “The difference is between users and daily users; to get real growth we need 10 times the current daily active users, because we monetize time spent on the platform,” said Farooq Adam, a fashion e-commerce app Fynd’s co-founder. “We’re hoping smart phone users become daily internet users once Reliance Jio launches 4G cheap data plans.”

Coming to education, even here the number of users who actually pay for the services that they use isn’t encouraging at all.

“We have had people request us to make our videos available offline because they only get to use the Net intermittently,” said Abhishek Patil, CEO, Oliveboard. “These pain points frustrate the user and make them give up on services. Though it is true that a larger number of people using the internet definitely mean a huge user base but for monetization we have to work upon the fact that people have to leave behind that hesitation to pay online for the service that they use.

7 Ways to Increase Website Traffic

Lack of massive budget, no battalion of marketers but still want to carve a niche? Seems like next to impossible, right? May be it isn’t so. The trick lies in consistent effort and a little investment i.e. your time. Here are a few ways to boost traffic:

  1. Make Your Website User Friendly – Your website is where the journey begins. The way it looks and the content can have a huge impact on the search engine results. One has to keep certain things in mind to increase the site’s visibility. Try and use more of relevant keywords. Figure out a main keyword for each page and use it as many times as possible but don’t go overboard. The keyword can be small or maybe two-three worded phrase. One can include the name of a particular area or place in the keyword to bring in more local traffic. Though using a video, images etc can be appealing but at times it can be ignored by search engines, so make sure to give a description along with it. A URL that is short and relevant makes it easier for humans as well as search engines to easily understand what the page is about.
  2. Importance of Going Through a Keyword Research – We all at times might have faced this situation where while typing a certain question, Google automatically comes up with relevant or similar answers. It is no magic or some super power but the reason lies in the fact that a lot of other people too might have searched on the same topic. With these frequently searched terms, one can get new ideas for posts that can be of great help to your audience. The keyword planner tool by Google is of great help to paid advertisers to plan their campaigns.
  3. Plan Your Content Strategy – It is not only about making your site appealing to the search engines, but also towards making it a place where people would want to visit again and again. One should keep updating the site with content that is informs, entertains and educates the readers. To keep up to the needs of consistently adding up a new content, have a section for the blog. If you’re writing skills are not something to boast about or writing isn’t your cup of tea, no need to worry. You can still start. Just plan it out properly and keep the taste of your audience in your mind while writing.
  4. Using Buzzsumo and Other Tools – The success mantra these days is all about keeping a tab on the competitors, their strategies, content that is viral and new ideas. Some of the popularly used content research tools are Buzzsumo, Buffer.com and Traackr.com etc. These tools help one find the trending topics, popular posts and content easily. It is a way to peep into the minds of the readers and what they really want to read.
  5. Submissions by Experts on your Post – One of the best way to give your content an edge is by including advice and opinions by experts in that particular field. The authenticity of the content reaches an all time high because of the submissions by experts. Not only inform them that you will be using their submission but even ask them to share it with their followers.
  6. Focus on Niche Related Platforms – A good content definitely has a stand of its own but one should also remember that taking it to the right place is as important. In other words, go through a proper research and share your content in platforms that are related to your industry or field. Posting a fashion related content on a platform where software is discussed makes no sense.
  7. Be in touch With Your Visitors – To ensure that visitors keep coming back to your site, encourage more and more people to join your mailing list. The more the subscriptions, the better for your business. Offering gifts like ebook and other freebies can also help. After having a proper mailing list, regularly send newsletters to the potential customers. Just make sure that the content is relevant to your business. Make the content interesting as well as useful.

It’s not just the big brands that

Search yourself – To keep track of new content, you can Google search through your url or brand name. This same thing can be followed in Google Images too. Set up a Google Alert to keep track and be updated. In order to avoid clutter in your inbox, go for settings according to which notifications are mailed to you once a day.

Create Your Own Positive Online Presence – To start with, online reputation can be managed by claiming your free business listings on the major online directories and social media networks. No worries of shelling out a huge sum, one can share information that would present your business in a new light. This also ensures that you’re in control of the official voice of your business on different outlets. The best part about these big directories is that they tend to occupy a lot of the search results for your business name, pushing any potential negative reviews off the first page results.



3. Add New Content to Your Social Media Profiles – The work doesn’t just end by starting online social media profiles; one needs to ensure that it is updated with new content regularly. This is your identity and reflection in, thus your reputation. The content should be interesting, relevant a definitely bring out your positive side. You want to ensure they are current and show you in a positive light. Positive reviews on your website is also a great way to generate quality content.

4. Listen to What Others Are Saying about You – One should always be aware of what is being said about your business. You can always set a Google Alert on your business name to keep a tab. There are various other reputation management tools too that can be used.These  tools can not only track mentions of your business but even report on sentiment for your brand online.

5. Be Proactive, Not Reactive When Responding – There’s too much information and advice on exactly when to respond to negative public comments. A never ending debate to respond publicly or not is still on. Though one should avoid responding while one is aggressive, and not to forget never ever accuse a reviewer of being fake. Think about the whole situation; take as much time as you want before responding. One wrong comment can spoil the entire thing. Be very careful while responding.

Promote Yourself

Promoting your business through an excellent SEO strategy on your website, social media, blog and other websites can help you offset any negative comments in two ways. First, the positive and optimized content can show up higher than the negative comments on search engine results pages. Second, most people realize that no business is perfect. If you have a dominant number of positive reviews among a few negatives, your chances of losing a potential customer from the few critical comments is much less than if the negative reviews were the only reviews published.

Today, businesses are more vulnerable to online attacks on their reputation than ever before. Taking proactive actions to optimize positive reviews and manage negative ones will help you minimize this vulnerability.

Should I buy a farmland? Is it a good investment? With so much of information and advice, it can be really confusing. Here, we are sharing a few tips and information which can make it easier for anyone who wants to buy a farmland get a better idea and see it as one of the best forms of investment. To know more:

comment

The article was really helpful and informative. You have discussed a lot of important aspects that most of us have always wanted to know but ended up being more confused. I am also planning to invest in a farmland in Delhi-NCR, kindly suggest names of some good projects.

Few months back my father invested in a farm land in Delhi-NCR. Initially, we were also confused and had to go through a lot of research. After a lot of searching and visiting the places personally, we came to a final conclusion that Flora Farms was the best amongst all. Not only the price was reasonable, the location was perfect as well. With so much of development in the sectors of infrastructure, communication etc and many renowned companies planning to shift base to this place, this is the best where you can invest.

When I had invested in Flora farms, even I had no clue that it would turn out to be such an amazing experience. Though the biggest surprise was that within 2 years the price increased to more than double the amount I had purchased it for. It turned out to be a great investment and deal for me.