I've got a tinyows on localhost that works fine (both through browser GetFeature and QGIS). But my OpenLayers code fails. I've checked here:
Display a WFS layer with OpenLayers and here : How to add a simple WFS layer from GeoServer to OpenLayers map?
and other similar questions to no avail. Can anyone help?

Here is the code:

    wfs = new OpenLayers.Layer.Vector("Editable Features", {
    strategies : [new OpenLayers.Strategy.Fixed(), saveStrategy],
    projection: new OpenLayers.Projection("EPSG:4326"),
    protocol: new OpenLayers.Protocol.WFS({
        version: "1.1.0",
        srsName: "EPSG:4326",
        url: "http://localhost/cgi-bin/tinyows",
        featurePrefix: "tows",
        featureNS :  "http://www.tinyows.org/",
        featureType: "trad",
        geometryName: "wkb_geometry",
        schema: "http://127.0.0.1/cgi-bin/tinyows?service=WFS&amp;version=1.1.0&amp;request=DescribeFeatureType&amp;Typename=tows:trad"
    })
}); 

map.addLayers([gphy, wfs]);


Here is the xml according to Firebug:

&lt;wfs:GetFeature xmlns:wfs="http://www.opengis.net/wfs" service="WFS" version="1.1.0" xsi:schemaLocation="http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.1.0/wfs.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"&gt;





Here is the post response according to firebug:

&lt;?xml version='1.0' encoding='UTF-8'?&gt;
&lt;ows:ExceptionReport
  xmlns='http://www.opengis.net/ows'
  xmlns:ows='http://www.opengis.net/ows'
  xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
  xsi:schemaLocation='http://www.opengis.net/ows http://schemas.opengis.net/ows/1.0.0/owsExceptionReport.xsd'
  version='1.1.0' language='en'&gt;
&lt;ows:Exception exceptionCode='InvalidParameterValue' locator='request'&gt;
&lt;ows:ExceptionText&gt;XML request isn't valid&lt;/ows:ExceptionText&gt;
&lt;/ows:Exception&gt;
&lt;/ows:ExceptionReport&gt;


Here is the tinyows config file:

&lt;tinyows online_resource="http://127.0.0.1/cgi-bin/tinyows"
     schema_dir="/usr/local/tinyows/schema/"&gt;
&lt;pg host="127.0.0.1" user="postgres" password="****" dbname="****" port="5432"/&gt;
&lt;metadata name="TinyOWS Server"
       title="TinyOWS Server - Demo Service" /&gt;
&lt;layer retrievable="1"
    writable="1"
    ns_prefix="tows"
    ns_uri="http://www.tinyows.org/"
    name="trad"
    title="Träd" /&gt;
&lt;/tinyows&gt;


Can anyone help?

Thanks in advance


Question: Embedding Applet in JSP
Answer: Can the code attributte be a .jar ? Everything in the right directory?

Try something like this:

&lt;applet code="HelloApplet.class" name="HelloApplet" archive="HelloApplet.jar"
    width=300 height=300&gt;
    &lt;param name="bgcolor" value="ffffff"&gt;
    &lt;param name="fontcolor" value="000000"&gt;
    Your browser is not Java enabled.
&lt;/applet&gt;


For more help, use this link