Strictly necessary cookies are on by default and cannot be turned off. Functional, Performance and Tracking/targeting/sharing cookies can be turned on below based on your preferences (this banner will remain available for you to accept cookies). You may change your cookie settings by deleting cookies from your browser. Then this banner will appear again. You can learn more details about cookies HERE.
Strictly necessary (always on)
Functional, Performance and Tracking/targeting/sharing (default off)
Creating a server application with all dynamic pages.Using the WICED macro START_OF_HTTP_PAGE_DATABASE to define all the possible web pages and page callbacks. In our app can treat the pages generically so only a single callback needed for all our pages - relying on the fact that WICED will provide the specific filename and/or data to the callback function.
Since we will have many pages (more than shown below) I would prefer to use wildcard syntax in the web page data base, see below. There appears to be a WICED problem related to this.
If a POST request, we parse the data (part of the parameter http_data in the callback) for some keywords specific to our application. Then we read the file passed as parameter url_path from our embedded file system and serve that via the WICED api wiced_http_response_stream_write. The problem is sometimes a POST request is divided over 2 packets. In the first packet the file name is correct, but no data is attached, http_data->message_data_length = 0. The subsequent packet will have the data but now the filename is incorrect, it is as specified in the web page data base, "*.html". If I do not use wildcard characters in the data base and populate it explicitly with all the possible files everything works as expected. Moving forward we may have hundreds of possible pages so the use of wildcard in the web page data base is needed.
3. Sure,can come up with a scheme that does what you suggest, logic to cache the name. If there is an underlying WICED bug would be preferable to get that fixed, or at least acknowledged along with any caveats. By the way this is WICED studio 6.2.
Thanks. I can not share source code or project as is as it is proprietary. Not sure if I can create some stripped down version. In the mean time I am testing your suggestion of caching the file name to see if that is a reliable work around.