dashed-slug.net › Forums › Full Node Multi Coin Adapter extension support › How to add multiple Coins
- This topic has 7 replies, 2 voices, and was last updated 4 years, 4 months ago by alexg.
-
AuthorPosts
-
July 30, 2020 at 6:54 pm #8994AnonymousInactive
Hello!
I added 1 coin. Now when I add more Coins with plugins, there comes an error that the function already used. So I renamed the function. Now it doesn’t come up in the Wallets as a tab. How can I add more?July 30, 2020 at 7:09 pm #8995AnonymousInactiveAnd I already tried everything you posted nothing works. When I activate the plugin, the row of the 2nd coin doesn’t show up in the Wallets Tab
July 31, 2020 at 4:47 am #8996alexgKeymasterHello,
Please describe what you did exactly, and which coin adapter you are using. Once you do, I will transfer this thread to the correct forum and will provide assistance.
with regards
July 31, 2020 at 8:45 am #8997AnonymousInactiveit was the multi node coin adapter
July 31, 2020 at 8:54 am #8999alexgKeymasterOK.
Suppose you want to add two coins, with symbols ABC and XYZ.
This is how you can use the
wallets_multiadapter_coins
filter to add more than one coin (I have omitted most of the settings for clarity):function wallets_multiadapter_coins_filter( $coins ) { $coins['ABC'] = array( // replace ABC with the coin's ticker symbol in this line // Coin symbol (again) 'symbol' => 'ABC', // Coin name 'name' => 'ABC coin', // MORE SETTINGS GO HERE // URL to an 64x64 icon for the coin. Or leave empty to pull the icon from 'assets/sprites/SYMBOL.png'. 'icon url' => 'http://www.example.com/abc-coin-icon-64x64.png', ); $coins['XYZ'] = array( // replace XYZ with the coin's ticker symbol in this line // Coin symbol (again) 'symbol' => 'XYZ', // Coin name 'name' => 'XYZ coin', // MORE SETTINGS GO HERE // URL to an 64x64 icon for the coin. Or leave empty to pull the icon from 'assets/sprites/SYMBOL.png'. 'icon url' => 'http://www.example.com/xyz-coin-icon-64x64.png', ); return $coins; } add_filter( 'wallets_multiadapter_coins', 'wallets_multiadapter_coins_filter' );
If you really wanted to define multiple functions you could, but there’s no need.
July 31, 2020 at 10:02 am #9000AnonymousInactiveI added that to the Plugin but it still only shows the first Coin
July 31, 2020 at 10:04 am #9001AnonymousInactiveSorry, now it doesn’t show any coins
July 31, 2020 at 12:50 pm #9002alexgKeymasterOK,
Please answer all of the points below:
1. You say you see no coins. Where do you see no coins? At the frontend UIs, or at the admin section (Wallets -> Adapters)?
2. If the coins are listed in the admin section, what is the status of the coins? If there’s any error in the status column, please copy and paste it so I can see.
3. Is your plugin file activated? See the Plugins screen and check your PHP file.
4. What is the exact code you entered in the PHP file? If you show me, I can look at your code to see if there’s any errors.
with regards
P.S. In general, please try to be more specific so I can help you. (see point 3 here). Thank you.
-
AuthorPosts
- You must be logged in to reply to this topic.