diff options
author | Jon Bergli Heier <snakebite@jvnv.net> | 2011-01-02 16:50:41 +0100 |
---|---|---|
committer | Jon Bergli Heier <snakebite@jvnv.net> | 2011-01-02 16:50:41 +0100 |
commit | f78248234b3f284b77a35b3249ccfb526d18c871 (patch) | |
tree | edb7342121257e3d93ff0605f69c63fbdd6412a7 | |
parent | 4a0d339854536f65b9418c79b617bb718062905f (diff) |
Prefix paths with /files in MusicDirectory::render().
-rw-r--r-- | music.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -98,11 +98,11 @@ void MusicDirectory::render(HTTP::Connection::p req, HTTPResponse& res) { for(PathListings::iterator it = directories.begin(); it != directories.end(); it++) { std::string rel_path = it->string().substr(music::root_directory.string().size()); - res.write(boost::str(boost::format("<a href=\"%s\">%s</a><br />") % rel_path % rel_path)); + res.write(boost::str(boost::format("<a href=\"/files%s\">%s</a><br />") % rel_path % rel_path)); } for(PathListings::iterator it = tracks.begin(); it != tracks.end(); it++) { std::string rel_path = it->string().substr(music::root_directory.string().size()); - res.write(boost::str(boost::format("<a href=\"%s\">%s</a><br />") % rel_path % rel_path)); + res.write(boost::str(boost::format("<a href=\"/files%s\">%s</a><br />") % rel_path % rel_path)); } } |