0% found this document useful (0 votes)
9 views2 pages

Code

best code
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views2 pages

Code

best code
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 2

<html lang="en">

<head>
<meta charset="UTF-8"></meta>
<meta content="width=device-width, initial-scale=1.0" name="viewport"></meta>
<title>Blog</title>
<link href="style.css" rel="stylesheet"></link>
</head>
<body>

<h3 style="text-align: center;">&nbsp;<span style="-webkit-text-size-adjust:


auto; font-family: helvetica; font-size: 18px; text-align: center;">Welcome to
Srilankan Video !</span><span style="-webkit-text-size-adjust: auto; font-family:
helvetica; font-size: 25px; text-align: center;"> </span></h3><p></p>
<p style="text-align: center;">&nbsp;<span br="" style="-webkit-text-size-
adjust: auto; font-family: verdana; font-size: 11px; text-align: center;">
Videos බලන්න නම් මෙ විදියට කරන්න.<br />
To watch the video, follow these rules.<br /><br />
මුලින්ම තියෙන රතු පාට බටන් එක ඔබන්න ඊටපස්සෙ ඔයාව වෙන පිටුවකට යයි. <br />
First, press the red button,Then you will be taken to another page.<br /><br />

ඒ පිටුවේ තප්පර 20 ක් විතර ඉන්න.<br /> Stay on the page for about 20
seconds.<br /><br />

ඊටපස්සෙ බැක් වෙලා ඇවිත් ආපහු දෙවෙනියට තියෙන කොළ පාට බටන් එක ඔබන්න. <br />
Then come back and press the green button. <br /><br />

එතකොට ඔයාව Video එකට කෙලින්ම යයි. <br /> Then you will go directly to the
video.<br /><br />

කියලා තියන විදියට කරොත් විතරයි ඔයාට video බලන්න පුළුවන්. <br /> You can
watch the video only if you follow the instructions.<br /><br />
ඒක නිසා කියපු විදිහට පිලිවෙලට කරන්න. <br /> fallow this Rules. </span></p>

<button class="btnRed2" id="redButton" style="-webkit-text-size-adjust: auto;


background-color: red; border-radius: 10px; color: white; display: block; font-
size: 16px; height: 60px; margin: 0px auto; width: 230px;">Click</button><br />
<button class="btnGreen2" disabled="" id="greenButton" style="-webkit-text-
size-adjust: auto; background-color: green; border-radius: 10px; color: white;
display: block; font-size: 16px; height: 60px; margin: 0px auto; width:
230px;">Watch the video</button>

<script>
// Get references to the buttons
const redButton = document.getElementById('redButton');
const greenButton = document.getElementById('greenButton');

// Check if the red button was previously clicked


const redButtonClicked = sessionStorage.getItem('redButtonClicked');
if (redButtonClicked) {
greenButton.removeAttribute('disabled');
}

// Add event listener to the red button


redButton.addEventListener('click', function() {
// Redirect to the red page
window.location.href =
'https://crockerydestructivespoken.com/xaan84rssxaxajr25if?
key=90659fdsvsd567bc8676bfa977e3610b6xaxa4e1c';
// Store the state of the red button
sessionStorage.setItem('redButtonClicked', true);
});

// Add event listener to the green button


greenButton.addEventListener('click', function() {
// Check if the red button was clicked
const redButtonClicked = sessionStorage.getItem('redButtonClicked');
if (!redButtonClicked) {
// Redirect to the error page if the red button was not clicked
window.location.href = 'error.html';
} else {
// Redirect to the green page if the red button was clicked
window.location.href = 'https://www.youtube.com/results?
search_query=shamod+firezz';
}
});

// Refresh the page every 5 seconds


setInterval(function() {
window.location.reload();
}, 10000); // 10000 milliseconds = 10 seconds

</script>
</body>
</html>

You might also like