My Steemit Friends Update: Power Down Ranking page now includes "Sum of SP being withdrawn" calculator
utopian-io·@magicmonk·
0.000 HBDMy Steemit Friends Update: Power Down Ranking page now includes "Sum of SP being withdrawn" calculator
- <a href="http://mysteemitfriends.online">My Steemit Friends Tool website.</a><br> - <a href="http://github.com/Bulletproofmonk/MySteemitFriends">Github repository.</a> - <a href="https://github.com/Bulletproofmonk/MySteemitFriends/commit/2eab5f2b533816fc2ea38f1403757efb84138e6b">Commit for this update</a> <br><br> Below is the description of new features added to the Power Down Ranking Table, accessible at http://mysteemitfriends.online/powerdown.php ### New Features On the Steemit Power Down Ranking page within the My Steemit Friends website, you will see a new panel titled "Sum of SP being withdrawn".  In this panel, you can enter the number of top SP holders in a textbox (default value 200, maximum value 500), then click the "calculate" button.  You will then be able to see the sum of SP being withdrawn from the top X SP holders at the next powerdown, rounded to the nearest SP.  You can change the number in the text box and click Calculate again without exiting this page, so you can see the difference in SP by changing the number of top SP holders.  You can scroll down to the rankings at any time and it is still working as previously described.  ### How did you implement it? - <a href="https://github.com/Bulletproofmonk/MySteemitFriends/commit/2eab5f2b533816fc2ea38f1403757efb84138e6b">Relevant Commit</a> <br><br> **<a href="https://github.com/Bulletproofmonk/MySteemitFriends/blob/master/powerdown.php">powerdown.php</a>**: A panel was added with a numerical textbox and a button that calls an AJAX function that passes the contents of the textbox to a PHP file to be processed. The PHP file then returns the value (total SP being withdrawn) and this is then printed in the same panel underneath the button. **<a href="https://github.com/Bulletproofmonk/MySteemitFriends/blob/master/calcSumSP.php">calcSumSP.php</a>**: This PHP file retrieves the number of top SP holders parameter from *powerdown.php* via an AJAX call. It sanitizes the input value using filter_var and then binds the value to a prepared SQL statement to find the sum of SP being withdrawn from this amount of top SP holders. It then returns the sum of SP which is passed back to *powerdown.php*. <br /><hr/><em>Posted on <a href="https://utopian.io/utopian-io/@magicmonk/my-steemit-friends-update-power-down-ranking-page-now-includes-sum-of-sp-being-withdrawn-calculator">Utopian.io - Rewarding Open Source Contributors</a></em><hr/>
👍 liangfengyouren, bobdos, chelsea.bear, steemitstats, thecrytotrader, phedizzle, faizan-ashraf, cryptonewsly, atmosblack, centerlink, mikepedro, bmj, webcoop, trevorpetrie, jaycobbell, urs, mumofmany, steemulator, fisnikk, steemsquad, teamaustralia, juicy-shark, ausbitbank, shellyduncan, world-travel-pro, hakansorucu, khayziljoy, shreetbn, lydiachan, arama, vandadream, justyy, dailychina, fishaa, serenazz, regals, cnsteem, gohba.handcrafts, dailystats, happyukgo, lilypang22, gogoabc, vincenthan, ivysrono, shengjian, cha0s0000, moobear, ety001, jianan, foodielifestyle, superbing, geass, dailyfortune, steemitvip, linda65, prch, lakemountain, woolfe19861008, travelgirl, magicmonk, catwomanteresa, mirahu, ladolcefirma, dodybireuen, teamsteem, berkah, mrs.agsexplorer, pnc, bitcoiner, greenstar, susanli3769, mrsquiggle, joythewanderer, helo, sandan, vladimir-simovic, cifer, codingdefined, utopian-io,