I am using yaws 1.71 with one appmod mounted at "/blog". 

Based on the yaws_api.hrl:

      prepath,          %% Path prior to 'dynamic' segment of URI.
                            %%  ie http://some.host/<prepath>/<script-point>/d/e

The yaws arg field 'prepath' is always returning '/' when I thought it should return '/blog'.

Is this the expected behavior or a bug?

If this is the expected behavior, then how does one determine the path where the appmod was mounted?

Thanks,

Robin


start_yaws(Port)->
      code:add_patha("/opt/local/lib/yaws/ebin"),
     
     yaws:start_embedded("./apps/blog/www",
       [{servername, "localhost"},
        {port, Port},
         {appmods,[{"/blog",boot}]},
         {opaque,[{"appname",blog}]},
         {allowed_scripts,[]}],
       [{logdir,"./log"}]).

out(A) ->
  io:format("arg:~s~n",[?format_record(A, arg)).


============
arg:record arg
     clisock = #Port< 0.342>
     client_ip_port = {{127,0,0,1},52866}
     headers = {headers,"keep-alive",
                        "text/xml,application/xml,application/xhtml+xml,text/html;q=0.9,text/plain;q=0.8,image/png,*/*;q= 0.5",
                        "localhost:3000",
                        undefined,
                        undefined,
                        undefined,
                        undefined,
                        undefined,
                        undefined,
                        undefined,
                        "Mozilla/5.0 (Macintosh; U; Intel Mac OS X; en-US; rv: 1.8.1.7) Gecko/20070914 Firefox/2.0.0.7",
                        undefined,
                        [],
                        "300",
                        undefined,
                        undefined,
                        undefined,
                        undefined,
                        undefined,
                        undefined,
                        [{http_header,9,
                                      'Accept-Charset',
                                      undefined,
                                      "ISO-8859-1,utf-8;q=0.7,*;q=0.7"},
                         {http_header,10,
                                      'Accept-Encoding',
                                      undefined,
                                      "gzip,deflate"},
                         {http_header,11,
                                      'Accept-Language',
                                      undefined,
                                      "en-us,en;q=0.5"}]}
     req = {http_request,'GET',{abs_path,"/blog/posts"},{1,1}}
     clidata = undefined
     server_path = "/blog/posts"
     querydata = undefined
     appmoddata = posts
     docroot = "./apps/blog/www"
     docroot_mount = "/"
     fullpath = "./apps/blog/www/blog/posts"
     cont = undefined
     state = undefined
     pid = <0.205.0>
     opaque = [{"appname",blog}]
     appmod_prepath = "/"
     prepath = "/"
     pathinfo = "/posts"