I am Learning PHP

Started on the old forum in August 2022 · view the original in the archive · old links redirect here

1 reply · 106 views · started 4 years ago · 1 min read

2 participants
abhitn Junior · 15 posts #1

I started learning PHP and I made this simple copy of bomb game Can't wait to start learning backend part and make my own websites Will I be successfull, If I'll start learning now with dedication? Would I understand anything if I'll continue to learn?

<html>
</head>
<title> Bomb Squad</title>
<style>
a {
color: green;}
.ap{
border: 2px solid;
text-align: center;
}
h1{
text-align: center;
}
red{
background-color:2b2525;
font-size:24px;
font
}
blue{
background-color:2b2525;
font-size:24px;
}
</style>
</head>
<body>
<div class="ap">
<img src="al.jpg"><br>
Aliens have planted Nuclear Bombs in several cities!<br>
Your mission is to disable Bombs and save the World!<br>
then you will get FREE Cash gift!<br>
<br><br>
<b>Just cut Correct wire and Disable the Bomb<b><br>
<br>
<red><a href="?action=soc">Click here for Red wire </a></red><br>
<blue><a href="?action=soc">Click here for Blue wire </a></blue>
</div>
</body>
</html>

<?php
$action=($_GET['action']);
if ($action=="soc"){
$rand=rand(0, 1);
if ($rand==0) {
echo "<h1>You Win<br>Bomb Diffused</h1>";
}
Else
{
echo "<h1>You Lose<br>Bomb Blast</h1>";
}}
?>
centi Developer · 159 posts #2

it does work actually.. nice

😳 .................................... http://photomag.lk/ .................................... 🤨

Sign in to reply.

Similar topics

Keyboard shortcuts

g f
Go to forums
g h
Go to your feed
g m
Go to messages
r
Reply (in a topic)
/
Search
j
Next post
k
Previous post
?
This list
Ctrl/⌘ + Enter
Send what you are writing
Ctrl/⌘ + B / I
Bold / italic while writing
Esc
Close