As API-Keys/Credentials are needed to do this, you should perform the injection from your website's backend. Depending on the programming language your website is written in, there are different libraries you can use to achieve this. However you can also do this completely on your own by just sending the correct payload to the Marketing Cloud API.
An example payload for triggering a journey builder entry event with event data can be found in the marketing cloud documentation: POST /interaction/v1/events
The request could look something like this:
Authorization: Bearer YOUR_ACCESS_TOKEN
Here you can find some of the available SDKs: