[pmwiki-users] Potential PageHeader problem with Fixflow?
Patrick R. Michaud
pmichaud at pobox.com
Tue Feb 14 19:45:48 CST 2006
On Tue, Feb 14, 2006 at 11:24:08PM +0000, Hans wrote:
> Tuesday, February 14, 2006, 11:06:23 PM, Matt wrote:
> >> I notice that mattkemplelogo.gifi is here:
> >> http://www.mattkemple.com/pmwiki/uploads/Site/mattkemplelogo.gif
> >> and not here, as the link from the uploads page suggest:
> >> http://www.mattkemple.com/pmwiki/pub/uploads/Site/mattkemplelogo.gif
> > I would expect this if I had uploaded the files to the server
> > directly, but why did this happen if I used Attach:file.ext to
> > upload the file?
> You did not have $UploadUrlfmt defined (???), and since pmwiki 2.1.beta23
> $UploadUrlFmt is based on $PubDirUrl, so i guess pmwiki assumed
> uploads/ to be in pmwiki/pub/ for the Attach: markup, but allowed file
> uploads to go to pmwiki/uploads/Group ???
> It certainly seems odd.
Repeat after me: "Uploading a file and retrieving a file are
totally separate operations." :-)
Uploading a file places a file into a directory on the file system,
which is entirely controlled by $UploadDir. It's totally filesystem
based, and has absolutely nothing to do with urls.
The Attach: markup simply takes the filename reference that follows
"Attach:" and turns it into a url that (hopefully) corresponds to
the same location where the uploaded files have been placed. It
has no way of absolutely knowing what the corresponding url is,
because urls aren't filesystem paths. So, the "Attach:" markup
uses $UploadUrlFmt to decide what url to generate, but it
doesn't have any way of knowing if the value of $UploadUrlFmt
Starting with beta23, $UploadUrlFmt assumes that the uploads/ url
is in the same url location as the pub/ url, given by $PubDirUrl.
Previously PmWiki assumed that both of these were in the same place
as pmwiki.php, but with the improvements to the CleanUrls recipe
it makes more sense -- i.e., is more likely to make a correct guess --
if it uses the pub/ url as the basis instead of the script file.
More information about the pmwiki-users