Closed alibk1 closed 1 year ago
When you mint an NFT you are triggering a transaction, so this is expected behavior. If you don't want the user to have to sign transactions, you can pay for the gas yourself by setting Openzeppelin Defender settings in the ThirdwebManager, hover over the fields to see tooltips. If that is not what you intend to do, and just want to store an unminted NFT locally, you can create a new NFT() and store it for later use, but either way, for it to show up in the contract, you'll need to mint it.
Sidenote: I recommend using a testnet when testing this stuff, it seems like you're on Ethereum Mainnet.
In my project, we are creating random photos and download them to user's phone to sell them as NFT. The code below allows users to select the downloaded photo and upload it to ipfs server and then gets its url. Also I want to mint the NFT to user's wallet. But when i run the Mint function the page in attached photo is showing. I dont want to send any NFT or Coin to any walllet from logged walllet. I just want to make the user own the selected photo as NFT.
`using System.Collections; using System.Collections.Generic; using System.Threading.Tasks; using Thirdweb; using UnityEngine; using NativeGalleryNamespace; using UnityEngine.UI; using TMPro; using NFTStorage;
public class NFTTransfer : MonoBehaviour { public ThirdwebManager sdk; public NFTStorageClient client; public Contract contract; public TMP_Text text; public TMP_Text text2; public GameObject buttonSelect; public GameObject buttonSend; string url;
} `
What is the problem?