Dispaly current bitcoin price +5%

Discussion in 'Programming' started by asteraki1976, Mar 2, 2014.

  1. #1
    Hello

    I am looking to display daily the bitcoin price on a site and automaticaly adjust it to have +5% on the price so if te price is 500 Euro to display 525 Euro.

    Is there any script to do this?

    Thank you
     
    asteraki1976, Mar 2, 2014 IP
  2. mrwicked1981

    mrwicked1981 Greenhorn

    Messages:
    20
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    13
    #2
    Hi,

    if you dont have it.. contact me i can make that for you.. for a small salary.

    regards

    Rolf
     
    mrwicked1981, Mar 2, 2014 IP
  3. AlphaNine_Vini

    AlphaNine_Vini Active Member

    Messages:
    218
    Likes Received:
    10
    Best Answers:
    1
    Trophy Points:
    88
    #3
    Just find the variable of the price where priced is displayed and Add 25 value to that variable for example $price+25
     
    AlphaNine_Vini, Mar 3, 2014 IP
  4. mrwicked1981

    mrwicked1981 Greenhorn

    Messages:
    20
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    13
    #4
    First you need to create a api from one your Bitcoin Market places... if you have them you can calculate this.
     
    mrwicked1981, Mar 3, 2014 IP
  5. asteraki1976

    asteraki1976 Active Member

    Messages:
    56
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    91
    #5
    At the moment i have this :

    <?php
    $price = parsePrice(file_get_contents('http://www.yoururl.com')) * 1.05;
    ?>
    PHP:
    from user kohashi....

    But i don't know any link to add there and will work ....
     
    asteraki1976, Mar 3, 2014 IP
  6. mrwicked1981

    mrwicked1981 Greenhorn

    Messages:
    20
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    13
    #6
    Maybe and who is the function parsePrice ?
     
    mrwicked1981, Mar 3, 2014 IP
  7. mrwicked1981

    mrwicked1981 Greenhorn

    Messages:
    20
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    13
    #7
    But here a Sample:

    $data = file_get_contents("https://www.bitstamp.net/api/ticker");
    $data = json_decode($data, true);
    $spot_last = $data['last'];
    $fee = bcsub($data['last'],100,2);
    $price = bcadd($data['last'],$fee,2);
     
    mrwicked1981, Mar 3, 2014 IP
  8. PoPSiCLe

    PoPSiCLe Illustrious Member

    Messages:
    4,623
    Likes Received:
    725
    Best Answers:
    152
    Trophy Points:
    470
    #8
    What? Failed math-class much, mate?
     
    PoPSiCLe, Mar 4, 2014 IP
    Spoiltdiva likes this.
  9. asteraki1976

    asteraki1976 Active Member

    Messages:
    56
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    91
    #9
    How can i add here the +5% and also got the result in Euro?

    Thank you
     
    asteraki1976, Mar 5, 2014 IP