PHP Object Oriented Programming Constructor Methods Concepts Utilized In 26 Innocent Hindu Tourists Assassinated on 22nd Of May, 2025 In Pahalgam On Terorrist Attack(Both Images And PHP OOPS Constructor Methods Codings Included)
PHP Object Oriented Programming Constructor Methods Concepts Utilized In 26 Innocent Hindu Tourists Assassinated on 22nd Of May, 2025 In Pahalgam On Terorrist Attack(Both Images And PHP OOPS Constructor Methods Codings Included)
I am getting the popup of "Confirm Form Resubmission" as because I have used POST method in form (action).
Here I have created the form of Deceased 26 Hindu Tourists and I have called the values of the form using constructor and methods and once I click on the submit button my output will get generated as shown in the image below.
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Kashmir Pahalgam Tourists Attack</title>
<style type="text/css">
.d1{
background-color: lightgoldenrodyellow;
}
.d2{
color: green;
background-color: lightblue;
text-align: center;
}
.d3{
background-color: Orange;
display: flex;
gap: 15px;
font-size: 10px;
font-weight: bolder;
}
.d4{
background-color: yellowgreen;
}
.d5{
background-color: hotpink;
color: darkred;
font-size: 25px;
}
.d6{
text-align: center;
background-color: lightseagreen;
color: indigo;
font-size: 20px;
font-weight: bold;
}
</style>
</head>
<body class="d1">
<div class="d2">
<h2>In Memorial Of The Deceased 26 Tourists Of Pahalgam Terror Attack</h2>
</div>
<div class="d3">
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/bitan-adhikary.jpg" height="210px" width="210px"><p>Bitan Adhikari, West Bengal</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/sameer-guha.jpg" height="210px" width="210px"><br><p>Sameer Guha, West Bengal</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/manish-ranjan.jpg" height="210px" width="210px"><p>Manish Ranjan, West Bengal</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/sushil-nathaniel.jpg" height="210px" width="210px"><p>Sushil Nathaniel, Madhya Pradesh</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/syed-adil-hussain-shah.jpg" height="210px" width="210px"><p>Syed Adil Hussain Shah, Jammu And Kashmir</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/hemant-suhas-joshi.jpg" height="210px" width="210px"><p>Hemant Suhas Joshi, Maharashtra</p>
</div>
</div>
<div class="d3">
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/vinay-narwal.jpg" height="210px" width="210px"><p>Lt. Vinay Narwal, Haryana</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/atul-shrikant-mone.jpg" height="210px" width="210px"><p>Atul Shrikant Mone, Maharashtra</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/neeraj-udhwani.jpg" height="210px" width="210px"><p>Neeraj Udhwani, Rajasthan</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/sudip-neupane.jpg" height="210px" width="210px"><p>Sudip Neupane, Nepal</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/shubham-dwivedi.jpg" height="210px" width="210px"><p>Shubham Dwivedi, Uttar Pradesh</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/prashant-kumar-satpathi.jpg" height="210px" width="210px"><p>Prashant Kumar Satpathy, Odisha</p>
</div>
</div>
<div class="d3">
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/ramachandran.jpg" height="210px" width="210px"><p>N. Ramachandran, Kerala</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/sanjay-lakshman-lele.jpg" height="210px" width="210px"><p>Sanjay Lakshman Lele, Maharashtra</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/dinesh-agarwal.jpg" height="210px" width="210px"><p>Dinesh Agarwal, Chhattisgarh</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/dilip-disle.jpg" height="210px" width="210px"><p>Dilip Disle, Maharashtra</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/chandramauli.jpg" height="210px" width="210px"><p>J.S. Chandramouli, Andhra Pradesh</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/somisetti-madhusudan-rao.jpg" height="210px" width="210px"><p>Somisetti Madhusudan Rao, Karnataka</p>
</div>
</div>
<div class="d3">
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/santosh-jagdale.jpg" height="210px" width="210px"><p>Santosh Jagdale, Maharashtra</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/bharat-bhushan.jpg" height="210px" width="210px"><p>Bharat Bhushan, Karnataka</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/sumit-parmar.jpg" height="210px" width="210px"><p>Sumit Parmar, Gujarat</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/yatesh-parmar.jpg" height="210px" width="210px"><p>Yatish Parmar, Gujarat</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/tage-hailyang.jpg" height="210px" width="210px"><p>Tage Hailyang, Arunachal Pradesh</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/shailesh-kalathiya.jpg" height="210px" width="210px"><p>Shailesh Kalathiya, Gujarat</p>
</div>
</div>
<div class="d3">
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/manjunath-rao.jpg" height="210px" width="210px"><p>Manjunath Rao, Karnataka</p>
</div>
<div>
<img src="https://www.thehindu.com/infographics/2025-04-24/pahalgam-terror-attack-victims-tribute/image/kaustubh-ganbote-2.jpg" height="210px" width="210px"><p>Kaustubh Ganbote, Maharashtra</p>
</div>
</div>
<div class="d4">
<img src="https://thumbs.dreamstime.com/b/burning-bright-golden-warm-glow-candle-flames-many-beauti-beautiful-lit-tealight-candles-glowing-yellow-light-97370175.jpg" height="500px" width="1335px">
</div>
<div class="d5">
<p>It was 22nd of May, 2025 when the tourists were enjoying their holidays with their families suddenly the group of 4 terrorists appeared at that place and assassinated 26 innocent hindu tourists on spot infont of their families and the day was shattered by an act of senseless violence. So, from my end I tribute a huge condolences to all the 26 innocent tourists who were been deceased in the terror attack. I hope wherever the 26 innocent tourists are present, their souls are in rest in peace(RIP).</p>
</div>
<form class="d6" method="post">
<h3 align="center">Deceased 26 Hindu Tourists Form</h3>
Sl. No: <input type="number" name="sl_no"><br>
Name Of The Deceased: <input type="text" name="name"><br>
Parentage: <input type="text" name="parentage"><br>
Residence: <input type="text" name="residence"><br>
Gender: <input type="radio" name="gender" value="Male">Male
<input type="radio" name="gender" value="Female">Female<br>
Age: <input type="number" name="age"><br>
Occupation: <input type="text" name="occupation"><br>
Details: <textarea type="textarea" name="details"></textarea><br>
<button type="submit" name="submit" value="submit">Submit</button>
</form>
<?php
if (isset($_REQUEST['submit'])) {
$sl_no=$_REQUEST['sl_no'];
$name_of_the_deceased=$_REQUEST['name'];
$parentage=$_REQUEST['parentage'];
$residence=$_REQUEST['residence'];
$gender=$_REQUEST['gender'];
$age=$_REQUEST['age'];
$occupation=$_REQUEST['occupation'];
$details=$_REQUEST['details'];
class TouristForm{
function __construct($sl_no,$name_of_the_deceased,$parentage,$residence,$gender,$age,$occupation,$details)
{
$this->sn=$sl_no;
$this->notd=$name_of_the_deceased;
$this->pa=$parentage;
$this->re=$residence;
$this->ge=$gender;
$this->ag=$age;
$this->occu=$occupation;
$this->de=$details;
}
function display()
{
echo $this->sn."<br>".$this->notd."<br>".$this->pa."<br>".$this->re."<br>".$this->ge."<br>".$this->ag."<br>".$this->occu."<br>".$this->de;
}
}
$obj=new TouristForm($sl_no,$name_of_the_deceased,$parentage,$residence,$gender,$age,$occupation,$details);
$obj->display();
}
?>
</body>
</html>
Comments
Post a Comment