First of all, your demo-video.php page is just another HTML page. I can only see an HTML file embedded in another HTML file via iframe.
I'm not sure where you have hosted this HTML page but The Same Origin Policy prevents you from interacting with content loaded into an iframe from a different domain.
Two possibilities that you need to check:
- In order to work, you need to add CORS for the S3 bucket where you have stored all your videos.
- If you restrict viewer access settings in CloudFront, then viewers must use CloudFront signed URLs or signed cookies to access your content.
Thanks for the clues. Number two was the correct answer. I clicked the setting without understanding. All better now.
Trying To Embed An S3 CloudFront Distribution Video In A Simple PageAccepted Answerasked 9 months ago
Creating CloudFront Distribution, where do I enter my domain name?Accepted Answerasked 2 months ago
Video Embed in WordPress post showing errorasked 8 months ago
create a gallery of videoasked 9 months ago
Can I record the video of a Chime video conference?Accepted Answerasked 3 years ago
Adding Domain Name to CloudFront DistributionAccepted Answer
Adding OAI to CloudFront after the distribution is created
S3 + Cloudfront Combo not working Properly For Video Streamingasked 3 days ago
Can a CloudFront distribution have a chain of failover origins?asked 3 months ago
Not able to disable and delete a CloudFront distributionasked a month ago