Advertise Here
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email?
News
: Welcome to eMoneySpace!
May 21, 2022 07:02 PM
Home
Search
Login
Register
eMoneySpace
»
Webmaster's Corner
»
Developer Board
»
INNER HTLM AND FUNCTION SCRIPT HELP
INNER HTLM AND FUNCTION SCRIPT HELP
Pages: [
1
]
« previous
next »
Print
Author
Topic: INNER HTLM AND FUNCTION SCRIPT HELP (Read 691 times)
mbuk81
Reputation: (
0
)
Offline
Posts: 240
Referrals: 2
WIN 0.01BTC FREE @ BTCQUIX.XYZ
INNER HTLM AND FUNCTION SCRIPT HELP
Mar 18, 2021 12:51 AM
here is part of my script that i want the game to end and taking you to a different page instead of just restating
all the code here just not sure on how to chance the function from restating on click to going to where i want them to
if anyone can tell me what to chance will be very useful
var p = 0.2;
var scratched = 0;
function callback(d) {
scratched++;
if(scratched >= cards) {
if(win > (cards/3)) {
document.getElementById('result').innerHTML = 'click here to play again';
} else {
document.getElementById('result').innerHTML = 'You lose, but you can try again!';
instructions.addEventListener('click', restartAll, true);
}
function restartAll() {
instructions.removeEventListener('click', restartAll, false);
for(var i=0, l=cardsArray.length; i<l; i++) {
cardsArray
.restart();
cardsArray
.className = '';
isMouseDown = false;
}
}
}
}
Logged
JustClick
Reputation: (
+60
)
Offline
Posts: 5792
Referrals: 1
Re: INNER HTLM AND FUNCTION SCRIPT HELP
Reply #1:
Mar 19, 2021 05:08 AM
in this are of inner.HTML u can display anything
document.getElementById('result').innerHTML = '<a href="page.html"><button>CLICK TO GO</button></a>';
if want to redirect ur members then modify ur code like this
instead of this
document.getElementById('result').innerHTML = 'click here to play again';
use this
location.href = "
https://sitename.com/nextpage.html
";
*** MAKE YOUR SCRIPT BACKUP BEFORE TRYING ANY MODIFICATION ***
«
Last Edit: Mar 19, 2021 05:12 AM by JustClick
»
Logged
Pages: [
1
]
Print
« previous
next »
Jump to:
Please select a destination:
-----------------------------
EMS
-----------------------------
=> Forum Rules, FAQ and Announcements
=> Suggestions, Feedback and Forum Support
=> EMS Games & Contests
-----------------------------
Get Paid To Websites
-----------------------------
=> General Discussion
=> Crypto Currencies
=> Praises and Applause
=> Complaints
=> New and Pending Websites
=> Suspect Websites
=> Stable Websites
=> Downline Builder
=> Referral Exchange
=> Referral Deals
-----------------------------
Webmaster's Corner
-----------------------------
=> Developer Board
=> List your Website or Blog
=> Industry Announcements
=> Advertising Offers
-----------------------------
Members Lounge
-----------------------------
=> Chit-Chat Main
=> Buy and Sell
=> Introduce Yourself!
=> Non English Forum
=> Advertise Here