Xojo Web HTML viewer cannot access google.com?

Hi there, I would like to get started with Xojo Web but I am having some trouble with the basic functionality. When I am using the HTMLviewer for web there are no user-agent properties like we do have on the Desktop versions of Xojo. When I try to visit another site besides wikipedia I get connection refused. I find it strange that I can visit Wikipedia but not any other site. I don’t have these issues with Xojo Desktop.

How can I view Google properly?

I am also trying to view:
https://www.google.com/search?q=ACT+U/UTP+0.50+meter+CAT6+patchkabel+blauw&sa=X&rlz=1C1ONGR_nlNL983NL983&bi&tbm=shop

Same results. I am running on XojoWeb local host in the IDE debug locally.

When responding to the request, Google sets the X-Frame-Options to sameorigin, which blocks display in iframes. This is a security mechanism to prevent session hijacking and other trickery. You should open Google links in a new tab/window using Session.GoToURL:

Session.GoToURL( "https://google.com/", true )
2 Likes

Hi Anthongy,

Ah okay that is a bummer. From the desktop viewer it works though.

Yes, the DesktopHTMLViewer is more like a traditional browser. iframes in a web page are a much different beast with different security considerations and restrictions. Although there are some scenarios where your DesktopHTMLViewer may also be denied access.

2 Likes