Client.print working in firefox but not in Chrome

Hello,

I have a very peculiar issue. The following code works very well on firefox, but not in chrome when I send it from the arduino webserver :

client.println("<p><a href=\"/" + outputstringbuff + "/on\"><button class=\"button\">ON</button></a></p>");

outputstringbuff is a variable.

In chrome nothing is visible, FF has no issues.

When I nevertheless use this code :

client.print("<p><a href=\"/" + outputstringbuff + "/\"></a>");
client.println("<button class=\"button\">ON</button></p>");

it shows in both browsers.

Any thoughts about this ?

Sure. Use the code that works on both browsers.

This is the wrong place to ask about differences in the rendering engines of various browsers. Just find what works.

I think there is a way to query the browser to see which engine is in use then you can code the html differently. Blink, Trident, Gecko, and WebKit are the most used engines, but that is so far above my pay grade that all I can offer is use the code that works on both browsers.

Just a tip, you can use a single quote ' in your html instead of the double quote " and you won't have to worry about escaping the double quotes in the arduino code.