Skip to content

Commit

Permalink
v1 launch
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesmills committed Aug 2, 2024
1 parent 9426374 commit 57c0295
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 10 deletions.
31 changes: 23 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,24 @@
# Really Great Ads

## Integration
# Really Great Ads Integration Guide
Welcome to the Really Great Ads integration guide. This documentation will help you seamlessly integrate Really Great Ads into your website.

## Getting Started
To display ads on your website, follow these steps:

Add the Ad Container: Include the following HTML where you want the ads to appear on your page.

```html
<!-- Include this where you want the ads to appear-->
<div id="adverts-container"></div>
```

You can customize the container ID by changing `adverts-container` to any other ID of your choice. Make sure to use the same ID in the JavaScript code.

<link rel="stylesheet" type="text/css" href="https://cdn.reallygreatads.com/hostedStyles.css">
Include the Script: Add the following script to your page to initialize the ads.

```html
<script>
(function() {
const uniqueId = '274e687a-d809-43e3-b33e-acc2d78d03e1'; // Set your placement ID here
const containerId = 'adverts-container';
const uniqueId = '274e687a-d809-43e3-b33e-acc2d78d03e1'; // Replace with your own placement ID
const containerId = 'adverts-container'; // Replace if you used a different ID in the HTML
const script = document.createElement('script');
script.src = 'https://cdn.reallygreatads.com/script.min.js';
Expand All @@ -24,4 +29,14 @@
document.head.appendChild(script);
})();
</script>
```
```

## Important Notes

- **Custom Container ID**: If you want to use a different container ID, ensure that you update the containerId variable in the script to match the ID used in the HTML.

- **Placement ID**: Replace the uniqueId with your own placement ID provided by Really Great Ads. This ID is essential for loading the correct advertisements.

By following these instructions, you will successfully integrate Really Great Ads into your website, ensuring a seamless display of ads for your users.

If you encounter any issues or have further questions, please contact our support team.
3 changes: 1 addition & 2 deletions script.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
(function() {
// Function to fetch adverts data from the internal API
function fetchAdverts(uniqueId, currentUrl) {
const apiEndpoint = 'https://reallygreatads.test/api/placement'; // Update with your API endpoint
const apiEndpoint = 'https://api.reallygreatads.com/v1/placement';
const payload = {
uniqueId: uniqueId,
url: currentUrl
Expand Down

0 comments on commit 57c0295

Please sign in to comment.