Pages:
Author

Topic: PHP Bitcoin Node Status Page - page 3. (Read 10025 times)

member
Activity: 74
Merit: 10
www.btcaudio.eu || LIVE-AUDIO-TICKER
January 11, 2015, 09:13:56 AM
#23
can you add FREE DISK SPACE ?

Code:
Free disk space:
    $bytes disk_free_space(".");
    
$si_prefix = array( 'B''KB''MB''GB''TB''EB''ZB''YB' );
    
$base 1024;
    
$class min((int)log($bytes $base) , count($si_prefix) - 1);
  
//  echo $bytes . '';
    
echo sprintf('%1.2f' $bytes pow($base,$class)) . ' ' $si_prefix[$class] . '';
?>

LIVE DEMO: http://btcaudio.eu/node/
copper member
Activity: 3948
Merit: 2201
Verified awesomeness ✔
January 11, 2015, 07:09:07 AM
#22
Awesome, great to know the page is being used.

I've just updated the code with a better Readme and wrapped the node sub-version in htmlspecialchars Smiley
Ah alright, going to pull again than. Setting it up was really easy, but I'm a Web dev so I guess it should be easy for me Tongue
newbie
Activity: 28
Merit: 0
January 11, 2015, 06:08:30 AM
#21
Well, I just setup Bitcoin node, just try this, hahaha. I have always wanted to run a Bitcoin node so now I had a reason to do so. The status page can be found here: click. Bitcoind is still syncing blocks though and has been doing so for the last 12 hours.


Awesome, great to know the page is being used.

I've just updated the code with a better Readme and wrapped the node sub-version in htmlspecialchars Smiley
copper member
Activity: 3948
Merit: 2201
Verified awesomeness ✔
January 11, 2015, 05:50:40 AM
#20
Well, I just setup a Bitcoin node, just give this try this. I have always wanted to run a Bitcoin node so now I had a reason to do so. The status page can be found here: click. Bitcoind is still syncing blocks though and has been doing so for the last 12 hours.
full member
Activity: 141
Merit: 100
January 10, 2015, 10:27:57 AM
#19
You need to sanitize the protocol subversion before displaying it to users.

Any particular reason?
Nevermind, the client does it for you these days: https://github.com/bitcoin/bitcoin/commit/a946aa8d3ec7009ac670eeb65a525efe5eeb6e84

I haven't been around for a while.
This fix was made at version 0.9 (if I read it correctly). When doing a "getpeerlist" on my own client (or visiting CraigWatson's status page), I see some clients still having <0.9.
I think htmlspecialchars() shouldn't hurt. It's better than potentially endangering webmasters who integrates the status page on a <0.9 node.
hero member
Activity: 583
Merit: 500
January 09, 2015, 10:23:02 AM
#18
something new, time to give it a shot.
legendary
Activity: 1386
Merit: 1053
Please do not PM me loan requests!
January 09, 2015, 07:46:52 AM
#17
You need to sanitize the protocol subversion before displaying it to users.

Any particular reason?
Nevermind, the client does it for you these days: https://github.com/bitcoin/bitcoin/commit/a946aa8d3ec7009ac670eeb65a525efe5eeb6e84

I haven't been around for a while.

Welcome back Tongue
hero member
Activity: 560
Merit: 501
January 09, 2015, 07:13:04 AM
#16
You need to sanitize the protocol subversion before displaying it to users.

Any particular reason?
Nevermind, the client does it for you these days: https://github.com/bitcoin/bitcoin/commit/a946aa8d3ec7009ac670eeb65a525efe5eeb6e84

I haven't been around for a while.
newbie
Activity: 28
Merit: 0
January 09, 2015, 07:06:26 AM
#15
You need to sanitize the protocol subversion before displaying it to users.

Any particular reason?
hero member
Activity: 560
Merit: 501
January 09, 2015, 07:05:51 AM
#14
You need to sanitize the protocol subversion before displaying it to users.
sr. member
Activity: 377
Merit: 250
https://keybase.io/magicmann
January 08, 2015, 10:13:19 AM
#13
Would you consider adding something in the config files that would give users the option of displaying the connected user's IPs?

It already exists, just flip the 'display_peer_info' switch to TRUE -  a full readme is on the way though Smiley Smiley

Reference: https://github.com/craigwatson/bitcoind-status/blob/master/php/config.php#L20


My bad, I meant to not display it, but I see I can just ensure that's set to false.
newbie
Activity: 28
Merit: 0
January 08, 2015, 09:13:04 AM
#12
Would you consider adding something in the config files that would give users the option of displaying the connected user's IPs?

It already exists, just flip the 'display_peer_info' switch to TRUE -  a full readme is on the way though Smiley Smiley

Reference: https://github.com/craigwatson/bitcoind-status/blob/master/php/config.php#L20
sr. member
Activity: 377
Merit: 250
https://keybase.io/magicmann
January 08, 2015, 08:56:35 AM
#11
Would you consider adding something in the config files that would give users the option of displaying the connected user's IPs?
newbie
Activity: 28
Merit: 0
January 08, 2015, 07:03:37 AM
#10
Just improved a few things, including handling errors from RPC and responsifying the peer information tables, check out the live copy here: https://loki.vikingserv.net

A full README is next on the list! Smiley

This is fantastic. Likely going to fork it to use for a cryptocurrency I've been supporting and running nodes for.  Wink

Thanks, much appreciated - please feel free to tip/donate if you find it useful Smiley

Submitted a pull request with some potential improvements just now Smiley

Pull request merged Smiley
sr. member
Activity: 377
Merit: 250
https://keybase.io/magicmann
January 07, 2015, 10:41:39 PM
#9
This is fantastic. Likely going to fork it to use for a cryptocurrency I've been supporting and running nodes for.  Wink
legendary
Activity: 1386
Merit: 1053
Please do not PM me loan requests!
January 07, 2015, 10:48:34 AM
#8
Submitted a pull request with some potential improvements just now Smiley
sr. member
Activity: 350
Merit: 250
★YoBit.Net★ 350+ Coins Exchange & Dice
January 07, 2015, 08:36:02 AM
#7
Very Nice, It might be nice to show some Peer Info, Who is connected, What version of bitcoind they use etc.

I can fork your code and add this if you like, You are welcome to use it.

MrF

Just added this - bit of a hacky implementation as it's not responsive, but responsive tables are annoying as hell Smiley

No thats good, Looks really neat.

Good Job Smiley

Would be nice to have multiple themes Smiley I will use this for my full node.
newbie
Activity: 28
Merit: 0
January 07, 2015, 08:14:40 AM
#6
Very Nice, It might be nice to show some Peer Info, Who is connected, What version of bitcoind they use etc.

I can fork your code and add this if you like, You are welcome to use it.

MrF

Just added this - bit of a hacky implementation as it's not responsive, but responsive tables are annoying as hell Smiley
sr. member
Activity: 350
Merit: 250
★YoBit.Net★ 350+ Coins Exchange & Dice
January 07, 2015, 06:08:42 AM
#5
Very Nice, It might be nice to show some Peer Info, Who is connected, What version of bitcoind they use etc.

I can fork your code and add this if you like, You are welcome to use it.

MrF
legendary
Activity: 1386
Merit: 1053
Please do not PM me loan requests!
January 07, 2015, 01:37:42 AM
#4
Looks nice! I'll have a look, maybe put it on my node.
Pages:
Jump to: