1

phantom app

Hello everyone. When I press the send transaction button while on the Phantom devnet network, I can send it to Solana. I get this error when I switch to mainnet and try to send transaction. Is it because I'm in localhost? In the application, I did not write the code for the select any network part. How can I switch to the mainnet?

2 Answers 2

1

without the code its a bit hard to tell, but if you use wallet adapter it maybe smth like this:

    <ConnectionProvider endpoint={endpoint}>

Where the endpoint is the cluster url.

Could also be that you create a connection manually somewhere, then you would need to search for connection:

export const connection = new Connection(clusterApiUrl("devnet"), {
  commitment: "confirmed",
})

Hope this gives you a hint what to search for in your project. Here is an example game in case you need a reference: https://github.com/solana-developers/solana-game-starter-kits/tree/main/tiny-adventure

0

In phantom wallet find settings then find developer setting, and you can change network in phantom wallet. The network in phantom wallet and The network in should be the same

1
  • yes i know that but i want to transfer on mainnet. I can't figure out what I need to change to mainnet in my application.
    – Treanater
    May 29, 2023 at 9:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.