]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - pgsrc/MagicPhpWikiURLs
For security add .htaccess files to subdirectories.
[SourceForge/phpwiki.git] / pgsrc / MagicPhpWikiURLs
1 Mime-Version: 1.0 (Produced by PhpWiki 1.1.x)
2 Content-Type: application/x-phpwiki;
3   pagename=MagicPhpWikiURLs;
4   flags=PAGE_LOCKED
5 Content-Transfer-Encoding: binary
6
7 !!! About phpwiki: URLs
8
9 A special type of URL is available for making links to perform
10 administrative and other special functions in PhpWiki.  Here is a
11 brief description of how they work.
12
13 The basic syntax of a phpwiki: URL is
14   __phpwiki:__''pagename''__?__''query-args''
15
16 If ''pagename'' is omitted it defaults to the current page.
17
18 ''Query-args'' should be a set of parameters in standard
19 HTTP GET format.
20
21 The "action=''x''" parameter should almost always be given.  It can be one of
22 __browse__, __info__, __diff__, __search__, __edit__,
23 __zip__, __dumpserial__, __loadserial__,
24 __remove__, __lock__, __unlock__,
25 __login__, __logout__, __setprefs__ or __save__.
26 The default action is __browse__.
27
28 Some of the actions accept other parameters.
29
30 ;__info__: Accepts __showpagesource__.
31 ;__search__: Accepts __searchterm__, and __searchtype__.
32 ;__edit__: Accepts __version__.
33 ;__remove__: Accepts __verify__.
34 ;__save__: Accepts __editversion__, __minor_edit__, and  __content__.
35 ;__setprefs__: Accepts __edit_area_width__, __edit_area_height__.
36
37
38 !! Writing Magic Links in Wiki Pages
39
40 A magic link looks like:
41
42   __[[__ ''text'' __|__ ''phpwiki-url'' __]__
43
44 The "''text'' __|__" is optional but usually recommended. 
45 If given it will provide the label for the link.
46
47 The ''phpwiki-url'' is a __phpwiki:__ URL as described above.
48
49 !Some examples
50
51   [[ Edit the !SandBox | phpwiki:!SandBox?action=edit ] 
52 will generate a link which will take you directly to editing the SandBox, like so:
53 [ Edit the SandBox | phpwiki:SandBox?action=edit ].
54
55 Other possibilites:
56 * [ Diff the SandBox | phpwiki:SandBox?action=diff ],
57 * [ Lock the HomePage | phpwiki:HomePage?action=lock ],
58 * [ Get a Full Zip Dump | phpwiki:?action=zip&include=all ],
59 * [ Page titles containing 'wiki' | phpwiki:?action=search&searchterm=wiki ],
60
61 !! Writing Magic Forms in Wiki Pages
62
63 If one of the ''query-args'' has a value like
64   ''arg''__=__''opt-width''__(__''opt-dflt-val''__)__
65 the link will be rendered as a form, rather than as an anchor.
66
67 ''Opt-width'', if given specifies the size of the input area, while
68 ''opt-dflt-val'' specifies the default value for the input.
69 If ''text'' is given in the link, then a submit-button with that
70 label will be included in the form, otherwise the submit button
71 will be omitted.
72
73 Examples:
74
75   [[ Full Search | phpwiki:?action=search&searchtype=full&searchterm=() ] 
76 gives
77 [ Full Search | phpwiki:?action=search&searchtype=full&searchterm=() ] 
78
79 While
80   [[ phpwiki:?action=search&searchterm=12() ]
81 yields
82 [ phpwiki:?action=search&searchterm=12() ]
83
84 Other examples:
85 [ Browse Page | phpwiki:?action=browse&pagename=() ]
86