Wiki source code of Attachments

Last modified by Thomas Mortagne on 2023/10/10

Hide last authors
Raluca Moisa 14.2 1 {{box cssClass="floatinginfobox" title="**Contents**"}}
2 {{toc/}}
3 {{/box}}
Silvia Macovei 7.1 4
Vincent Massol 1.33 5 A page can contain attachments which can then later be referenced from within a page. For example this is very useful for attaching images and displaying them in the page's content.
Vincent Massol 1.1 6
Silvia Macovei 11.3 7 = Attaching a file =
Vincent Massol 1.1 8
Silvia Macovei 8.1 9 There are 3 possibilities to attach a file:
Vincent Massol 1.26 10
Silvia Macovei 11.3 11 == Using the top level menu ==
Vincent Massol 1.29 12
Silvia Macovei 32.2 13 You can add an attachment using the "More actions" menu:
Sergiu Dumitriu 26.3 14
Thomas Mortagne 50.1 15 {{image reference="AddAttachmentsFlamingo.png"/}}
Raluca Moisa 14.2 16
Vincent Massol 29.1 17 When clicked, it'll direct you to the Attachments tab located at the bottom of the page:
Vincent Massol 1.29 18
Thomas Mortagne 56.1 19 {{image reference="view-attachments.png"/}}
Vincent Massol 1.26 20
Vincent Massol 29.1 21 == Using the attachment tab at the bottom of the page ==
Vincent Massol 1.26 22
Vincent Massol 29.1 23 View the page on which you wish to attach a file and then click on the "Attachments" tab at the bottom of the page.
Vincent Massol 1.29 24
Sergiu Dumitriu 26.2 25 {{image reference="attachments.png"/}}
Silvia Macovei 8.1 26
Vincent Massol 29.1 27 Note that the file selector that appears allows you to select as many files as you wish to upload. Thus you don't need to add attachments one by one.
28
Oana-Lavinia Florean 66.2 29 Use the arrows in the upper right corner to navigate to uploaded files.
30
Silvia Macovei 11.3 31 == Using the WYSIWYG editor ==
Vincent Massol 1.29 32
Gabriela Anechitoaei 34.1 33 Edit the page on which you wish to attach a file using the WYSIWYG editor. To link a specific text with an attachment click on "Link" in the toolbar. From the arrow change Page to Attachment or click on Upload to add a new file directly.
Vincent Massol 1.29 34
Gabriela Anechitoaei 34.1 35 To add an image directly in the page click on "Image" and select an existing one from the wiki or click on Upload and add a new image from your computer.
36
Gabriela Anechitoaei 40.1 37 {{image reference="AttachmentWysiwygToucan.png"/}}
Vincent Massol 1.29 38
Manuel Leduc 62.1 39 = Moving an attachment =
40
41 {{version since="14.0RC1"}}
42
43 {{image reference="attachment_button.png" width="960px"/}}
44
45 A button is available in the attachments pane, allowing to move or rename an attachment. It is possible to change the name or the location of the attachments. Optionally, a redirection action is proposed, allowing to automatically redirect requests to the old location of an attachment to the new one.
46 {{/version}}
47
48 {{version since="14.2RC1"}}
49
50 {{image reference="move_attachment_refactoring.png" width="960px"/}}
51
52 When moving an attachment, the pages using the moved attachment are automatically refactored to point to the new location of the attachment. Advanced users can deactivate this refactoring in the move attachment form.
Manuel Leduc 63.2 53 {{/version}}
Manuel Leduc 62.1 54
55
Oana-Lavinia Florean 58.2 56 = Deleting an attachment =
57
58 An attachment can be deleted by pressing the delete button that is shown only if the user has the specific rights for this. Also, a confirmation modal is provided for the action to be completed.
59
60 {{image reference="deleteAttachmentModal.png"/}}
61
Silvia Macovei 11.3 62 = Linking to an attached file/image =
Vincent Massol 1.29 63
Thomas Mortagne 71.1 64 If you're using the Wiki editor, you can use the [[Wiki Syntax>>Documentation.UserGuide.Features.XWikiSyntax]] to display an image inline or link to an attachment.
Vincent Massol 1.31 65
Gabriela Anechitoaei 35.1 66 If you're using the WYSIWYG editor, then use the "Link" or "Image" buttons as shown above.
Vincent Massol 1.33 67
Silvia Macovei 11.3 68 = Linking to an external file/image =
Vincent Massol 1.33 69
Vincent Massol 1.35 70 If your file is on a remote server and you wish to link to it from your wiki, simply use the URL of the link as the content of your wiki link. For example, using the wiki editor you'd write:
Vincent Massol 1.34 71
Vincent Massol 9.1 72 * **XWiki Syntax 1.0**: {{code language="none"}}[http://some_remote_server/path/to/file>text to display]{{/code}}
73 * **XWiki Syntax 2.0**: {{code language="none"}}[[text to display>>http://some_remote_server/path/to/file]]{{/code}}
Vincent Massol 1.34 74
75 For displaying an image located on a remote server, use the following HTML code snippet:
76
Vincent Massol 9.1 77 * **XWiki Syntax 1.0**: {{code language="xml"}}<img src="http://some_remote_server/path/to/image"/>{{/code}}
78 * **XWiki Syntax 2.0**: {{code language="none"}}image:http://some_remote_server/path/to/image{{/code}}
79
Thomas Mortagne 71.1 80 See the [[XWiki Syntax Guide>>Documentation.UserGuide.Features.XWikiSyntax]] for more details.
Caleb James DeLisle 17.1 81
Manuel Leduc 60.1 82 = Backlinks indexation =
83
84 {{version since="14.2RC1"}}
85 Page including attachments (or images) from other pages are now listed in their [[backlinks>>Documentation.UserGuide.Features.Navigate.WebHome#HBacklinks]].
86 {{/version}}
87
Caleb James DeLisle 18.1 88 = Size Limit =
Vincent Massol 19.2 89
Manuel Smeria 28.2 90 The maximum size of an attachment is limited by the administrator. By default it is set at about 32 megabytes.
Caleb James DeLisle 18.1 91
Caleb James DeLisle 19.1 92 = Learn More =
Vincent Massol 19.2 93
Thomas Mortagne 71.1 94 For more information about how XWiki attachments work and how to configure/tune the attachment store, you can examine the [[administrator's guide to attachments>>Documentation.AdminGuide.Attachments]].

Get Connected