Nyau
Newbie
Offline
Activity: 28
Merit: 0
|
|
July 06, 2015, 07:28:57 PM |
|
I'm trying to get up my first website with this script, but I don't have SSL and it always redirects to https://.. I found this // - Set this to true if you want users that come to http:// to be redirected // to https:// But what do I have to set to true? There's nothing like this..
|
|
|
|
|
|
|
|
|
Each block is stacked on top of the previous one. Adding another block to the top makes all lower blocks more difficult to remove: there is more "weight" above each block. A transaction in a block 6 blocks deep (6 confirmations) will be very difficult to remove.
|
|
|
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
|
|
owlcatz
Legendary
Offline
Activity: 3626
Merit: 1967
|
|
July 06, 2015, 07:30:44 PM |
|
I'm trying to get up my first website with this script, but I don't have SSL and it always redirects to https://.. I found this // - Set this to true if you want users that come to http:// to be redirected // to https:// But what do I have to set to true? There's nothing like this.. Those are comments in the code. There should be some code right underneath, like (This is just a guess) $HTTPS == "true"
(Or something along those lines). Good luck! Sorry, I didn't realize the source was on the OP. This is javascript, so it's different: Here is the default code, which is causing your redirects to https:// force_https_redirect: !isRunningLocally()
Since I'm not a Javascript person, I can only guess that removing the ! in front of that function call above will reverse the effect of what is there now - Here is the function it calls if it helps - // :: Bool function isRunningLocally() { return /^localhost/.test(window.location.host); }
Edit - Or, you could try just replacing !isRunningLocally() with either : true or "true" and see if that fixes it. Good luck!
|
. I C Λ R U S | | | | █████▄▄█████▄▄ ████████▀▀▀████ ██████▀█████▀███ ████████████████ ████████████████ ████████████████ ░▄█████████████████ ███████████████████ ███████████████████ ████████░░░▀▀▀▀▀▀▀▀ ████████▄▄▄████████ ███████████████████ █████████████████▀ | ░░░███ ▄▄▄███ ██████ ░░░███ ░░░███ ░░░███ ░░░███ ░░░███ ░░░███ ░░░███ ▄████████ ███▌░▐███ ████████▀ | | | | | █████████████████████ █████████████████████ █████████████████████ ██████▀▀▀▀████▀▀█████ █████░░▄▄░░██░░░█████ █████▄▄██░░███░░█████ █████▀▀▀▀░░▀██░░█████ ████░░░░▄▄▄▄█▀░░▀████ ████░░░░░░░░█░▀▀░████ █████████████████████ █████████████████████ █████████████████████ █████████████████████ | ████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ████ | ████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ████ | ████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ████ | | | | ████ ██
██ ████ | | ████ ██
██ ████ |
[/ce
|
|
|
Nyau
Newbie
Offline
Activity: 28
Merit: 0
|
|
July 06, 2015, 08:05:59 PM |
|
I'm trying to get up my first website with this script, but I don't have SSL and it always redirects to https://.. I found this // - Set this to true if you want users that come to http:// to be redirected // to https:// But what do I have to set to true? There's nothing like this.. Those are comments in the code. There should be some code right underneath, like (This is just a guess) $HTTPS == "true"
(Or something along those lines). Good luck! Sorry, I didn't realize the source was on the OP. This is javascript, so it's different: Here is the default code, which is causing your redirects to https:// force_https_redirect: !isRunningLocally()
Since I'm not a Javascript person, I can only guess that removing the ! in front of that function call above will reverse the effect of what is there now - Here is the function it calls if it helps - // :: Bool function isRunningLocally() { return /^localhost/.test(window.location.host); }
Edit - Or, you could try just replacing !isRunningLocally() with either : true or "true" and see if that fixes it. Good luck! I know it's just comments in the code.. I'm noob, but not that big BTW: I removed the ! and it's working! Thanks!
|
|
|
|
pescu23
Newbie
Offline
Activity: 19
Merit: 0
|
|
July 06, 2015, 08:20:30 PM |
|
I miss the TARGET to roll over or under...
Anyone can help me a bit to add this to the script?
|
|
|
|
owlcatz
Legendary
Offline
Activity: 3626
Merit: 1967
|
|
July 06, 2015, 09:28:14 PM |
|
I know it's just comments in the code.. I'm noob, but not that big BTW: I removed the ! and it's working! Thanks! No problem, and btw, I didn't mean to imply you were a noob, I just thought it was odd that you only included the comments and not the code. Glad you got it working. Always hated Javascript myself, it can really be messy sometimes!
|
. I C Λ R U S | | | | █████▄▄█████▄▄ ████████▀▀▀████ ██████▀█████▀███ ████████████████ ████████████████ ████████████████ ░▄█████████████████ ███████████████████ ███████████████████ ████████░░░▀▀▀▀▀▀▀▀ ████████▄▄▄████████ ███████████████████ █████████████████▀ | ░░░███ ▄▄▄███ ██████ ░░░███ ░░░███ ░░░███ ░░░███ ░░░███ ░░░███ ░░░███ ▄████████ ███▌░▐███ ████████▀ | | | | | █████████████████████ █████████████████████ █████████████████████ ██████▀▀▀▀████▀▀█████ █████░░▄▄░░██░░░█████ █████▄▄██░░███░░█████ █████▀▀▀▀░░▀██░░█████ ████░░░░▄▄▄▄█▀░░▀████ ████░░░░░░░░█░▀▀░████ █████████████████████ █████████████████████ █████████████████████ █████████████████████ | ████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ████ | ████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ████ | ████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ████ | | | | ████ ██
██ ████ | | ████ ██
██ ████ |
[/ce
|
|
|
pescu23
Newbie
Offline
Activity: 19
Merit: 0
|
|
July 07, 2015, 08:22:58 AM |
|
Hi!!
I have a couple doubts, please it would be great if someone could HELP me!!!
- Where do I configure the Hedge and so??
- And why do the Domain appears like unverified??
- How can I add the TARGET (Under 50.5 or Over whatever) to the script?? (This is a important missing thing!)
Thanks in advance!!
|
|
|
|
pescu23
Newbie
Offline
Activity: 19
Merit: 0
|
|
July 07, 2015, 05:07:25 PM |
|
No one can help me here??
|
|
|
|
hamburger
|
|
July 07, 2015, 06:11:30 PM |
|
No one can help me here?? If you want to change the "Chance:", find in the app.js the following line of code multiplier: { str: '2.00', num: 2.00, error: undefined }, Set multiplier anything between 1 and 10 - just note the profit drop if the Chance increase an it will increase if the Chance decrease.
|
Datacoin : DHZ6H91fsDoBHbdqED3ysCJJ2TUh3zRMZD Krugercoin : Yz3A9sTMp2yh5QLuAL8YQyvS5PdjHRHkkf
|
|
|
pescu23
Newbie
Offline
Activity: 19
Merit: 0
|
|
July 07, 2015, 06:16:39 PM |
|
No one can help me here?? If you want to change the "Chance:", find in the app.js the following line of code multiplier: { str: '2.00', num: 2.00, error: undefined }, Set multiplier anything between 1 and 10 - just note the profit drop if the Chance increase an it will increase if the Chance decrease. I don't want to change the Chance, I want to add the target number. Example for Multiplier x4, the Chance would be 24.75% and the Target would be > 75.24 I would like to show the target before Rolling the dice. How can I implement this? I'm a bit lost here...
|
|
|
|
hamburger
|
|
July 07, 2015, 06:56:42 PM |
|
I don't want to change the Chance, I want to add the target number.
Example for Multiplier x4, the Chance would be 24.75% and the Target would be > 75.24
I would like to show the target before Rolling the dice.
How can I implement this? I'm a bit lost here...
It is very important to explain exactly what you want. Do not expect people who are willing to take time to help you to just know what you are actually want. If you want to display "Target" instead of "Chance" Find the following code in app.js return el.div( {}, el.span( {className: 'lead', style: { fontWeight: 'bold' }}, 'Chance: ' ), innerNode );
return el.div( {}, el.span( {className: 'lead', style: { fontWeight: 'bold' }}, 'Target: ' ), innerNode );
Then change the code to inverse the calculation Find the following code in app.js // Just show '--' if chance can't be calculated var innerNode; if (isError) { innerNode = el.span( {className: 'lead'}, ' --' ); } else { innerNode = el.span( {className: 'lead'}, ' ' + (winProb * 100).toFixed(2).toString() + '%' ); }
change it to // Just show '--' if chance can't be calculated var innerNode; if (isError) { innerNode = el.span( {className: 'lead'}, ' --' ); } else { innerNode = el.span( {className: 'lead'}, ' > ' + ((winProb * -100) + 100 ).toFixed(2).toString() + '%' ); }
You site will display; Target: > 75.24%as simple as that! Enjoy.
|
Datacoin : DHZ6H91fsDoBHbdqED3ysCJJ2TUh3zRMZD Krugercoin : Yz3A9sTMp2yh5QLuAL8YQyvS5PdjHRHkkf
|
|
|
pescu23
Newbie
Offline
Activity: 19
Merit: 0
|
|
July 07, 2015, 07:02:44 PM |
|
Hamburger you are right I will be more specific when asking!
I would like to show both but I think I will be able (I'll try!) to implement it with your explanation.
Thank you very very very much, I was struggling my small mind with this all day!!
Thanks again!!!
|
|
|
|
pescu23
Newbie
Offline
Activity: 19
Merit: 0
|
|
July 07, 2015, 07:10:50 PM |
|
I'm having some difficulties to get the calculation for the <
|
|
|
|
pescu23
Newbie
Offline
Activity: 19
Merit: 0
|
|
July 07, 2015, 07:21:03 PM |
|
got it!
I'm publishing it in case anyone is interested:
((winProb * - 100)*-1).toFixed(2).toString()
|
|
|
|
coinableS
Legendary
Offline
Activity: 1442
Merit: 1179
|
|
July 18, 2015, 11:12:50 PM |
|
After installing this to my domain under the directory /dice it seems to have PERMANENTLY edited my server config. Even after completely deleting the directory I installed this to it still redirects to moneypot. I'd like to have my directory back for my own usage, what do I need to do to stop this auto-redirect?
|
|
|
|
coinableS
Legendary
Offline
Activity: 1442
Merit: 1179
|
|
July 19, 2015, 04:46:56 PM |
|
After installing this to my domain under the directory /dice it seems to have PERMANENTLY edited my server config. Even after completely deleting the directory I installed this to it still redirects to moneypot. I'd like to have my directory back for my own usage, what do I need to do to stop this auto-redirect?
SOLVED, it appears the issue was with my server and not this script. Since there is over 1,000 files it took longer to delete than my FTP manager lead me to believe. Why does this app have over 1,000 files? Seems like a bit much for a site that just uses moneypot API. API is supposed to make things lightweight...
|
|
|
|
dan (OP)
Newbie
Offline
Activity: 50
Merit: 0
|
|
July 28, 2015, 02:02:02 AM |
|
SOLVED, it appears the issue was with my server and not this script. Since there is over 1,000 files it took longer to delete than my FTP manager lead me to believe. Why does this app have over 1,000 files? Seems like a bit much for a site that just uses moneypot API. API is supposed to make things lightweight...
Untitled Dice consists of three files (app.js, index.html, style.css) and about a dozen dependency files found in the vendor and node_modules folders. The rest of those files are nonessential cruft managed by Git and its package manager. 1500+ files are in the ".git" directory that Git creates whenever you clone a project. This folder contains all of the revisions made to a project over time and is only necessary for development purposes, so avoid pushing it to your production server. 1000+ files are in the "node_modules" directory. Untitled Dice uses a package manager called NPM to maintain that folder of dependencies. Even though Untitled Dice only uses 9 files within that folder, the NPM tool populates it with all the development files that each dependency comes with. You can see the actual files that Untitled Dice depends on right here: https://github.com/untitled-dice/untitled-dice.github.io/blob/master/index.htmlOne quick solution would be to zip the untitled-dice directory, FTP it to your server, and then unzip it there. I'll look into isolating Untitled Dice's dependencies to make life easier for this workflow.
|
|
|
|
coinableS
Legendary
Offline
Activity: 1442
Merit: 1179
|
|
July 28, 2015, 04:36:51 AM |
|
1500+ files are in the ".git" directory that Git creates whenever you clone a project. This folder contains all of the revisions made to a project over time and is only necessary for development purposes, so avoid pushing it to your production server.
Thanks for that explanation Dan, I was wondering why there were so many files included when I cloned it on github.
|
|
|
|
smeagol
Legendary
Offline
Activity: 1008
Merit: 1005
|
|
July 29, 2015, 03:45:47 AM |
|
I put a script up at neodice.ga, it would be great if you could take a look and give me feedback! (There is a rudimentary XP feature, if you have any ideas feel free to PM me)
|
|
|
|
dan (OP)
Newbie
Offline
Activity: 50
Merit: 0
|
|
August 13, 2015, 10:08:17 PM Last edit: August 13, 2015, 10:33:00 PM by dan |
|
v0.0.7 Release: Hooked up Moneypot's new socket/chat serverMoneypot just released a new socket-server which includes a better chat-server and pushes notifications when the user's unconfirmed and confirmed balances change. This update doesn't change very many lines of code since the new chat-server has an almost identical API to the old one. If you want to check it out or if you want to implement this update on your own Untitled-Dice variant, you can see the changes here: https://github.com/untitled-dice/untitled-dice.github.io/commit/2e5a03fa0c683ab6f35fe7246ab538aa18f3cabdWhat this changes about Untitled-Dice: - Chat messages are now saved in Moneypot's database and not forgotten when the chat-server resets.
- Muted users are now saved in Moneypot's database and not forgotten when the chat-server resets.
- The UI now instantly updates to reflect the user's unconfirmed balance and when the user's deposit is confirmed and ready to spend.
For example, as soon as the user makes a bitcoin deposit to your app, Untitled-Dice displays it:
https://dl.dropboxusercontent.com/spa/quq37nq1583x0lf/-vxm59n-.png
And once a block confirms the deposit, Untitled-Dice rolls it into the user's balance:
https://dl.dropboxusercontent.com/spa/quq37nq1583x0lf/1xv64a03.png
In other words, users get instant peace of mind when they deposit into your app.
- Mods now actually have /mute and /unmute power. With the previous chat-server, mods were powerless.
- HH:MM timestamps are now displayed next to chat messages: https://i.imgur.com/fAZ8FrQ.png
|
|
|
|
coinableS
Legendary
Offline
Activity: 1442
Merit: 1179
|
|
August 13, 2015, 10:23:37 PM |
|
Very nice! Good update IMO, I think some people were confused about having to refresh to see their updated balance after a deposit. Keep up the good work guys!
|
|
|
|
|