summaryrefslogtreecommitdiff
path: root/inc/init.php
Commit message (Collapse)AuthorAge
* fixed fullpath() for certain Windows setupsAndreas Gohr2009-02-05
| | | | | | Ignore-this: 7059284786889a3ead12f5a4b3873bdf darcs-hash:20090205170449-7ad00-63f9459819a355abc7a154e07b487d8431097614.gz
* fixed multiple gzip/sendfile problems in css and js dispatchers FS#1571Andreas Gohr2009-01-22
| | | | | | | | | | - Avoid double compression when gzip_output is enabled - Only compress when gzip_output is enabled - Do not use x-sendfile for compressed content (content-encoding is not supported) - Make sure the script terminates after using x-sendfile - Moved gzip browser support check to init.php darcs-hash:20090122215010-7ad00-765765d353ff78df5b8704086328c5c699bbe7e0.gz
* further updates to config_cascade patchChris Smith2009-01-22
| | | | | | | | | | - add mediameta and license config files into the cascade - update the cache validity code in cache.php, css.php & js.php to use config_cascade - redo inclusion of main config files to avoid suppression of errors in config files - add getConfigFiles($type) function - minor updates elsewhere to use config_cascade rather than hardcoded config file names darcs-hash:20090122114457-f07c6-98ad5627fd5df93edf8dd03289b9cf6d81962afe.gz
* add error suppression to iswin check to avoid notices when ↵Chris Smith2009-01-22
| | | | | | DOKU_UNITTEST_ASSUME_WINDOWS isn't set darcs-hash:20090122081649-f07c6-e7744b1496e1a05ab089812fd7ca3716ecec2290.gz
* include preload.php without error suppression (but after existence check)Chris Smith2009-01-22
| | | | darcs-hash:20090122080426-f07c6-c2e4cb107f9d07f333a9fe295f5df5bd9d3fb15f.gz
* Update for config cascade patch, fixes a couple of issuesChris Smith2009-01-19
| | | | darcs-hash:20090119050218-f07c6-8cb3615ee51fe81ef90b1e54675c359d84a2e57c.gz
* Rework configuration loading to use a predefined file list or cascadeChris Smith2009-01-18
| | | | | | | | | | | | This change add the global $config_cascade which holds the list of files to be read for each configuration setting group. Dokuwiki adds in its configuration file values after preload.php, giving preload.php to set its own configuration cascade. One side effect of the change is "local.protected.php" is part of the default cascade, removing the need for it to be included at the bottom of local.php. darcs-hash:20090118181204-f07c6-fea1c406da1bbdb0a52ab40914f11b835e797728.gz
* Media changelog addedmichael2009-01-18
| | | | | | | | There is a new media changelog now, with the flag RECENTS_MEDIA_CHANGES media changes can be requested from the getRecents()-function or the new getRecentsSince()-function, that returns all changes since a given timestamp and optionally before a given timestamp. The media upload and the XML-RPC-server have been changed to use these functions. Additionally, the event MEDIA_UPLOAD_FINISH has been extended, it has a new $data-attribute (the 5th), that contains a boolean if the file does already exist and will be overwritten. darcs-hash:20090118154345-074e0-5d9a90d269e86d8c6a156ecce5cf63115c827433.gz
* moved no purg on referer code to the correct positionAndreas Gohr2008-12-12
| | | | darcs-hash:20081212225011-7ad00-dbd829b7c617cc519735525522c3155df506cb2b.gz
* don't check for file existance in fullpath() by defaultAndreas Gohr2008-12-13
| | | | | | | | In most (all) calls to fullpath() the existance of the resulting path is not important or is checked externally, so checking inside fullpath() is a waste of CPU cycles. darcs-hash:20081213083355-7ad00-4987a85950a13e5d3c527b3b17b1092e0fa1c567.gz
* ignore purge command when HTTP referer is setAndreas Gohr2008-12-12
| | | | darcs-hash:20081212222614-7ad00-0b69e3b788b8ee3423cbbd9fb32868234ca679ca.gz
* Make license selectable from config FS#312Andreas Gohr2008-10-12
| | | | darcs-hash:20081012113150-7ad00-6408da058bdb6c923159d445e03b76f54b579362.gz
* keep undisplayed messages over redirectsAndreas Gohr2008-09-29
| | | | | | | | | When act_redirect is executed (post data was received and mode show is called) all undisplayed messages (from calls to msg()) are saved in the session now. These messages are then revived in inc/init.php. This makes sure no errors that occured before the redirect are lost. darcs-hash:20080929203831-7ad00-d0869fd3093f57c1ea64ccbaf05d7fd98f68c5e1.gz
* rewrote the fullpath function FS#1462Andreas Gohr2008-09-14
| | | | | | | | | The fullpath function now correctly handles windows drive letter paths and UNC paths making sure that those are not destroyed with upper dir .. notation. Unit tests where added. darcs-hash:20080914134744-7ad00-9abf5931d910a0b12979b1f69b090e8ecd568c71.gz
* more cookie security FS#1490Andreas Gohr2008-09-13
| | | | | | | | | | | | This patch adds the httponly option to the PHP session cookies and DokuWiki's auth cookie when supported by the PHP version. It also adds a new config option 'securecookie' which is enabled by default. It makes sure the browser will not sent a cookie set via HTTPS over a non-secured connection. This option has to be disabled for wikis that only protect the login with SSL but not the whole wiki. darcs-hash:20080912224922-7ad00-d5275147ba9d17a9f6defa8a51ca720da74ba8a0.gz
* avoid warning on file_exists FS#1428Andreas Gohr2008-09-12
| | | | darcs-hash:20080912212311-7ad00-26249ceb7fb08a442888942072ef2dd8279ab3d2.gz
* avoid deprected warnings in php5.3 FS#1464Andreas Gohr2008-08-24
| | | | darcs-hash:20080824085653-7ad00-44925f90b286493b9b55d1ace59136a676786faf.gz
* support for an option inc/preload.php fileAndreas Gohr2008-06-28
| | | | | | | | This patch readds the possibilities previously gained by the DOKUWIKI_INIT event by adding support for including a file named inc/preload.php. When available, it will be included before any defines for dokuwiki are set. darcs-hash:20080627222629-7ad00-a663ded7ac08369f011e1f63e1c60fa81ec05b51.gz
* DOKUWIKI_INIT patch rollbackAndreas Gohr2008-06-27
| | | | darcs-hash:20080627214831-7ad00-d6eee0ddd406c972455871da75d04c5f5fc8a307.gz
* added DOKUWIKI_INIT eventMichael Klier2008-06-22
| | | | | | | | This patch adds a new event DOKUWIKI_INIT to the event system. The event is triggered in inc/init.php right after DOKU_INC has been defined and allows action plugins to interfere with DokuWiki s init process. darcs-hash:20080622144154-23886-5153094bd78c2cea7f97e24c7b41cac6c641f49f.gz
* fix for UNC pathsilya2008-04-12
| | | | | | This patch fixes use of UNC path in $conf['savedir'] and calling of /bin/ scripts. darcs-hash:20080412124628-51399-9f85214fa4d787d5ad3a3b3c1ca655a29efc07e4.gz
* Update GetBaseURL() to avoid multiple consecutive slashes in absolute return ↵Chris Smith2008-04-18
| | | | | | values (incl. test cases) darcs-hash:20080418101946-f07c6-615691fab5d4b5714134634b38567ca8422a0aa0.gz
* try to increase the PCRE backtrack limitAndreas Gohr2008-04-09
| | | | | | | This should avoid problems with larger pages on newer PHP versions. See http://www.freelists.org/archives/dokuwiki/04-2008/msg00049.html darcs-hash:20080409181615-7ad00-de4f7a0602692b28e048d215c2e2b9657f96b81c.gz
* introducing the new tmp dirMichael Klier2008-02-27
| | | | darcs-hash:20080227215640-23886-606fc55ada5d6c3c80f14967746ec6aa0a4b3321.gz
* use strftime() instead of date() FS#1335 :!:Andreas Gohr2008-02-23
| | | | | | | | | | | | | | This patch replaces the use of the date() function with the strftime() function. The latter will respect a set locale and will use localized strings for things like month names. Because the format options for strftime differ from the ones used in date, DokuWiki will rest the value of $conf['dformat'] if it contains an old date format string (detected by missing % characters). Plugins or templates using the $conf['dformat'] need to be updated. darcs-hash:20080223124045-7ad00-6afb2b839afc58781463e25577e06adb675fff79.gz
* Probably fixes cookie loss on https/http switch FS#1174Andreas Gohr2008-01-24
| | | | darcs-hash:20080124211231-7ad00-5d9f8e834be5d7d3abc772ad7c956455258dad59.gz
* fullpath fix for WindowsAndreas Gohr2007-09-30
| | | | darcs-hash:20070930214958-7ad00-bc8ca26f86ea4c9e68ea2b8f3cacc2a598543122.gz
* don't use realpath() anymore (FS#1261 and others)Andreas Gohr2007-09-30
| | | | | | | | | | | The use of realpath() to clean up relative file names caused some trouble in certain setups relying on symlinks or having restricitve file structure setups. This patch replaces all realpath() calls with a PHP only replacement which should solve those problems. darcs-hash:20070930184250-7ad00-512ff04c95f57fc9eaf104f80372237a3c94286f.gz
* fix for magic quote fixing inside array keysAndreas Gohr2007-08-19
| | | | darcs-hash:20070819211952-7ad00-a1a321178ef3c5a85b2e422a01eda8066eb10588.gz
* separated TOC from pageAndreas Gohr2007-08-05
| | | | | | | | | | | | | | | | | | This patch introduces a tpl_toc() function which can be used to freely place the Table of Contents in a template. When used, tpl_content should be called with a parameter of false to supress the automatic TOC placement. Note: if tpl_toc() us run *before* tpl_content(), TOCs will not work in the preview. A work around is to run tpl_content() in a output buffer first. This patch also adds a getTOC() function for admin plugins which allows plugin authors to put create their own TOC which will be placed correctly in the template. A convenience function html_mktocitem() is available. The config manager was adjusted to make ue of this new feature, but some bugs might remain. darcs-hash:20070805132405-7ad00-77d2c3cdf66cc62b2d408cc6580f938636a109af.gz
* never use full URL in cookie paths FS#1146Andreas Gohr2007-06-03
| | | | | | | Introduces a DOKU_REL constant always pointing to the DokuWiki directory regardless of the used canonical setting. darcs-hash:20070603191451-7ad00-a5227a3632b3337f5da90551d3166d9b5db56638.gz
* typo fix in compression method check FS#919Andreas Gohr2007-05-14
| | | | darcs-hash:20070514165529-7ad00-bf2cd39a2e34b03aa8d10dd8ca943b0b27127e79.gz
* disable any possibly configured global zlib compression FS#1132Andreas Gohr2007-05-14
| | | | darcs-hash:20070514164557-7ad00-7a40f60658af5e626698b4a262f5e70168c5c896.gz
* rebuild $_REQUEST manually to avoid cookie interference FS#1104Andreas Gohr2007-05-13
| | | | darcs-hash:20070513181524-7ad00-20cb0328fc1b2881120d825f74ec032a5171f782.gz
* Typo in default nice_die messageGuy Brand2007-04-24
| | | | darcs-hash:20070424211611-19e2d-ae76695e8114a064b5cebc2cad6fd55e7030e096.gz
* set scope for session cookies FS#1109Andreas Gohr2007-03-26
| | | | darcs-hash:20070326180948-7ad00-c35eeabfe0d77e9decfd4fc6d776eaaa72be219c.gz
* make setup error a little more verboseMike Frysinger2006-12-11
| | | | | | | | | | if a subdir is not setup properly, then init_paths() in inc/init.php will use the pretty name ("datadir" instead of "pages"; "olddir" instead of "attic"). attached patch simply includes the actual directory name in the output so people dont have to look it up in the source code. darcs-hash:20061211194244-5224c-2d22eeb08d770108d1d993783e95d11bef0e8855.gz
* metadata update to support both persistent and non-persistent metadatachris2006-11-26
| | | | | | | | | | | | | | | | Key changes: - metadata stored on disk in two arrays, 'current' & 'persistent' - p_set_metadata has an additional parameter, $persistent, which defaults to true - metadata set within the renderer defaults to non-persistent - new event hook, PARSER_METADATA_RENDER, which wraps around metadata rendering process. For full details of this event refer to the event list documentation at splitbrain. The patch includes automatic conversion of metadata in current form to the new format For more details also see http://www.freelists.org/archives/dokuwiki/11-2006/msg00221.html and any follow-up messages. darcs-hash:20061126152144-9b6ab-a4e40c221e0274b13da07dc2fc1d2100f5f3a50e.gz
* Word-Length IndexerTNHarris2006-11-12
| | | | | | | | | | | | | | | | | A modification to the indexer that sorts words based on length. This should make searching a little bit more efficient. After the patch is applied, your old index will be automatically converted to the new format (when you visit a page). The new index format is: 1. Index files are stored in savedir/index 2. Word lists are stored as wlen.idx. This used to be word.idx. 3. Word indexes are stored as ilen.idx. This used to be index.idx. 4. The page list, page.idx, is simply copied to the new location. Any plugins you have, such as the blog plugin, that read the index files need to be updated. darcs-hash:20061112194900-2b9f0-a975498ccf0a1d39c6df73b79bcd028d5e81c389.gz
* use DOKU_URL as key for sessions and auth cookie #896 #581 #884Andreas Gohr2006-10-03
| | | | | | | | | | This patch changes the DOKU_COOKIE define to be based on the DOKU_URL define. DOKU_COOKIE is now used as session key as well, making sessions no longer dependend on the title option. This should fix problems with multiple wikis on the same host (using the same title) and wikis accessed through different URLs. darcs-hash:20061003121546-7ad00-aea4c256b7752815ed422ce74a659152a601d267.gz
* minor bugfix and boring error removalchris2006-09-23
| | | | darcs-hash:20060923203609-9b6ab-ecca679faa254a29772868508050fcf3206b0814.gz
* add authname memory cachechris2006-09-23
| | | | | | | | actions which concern multiple pages (e.g. search, backlinks, recents) end up repeatedly encoding the current user's name and groups. This change caches the results of the encoding allowing them to be reused. darcs-hash:20060923161206-9b6ab-a3ec8f1c2ec284d84b9ff85cba1e56165b2967a7.gz
* suppress boring errorsBen Coburn2006-09-08
| | | | | | | | Suppress any errors from set_time_limit, unlink, and file_exists functions. see: http://www.freelists.org/archives/dokuwiki/09-2006/msg00004.html darcs-hash:20060908193433-05dcb-013617431870ab5bfb2ce8c6e99ba5af13493228.gz
* conflict resolution for memory cache initAndreas Gohr2006-08-30
| | | | darcs-hash:20060830210459-7ad00-8f7a2ae826d5f893d3e48f41c8ae868987ec0dd2.gz
* scalable changelog redesignBen Coburn2006-08-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch provides a rewritten changelog system that is designed to run efficiently on both small and large wikis. The patch includes a plugin to convert changelogs from the current format. The conversion is non-destructive and happens automatically. For more information on the new changelog format see "http://wiki.splitbrain.org/wiki:changelog". Structure In short the changelog is now stored in per-page changelog files, with a recent changes cache. The recent changes cache is kept in "/data/meta/_dokuwiki.changes" and trimmed daily. The per-page changelogs are kept in "/data/meta/<ns>/<page_id>.changes" files. To preserve revision information for revisions stored in the attic, the "*.changes" files are not removed when their page is deleted. This allows the full life-cycle of page creation, deletion, and reversion to be tracked. Format The changelog line format now uses a general "line type" field in place of the special "minor" change syntax. There is also an extra field that can be used to store arbitrary data associated with special line types. The reverted line type (R) is a good example. There the extra field holds the revision date used as the source for reverting the page. See the wiki for the complete syntax description. Code Notes The changelog functions have been rewritten to load the whole file only if it is small. For larger files, the function loads only the relevant chunk(s). Parsed changelog lines are cached in memory to speed future function calls. getRevisionInfo A binary search is used to locate the chunk expected to contain the requested revision. The whole chunk is parsed, and adjacent lines are optimistically cached to speed consecutive calls. getRevisions Reads the changelog file backwards (newest first) in chunks until the requested number of lines have been read. Parsed changelog lines are cached for subsequent calls to getRevisionInfo. Because revisions are read from the changelog they are no longer guaranteed to exist in the attic. (Note: Even with lines of arbitrary length getRevisionInfo and getRevisions never split changelog lines while reading. This is done by sliding the "file pointer" forward to the end of a line after each blind seek.) isMinor Removed. To detect a minor edit check the type as follows: $parsed_logline['type'] darcs-hash:20060830182753-05dcb-1c5ea17f581197a33732a8d11da223d809c03506.gz
* further update to global memory cache arrayschris2006-08-29
| | | | | | | | | | | | | - remove initialisation of caches in inc/pageutils.php - add global declaration to init.php to support init.php being included from within a function, e.g. unit testing ;-) - minor change to utf8_substr, remove non-essential brackets added as part of an earlier patch darcs-hash:20060829134806-9b6ab-ab15191344a83be664c412403dc84a24fa2253a2.gz
* init global memory cache arraysBen Coburn2006-08-28
| | | | | | | | Update to 'add function result caching for cleanID and wikiFN'. Makes certain that arrays exist for the caches, without checking on each function call. Properly create multidimensional arrays in wikiFN(). darcs-hash:20060828071205-05dcb-7c8dbdb5ea4e7b73808ec3bd9222df1b837d3a1f.gz
* typo fix for compression checkAndreas Gohr2006-08-25
| | | | darcs-hash:20060825174755-7ad00-e67f267dd1552ba22b01662de6dbb84faf33e5f8.gz
* compression fallbackAndreas Gohr2006-08-25
| | | | | | | This updates the availability check of the choosen compression method. If bzip2 is configured but not available it falls back to gzip if available. darcs-hash:20060825144739-7ad00-9f7ce54fd1dbf0d7a8272393e9bc02d862b28fff.gz
* unittest fixeschris2006-08-04
| | | | darcs-hash:20060804142243-9b6ab-d208f7f1a67a9958fda05c519c8407ad5e733cea.gz