Hi Hassan,
You really should not connect your browser directly to your DB. The security risks are way to high. That is why the server is set up so, that it is very hard to do. (It's not imposible, but it really shouldn't nedone like that!)
What you need is a piece of middleware that sits between your frontend(browser) and your backend(serverr+middleware). There are loads of solutions available for this, and you need to find one where you are comfortable with. Search for REST or GRAPHQL in cmbination with the server you use.
Oh, Pick one of those protocols, and stick wit it. REST is the older more proven technolgy, GRAPHQL is the new way. If you are blank on those, you might want to go with the later, but i suspect the setup of it is a tad harder.
Regards
Sander