Last post Oct 03, 2018 07:19 AM by Brando ZWZ
Sep 27, 2018 02:10 PM|ashwin.barfa|LINK
Error: Refused to display 'https://www.google.com/' in a frame because it set 'X-Frame-Options' to 'sameorigin'.
My application runs on a http://localhost:xxxx
How can solve this issue.?
Sep 27, 2018 03:24 PM|mgebhard|LINK
X-Frame-Options is set by Google. There's nothing you can do to change this.
Oct 03, 2018 07:19 AM|Brando ZWZ|LINK
As mgebhard says, we couldn't directly use google search, since it set the 'X-Frame-Options' to 'sameorigin'.
Here is a workaround.
You could solve using Google CSE (Custom Searche Engine), which can be easily inserted into an iframe. You can create your own search engine, that search selected sites or also in entire Google's database.
More details, you could refer to below article.