Re: Euphoria MVC updates
- Posted by jmduro Nov 06, 2021
- 3301 views
With example4.ex and the development server, I finally understood what was going wrong: in example3.ex and example4.ex, there is a condition of beeing in examples/ sub-directory. I removed the condition to get example4.ex working:
set_template_path( "../templates" )
instead of:
if search:ends( "examples", current_dir() ) then -- make sure we can find our templates -- if we're in the 'examples' directory set_template_path( "../templates" ) end if
Now after reading once more Apache configuration on euphoria-mvc github page, I understand what I didn't before: to call euphoria-mvc code while adressing a different route, I need redirection in lighttpd configuration as mentionned under "# Send all non-existant paths to index.esp".
I thought it would be possible to call different cgi-scripts within same project folder but I understand it is not possible il I snd all non-existant paths to example3.ex. I expected a call to be http://127.0.0.1/example3.ex/index.html or better http://127.0.0.1/index.ex.
Jean-Marc