aboutsummaryrefslogtreecommitdiff
path: root/IkiWiki/Plugin/attachment.pm
Commit message (Collapse)AuthorAge
* Fix committing attachments when using svn.Joey Hess2013-07-10
|
* prune: do not prune beyond an optional base directory, and add a testSimon McVittie2012-04-07
| | | | | | | | Previously, prune("wiki/srcdir/sandbox/test.mdwn") could delete srcdir or even wiki, if they happened to be empty. This is rarely what you want: there's usually some base directory (destdir, srcdir, transientdir or another subdirectory of wikistatedir) beyond which you do not want to delete.
* avoid unnecessary uses of UNIVERSALJoey Hess2012-03-18
| | | | | | | Foo->Bar->can("method") works just as well, even if Foo::Bar is not loaded. Using UNIVERSAL::can is deprecated. But, I was unable to easily eliminate conditional.pm's use of UNIVERSAL::can
* attachment: Fix utf-8 display bug.Joey Hess2012-01-15
|
* attachment: Bugfix to create directory when moving attachment out of ↵Joey Hess2011-07-11
| | | | holding area.
* attachment: Bugfix to move upload attachments out of holding area when saving.Joey Hess2011-07-11
|
* Bugfix for trying to attach files to a subpage of the index page.Joey Hess2011-07-07
|
* improve detection of ajax requestJoey Hess2011-06-17
| | | | | | | | | | | | | | | | Firefox sent an accept header for application/xml, not application/json, and also weakened the priority to 0.8. So that stuff is not to be trusted; instead I found a better way: When an ajax upload is *not* being made, the Upload Attachment button will be used, so enable ajax if an upload is being made without that button having been used. Also, testing with firefox revealed it refused to process a response that was type application/json, and checking the demo page for the jquery file upload plugin, it actually returns the json with type text/html. Ugh. Followed suite. Now tested with: chromium, chromium (w/o js), firefox, firefox (w/o js), and w3m.
* show ikiwiki error when attachment is rejectedJoey Hess2011-06-16
|
* let thru HTTP_ACCEPTJoey Hess2011-06-15
| | | | | | | | Needed for attachment to return json when requested. I think some browsers send Accept: * , so I made sure to check that json was explicitly listed as to be accepted, as well as having a high priority.
* bugfixesJoey Hess2011-06-15
| | | | Make sure staged attachments sort as earlier, even if they're not really.
* typoJoey Hess2011-06-15
|
* use jquery underlayJoey Hess2011-06-15
|
* load attachment javascript into template the clean wayJoey Hess2011-06-15
|
* WIPJoey Hess2011-06-15
|
* WIPJoey Hess2011-06-15
|
* remove trailing slash from attachment_holding_dirJoey Hess2011-06-14
| | | | | If it's passed a filename, it should return the filename inside the holding dir. If passed a page, the directory sans slash. All code adds the slash.
* more generic interfaceJoey Hess2011-06-14
|
* bugfixesJoey Hess2011-06-14
|
* bugfix for attachments of non-index pagesJoey Hess2011-06-14
|
* fix removal of helf attachmentsJoey Hess2011-06-14
| | | | | | | | | | | | | | Left out confirmation of removal for held attachments because a) they're not in the wiki yet, so confirmation is a bit unnecessary b) it would be hard c) eases later integration of jquery file upload interface Also changed where attachments of index are held (to match where they're stored in the srcdir). Note that the attachment formbuilder hook was made to run last, so that the list of attachments is not generated before removal, in the fast path w/o confirm.
* fixed previewing of attachments from holding areaJoey Hess2011-06-14
|
* fixed saving attachments on page saveJoey Hess2011-06-14
| | | | | Also saved on preview, but previewing is a bit broken, does not see the newly saved attachment yet.
* attachment list includes new attachments in holding areaJoey Hess2011-06-14
| | | | | | | | | | | | | | | Note that it's possible for an attachment in the holding area to be older than an attachemnt in the wiki with the same name. I intentionally show the one in the holding area in this (unlikely) case, since saving the page will overwrite the wiki's file with the held attachment. It does not seem worth the bother of doing something more intelligent, since in this case two people have basically conflicted with one-another.. and both attachment contents will be stored in revision control in case it needs to be sorted out. I had to remove the hyperlink for attachments in the holding area, since they're not yet live on the web. This could be annoying/confusing. Added a moseover notice instead.
* untaint and linkpage the page name used in attachment holding directoryJoey Hess2011-06-14
|
* store filename in holding dir in linkpage formJoey Hess2011-06-14
| | | | | Avoids any unpleasantness with .. or other special chars in the attachment filename.
* store attachments in holding area; commit to wiki on page saveJoey Hess2011-06-14
| | | | | | | | | | | | | | | | | | | | | This makes uploading a lot of attachments somewhat faster, because the user does not need to wait for a long website refresh after each upload. Still probably somewhat slow, since ikiwiki has to run for each upload. More importantly, this opens the door for integration of things like the jquery file upload interface, which allow drag-n-drop and multiple file uploads to be queued and then ran. It uses rcs_commit_staged, which leaves out tla and mercurual which lack that, but since rename, remove, autoindex, etc also use that, I think it's fine for attachments to also depend on it. The attachment list is currently broken; it does not look in the holding area yet, and its links to the attached files won't work since they're not yet in the wiki. previewing is also currently broken. Work sponsored by TOVA.
* refactorJoey Hess2011-06-14
|
* remove second parameter to include_javascriptJoey Hess2011-01-02
| | | | | function used to take a second parameter to control absoluteness, no longer does
* attachment: Fix attachment file size display.Joey Hess2010-09-21
|
* don't run check_canedit in nonfatal modeJoey Hess2010-08-30
|
* rcs_commit and rcs_commit_staged api changesJoey Hess2010-06-23
| | | | | | | | | | | Using named parameters for these is overdue. Passing the session in a parameter instead of passing username and IP separately will later allow storing other session info, like username or part of the email. Note that these functions are not part of the exported API, and the prototype change will catch (most) skew, so I am not changing API versions. Any third-party plugins that call them will need updated though.
* stop using REMOTE_ADDRJoey Hess2010-06-23
| | | | | | | | | | | Everywhere that REMOTE_ADDR was used, a session object is available, so instead use its remote_addr method. In IkiWiki::Receive, stop setting a dummy REMOTE_ADDR. Note that it's possible for a session cookie to be obtained using one IP address, and then used from another IP. In this case, the first IP will now be used. I think that should be ok.
* attachment: Support Windows paths when taking basename of client-supplied ↵Joey Hess2010-06-16
| | | | file name.
* attachment: When inserting links, insert img directives for images, if that ↵Joey Hess2010-06-12
| | | | plugin is enabled.
* attachment: Show files from underlay in attachments list.Joey Hess2010-06-12
| | | | | While those files cannot be removed or renamed, this allows easy downloading of them, and a new version can after all be uploaded.
* unfinished file_prune revampJoey Hess2010-04-17
| | | | | | | | | Many calls to file_prune were incorrectly calling it with 2 parameters. In cases where the filename being checked is relative to the srcdir, that is not needed. Made absolute filenames be pruned. (This won't work for the 2 parameter call style.)
* add section informationJoey Hess2010-02-12
|
* attachment: Fix reversion in attachment sorting by age.Joey Hess2009-12-14
| | | | | Reversion was introduced by over-eager removal of mtime_raw in 2b569f99d9e7f1d4d30c7f3adde9729ff4d868cf
* attachment: Fix several utf-8 problems.Joey Hess2009-12-14
| | | | | Similar to those in the rename plugin, although here we can't use the form object.
* remove deprecated admin prefsJoey Hess2008-12-24
| | | | | | | | | | A new ikiwiki-transition moveprefs subcommand can pull the old data out of the userdb and inject it into the setup file. Note that it leaves the old values behind in the userdb too. I did this because I didn't want to lose data if it fails writing the setup file for some reason, and the old data in the userdb will only use a small amount of space. Running the command multiple times will mostly not change anything.
* finalise version 3.00 of the plugin apiJoey Hess2008-12-23
|
* Coding style change: Remove explcit vim folding markers.Joey Hess2008-12-17
|
* fix relativedate timezone inclusionJoey Hess2008-10-19
| | | | | | The machine parseable date needs to include a timezone. Also, simplified the interface for date display.
* Add an underlay for javascript, and add ikiwiki.js containing some utility code.Joey Hess2008-10-17
| | | | | | | * Add an underlay for javascript, and add ikiwiki.js containing some utility code. * toggle: Stop embedding the full toggle code on each page using it, and move it to toggle.js in the javascript underlay.
* lockedit: Support specifying which users (and IP addresses) a page is locked ↵Joey Hess2008-10-08
| | | | for. This supports most of the ACL type things users have been wanting to be done. Closes: #443346 (It does not control who can read a page, but that's out of scope for ikiwiki.)
* attachment: Support adding attachments to pages even as they are being created.Joey Hess2008-10-02
|
* Export pagetitle, titlepage, linkpage.Joey Hess2008-09-27
|
* pagetype is exportedJoey Hess2008-09-27
|
* attachment: Add admin() pagespec to test if the uploading user is a wiki admin.Joey Hess2008-09-25
|