How to generate ethereum qr code address with amount?

0 votes

I working on coinpayment gateway I want to generate qr code with address and amount. How to pass amount in google chart api with address?

This code is perfect working for bitcoin:

<img width="220" height="220" src="https://blockchain.info/qr?data=ethereum:<?php echo $result['result']['address']; ?>?amount=<?php echo $result['result']['amount']; ?>%26label=example%2520label">

But these both are not getting amount with address

<center><img width="220" height="220" alt="bitcoin" src="http://chart.apis.google.com/chart?cht=qr&chs=500x500&chl=Ethereum:<?php echo $result['result']['address']; ?>&chld=H|0"></center>

<center><img width="220" height="220" alt="bitcoin" src="https://chart.googleapis.com/chart?chs=300x300&cht=qr&chl=ethereum:0x<?php echo $result['result']['address']; ?>&choe=UTF-8"></center>`

Sep 6, 2018 in Blockchain by digger
• 27,620 points
265 views

2 answers to this question.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.
0 votes

I think it's impossible, because even big coin accepting sites like "coinpayments.net" 's qr payment code doesn't include the amount. (But if paid with bitcoin or other currency it does.) Sorry to let you down but the best you could do is

src="https://chart.googleapis.com/chart?chs=300&300&chld=L|2&cht=qr&chl=ethereum:<?php echo $result['result']['address']; ?>"

the link will look somthing like

https://chart.googleapis.com/chart?chs=225x225&chld=L|2&cht=qr&chl=ethereum:0x9610a371F94BE34D4D0CB9c35D621d657133c0e5

no one seems to include their amount...

answered Sep 6, 2018 by slayer
• 29,040 points
0 votes

You implement this package: ethereum-qr-code.

It implements the EIP67 standard which uses a value field for the amount-to-pay and an ethereumfield for the ETH address.

However, actual usage of the QR protocol is currently very fractured and gives different and unexpected results based on which wallet the user uses.

Some problems found with some Ethereum wallets:

  • imTokenBRD walletLykke require a QR field: amount to be ETH

  • Trust wallet requires a QR field: amount to be wei instead of ETH!

  • Toshi wallet crashes on QR code scan (at time of writing 2018-07-24)

  • None of the wallets we tried use the value field.

answered Sep 6, 2018 by Omkar
• 65,850 points

Related Questions In Blockchain

0 votes
1 answer

How to generate new address for blockchain wallet?

You can use the following to generate ...READ MORE

answered Jul 16, 2018 in Blockchain by digger
• 27,620 points
45 views
0 votes
1 answer

How do I get the total amount sent to an address?

If you are using web3JS you can ...READ MORE

answered Jul 18, 2018 in Blockchain by Johnathon
• 9,050 points
20 views
0 votes
1 answer

How to generate Bitcoin address in Ruby?

In your generate_address_from_public_key_hash method, the checksum should be over ...READ MORE

answered Aug 22, 2018 in Blockchain by slayer
• 29,040 points
119 views
0 votes
1 answer

How to generate pem with openssl?

Here’s the working code: int generatePem(char **pem) { ...READ MORE

answered Aug 23, 2018 in Blockchain by digger
• 27,620 points
62 views
0 votes
1 answer

Protocols used in a distributed/dlt system for the nodes to establish communication

yes all are over TCP/IP connections secured by TLS encryption in hashgraph architecture-hashgraph, ...READ MORE

answered Aug 6, 2018 in Blockchain by ariaholic
• 7,320 points
43 views
0 votes
1 answer

Truffle tests not running after truffle init

This was a bug. They've fixed it. ...READ MORE

answered Sep 11, 2018 in Blockchain by Christine
• 15,790 points
65 views
0 votes
1 answer
0 votes
1 answer

Php code to generate Ethereum wallets.

You can use web3.eth.accounts in web3js web3.eth.accounts.create(); With Php, ...READ MORE

answered Jul 27, 2018 in Blockchain by slayer
• 29,040 points
260 views
0 votes
1 answer

How to generate Bitcoin address?

Convert the hex string back to bytes ...READ MORE

answered Aug 20, 2018 in Blockchain by slayer
• 29,040 points
47 views

© 2018 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved.
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of MongoDB, Inc.