{"id":2231,"date":"2025-01-27T17:39:38","date_gmt":"2025-01-27T17:39:38","guid":{"rendered":"https:\/\/alainpersonaltrainer.ae\/?page_id=2231"},"modified":"2025-06-12T12:20:00","modified_gmt":"2025-06-12T12:20:00","slug":"\u062d\u0627\u0633\u0628\u0629-\u0645\u0624\u0634\u0631-\u0643\u062a\u0644\u0629-\u0627\u0644\u062c\u0633\u0645","status":"publish","type":"page","link":"https:\/\/alainpersonaltrainer.ae\/ar\/\u062d\u0627\u0633\u0628\u0629-\u0645\u0624\u0634\u0631-\u0643\u062a\u0644\u0629-\u0627\u0644\u062c\u0633\u0645\/","title":{"rendered":"\u062d\u0627\u0633\u0628\u0629 \u0645\u0624\u0634\u0631 \u0643\u062a\u0644\u0629 \u0627\u0644\u062c\u0633\u0645 (BMI) \u0645\u062c\u0627\u0646\u064a\u0629 \u0639\u0628\u0631 \u0627\u0644\u0625\u0646\u062a\u0631\u0646\u062a"},"content":{"rendered":"<div data-elementor-type=\"wp-page\" data-elementor-id=\"2231\" class=\"elementor elementor-2231\" data-elementor-post-type=\"page\">\n\t\t\t\t<div class=\"elementor-element elementor-element-6d20005 e-flex e-con-boxed e-con e-parent\" data-id=\"6d20005\" data-element_type=\"container\">\n\t\t\t\t\t<div class=\"e-con-inner\">\n\t\t\t\t<div class=\"elementor-element elementor-element-dea6078 elementor-widget elementor-widget-heading\" data-id=\"dea6078\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t\t<h2 class=\"elementor-heading-title elementor-size-default\">\u0627\u062d\u0633\u0628 \u0645\u0624\u0634\u0631 \u0643\u062a\u0644\u0629 \u062c\u0633\u0645\u0643 (BMI)<\/h2>\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-041a596 elementor-widget elementor-widget-heading\" data-id=\"041a596\" data-element_type=\"widget\" data-widget_type=\"heading.default\">\n\t\t\t\t\t<p class=\"elementor-heading-title elementor-size-default\">\u0627\u062d\u0633\u0628 \u0645\u0624\u0634\u0631 \u0643\u062a\u0644\u0629 \u062c\u0633\u0645\u0643 (BMI) \u0648\u0627\u062d\u0635\u0644 \u0639\u0644\u0649 \u062e\u0637\u0637 \u063a\u0630\u0627\u0626\u064a\u0629 \u0645\u062e\u0635\u0635\u0629 \u0644\u0641\u0642\u062f\u0627\u0646 \u0627\u0644\u0648\u0632\u0646 \u0623\u0648 \u0627\u0644\u062d\u0641\u0627\u0638 \u0639\u0644\u064a\u0647 \u0623\u0648 \u0632\u064a\u0627\u062f\u062a\u0647.<\/p>\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t<div class=\"elementor-element elementor-element-4bd8a68 e-flex e-con-boxed e-con e-parent\" data-id=\"4bd8a68\" data-element_type=\"container\">\n\t\t\t\t\t<div class=\"e-con-inner\">\n\t\t\t\t<div class=\"elementor-element elementor-element-a628135 elementor-widget elementor-widget-html\" data-id=\"a628135\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t\t<div class=\"bmi-widget\">\r\n    <div class=\"title\">\u062d\u0627\u0633\u0628\u0629 \u0645\u0624\u0634\u0631 \u0643\u062a\u0644\u0629 \u0627\u0644\u062c\u0633\u0645 (BMI)<\/div>\r\n    <div class=\"container\">\r\n        <div class=\"input-container\">\r\n            <div class=\"inputs\">\r\n                <input id=\"weight\" type=\"text\" placeholder=\"\u0627\u0644\u0648\u0632\u0646 (\u0628\u0627\u0644\u0643\u064a\u0644\u0648\u062c\u0631\u0627\u0645)\" oninput=\"validateNumberInput(this)\">\r\n                <input id=\"height\" type=\"text\" placeholder=\"\u0627\u0644\u0637\u0648\u0644 (\u0628\u0627\u0644\u0633\u0646\u062a\u064a\u0645\u062a\u0631)\" oninput=\"validateNumberInput(this)\">\r\n            <\/div>\r\n        <\/div>\r\n        <button id=\"calculateBMI\">\u0627\u062d\u0633\u0628<\/button>\r\n        <button id=\"resetButton\">\u0625\u0639\u0627\u062f\u0629 \u062a\u0639\u064a\u064a\u0646<\/button>\r\n        <div id=\"bmiResult\">\u0645\u0624\u0634\u0631 \u0643\u062a\u0644\u0629 \u0627\u0644\u062c\u0633\u0645: <span>0.0<\/span><\/div>\r\n        <div id=\"rangeResult\">\u064a\u0631\u062c\u0649 \u0625\u062f\u062e\u0627\u0644 \u0637\u0648\u0644\u0643 \u0648\u0648\u0632\u0646\u0643.<\/div>\r\n        <div id=\"recommendation\"><\/div>\r\n\r\n        <!-- New Diet Plan Section -->\r\n        <div id=\"dietPlanSection\">\r\n            <h3>\u062e\u0637\u0629 \u063a\u0630\u0627\u0626\u064a\u0629 \u0645\u0642\u062a\u0631\u062d\u0629<\/h3>\r\n            <div id=\"dietPlan\"><\/div>\r\n        <\/div>\r\n        \r\n        <div id=\"graphContainer\">\r\n            <canvas id=\"bmiGraph\"><\/canvas>\r\n        <\/div>\r\n    <\/div>\r\n<\/div>\r\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t<div class=\"elementor-element elementor-element-3575aba e-flex e-con-boxed e-con e-parent\" data-id=\"3575aba\" data-element_type=\"container\">\n\t\t\t\t\t<div class=\"e-con-inner\">\n\t\t\t\t<div class=\"elementor-element elementor-element-e878fae elementor-widget elementor-widget-html\" data-id=\"e878fae\" data-element_type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t\t<script src=\"https:\/\/cdn.jsdelivr.net\/npm\/chart.js\"><\/script>\n<script>\n    function validateNumberInput(input) {\n        input.value = input.value.replace(\/[^0-9]\/g, '');\n    }\n\n    document.addEventListener('DOMContentLoaded', function () {\n        const heightInput = document.getElementById('height');\n        const weightInput = document.getElementById('weight');\n        const calculateButton = document.getElementById('calculateBMI');\n        const resetButton = document.getElementById('resetButton');\n        const bmiResult = document.querySelector('#bmiResult span');\n        const rangeResult = document.getElementById('rangeResult');\n        const recommendation = document.getElementById('recommendation');\n        const dietPlan = document.getElementById('dietPlan');\n        const graphContainer = document.getElementById('graphContainer');\n        const bmiGraph = document.getElementById('bmiGraph').getContext('2d');\n\n        let chart;\n\n        calculateButton.addEventListener('click', calculateBMI);\n        resetButton.addEventListener('click', resetInputs);\n\n        function calculateBMI() {\n            const height = parseFloat(heightInput.value);\n            const weight = parseFloat(weightInput.value);\n\n            if (isNaN(height) || isNaN(weight) || height <= 0 || weight <= 0) {\n                alert('Please enter valid height and weight values.');\n                return;\n            }\n\n            const bmi = weight \/ ((height \/ 100) ** 2);\n            bmiResult.textContent = bmi.toFixed(1);\n\n            const category = displayBMIRange(bmi);\n            generateRecommendation(category);\n            generateDietPlan(category);\n            drawGraph(bmi);\n        }\n\n        function displayBMIRange(bmi) {\n            if (bmi < 18.5) {\n                rangeResult.textContent = 'Underweight';\n                rangeResult.style.color = 'rgb(12, 137, 238)';\n                return 'Underweight';\n            } else if (bmi < 25) {\n                rangeResult.textContent = 'Healthy';\n                rangeResult.style.color = 'rgb(0, 137, 0)';\n                return 'Healthy';\n            } else if (bmi < 30) {\n                rangeResult.textContent = 'Overweight';\n                rangeResult.style.color = 'rgb(227, 212, 47)';\n                return 'Overweight';\n            } else {\n                rangeResult.textContent = 'Obese';\n                rangeResult.style.color = 'rgb(255, 0, 0)';\n                return 'Obese';\n            }\n        }\n\n        function generateRecommendation(category) {\n            let advice = '';\n            switch (category) {\n                case 'Underweight':\n                    advice = 'Consider increasing your calorie intake with nutrient-dense foods such as nuts, avocados, and lean protein. Consult a dietitian for a personalized plan.';\n                    break;\n                case 'Healthy':\n                    advice = 'Maintain your healthy weight by eating a balanced diet rich in fruits, vegetables, lean proteins, and whole grains. Stay active!';\n                    break;\n                case 'Overweight':\n                    advice = 'Focus on portion control and reduce intake of sugary and high-fat foods. Incorporate regular physical activity into your routine.';\n                    break;\n                case 'Obese':\n                    advice = 'Adopt a low-calorie diet and increase physical activity. Seek guidance from a healthcare provider for a structured weight-loss plan.';\n                    break;\n            }\n            recommendation.textContent = advice;\n        }\n\n        function generateDietPlan(category) {\n            let diet = '';\n            switch (category) {\n                case 'Underweight':\n                    diet = `\n                        <div class=\"diet-item\">\n                         \n                            <div><strong>Breakfast:<\/strong> Oats with almond butter and banana<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n                            \n                            <div><strong>Snack:<\/strong> Greek yogurt with nuts and berries<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n                            \n                            <div><strong>Lunch:<\/strong> Grilled chicken with quinoa and vegetables<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n                            \n                            <div><strong>Snack:<\/strong> Smoothie with protein powder, spinach, and peanut butter<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n                            \n                            <div><strong>Dinner:<\/strong> Salmon with brown rice and steamed broccoli<\/div>\n                        <\/div>\n                    `;\n                    break;\n                case 'Healthy':\n                    diet = `\n                        <div class=\"diet-item\">\n                            \n                            <div><strong>Breakfast:<\/strong> Scrambled eggs with avocado and whole-grain toast<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n                            \n                            <div><strong>Snack:<\/strong> Apple with peanut butter<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n                           \n                            <div><strong>Lunch:<\/strong> Turkey wrap with veggies and hummus<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n                           \n                            <div><strong>Snack:<\/strong> Carrot sticks with guacamole<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n                           \n                            <div><strong>Dinner:<\/strong> Grilled chicken with steamed asparagus and couscous<\/div>\n                        <\/div>\n                    `;\n                    break;\n                case 'Overweight':\n                    diet = `\n                        <div class=\"diet-item\">\n                            \n                            <div><strong>Breakfast:<\/strong> Greek yogurt with chia seeds and strawberries<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n                            \n                            <div><strong>Snack:<\/strong> Almonds and a piece of dark chocolate<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n\n                            <div><strong>Lunch:<\/strong> Boiled eggs with spinach salad<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n\n                            <div><strong>Snack:<\/strong> Cucumber and hummus<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n\n                            <div><strong>Dinner:<\/strong> Grilled chicken with roasted vegetables<\/div>\n                        <\/div>\n                    `;\n                    break;\n                case 'Obese':\n                    diet = `\n                        <div class=\"diet-item\">\n\n                            <div><strong>Breakfast:<\/strong> Vegetable omelette with spinach and mushrooms<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n\n                            <div><strong>Snack:<\/strong> Apple with a handful of almonds<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n\n                            <div><strong>Lunch:<\/strong> Grilled salmon with steamed broccoli<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n\n                            <div><strong>Snack:<\/strong> Smoothie with spinach, avocado, and protein powder<\/div>\n                        <\/div>\n                        <div class=\"diet-item\">\n\n                            <div><strong>Dinner:<\/strong> Grilled chicken with roasted Brussels sprouts<\/div>\n                        <\/div>\n                    `;\n                    break;\n            }\n\n            dietPlan.innerHTML = diet;\n        }\n\n        function resetInputs() {\n            heightInput.value = '';\n            weightInput.value = '';\n            bmiResult.textContent = 'BMI: 0.0';\n            rangeResult.textContent = 'Please enter your height and weight.';\n            recommendation.textContent = '';\n            dietPlan.innerHTML = '';\n            if (chart) {\n                chart.destroy();\n            }\n        }\n\n        function drawGraph(bmi) {\n            if (chart) {\n                chart.destroy();\n            }\n\n            chart = new Chart(bmiGraph, {\n                type: 'bar',\n                data: {\n                    labels: ['BMI'],\n                    datasets: [{\n                        label: 'BMI',\n                        data: [bmi],\n                        backgroundColor: 'rgba(75, 192, 192, 0.2)',\n                        borderColor: 'rgba(75, 192, 192, 1)',\n                        borderWidth: 1\n                    }]\n                },\n                options: {\n                    scales: {\n                        y: {\n                            beginAtZero: true\n                        }\n                    }\n                }\n            });\n        }\n    });\n<\/script>\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t<div class=\"elementor-element elementor-element-1120134 e-flex e-con-boxed e-con e-parent\" data-id=\"1120134\" data-element_type=\"container\">\n\t\t\t\t\t<div class=\"e-con-inner\">\n\t\t\t\t<div class=\"elementor-element elementor-element-a19f1ec elementor-widget elementor-widget-text-editor\" data-id=\"a19f1ec\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t\t\t\t\t\t<h2 class=\"nhsuk-heading-l\">\u0646\u062a\u064a\u062c\u062a\u0643<\/h2><section><div><p>\u0633\u064a\u062a\u0645 \u0639\u0631\u0636 \u0646\u062a\u064a\u062c\u062a\u0643 \u0644\u0645\u0624\u0634\u0631 \u0643\u062a\u0644\u0629 \u0627\u0644\u062c\u0633\u0645 (BMI) \u0643\u0631\u0642\u0645 \u0636\u0645\u0646 \u0625\u062d\u062f\u0649 \u0647\u0630\u0647 \u0627\u0644\u0641\u0626\u0627\u062a \u0627\u0644\u0648\u0632\u0646\u064a\u0629:<\/p><ul><li>\u0646\u0642\u0635 \u0627\u0644\u0648\u0632\u0646<\/li><li>\u0648\u0632\u0646 \u0635\u062d\u064a<\/li><li>\u0632\u064a\u0627\u062f\u0629 \u0627\u0644\u0648\u0632\u0646<\/li><li>\u0633\u0645\u0646\u0629<\/li><\/ul><p class=\"translation-block\">\u0628\u0639\u062f \u0627\u0644\u062d\u0635\u0648\u0644 \u0639\u0644\u0649 \u0646\u062a\u064a\u062c\u062a\u0643\u060c \u0642\u062f \u064a\u064f\u0637\u0644\u0628 \u0645\u0646\u0643 \u0642\u064a\u0627\u0633 \u0645\u062d\u064a\u0637 \u062e\u0635\u0631\u0643. \u0647\u0630\u0627 \u064a\u0633\u0627\u0639\u062f\u0643 \u0639\u0644\u0649 \u0645\u0639\u0631\u0641\u0629 \u0625\u0630\u0627 \u0643\u0646\u062a \u062a\u062d\u0645\u0644 \u0648\u0632\u0646\u0627\u064b \u0632\u0627\u0626\u062f\u0627\u064b \u0641\u064a \u0645\u0646\u0637\u0642\u0629 \u0627\u0644\u0628\u0637\u0646.\n\u064a\u0645\u0643\u0646\u0643 \u0623\u064a\u0636\u0627\u064b \u0625\u062c\u0631\u0627\u0621 \u0627\u062e\u062a\u0628\u0627\u0631 \u062a\u0642\u064a\u064a\u0645 \u062a\u0641\u0635\u064a\u0644\u064a \u0644\u0644\u062c\u0633\u0645 \u0648\u0627\u0644\u0635\u062d\u0629 \u0645\u062c\u0627\u0646\u0627\u064b \u0628\u0632\u064a\u0627\u0631\u0629 \u0641\u0631\u0639\u0646\u0627.<\/p><\/div><\/section>\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>","protected":false},"excerpt":{"rendered":"<p>Calculate Your BMI &#8211; Body Mass Index calculate your bmi and get customized diet plans for weight loss, maintenance, or gain. BMI Calculator Calculate Reset BMI: 0.0 Please enter your height and weight. Suggested Diet Plan Your result Your BMI result will be displayed as a number with one of these weight categories: underweight a [&hellip;]<\/p>","protected":false},"author":1,"featured_media":2267,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"class_list":["post-2231","page","type-page","status-publish","has-post-thumbnail","hentry"],"_links":{"self":[{"href":"https:\/\/alainpersonaltrainer.ae\/ar\/wp-json\/wp\/v2\/pages\/2231","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/alainpersonaltrainer.ae\/ar\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/alainpersonaltrainer.ae\/ar\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/alainpersonaltrainer.ae\/ar\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/alainpersonaltrainer.ae\/ar\/wp-json\/wp\/v2\/comments?post=2231"}],"version-history":[{"count":91,"href":"https:\/\/alainpersonaltrainer.ae\/ar\/wp-json\/wp\/v2\/pages\/2231\/revisions"}],"predecessor-version":[{"id":3372,"href":"https:\/\/alainpersonaltrainer.ae\/ar\/wp-json\/wp\/v2\/pages\/2231\/revisions\/3372"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/alainpersonaltrainer.ae\/ar\/wp-json\/wp\/v2\/media\/2267"}],"wp:attachment":[{"href":"https:\/\/alainpersonaltrainer.ae\/ar\/wp-json\/wp\/v2\/media?parent=2231"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}