davidmoreno / onion

C library to create simple HTTP servers and Web Applications.
http://www.coralbits.com/libonion/
Other
2.01k stars 251 forks source link

Update ofileserver example #266

Closed YggdrasiI closed 3 years ago

YggdrasiI commented 4 years ago

Hello,

in my opinion the example 'ofileserver' is a good starting point for own projects. Unfortunately it contains a few stumbling blocks and I've tried to remove them.

This pull request polishes the html template, adds a German po file, and adds a comment about a 'trap' with setlocale(LC_ALL, ""); and number conversions. Finally, I wraps request handler into an onion_url_handler to show how to use the url filtering and why "^" might be a good regex pattern. (not consuming characters.)

The changes are separated into four commits.

Regards Olaf