From dd6ca650ce6daff9b0dcea1074aa02ae61c58e56 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 8 Jul 2011 21:52:07 +0000 Subject: [PATCH 01/49] Fix: Parent class must be declared. --- htdocs/product/canvas/default/product.default.class.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/htdocs/product/canvas/default/product.default.class.php b/htdocs/product/canvas/default/product.default.class.php index 41e9b68fc61..9153bb34cb8 100644 --- a/htdocs/product/canvas/default/product.default.class.php +++ b/htdocs/product/canvas/default/product.default.class.php @@ -20,8 +20,9 @@ * \file htdocs/product/canvas/default/product.default.class.php * \ingroup produit * \brief Fichier de la classe des produits par defaut - * \version $Id$ + * \version $Id: product.default.class.php,v 1.40 2011/07/08 21:52:07 eldy Exp $ */ +include_once(DOL_DOCUMENT_ROOT.'/product/class/product.class.php'); /** * \class ProductDefault From 1b3e831734670b7d03f47c10fcf68209f08f5adf Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 8 Jul 2011 23:35:05 +0000 Subject: [PATCH 02/49] Test with phpunit --- test/README | 23 +++++++++++++++++++---- test/phpunit/phpunittest.xml | 14 ++++++++++++++ 2 files changed, 33 insertions(+), 4 deletions(-) diff --git a/test/README b/test/README index 75f248986b8..4b573b22b3e 100644 --- a/test/README +++ b/test/README @@ -30,16 +30,31 @@ Note that xdebug must be installed for this feature to work. * Generate a report of Unit tests code coverage among all Dolibarr classes: Increase your PHP memory (memory_limit in php.ini) to 512MB. -Check that you use the "mysqli" driver in your conf.php file (otherwise -edit the file phpunittest.xml). +Check that you use the "mysqli" driver in your conf.php file (otherwise edit the file phpunittest.xml). +Remove all files into dolibarr root found with "find . | grep CVS\/Base\/ | grep \.php" > cd test -> phpunit -d memory_limit=-1 --configuration ./phpunit/phpunittest.xml --coverage-html ./report --coverage-clover ./report/logs/phpunit.coverage.xml --log-junit ./report/logs/phpunit.xml phpunit/AllTests.php +> phpunit -d memory_limit=-1 -d max_execution_time=0 --configuration ./phpunit/phpunittest.xml --coverage-html ./report --coverage-clover ./report/logs/phpunit.coverage.xml --log-junit ./report/logs/phpunit.xml phpunit/AllTests.php + +If there is a fu... timeout before end, try this: +> cd test +> php -d max_input_time=0 -d max_execution_time=0 /usr/bin/phpunit -d memory_limit=-1 -d max_input_time=0 -d max_execution_time=0 --configuration ./phpunit/phpunittest.xml --coverage-html ./report phpunit/AllTests.php +puis renice -11 du process php + + + +PHP-CODESNIFFER +--------------- +* Install phpcs + +* Launch PHP-Codesniffer: +> cd test +> phpcs --debug -d memory_limit=-1 --configuration=./phpunit/phpunittest.xml --phpunit-xml=./report/logs/pdepend.xml --summary-xml=./report/logs/summary.xml --jdepend-chart=./report/logs/jdepend.svg --overview-pyramid=./report/logs/pyramid.svg --ignore=custom,custom2,adodbtime,artichow,ckeditor,efc_xfss,fckeditor,fpdf,geoip,magpierss,nusoap,odtphp,phpexcel,php_writeexcel,smarty,smtps,tcpdf,vcard ../htdocs PHPDEPEND --------- -* Install PDepend +* Install pdepend * Launch PDepend analysis: > cd test diff --git a/test/phpunit/phpunittest.xml b/test/phpunit/phpunittest.xml index eee177bc1ad..d9d90bcd8a5 100644 --- a/test/phpunit/phpunittest.xml +++ b/test/phpunit/phpunittest.xml @@ -4,9 +4,16 @@ ../CVS/ + ../../build/ + ../../dev/ + ../../doc/ + ../../htdocs/CVS/ ../../test/ ../../htdocs/custom/ ../../htdocs/custom2/ + ../../htdocs/products/canvas/ + ../../htdocs/contact/canvas/ + ../../htdocs/societe/canvas/ ../../htdocs/includes/adodbtime/ ../../htdocs/includes/artichow/ ../../htdocs/includes/barcode/php-barcode/ @@ -43,9 +50,16 @@ ../../htdocs/includes/modules/fichinter/modules_fichinter.php ../CVS/ + ../../build/ + ../../dev/ + ../../doc/ + ../../htdocs/CVS/ ../../test/ ../../htdocs/custom/ ../../htdocs/custom2/ + ../../htdocs/products/canvas/ + ../../htdocs/contact/canvas/ + ../../htdocs/societe/canvas/ ../../htdocs/includes/adodbtime/ ../../htdocs/includes/artichow/ ../../htdocs/includes/barcode/php-barcode/ From 4c819bff32a26fd8b0637e9dba4d4a9b664e641a Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 00:11:55 +0000 Subject: [PATCH 03/49] Test with phpcs --- test/README | 6 +- test/codesniffer/php.ini | 1858 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 1861 insertions(+), 3 deletions(-) create mode 100755 test/codesniffer/php.ini diff --git a/test/README b/test/README index 4b573b22b3e..79a4cba739b 100644 --- a/test/README +++ b/test/README @@ -35,10 +35,10 @@ Remove all files into dolibarr root found with "find . | grep CVS\/Base\/ | grep > cd test > phpunit -d memory_limit=-1 -d max_execution_time=0 --configuration ./phpunit/phpunittest.xml --coverage-html ./report --coverage-clover ./report/logs/phpunit.coverage.xml --log-junit ./report/logs/phpunit.xml phpunit/AllTests.php -If there is a fu... timeout before end, try this: +If there is a timeout before end, try this: > cd test > php -d max_input_time=0 -d max_execution_time=0 /usr/bin/phpunit -d memory_limit=-1 -d max_input_time=0 -d max_execution_time=0 --configuration ./phpunit/phpunittest.xml --coverage-html ./report phpunit/AllTests.php -puis renice -11 du process php +puis renice -10 du process php @@ -48,7 +48,7 @@ PHP-CODESNIFFER * Launch PHP-Codesniffer: > cd test -> phpcs --debug -d memory_limit=-1 --configuration=./phpunit/phpunittest.xml --phpunit-xml=./report/logs/pdepend.xml --summary-xml=./report/logs/summary.xml --jdepend-chart=./report/logs/jdepend.svg --overview-pyramid=./report/logs/pyramid.svg --ignore=custom,custom2,adodbtime,artichow,ckeditor,efc_xfss,fckeditor,fpdf,geoip,magpierss,nusoap,odtphp,phpexcel,php_writeexcel,smarty,smtps,tcpdf,vcard ../htdocs +> /usr/bin/php5 -c ./codesniffer/php.ini /usr/bin/phpcs --report=xml --standard=./codesniffer ../htdocs/test.php diff --git a/test/codesniffer/php.ini b/test/codesniffer/php.ini new file mode 100755 index 00000000000..6f374340edd --- /dev/null +++ b/test/codesniffer/php.ini @@ -0,0 +1,1858 @@ +[PHP] + +; ************************ +: Need a special php.ini to allow usage of +; ************************ + +;;;;;;;;;;;;;;;;;;; +; About php.ini ; +;;;;;;;;;;;;;;;;;;; +; PHP's initialization file, generally called php.ini, is responsible for +; configuring many of the aspects of PHP's behavior. + +; PHP attempts to find and load this configuration from a number of locations. +; The following is a summary of its search order: +; 1. SAPI module specific location. +; 2. The PHPRC environment variable. (As of PHP 5.2.0) +; 3. A number of predefined registry keys on Windows (As of PHP 5.2.0) +; 4. Current working directory (except CLI) +; 5. The web server's directory (for SAPI modules), or directory of PHP +; (otherwise in Windows) +; 6. The directory from the --with-config-file-path compile time option, or the +; Windows directory (C:\windows or C:\winnt) +; See the PHP docs for more specific information. +; http://php.net/configuration.file + +; The syntax of the file is extremely simple. Whitespace and Lines +; beginning with a semicolon are silently ignored (as you probably guessed). +; Section headers (e.g. [Foo]) are also silently ignored, even though +; they might mean something in the future. + +; Directives following the section heading [PATH=/www/mysite] only +; apply to PHP files in the /www/mysite directory. Directives +; following the section heading [HOST=www.example.com] only apply to +; PHP files served from www.example.com. Directives set in these +; special sections cannot be overridden by user-defined INI files or +; at runtime. Currently, [PATH=] and [HOST=] sections only work under +; CGI/FastCGI. +; http://php.net/ini.sections + +; Directives are specified using the following syntax: +; directive = value +; Directive names are *case sensitive* - foo=bar is different from FOO=bar. +; Directives are variables used to configure PHP or PHP extensions. +; There is no name validation. If PHP can't find an expected +; directive because it is not set or is mistyped, a default value will be used. + +; The value can be a string, a number, a PHP constant (e.g. E_ALL or M_PI), one +; of the INI constants (On, Off, True, False, Yes, No and None) or an expression +; (e.g. E_ALL & ~E_NOTICE), a quoted string ("bar"), or a reference to a +; previously set variable or directive (e.g. ${foo}) + +; Expressions in the INI file are limited to bitwise operators and parentheses: +; | bitwise OR +; ^ bitwise XOR +; & bitwise AND +; ~ bitwise NOT +; ! boolean NOT + +; Boolean flags can be turned on using the values 1, On, True or Yes. +; They can be turned off using the values 0, Off, False or No. + +; An empty string can be denoted by simply not writing anything after the equal +; sign, or by using the None keyword: + +; foo = ; sets foo to an empty string +; foo = None ; sets foo to an empty string +; foo = "None" ; sets foo to the string 'None' + +; If you use constants in your value, and these constants belong to a +; dynamically loaded extension (either a PHP extension or a Zend extension), +; you may only use these constants *after* the line that loads the extension. + +;;;;;;;;;;;;;;;;;;; +; About this file ; +;;;;;;;;;;;;;;;;;;; +; PHP comes packaged with two INI files. One that is recommended to be used +; in production environments and one that is recommended to be used in +; development environments. + +; php.ini-production contains settings which hold security, performance and +; best practices at its core. But please be aware, these settings may break +; compatibility with older or less security conscience applications. We +; recommending using the production ini in production and testing environments. + +; php.ini-development is very similar to its production variant, except it's +; much more verbose when it comes to errors. We recommending using the +; development version only in development environments as errors shown to +; application users can inadvertently leak otherwise secure information. + +;;;;;;;;;;;;;;;;;;; +; Quick Reference ; +;;;;;;;;;;;;;;;;;;; +; The following are all the settings which are different in either the production +; or development versions of the INIs with respect to PHP's default behavior. +; Please see the actual settings later in the document for more details as to why +; we recommend these changes in PHP's behavior. + +; allow_call_time_pass_reference +; Default Value: On +; Development Value: Off +; Production Value: Off + +; display_errors +; Default Value: On +; Development Value: On +; Production Value: Off + +; display_startup_errors +; Default Value: Off +; Development Value: On +; Production Value: Off + +; error_reporting +; Default Value: E_ALL & ~E_NOTICE +; Development Value: E_ALL | E_STRICT +; Production Value: E_ALL & ~E_DEPRECATED + +; html_errors +; Default Value: On +; Development Value: On +; Production value: Off + +; log_errors +; Default Value: Off +; Development Value: On +; Production Value: On + +; magic_quotes_gpc +; Default Value: On +; Development Value: Off +; Production Value: Off + +; max_input_time +; Default Value: -1 (Unlimited) +; Development Value: 60 (60 seconds) +; Production Value: 60 (60 seconds) + +; output_buffering +; Default Value: Off +; Development Value: 4096 +; Production Value: 4096 + +; register_argc_argv +; Default Value: On +; Development Value: Off +; Production Value: Off + +; register_long_arrays +; Default Value: On +; Development Value: Off +; Production Value: Off + +; request_order +; Default Value: None +; Development Value: "GP" +; Production Value: "GP" + +; session.bug_compat_42 +; Default Value: On +; Development Value: On +; Production Value: Off + +; session.bug_compat_warn +; Default Value: On +; Development Value: On +; Production Value: Off + +; session.gc_divisor +; Default Value: 100 +; Development Value: 1000 +; Production Value: 1000 + +; session.hash_bits_per_character +; Default Value: 4 +; Development Value: 5 +; Production Value: 5 + +; short_open_tag +; Default Value: On +; Development Value: Off +; Production Value: Off + +; track_errors +; Default Value: Off +; Development Value: On +; Production Value: Off + +; url_rewriter.tags +; Default Value: "a=href,area=href,frame=src,form=,fieldset=" +; Development Value: "a=href,area=href,frame=src,input=src,form=fakeentry" +; Production Value: "a=href,area=href,frame=src,input=src,form=fakeentry" + +; variables_order +; Default Value: "EGPCS" +; Development Value: "GPCS" +; Production Value: "GPCS" + +;;;;;;;;;;;;;;;;;;;; +; php.ini Options ; +;;;;;;;;;;;;;;;;;;;; +; Name for user-defined php.ini (.htaccess) files. Default is ".user.ini" +;user_ini.filename = ".user.ini" + +; To disable this feature set this option to empty value +;user_ini.filename = + +; TTL for user-defined php.ini files (time-to-live) in seconds. Default is 300 seconds (5 minutes) +;user_ini.cache_ttl = 300 + +;;;;;;;;;;;;;;;;;;;; +; Language Options ; +;;;;;;;;;;;;;;;;;;;; + +; Enable the PHP scripting language engine under Apache. +; http://php.net/engine +engine = On + +; This directive determines whether or not PHP will recognize code between +; tags as PHP source which should be processed as such. It's been +; recommended for several years that you not use the short tag "short cut" and +; instead to use the full tag combination. With the wide spread use +; of XML and use of these tags by other languages, the server can become easily +; confused and end up parsing the wrong code in the wrong context. But because +; this short cut has been a feature for such a long time, it's currently still +; supported for backwards compatibility, but we recommend you don't use them. +; Default Value: On +; Development Value: Off +; Production Value: Off +; http://php.net/short-open-tag +short_open_tag = On + +; Allow ASP-style <% %> tags. +; http://php.net/asp-tags +asp_tags = Off + +; The number of significant digits displayed in floating point numbers. +; http://php.net/precision +precision = 14 + +; Enforce year 2000 compliance (will cause problems with non-compliant browsers) +; http://php.net/y2k-compliance +y2k_compliance = On + +; Output buffering is a mechanism for controlling how much output data +; (excluding headers and cookies) PHP should keep internally before pushing that +; data to the client. If your application's output exceeds this setting, PHP +; will send that data in chunks of roughly the size you specify. +; Turning on this setting and managing its maximum buffer size can yield some +; interesting side-effects depending on your application and web server. +; You may be able to send headers and cookies after you've already sent output +; through print or echo. You also may see performance benefits if your server is +; emitting less packets due to buffered output versus PHP streaming the output +; as it gets it. On production servers, 4096 bytes is a good setting for performance +; reasons. +; Note: Output buffering can also be controlled via Output Buffering Control +; functions. +; Possible Values: +; On = Enabled and buffer is unlimited. (Use with caution) +; Off = Disabled +; Integer = Enables the buffer and sets its maximum size in bytes. +; Note: This directive is hardcoded to Off for the CLI SAPI +; Default Value: Off +; Development Value: 4096 +; Production Value: 4096 +; http://php.net/output-buffering +output_buffering = 4096 + +; You can redirect all of the output of your scripts to a function. For +; example, if you set output_handler to "mb_output_handler", character +; encoding will be transparently converted to the specified encoding. +; Setting any output handler automatically turns on output buffering. +; Note: People who wrote portable scripts should not depend on this ini +; directive. Instead, explicitly set the output handler using ob_start(). +; Using this ini directive may cause problems unless you know what script +; is doing. +; Note: You cannot use both "mb_output_handler" with "ob_iconv_handler" +; and you cannot use both "ob_gzhandler" and "zlib.output_compression". +; Note: output_handler must be empty if this is set 'On' !!!! +; Instead you must use zlib.output_handler. +; http://php.net/output-handler +;output_handler = + +; Transparent output compression using the zlib library +; Valid values for this option are 'off', 'on', or a specific buffer size +; to be used for compression (default is 4KB) +; Note: Resulting chunk size may vary due to nature of compression. PHP +; outputs chunks that are few hundreds bytes each as a result of +; compression. If you prefer a larger chunk size for better +; performance, enable output_buffering in addition. +; Note: You need to use zlib.output_handler instead of the standard +; output_handler, or otherwise the output will be corrupted. +; http://php.net/zlib.output-compression +zlib.output_compression = Off + +; http://php.net/zlib.output-compression-level +;zlib.output_compression_level = -1 + +; You cannot specify additional output handlers if zlib.output_compression +; is activated here. This setting does the same as output_handler but in +; a different order. +; http://php.net/zlib.output-handler +;zlib.output_handler = + +; Implicit flush tells PHP to tell the output layer to flush itself +; automatically after every output block. This is equivalent to calling the +; PHP function flush() after each and every call to print() or echo() and each +; and every HTML block. Turning this option on has serious performance +; implications and is generally recommended for debugging purposes only. +; http://php.net/implicit-flush +; Note: This directive is hardcoded to On for the CLI SAPI +implicit_flush = Off + +; The unserialize callback function will be called (with the undefined class' +; name as parameter), if the unserializer finds an undefined class +; which should be instantiated. A warning appears if the specified function is +; not defined, or if the function doesn't include/implement the missing class. +; So only set this entry, if you really want to implement such a +; callback-function. +unserialize_callback_func = + +; When floats & doubles are serialized store serialize_precision significant +; digits after the floating point. The default value ensures that when floats +; are decoded with unserialize, the data will remain the same. +serialize_precision = 100 + +; This directive allows you to enable and disable warnings which PHP will issue +; if you pass a value by reference at function call time. Passing values by +; reference at function call time is a deprecated feature which will be removed +; from PHP at some point in the near future. The acceptable method for passing a +; value by reference to a function is by declaring the reference in the functions +; definition, not at call time. This directive does not disable this feature, it +; only determines whether PHP will warn you about it or not. These warnings +; should enabled in development environments only. +; Default Value: On (Suppress warnings) +; Development Value: Off (Issue warnings) +; Production Value: Off (Issue warnings) +; http://php.net/allow-call-time-pass-reference +allow_call_time_pass_reference = Off + +; Safe Mode +; http://php.net/safe-mode +safe_mode = Off + +; By default, Safe Mode does a UID compare check when +; opening files. If you want to relax this to a GID compare, +; then turn on safe_mode_gid. +; http://php.net/safe-mode-gid +safe_mode_gid = Off + +; When safe_mode is on, UID/GID checks are bypassed when +; including files from this directory and its subdirectories. +; (directory must also be in include_path or full path must +; be used when including) +; http://php.net/safe-mode-include-dir +safe_mode_include_dir = + +; When safe_mode is on, only executables located in the safe_mode_exec_dir +; will be allowed to be executed via the exec family of functions. +; http://php.net/safe-mode-exec-dir +safe_mode_exec_dir = + +; Setting certain environment variables may be a potential security breach. +; This directive contains a comma-delimited list of prefixes. In Safe Mode, +; the user may only alter environment variables whose names begin with the +; prefixes supplied here. By default, users will only be able to set +; environment variables that begin with PHP_ (e.g. PHP_FOO=BAR). +; Note: If this directive is empty, PHP will let the user modify ANY +; environment variable! +; http://php.net/safe-mode-allowed-env-vars +safe_mode_allowed_env_vars = PHP_ + +; This directive contains a comma-delimited list of environment variables that +; the end user won't be able to change using putenv(). These variables will be +; protected even if safe_mode_allowed_env_vars is set to allow to change them. +; http://php.net/safe-mode-protected-env-vars +safe_mode_protected_env_vars = LD_LIBRARY_PATH + +; open_basedir, if set, limits all file operations to the defined directory +; and below. This directive makes most sense if used in a per-directory +; or per-virtualhost web server configuration file. This directive is +; *NOT* affected by whether Safe Mode is turned On or Off. +; http://php.net/open-basedir +;open_basedir = + +; This directive allows you to disable certain functions for security reasons. +; It receives a comma-delimited list of function names. This directive is +; *NOT* affected by whether Safe Mode is turned On or Off. +; http://php.net/disable-functions +disable_functions = + +; This directive allows you to disable certain classes for security reasons. +; It receives a comma-delimited list of class names. This directive is +; *NOT* affected by whether Safe Mode is turned On or Off. +; http://php.net/disable-classes +disable_classes = + +; Colors for Syntax Highlighting mode. Anything that's acceptable in +; would work. +; http://php.net/syntax-highlighting +;highlight.string = #DD0000 +;highlight.comment = #FF9900 +;highlight.keyword = #007700 +;highlight.bg = #FFFFFF +;highlight.default = #0000BB +;highlight.html = #000000 + +; If enabled, the request will be allowed to complete even if the user aborts +; the request. Consider enabling it if executing long requests, which may end up +; being interrupted by the user or a browser timing out. PHP's default behavior +; is to disable this feature. +; http://php.net/ignore-user-abort +;ignore_user_abort = On + +; Determines the size of the realpath cache to be used by PHP. This value should +; be increased on systems where PHP opens many files to reflect the quantity of +; the file operations performed. +; http://php.net/realpath-cache-size +;realpath_cache_size = 16k + +; Duration of time, in seconds for which to cache realpath information for a given +; file or directory. For systems with rarely changing files, consider increasing this +; value. +; http://php.net/realpath-cache-ttl +;realpath_cache_ttl = 120 + +;;;;;;;;;;;;;;;;; +; Miscellaneous ; +;;;;;;;;;;;;;;;;; + +; Decides whether PHP may expose the fact that it is installed on the server +; (e.g. by adding its signature to the Web server header). It is no security +; threat in any way, but it makes it possible to determine whether you use PHP +; on your server or not. +; http://php.net/expose-php +expose_php = On + +;;;;;;;;;;;;;;;;;;; +; Resource Limits ; +;;;;;;;;;;;;;;;;;;; + +; Maximum execution time of each script, in seconds +; http://php.net/max-execution-time +; Note: This directive is hardcoded to 0 for the CLI SAPI +max_execution_time = 300 + +; Maximum amount of time each script may spend parsing request data. It's a good +; idea to limit this time on productions servers in order to eliminate unexpectedly +; long running scripts. +; Note: This directive is hardcoded to -1 for the CLI SAPI +; Default Value: -1 (Unlimited) +; Development Value: 60 (60 seconds) +; Production Value: 60 (60 seconds) +; http://php.net/max-input-time +max_input_time = 300 + +; Maximum input variable nesting level +; http://php.net/max-input-nesting-level +;max_input_nesting_level = 64 + +; Maximum amount of memory a script may consume (128MB) +; http://php.net/memory-limit +memory_limit = -1 + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +; Error handling and logging ; +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + +; This directive informs PHP of which errors, warnings and notices you would like +; it to take action for. The recommended way of setting values for this +; directive is through the use of the error level constants and bitwise +; operators. The error level constants are below here for convenience as well as +; some common settings and their meanings. +; By default, PHP is set to take action on all errors, notices and warnings EXCEPT +; those related to E_NOTICE and E_STRICT, which together cover best practices and +; recommended coding standards in PHP. For performance reasons, this is the +; recommend error reporting setting. Your production server shouldn't be wasting +; resources complaining about best practices and coding standards. That's what +; development servers and development settings are for. +; Note: The php.ini-development file has this setting as E_ALL | E_STRICT. This +; means it pretty much reports everything which is exactly what you want during +; development and early testing. +; +; Error Level Constants: +; E_ALL - All errors and warnings (includes E_STRICT as of PHP 6.0.0) +; E_ERROR - fatal run-time errors +; E_RECOVERABLE_ERROR - almost fatal run-time errors +; E_WARNING - run-time warnings (non-fatal errors) +; E_PARSE - compile-time parse errors +; E_NOTICE - run-time notices (these are warnings which often result +; from a bug in your code, but it's possible that it was +; intentional (e.g., using an uninitialized variable and +; relying on the fact it's automatically initialized to an +; empty string) +; E_STRICT - run-time notices, enable to have PHP suggest changes +; to your code which will ensure the best interoperability +; and forward compatibility of your code +; E_CORE_ERROR - fatal errors that occur during PHP's initial startup +; E_CORE_WARNING - warnings (non-fatal errors) that occur during PHP's +; initial startup +; E_COMPILE_ERROR - fatal compile-time errors +; E_COMPILE_WARNING - compile-time warnings (non-fatal errors) +; E_USER_ERROR - user-generated error message +; E_USER_WARNING - user-generated warning message +; E_USER_NOTICE - user-generated notice message +; E_DEPRECATED - warn about code that will not work in future versions +; of PHP +; E_USER_DEPRECATED - user-generated deprecation warnings +; +; Common Values: +; E_ALL & ~E_NOTICE (Show all errors, except for notices and coding standards warnings.) +; E_ALL & ~E_NOTICE | E_STRICT (Show all errors, except for notices) +; E_COMPILE_ERROR|E_RECOVERABLE_ERROR|E_ERROR|E_CORE_ERROR (Show only errors) +; E_ALL | E_STRICT (Show all errors, warnings and notices including coding standards.) +; Default Value: E_ALL & ~E_NOTICE +; Development Value: E_ALL | E_STRICT +; Production Value: E_ALL & ~E_DEPRECATED +; http://php.net/error-reporting +error_reporting = E_ALL & ~E_DEPRECATED + +; This directive controls whether or not and where PHP will output errors, +; notices and warnings too. Error output is very useful during development, but +; it could be very dangerous in production environments. Depending on the code +; which is triggering the error, sensitive information could potentially leak +; out of your application such as database usernames and passwords or worse. +; It's recommended that errors be logged on production servers rather than +; having the errors sent to STDOUT. +; Possible Values: +; Off = Do not display any errors +; stderr = Display errors to STDERR (affects only CGI/CLI binaries!) +; On or stdout = Display errors to STDOUT +; Default Value: On +; Development Value: On +; Production Value: Off +; http://php.net/display-errors +display_errors = Off + +; The display of errors which occur during PHP's startup sequence are handled +; separately from display_errors. PHP's default behavior is to suppress those +; errors from clients. Turning the display of startup errors on can be useful in +; debugging configuration problems. But, it's strongly recommended that you +; leave this setting off on production servers. +; Default Value: Off +; Development Value: On +; Production Value: Off +; http://php.net/display-startup-errors +display_startup_errors = Off + +; Besides displaying errors, PHP can also log errors to locations such as a +; server-specific log, STDERR, or a location specified by the error_log +; directive found below. While errors should not be displayed on productions +; servers they should still be monitored and logging is a great way to do that. +; Default Value: Off +; Development Value: On +; Production Value: On +; http://php.net/log-errors +log_errors = On + +; Set maximum length of log_errors. In error_log information about the source is +; added. The default is 1024 and 0 allows to not apply any maximum length at all. +; http://php.net/log-errors-max-len +log_errors_max_len = 1024 + +; Do not log repeated messages. Repeated errors must occur in same file on same +; line unless ignore_repeated_source is set true. +; http://php.net/ignore-repeated-errors +ignore_repeated_errors = Off + +; Ignore source of message when ignoring repeated messages. When this setting +; is On you will not log errors with repeated messages from different files or +; source lines. +; http://php.net/ignore-repeated-source +ignore_repeated_source = Off + +; If this parameter is set to Off, then memory leaks will not be shown (on +; stdout or in the log). This has only effect in a debug compile, and if +; error reporting includes E_WARNING in the allowed list +; http://php.net/report-memleaks +report_memleaks = On + +; This setting is on by default. +;report_zend_debug = 0 + +; Store the last error/warning message in $php_errormsg (boolean). Setting this value +; to On can assist in debugging and is appropriate for development servers. It should +; however be disabled on production servers. +; Default Value: Off +; Development Value: On +; Production Value: Off +; http://php.net/track-errors +track_errors = Off + +; Turn off normal error reporting and emit XML-RPC error XML +; http://php.net/xmlrpc-errors +;xmlrpc_errors = 0 + +; An XML-RPC faultCode +;xmlrpc_error_number = 0 + +; When PHP displays or logs an error, it has the capability of inserting html +; links to documentation related to that error. This directive controls whether +; those HTML links appear in error messages or not. For performance and security +; reasons, it's recommended you disable this on production servers. +; Note: This directive is hardcoded to Off for the CLI SAPI +; Default Value: On +; Development Value: On +; Production value: Off +; http://php.net/html-errors +html_errors = Off + +; If html_errors is set On PHP produces clickable error messages that direct +; to a page describing the error or function causing the error in detail. +; You can download a copy of the PHP manual from http://php.net/docs +; and change docref_root to the base URL of your local copy including the +; leading '/'. You must also specify the file extension being used including +; the dot. PHP's default behavior is to leave these settings empty. +; Note: Never use this feature for production boxes. +; http://php.net/docref-root +; Examples +;docref_root = "/phpmanual/" + +; http://php.net/docref-ext +;docref_ext = .html + +; String to output before an error message. PHP's default behavior is to leave +; this setting blank. +; http://php.net/error-prepend-string +; Example: +;error_prepend_string = "" + +; String to output after an error message. PHP's default behavior is to leave +; this setting blank. +; http://php.net/error-append-string +; Example: +;error_append_string = "" + +; Log errors to specified file. PHP's default behavior is to leave this value +; empty. +; http://php.net/error-log +; Example: +;error_log = php_errors.log +; Log errors to syslog (Event Log on NT, not valid in Windows 95). +;error_log = syslog + +;;;;;;;;;;;;;;;;; +; Data Handling ; +;;;;;;;;;;;;;;;;; + +; The separator used in PHP generated URLs to separate arguments. +; PHP's default setting is "&". +; http://php.net/arg-separator.output +; Example: +;arg_separator.output = "&" + +; List of separator(s) used by PHP to parse input URLs into variables. +; PHP's default setting is "&". +; NOTE: Every character in this directive is considered as separator! +; http://php.net/arg-separator.input +; Example: +;arg_separator.input = ";&" + +; This directive determines which super global arrays are registered when PHP +; starts up. If the register_globals directive is enabled, it also determines +; what order variables are populated into the global space. G,P,C,E & S are +; abbreviations for the following respective super globals: GET, POST, COOKIE, +; ENV and SERVER. There is a performance penalty paid for the registration of +; these arrays and because ENV is not as commonly used as the others, ENV is +; is not recommended on productions servers. You can still get access to +; the environment variables through getenv() should you need to. +; Default Value: "EGPCS" +; Development Value: "GPCS" +; Production Value: "GPCS"; +; http://php.net/variables-order +variables_order = "GPCS" + +; This directive determines which super global data (G,P,C,E & S) should +; be registered into the super global array REQUEST. If so, it also determines +; the order in which that data is registered. The values for this directive are +; specified in the same manner as the variables_order directive, EXCEPT one. +; Leaving this value empty will cause PHP to use the value set in the +; variables_order directive. It does not mean it will leave the super globals +; array REQUEST empty. +; Default Value: None +; Development Value: "GP" +; Production Value: "GP" +; http://php.net/request-order +request_order = "GP" + +; Whether or not to register the EGPCS variables as global variables. You may +; want to turn this off if you don't want to clutter your scripts' global scope +; with user data. +; You should do your best to write your scripts so that they do not require +; register_globals to be on; Using form variables as globals can easily lead +; to possible security problems, if the code is not very well thought of. +; http://php.net/register-globals +register_globals = Off + +; Determines whether the deprecated long $HTTP_*_VARS type predefined variables +; are registered by PHP or not. As they are deprecated, we obviously don't +; recommend you use them. They are on by default for compatibility reasons but +; they are not recommended on production servers. +; Default Value: On +; Development Value: Off +; Production Value: Off +; http://php.net/register-long-arrays +register_long_arrays = Off + +; This directive determines whether PHP registers $argv & $argc each time it +; runs. $argv contains an array of all the arguments passed to PHP when a script +; is invoked. $argc contains an integer representing the number of arguments +; that were passed when the script was invoked. These arrays are extremely +; useful when running scripts from the command line. When this directive is +; enabled, registering these variables consumes CPU cycles and memory each time +; a script is executed. For performance reasons, this feature should be disabled +; on production servers. +; Note: This directive is hardcoded to On for the CLI SAPI +; Default Value: On +; Development Value: Off +; Production Value: Off +; http://php.net/register-argc-argv +register_argc_argv = Off + +; When enabled, the SERVER and ENV variables are created when they're first +; used (Just In Time) instead of when the script starts. If these variables +; are not used within a script, having this directive on will result in a +; performance gain. The PHP directives register_globals, register_long_arrays, +; and register_argc_argv must be disabled for this directive to have any affect. +; http://php.net/auto-globals-jit +auto_globals_jit = On + +; Maximum size of POST data that PHP will accept. +; http://php.net/post-max-size +post_max_size = 8M + +; Magic quotes are a preprocessing feature of PHP where PHP will attempt to +; escape any character sequences in GET, POST, COOKIE and ENV data which might +; otherwise corrupt data being placed in resources such as databases before +; making that data available to you. Because of character encoding issues and +; non-standard SQL implementations across many databases, it's not currently +; possible for this feature to be 100% accurate. PHP's default behavior is to +; enable the feature. We strongly recommend you use the escaping mechanisms +; designed specifically for the database your using instead of relying on this +; feature. Also note, this feature has been deprecated as of PHP 5.3.0 and is +; scheduled for removal in PHP 6. +; Default Value: On +; Development Value: Off +; Production Value: Off +; http://php.net/magic-quotes-gpc +magic_quotes_gpc = Off + +; Magic quotes for runtime-generated data, e.g. data from SQL, from exec(), etc. +; http://php.net/magic-quotes-runtime +magic_quotes_runtime = Off + +; Use Sybase-style magic quotes (escape ' with '' instead of \'). +; http://php.net/magic-quotes-sybase +magic_quotes_sybase = Off + +; Automatically add files before PHP document. +; http://php.net/auto-prepend-file +auto_prepend_file = + +; Automatically add files after PHP document. +; http://php.net/auto-append-file +auto_append_file = + +; By default, PHP will output a character encoding using +; the Content-type: header. To disable sending of the charset, simply +; set it to be empty. +; +; PHP's built-in default is text/html +; http://php.net/default-mimetype +default_mimetype = "text/html" + +; PHP's default character set is set to empty. +; http://php.net/default-charset +;default_charset = "iso-8859-1" + +; Always populate the $HTTP_RAW_POST_DATA variable. PHP's default behavior is +; to disable this feature. +; http://php.net/always-populate-raw-post-data +;always_populate_raw_post_data = On + +;;;;;;;;;;;;;;;;;;;;;;;;; +; Paths and Directories ; +;;;;;;;;;;;;;;;;;;;;;;;;; + +; UNIX: "/path1:/path2" +;include_path = ".:/usr/share/php" +; +; Windows: "\path1;\path2" +;include_path = ".;c:\php\includes" +; +; PHP's default setting for include_path is ".;/path/to/php/pear" +; http://php.net/include-path + +; The root of the PHP pages, used only if nonempty. +; if PHP was not compiled with FORCE_REDIRECT, you SHOULD set doc_root +; if you are running php as a CGI under any web server (other than IIS) +; see documentation for security issues. The alternate is to use the +; cgi.force_redirect configuration below +; http://php.net/doc-root +doc_root = + +; The directory under which PHP opens the script using /~username used only +; if nonempty. +; http://php.net/user-dir +user_dir = + +; Directory in which the loadable extensions (modules) reside. +; http://php.net/extension-dir +; extension_dir = "./" +; On windows: +; extension_dir = "ext" + +; Whether or not to enable the dl() function. The dl() function does NOT work +; properly in multithreaded servers, such as IIS or Zeus, and is automatically +; disabled on them. +; http://php.net/enable-dl +enable_dl = Off + +; cgi.force_redirect is necessary to provide security running PHP as a CGI under +; most web servers. Left undefined, PHP turns this on by default. You can +; turn it off here AT YOUR OWN RISK +; **You CAN safely turn this off for IIS, in fact, you MUST.** +; http://php.net/cgi.force-redirect +;cgi.force_redirect = 1 + +; if cgi.nph is enabled it will force cgi to always sent Status: 200 with +; every request. PHP's default behavior is to disable this feature. +;cgi.nph = 1 + +; if cgi.force_redirect is turned on, and you are not running under Apache or Netscape +; (iPlanet) web servers, you MAY need to set an environment variable name that PHP +; will look for to know it is OK to continue execution. Setting this variable MAY +; cause security issues, KNOW WHAT YOU ARE DOING FIRST. +; http://php.net/cgi.redirect-status-env +;cgi.redirect_status_env = ; + +; cgi.fix_pathinfo provides *real* PATH_INFO/PATH_TRANSLATED support for CGI. PHP's +; previous behaviour was to set PATH_TRANSLATED to SCRIPT_FILENAME, and to not grok +; what PATH_INFO is. For more information on PATH_INFO, see the cgi specs. Setting +; this to 1 will cause PHP CGI to fix its paths to conform to the spec. A setting +; of zero causes PHP to behave as before. Default is 1. You should fix your scripts +; to use SCRIPT_FILENAME rather than PATH_TRANSLATED. +; http://php.net/cgi.fix-pathinfo +;cgi.fix_pathinfo=1 + +; FastCGI under IIS (on WINNT based OS) supports the ability to impersonate +; security tokens of the calling client. This allows IIS to define the +; security context that the request runs under. mod_fastcgi under Apache +; does not currently support this feature (03/17/2002) +; Set to 1 if running under IIS. Default is zero. +; http://php.net/fastcgi.impersonate +;fastcgi.impersonate = 1; + +; Disable logging through FastCGI connection. PHP's default behavior is to enable +; this feature. +;fastcgi.logging = 0 + +; cgi.rfc2616_headers configuration option tells PHP what type of headers to +; use when sending HTTP response code. If it's set 0 PHP sends Status: header that +; is supported by Apache. When this option is set to 1 PHP will send +; RFC2616 compliant header. +; Default is zero. +; http://php.net/cgi.rfc2616-headers +;cgi.rfc2616_headers = 0 + +;;;;;;;;;;;;;;;; +; File Uploads ; +;;;;;;;;;;;;;;;; + +; Whether to allow HTTP file uploads. +; http://php.net/file-uploads +file_uploads = On + +; Temporary directory for HTTP uploaded files (will use system default if not +; specified). +; http://php.net/upload-tmp-dir +;upload_tmp_dir = + +; Maximum allowed size for uploaded files. +; http://php.net/upload-max-filesize +upload_max_filesize = 2M + +; Maximum number of files that can be uploaded via a single request +max_file_uploads = 20 + +;;;;;;;;;;;;;;;;;; +; Fopen wrappers ; +;;;;;;;;;;;;;;;;;; + +; Whether to allow the treatment of URLs (like http:// or ftp://) as files. +; http://php.net/allow-url-fopen +allow_url_fopen = On + +; Whether to allow include/require to open URLs (like http:// or ftp://) as files. +; http://php.net/allow-url-include +allow_url_include = Off + +; Define the anonymous ftp password (your email address). PHP's default setting +; for this is empty. +; http://php.net/from +;from="john@doe.com" + +; Define the User-Agent string. PHP's default setting for this is empty. +; http://php.net/user-agent +;user_agent="PHP" + +; Default timeout for socket based streams (seconds) +; http://php.net/default-socket-timeout +default_socket_timeout = 60 + +; If your scripts have to deal with files from Macintosh systems, +; or you are running on a Mac and need to deal with files from +; unix or win32 systems, setting this flag will cause PHP to +; automatically detect the EOL character in those files so that +; fgets() and file() will work regardless of the source of the file. +; http://php.net/auto-detect-line-endings +;auto_detect_line_endings = Off + +;;;;;;;;;;;;;;;;;;;;;; +; Dynamic Extensions ; +;;;;;;;;;;;;;;;;;;;;;; + +; If you wish to have an extension loaded automatically, use the following +; syntax: +; +; extension=modulename.extension +; +; For example, on Windows: +; +; extension=msql.dll +; +; ... or under UNIX: +; +; extension=msql.so +; +; ... or with a path: +; +; extension=/path/to/extension/msql.so +; +; If you only provide the name of the extension, PHP will look for it in its +; default extension directory. +; + +;;;;;;;;;;;;;;;;;;; +; Module Settings ; +;;;;;;;;;;;;;;;;;;; + +include_path="/media/DATA/Mes Developpements/dolibarr/test/codesniffer:/media/DATA/Mes Developpements/dolibarr/test:/home/ldestail/.eclipse/org.eclipse.platform_3.5.0_155965261/plugins/org.phpsrc.eclipse.pti.tools.codesniffer_1.2.6.R20100912000000/php/tools:/home/ldestail/.eclipse/org.eclipse.platform_3.5.0_155965261/plugins/org.phpsrc.eclipse.pti.library.pear_1.2.2.R20110627000000/php/library:/home/ldestail/.eclipse/org.eclipse.platform_3.5.0_155965261/plugins/org.phpsrc.eclipse.pti.library.pear_1.2.2.R20110627000000/php/library/PEAR" +[Date] +; Defines the default timezone used by the date functions +; http://php.net/date.timezone +;date.timezone = + +; http://php.net/date.default-latitude +;date.default_latitude = 31.7667 + +; http://php.net/date.default-longitude +;date.default_longitude = 35.2333 + +; http://php.net/date.sunrise-zenith +;date.sunrise_zenith = 90.583333 + +; http://php.net/date.sunset-zenith +;date.sunset_zenith = 90.583333 + +[filter] +; http://php.net/filter.default +;filter.default = unsafe_raw + +; http://php.net/filter.default-flags +;filter.default_flags = + +[iconv] +;iconv.input_encoding = ISO-8859-1 +;iconv.internal_encoding = ISO-8859-1 +;iconv.output_encoding = ISO-8859-1 + +[intl] +;intl.default_locale = +; This directive allows you to produce PHP errors when some error +; happens within intl functions. The value is the level of the error produced. +; Default is 0, which does not produce any errors. +;intl.error_level = E_WARNING + +[sqlite] +; http://php.net/sqlite.assoc-case +;sqlite.assoc_case = 0 + +[sqlite3] +;sqlite3.extension_dir = + +[Pcre] +;PCRE library backtracking limit. +; http://php.net/pcre.backtrack-limit +;pcre.backtrack_limit=100000 + +;PCRE library recursion limit. +;Please note that if you set this value to a high number you may consume all +;the available process stack and eventually crash PHP (due to reaching the +;stack size limit imposed by the Operating System). +; http://php.net/pcre.recursion-limit +;pcre.recursion_limit=100000 + +[Pdo] +; Whether to pool ODBC connections. Can be one of "strict", "relaxed" or "off" +; http://php.net/pdo-odbc.connection-pooling +;pdo_odbc.connection_pooling=strict + +;pdo_odbc.db2_instance_name + +[Pdo_mysql] +; If mysqlnd is used: Number of cache slots for the internal result set cache +; http://php.net/pdo_mysql.cache_size +pdo_mysql.cache_size = 2000 + +; Default socket name for local MySQL connects. If empty, uses the built-in +; MySQL defaults. +; http://php.net/pdo_mysql.default-socket +pdo_mysql.default_socket= + +[Phar] +; http://php.net/phar.readonly +;phar.readonly = On + +; http://php.net/phar.require-hash +;phar.require_hash = On + +;phar.cache_list = + +[Syslog] +; Whether or not to define the various syslog variables (e.g. $LOG_PID, +; $LOG_CRON, etc.). Turning it off is a good idea performance-wise. In +; runtime, you can define these variables by calling define_syslog_variables(). +; http://php.net/define-syslog-variables +define_syslog_variables = Off + +[mail function] +; For Win32 only. +; http://php.net/smtp +SMTP = localhost +; http://php.net/smtp-port +smtp_port = 25 + +; For Win32 only. +; http://php.net/sendmail-from +;sendmail_from = me@example.com + +; For Unix only. You may supply arguments as well (default: "sendmail -t -i"). +; http://php.net/sendmail-path +;sendmail_path = + +; Force the addition of the specified parameters to be passed as extra parameters +; to the sendmail binary. These parameters will always replace the value of +; the 5th parameter to mail(), even in safe mode. +;mail.force_extra_parameters = + +; Add X-PHP-Originating-Script: that will include uid of the script followed by the filename +mail.add_x_header = On + +; The path to a log file that will log all mail() calls. Log entries include +; the full path of the script, line number, To address and headers. +;mail.log = + +[SQL] +; http://php.net/sql.safe-mode +sql.safe_mode = Off + +[ODBC] +; http://php.net/odbc.default-db +;odbc.default_db = Not yet implemented + +; http://php.net/odbc.default-user +;odbc.default_user = Not yet implemented + +; http://php.net/odbc.default-pw +;odbc.default_pw = Not yet implemented + +; Controls the ODBC cursor model. +; Default: SQL_CURSOR_STATIC (default). +;odbc.default_cursortype + +; Allow or prevent persistent links. +; http://php.net/odbc.allow-persistent +odbc.allow_persistent = On + +; Check that a connection is still valid before reuse. +; http://php.net/odbc.check-persistent +odbc.check_persistent = On + +; Maximum number of persistent links. -1 means no limit. +; http://php.net/odbc.max-persistent +odbc.max_persistent = -1 + +; Maximum number of links (persistent + non-persistent). -1 means no limit. +; http://php.net/odbc.max-links +odbc.max_links = -1 + +; Handling of LONG fields. Returns number of bytes to variables. 0 means +; passthru. +; http://php.net/odbc.defaultlrl +odbc.defaultlrl = 4096 + +; Handling of binary data. 0 means passthru, 1 return as is, 2 convert to char. +; See the documentation on odbc_binmode and odbc_longreadlen for an explanation +; of odbc.defaultlrl and odbc.defaultbinmode +; http://php.net/odbc.defaultbinmode +odbc.defaultbinmode = 1 + +;birdstep.max_links = -1 + +[Interbase] +; Allow or prevent persistent links. +ibase.allow_persistent = 1 + +; Maximum number of persistent links. -1 means no limit. +ibase.max_persistent = -1 + +; Maximum number of links (persistent + non-persistent). -1 means no limit. +ibase.max_links = -1 + +; Default database name for ibase_connect(). +;ibase.default_db = + +; Default username for ibase_connect(). +;ibase.default_user = + +; Default password for ibase_connect(). +;ibase.default_password = + +; Default charset for ibase_connect(). +;ibase.default_charset = + +; Default timestamp format. +ibase.timestampformat = "%Y-%m-%d %H:%M:%S" + +; Default date format. +ibase.dateformat = "%Y-%m-%d" + +; Default time format. +ibase.timeformat = "%H:%M:%S" + +[MySQL] +; Allow accessing, from PHP's perspective, local files with LOAD DATA statements +; http://php.net/mysql.allow_local_infile +mysql.allow_local_infile = On + +; Allow or prevent persistent links. +; http://php.net/mysql.allow-persistent +mysql.allow_persistent = On + +; If mysqlnd is used: Number of cache slots for the internal result set cache +; http://php.net/mysql.cache_size +mysql.cache_size = 2000 + +; Maximum number of persistent links. -1 means no limit. +; http://php.net/mysql.max-persistent +mysql.max_persistent = -1 + +; Maximum number of links (persistent + non-persistent). -1 means no limit. +; http://php.net/mysql.max-links +mysql.max_links = -1 + +; Default port number for mysql_connect(). If unset, mysql_connect() will use +; the $MYSQL_TCP_PORT or the mysql-tcp entry in /etc/services or the +; compile-time value defined MYSQL_PORT (in that order). Win32 will only look +; at MYSQL_PORT. +; http://php.net/mysql.default-port +mysql.default_port = + +; Default socket name for local MySQL connects. If empty, uses the built-in +; MySQL defaults. +; http://php.net/mysql.default-socket +mysql.default_socket = + +; Default host for mysql_connect() (doesn't apply in safe mode). +; http://php.net/mysql.default-host +mysql.default_host = + +; Default user for mysql_connect() (doesn't apply in safe mode). +; http://php.net/mysql.default-user +mysql.default_user = + +; Default password for mysql_connect() (doesn't apply in safe mode). +; Note that this is generally a *bad* idea to store passwords in this file. +; *Any* user with PHP access can run 'echo get_cfg_var("mysql.default_password") +; and reveal this password! And of course, any users with read access to this +; file will be able to reveal the password as well. +; http://php.net/mysql.default-password +mysql.default_password = + +; Maximum time (in seconds) for connect timeout. -1 means no limit +; http://php.net/mysql.connect-timeout +mysql.connect_timeout = 60 + +; Trace mode. When trace_mode is active (=On), warnings for table/index scans and +; SQL-Errors will be displayed. +; http://php.net/mysql.trace-mode +mysql.trace_mode = Off + +[MySQLi] + +; Maximum number of persistent links. -1 means no limit. +; http://php.net/mysqli.max-persistent +mysqli.max_persistent = -1 + +; Allow accessing, from PHP's perspective, local files with LOAD DATA statements +; http://php.net/mysqli.allow_local_infile +;mysqli.allow_local_infile = On + +; Allow or prevent persistent links. +; http://php.net/mysqli.allow-persistent +mysqli.allow_persistent = On + +; Maximum number of links. -1 means no limit. +; http://php.net/mysqli.max-links +mysqli.max_links = -1 + +; If mysqlnd is used: Number of cache slots for the internal result set cache +; http://php.net/mysqli.cache_size +mysqli.cache_size = 2000 + +; Default port number for mysqli_connect(). If unset, mysqli_connect() will use +; the $MYSQL_TCP_PORT or the mysql-tcp entry in /etc/services or the +; compile-time value defined MYSQL_PORT (in that order). Win32 will only look +; at MYSQL_PORT. +; http://php.net/mysqli.default-port +mysqli.default_port = 3306 + +; Default socket name for local MySQL connects. If empty, uses the built-in +; MySQL defaults. +; http://php.net/mysqli.default-socket +mysqli.default_socket = + +; Default host for mysql_connect() (doesn't apply in safe mode). +; http://php.net/mysqli.default-host +mysqli.default_host = + +; Default user for mysql_connect() (doesn't apply in safe mode). +; http://php.net/mysqli.default-user +mysqli.default_user = + +; Default password for mysqli_connect() (doesn't apply in safe mode). +; Note that this is generally a *bad* idea to store passwords in this file. +; *Any* user with PHP access can run 'echo get_cfg_var("mysqli.default_pw") +; and reveal this password! And of course, any users with read access to this +; file will be able to reveal the password as well. +; http://php.net/mysqli.default-pw +mysqli.default_pw = + +; Allow or prevent reconnect +mysqli.reconnect = Off + +[mysqlnd] +; Enable / Disable collection of general statstics by mysqlnd which can be +; used to tune and monitor MySQL operations. +; http://php.net/mysqlnd.collect_statistics +mysqlnd.collect_statistics = On + +; Enable / Disable collection of memory usage statstics by mysqlnd which can be +; used to tune and monitor MySQL operations. +; http://php.net/mysqlnd.collect_memory_statistics +mysqlnd.collect_memory_statistics = Off + +; Size of a pre-allocated buffer used when sending commands to MySQL in bytes. +; http://php.net/mysqlnd.net_cmd_buffer_size +;mysqlnd.net_cmd_buffer_size = 2048 + +; Size of a pre-allocated buffer used for reading data sent by the server in +; bytes. +; http://php.net/mysqlnd.net_read_buffer_size +;mysqlnd.net_read_buffer_size = 32768 + +[OCI8] + +; Connection: Enables privileged connections using external +; credentials (OCI_SYSOPER, OCI_SYSDBA) +; http://php.net/oci8.privileged-connect +;oci8.privileged_connect = Off + +; Connection: The maximum number of persistent OCI8 connections per +; process. Using -1 means no limit. +; http://php.net/oci8.max-persistent +;oci8.max_persistent = -1 + +; Connection: The maximum number of seconds a process is allowed to +; maintain an idle persistent connection. Using -1 means idle +; persistent connections will be maintained forever. +; http://php.net/oci8.persistent-timeout +;oci8.persistent_timeout = -1 + +; Connection: The number of seconds that must pass before issuing a +; ping during oci_pconnect() to check the connection validity. When +; set to 0, each oci_pconnect() will cause a ping. Using -1 disables +; pings completely. +; http://php.net/oci8.ping-interval +;oci8.ping_interval = 60 + +; Connection: Set this to a user chosen connection class to be used +; for all pooled server requests with Oracle 11g Database Resident +; Connection Pooling (DRCP). To use DRCP, this value should be set to +; the same string for all web servers running the same application, +; the database pool must be configured, and the connection string must +; specify to use a pooled server. +;oci8.connection_class = + +; High Availability: Using On lets PHP receive Fast Application +; Notification (FAN) events generated when a database node fails. The +; database must also be configured to post FAN events. +;oci8.events = Off + +; Tuning: This option enables statement caching, and specifies how +; many statements to cache. Using 0 disables statement caching. +; http://php.net/oci8.statement-cache-size +;oci8.statement_cache_size = 20 + +; Tuning: Enables statement prefetching and sets the default number of +; rows that will be fetched automatically after statement execution. +; http://php.net/oci8.default-prefetch +;oci8.default_prefetch = 100 + +; Compatibility. Using On means oci_close() will not close +; oci_connect() and oci_new_connect() connections. +; http://php.net/oci8.old-oci-close-semantics +;oci8.old_oci_close_semantics = Off + +[PostgresSQL] +; Allow or prevent persistent links. +; http://php.net/pgsql.allow-persistent +pgsql.allow_persistent = On + +; Detect broken persistent links always with pg_pconnect(). +; Auto reset feature requires a little overheads. +; http://php.net/pgsql.auto-reset-persistent +pgsql.auto_reset_persistent = Off + +; Maximum number of persistent links. -1 means no limit. +; http://php.net/pgsql.max-persistent +pgsql.max_persistent = -1 + +; Maximum number of links (persistent+non persistent). -1 means no limit. +; http://php.net/pgsql.max-links +pgsql.max_links = -1 + +; Ignore PostgreSQL backends Notice message or not. +; Notice message logging require a little overheads. +; http://php.net/pgsql.ignore-notice +pgsql.ignore_notice = 0 + +; Log PostgreSQL backends Notice message or not. +; Unless pgsql.ignore_notice=0, module cannot log notice message. +; http://php.net/pgsql.log-notice +pgsql.log_notice = 0 + +[Sybase-CT] +; Allow or prevent persistent links. +; http://php.net/sybct.allow-persistent +sybct.allow_persistent = On + +; Maximum number of persistent links. -1 means no limit. +; http://php.net/sybct.max-persistent +sybct.max_persistent = -1 + +; Maximum number of links (persistent + non-persistent). -1 means no limit. +; http://php.net/sybct.max-links +sybct.max_links = -1 + +; Minimum server message severity to display. +; http://php.net/sybct.min-server-severity +sybct.min_server_severity = 10 + +; Minimum client message severity to display. +; http://php.net/sybct.min-client-severity +sybct.min_client_severity = 10 + +; Set per-context timeout +; http://php.net/sybct.timeout +;sybct.timeout= + +;sybct.packet_size + +; The maximum time in seconds to wait for a connection attempt to succeed before returning failure. +; Default: one minute +;sybct.login_timeout= + +; The name of the host you claim to be connecting from, for display by sp_who. +; Default: none +;sybct.hostname= + +; Allows you to define how often deadlocks are to be retried. -1 means "forever". +; Default: 0 +;sybct.deadlock_retry_count= + +[bcmath] +; Number of decimal digits for all bcmath functions. +; http://php.net/bcmath.scale +bcmath.scale = 0 + +[browscap] +; http://php.net/browscap +;browscap = extra/browscap.ini + +[Session] +; Handler used to store/retrieve data. +; http://php.net/session.save-handler +session.save_handler = files + +; Argument passed to save_handler. In the case of files, this is the path +; where data files are stored. Note: Windows users have to change this +; variable in order to use PHP's session functions. +; +; The path can be defined as: +; +; session.save_path = "N;/path" +; +; where N is an integer. Instead of storing all the session files in +; /path, what this will do is use subdirectories N-levels deep, and +; store the session data in those directories. This is useful if you +; or your OS have problems with lots of files in one directory, and is +; a more efficient layout for servers that handle lots of sessions. +; +; NOTE 1: PHP will not create this directory structure automatically. +; You can use the script in the ext/session dir for that purpose. +; NOTE 2: See the section on garbage collection below if you choose to +; use subdirectories for session storage +; +; The file storage module creates files using mode 600 by default. +; You can change that by using +; +; session.save_path = "N;MODE;/path" +; +; where MODE is the octal representation of the mode. Note that this +; does not overwrite the process's umask. +; http://php.net/session.save-path +;session.save_path = "/tmp" + +; Whether to use cookies. +; http://php.net/session.use-cookies +session.use_cookies = 1 + +; http://php.net/session.cookie-secure +;session.cookie_secure = + +; This option forces PHP to fetch and use a cookie for storing and maintaining +; the session id. We encourage this operation as it's very helpful in combatting +; session hijacking when not specifying and managing your own session id. It is +; not the end all be all of session hijacking defense, but it's a good start. +; http://php.net/session.use-only-cookies +session.use_only_cookies = 1 + +; Name of the session (used as cookie name). +; http://php.net/session.name +session.name = PHPSESSID + +; Initialize session on request startup. +; http://php.net/session.auto-start +session.auto_start = 0 + +; Lifetime in seconds of cookie or, if 0, until browser is restarted. +; http://php.net/session.cookie-lifetime +session.cookie_lifetime = 0 + +; The path for which the cookie is valid. +; http://php.net/session.cookie-path +session.cookie_path = / + +; The domain for which the cookie is valid. +; http://php.net/session.cookie-domain +session.cookie_domain = + +; Whether or not to add the httpOnly flag to the cookie, which makes it inaccessible to browser scripting languages such as JavaScript. +; http://php.net/session.cookie-httponly +session.cookie_httponly = + +; Handler used to serialize data. php is the standard serializer of PHP. +; http://php.net/session.serialize-handler +session.serialize_handler = php + +; Defines the probability that the 'garbage collection' process is started +; on every session initialization. The probability is calculated by using +; gc_probability/gc_divisor. Where session.gc_probability is the numerator +; and gc_divisor is the denominator in the equation. Setting this value to 1 +; when the session.gc_divisor value is 100 will give you approximately a 1% chance +; the gc will run on any give request. +; Default Value: 1 +; Development Value: 1 +; Production Value: 1 +; http://php.net/session.gc-probability +session.gc_probability = 1 + +; Defines the probability that the 'garbage collection' process is started on every +; session initialization. The probability is calculated by using the following equation: +; gc_probability/gc_divisor. Where session.gc_probability is the numerator and +; session.gc_divisor is the denominator in the equation. Setting this value to 1 +; when the session.gc_divisor value is 100 will give you approximately a 1% chance +; the gc will run on any give request. Increasing this value to 1000 will give you +; a 0.1% chance the gc will run on any give request. For high volume production servers, +; this is a more efficient approach. +; Default Value: 100 +; Development Value: 1000 +; Production Value: 1000 +; http://php.net/session.gc-divisor +session.gc_divisor = 1000 + +; After this number of seconds, stored data will be seen as 'garbage' and +; cleaned up by the garbage collection process. +; http://php.net/session.gc-maxlifetime +session.gc_maxlifetime = 1440 + +; NOTE: If you are using the subdirectory option for storing session files +; (see session.save_path above), then garbage collection does *not* +; happen automatically. You will need to do your own garbage +; collection through a shell script, cron entry, or some other method. +; For example, the following script would is the equivalent of +; setting session.gc_maxlifetime to 1440 (1440 seconds = 24 minutes): +; find /path/to/sessions -cmin +24 | xargs rm + +; PHP 4.2 and less have an undocumented feature/bug that allows you to +; to initialize a session variable in the global scope, even when register_globals +; is disabled. PHP 4.3 and later will warn you, if this feature is used. +; You can disable the feature and the warning separately. At this time, +; the warning is only displayed, if bug_compat_42 is enabled. This feature +; introduces some serious security problems if not handled correctly. It's +; recommended that you do not use this feature on production servers. But you +; should enable this on development servers and enable the warning as well. If you +; do not enable the feature on development servers, you won't be warned when it's +; used and debugging errors caused by this can be difficult to track down. +; Default Value: On +; Development Value: On +; Production Value: Off +; http://php.net/session.bug-compat-42 +session.bug_compat_42 = Off + +; This setting controls whether or not you are warned by PHP when initializing a +; session value into the global space. session.bug_compat_42 must be enabled before +; these warnings can be issued by PHP. See the directive above for more information. +; Default Value: On +; Development Value: On +; Production Value: Off +; http://php.net/session.bug-compat-warn +session.bug_compat_warn = Off + +; Check HTTP Referer to invalidate externally stored URLs containing ids. +; HTTP_REFERER has to contain this substring for the session to be +; considered as valid. +; http://php.net/session.referer-check +session.referer_check = + +; How many bytes to read from the file. +; http://php.net/session.entropy-length +session.entropy_length = 0 + +; Specified here to create the session id. +; http://php.net/session.entropy-file +; On systems that don't have /dev/urandom /dev/arandom can be used +; On windows, setting the entropy_length setting will activate the +; Windows random source (using the CryptoAPI) +;session.entropy_file = /dev/urandom + +; Set to {nocache,private,public,} to determine HTTP caching aspects +; or leave this empty to avoid sending anti-caching headers. +; http://php.net/session.cache-limiter +session.cache_limiter = nocache + +; Document expires after n minutes. +; http://php.net/session.cache-expire +session.cache_expire = 180 + +; trans sid support is disabled by default. +; Use of trans sid may risk your users security. +; Use this option with caution. +; - User may send URL contains active session ID +; to other person via. email/irc/etc. +; - URL that contains active session ID may be stored +; in publically accessible computer. +; - User may access your site with the same session ID +; always using URL stored in browser's history or bookmarks. +; http://php.net/session.use-trans-sid +session.use_trans_sid = 0 + +; Select a hash function for use in generating session ids. +; Possible Values +; 0 (MD5 128 bits) +; 1 (SHA-1 160 bits) +; This option may also be set to the name of any hash function supported by +; the hash extension. A list of available hashes is returned by the hash_algos() +; function. +; http://php.net/session.hash-function +session.hash_function = 0 + +; Define how many bits are stored in each character when converting +; the binary hash data to something readable. +; Possible values: +; 4 (4 bits: 0-9, a-f) +; 5 (5 bits: 0-9, a-v) +; 6 (6 bits: 0-9, a-z, A-Z, "-", ",") +; Default Value: 4 +; Development Value: 5 +; Production Value: 5 +; http://php.net/session.hash-bits-per-character +session.hash_bits_per_character = 5 + +; The URL rewriter will look for URLs in a defined set of HTML tags. +; form/fieldset are special; if you include them here, the rewriter will +; add a hidden field with the info which is otherwise appended +; to URLs. If you want XHTML conformity, remove the form entry. +; Note that all valid entries require a "=", even if no value follows. +; Default Value: "a=href,area=href,frame=src,form=,fieldset=" +; Development Value: "a=href,area=href,frame=src,input=src,form=fakeentry" +; Production Value: "a=href,area=href,frame=src,input=src,form=fakeentry" +; http://php.net/url-rewriter.tags +url_rewriter.tags = "a=href,area=href,frame=src,input=src,form=fakeentry" + +[MSSQL] +; Allow or prevent persistent links. +mssql.allow_persistent = On + +; Maximum number of persistent links. -1 means no limit. +mssql.max_persistent = -1 + +; Maximum number of links (persistent+non persistent). -1 means no limit. +mssql.max_links = -1 + +; Minimum error severity to display. +mssql.min_error_severity = 10 + +; Minimum message severity to display. +mssql.min_message_severity = 10 + +; Compatibility mode with old versions of PHP 3.0. +mssql.compatability_mode = Off + +; Connect timeout +;mssql.connect_timeout = 5 + +; Query timeout +;mssql.timeout = 60 + +; Valid range 0 - 2147483647. Default = 4096. +;mssql.textlimit = 4096 + +; Valid range 0 - 2147483647. Default = 4096. +;mssql.textsize = 4096 + +; Limits the number of records in each batch. 0 = all records in one batch. +;mssql.batchsize = 0 + +; Specify how datetime and datetim4 columns are returned +; On => Returns data converted to SQL server settings +; Off => Returns values as YYYY-MM-DD hh:mm:ss +;mssql.datetimeconvert = On + +; Use NT authentication when connecting to the server +mssql.secure_connection = Off + +; Specify max number of processes. -1 = library default +; msdlib defaults to 25 +; FreeTDS defaults to 4096 +;mssql.max_procs = -1 + +; Specify client character set. +; If empty or not set the client charset from freetds.comf is used +; This is only used when compiled with FreeTDS +;mssql.charset = "ISO-8859-1" + +[Assertion] +; Assert(expr); active by default. +; http://php.net/assert.active +;assert.active = On + +; Issue a PHP warning for each failed assertion. +; http://php.net/assert.warning +;assert.warning = On + +; Don't bail out by default. +; http://php.net/assert.bail +;assert.bail = Off + +; User-function to be called if an assertion fails. +; http://php.net/assert.callback +;assert.callback = 0 + +; Eval the expression with current error_reporting(). Set to true if you want +; error_reporting(0) around the eval(). +; http://php.net/assert.quiet-eval +;assert.quiet_eval = 0 + +[COM] +; path to a file containing GUIDs, IIDs or filenames of files with TypeLibs +; http://php.net/com.typelib-file +;com.typelib_file = + +; allow Distributed-COM calls +; http://php.net/com.allow-dcom +;com.allow_dcom = true + +; autoregister constants of a components typlib on com_load() +; http://php.net/com.autoregister-typelib +;com.autoregister_typelib = true + +; register constants casesensitive +; http://php.net/com.autoregister-casesensitive +;com.autoregister_casesensitive = false + +; show warnings on duplicate constant registrations +; http://php.net/com.autoregister-verbose +;com.autoregister_verbose = true + +; The default character set code-page to use when passing strings to and from COM objects. +; Default: system ANSI code page +;com.code_page= + +[mbstring] +; language for internal character representation. +; http://php.net/mbstring.language +;mbstring.language = Japanese + +; internal/script encoding. +; Some encoding cannot work as internal encoding. +; (e.g. SJIS, BIG5, ISO-2022-*) +; http://php.net/mbstring.internal-encoding +;mbstring.internal_encoding = EUC-JP + +; http input encoding. +; http://php.net/mbstring.http-input +;mbstring.http_input = auto + +; http output encoding. mb_output_handler must be +; registered as output buffer to function +; http://php.net/mbstring.http-output +;mbstring.http_output = SJIS + +; enable automatic encoding translation according to +; mbstring.internal_encoding setting. Input chars are +; converted to internal encoding by setting this to On. +; Note: Do _not_ use automatic encoding translation for +; portable libs/applications. +; http://php.net/mbstring.encoding-translation +;mbstring.encoding_translation = Off + +; automatic encoding detection order. +; auto means +; http://php.net/mbstring.detect-order +;mbstring.detect_order = auto + +; substitute_character used when character cannot be converted +; one from another +; http://php.net/mbstring.substitute-character +;mbstring.substitute_character = none; + +; overload(replace) single byte functions by mbstring functions. +; mail(), ereg(), etc are overloaded by mb_send_mail(), mb_ereg(), +; etc. Possible values are 0,1,2,4 or combination of them. +; For example, 7 for overload everything. +; 0: No overload +; 1: Overload mail() function +; 2: Overload str*() functions +; 4: Overload ereg*() functions +; http://php.net/mbstring.func-overload +;mbstring.func_overload = 0 + +; enable strict encoding detection. +;mbstring.strict_detection = Off + +; This directive specifies the regex pattern of content types for which mb_output_handler() +; is activated. +; Default: mbstring.http_output_conv_mimetype=^(text/|application/xhtml\+xml) +;mbstring.http_output_conv_mimetype= + +; Allows to set script encoding. Only affects if PHP is compiled with --enable-zend-multibyte +; Default: "" +;mbstring.script_encoding= + +[gd] +; Tell the jpeg decode to ignore warnings and try to create +; a gd image. The warning will then be displayed as notices +; disabled by default +; http://php.net/gd.jpeg-ignore-warning +;gd.jpeg_ignore_warning = 0 + +[exif] +; Exif UNICODE user comments are handled as UCS-2BE/UCS-2LE and JIS as JIS. +; With mbstring support this will automatically be converted into the encoding +; given by corresponding encode setting. When empty mbstring.internal_encoding +; is used. For the decode settings you can distinguish between motorola and +; intel byte order. A decode setting cannot be empty. +; http://php.net/exif.encode-unicode +;exif.encode_unicode = ISO-8859-15 + +; http://php.net/exif.decode-unicode-motorola +;exif.decode_unicode_motorola = UCS-2BE + +; http://php.net/exif.decode-unicode-intel +;exif.decode_unicode_intel = UCS-2LE + +; http://php.net/exif.encode-jis +;exif.encode_jis = + +; http://php.net/exif.decode-jis-motorola +;exif.decode_jis_motorola = JIS + +; http://php.net/exif.decode-jis-intel +;exif.decode_jis_intel = JIS + +[Tidy] +; The path to a default tidy configuration file to use when using tidy +; http://php.net/tidy.default-config +;tidy.default_config = /usr/local/lib/php/default.tcfg + +; Should tidy clean and repair output automatically? +; WARNING: Do not use this option if you are generating non-html content +; such as dynamic images +; http://php.net/tidy.clean-output +tidy.clean_output = Off + +[soap] +; Enables or disables WSDL caching feature. +; http://php.net/soap.wsdl-cache-enabled +soap.wsdl_cache_enabled=1 + +; Sets the directory name where SOAP extension will put cache files. +; http://php.net/soap.wsdl-cache-dir +soap.wsdl_cache_dir="/tmp" + +; (time to live) Sets the number of second while cached file will be used +; instead of original one. +; http://php.net/soap.wsdl-cache-ttl +soap.wsdl_cache_ttl=86400 + +; Sets the size of the cache limit. (Max. number of WSDL files to cache) +soap.wsdl_cache_limit = 5 + +[sysvshm] +; A default size of the shared memory segment +;sysvshm.init_mem = 10000 + +[ldap] +; Sets the maximum number of open links or -1 for unlimited. +ldap.max_links = -1 + +[mcrypt] +; For more information about mcrypt settings see http://php.net/mcrypt-module-open + +; Directory where to load mcrypt algorithms +; Default: Compiled in into libmcrypt (usually /usr/local/lib/libmcrypt) +;mcrypt.algorithms_dir= + +; Directory where to load mcrypt modes +; Default: Compiled in into libmcrypt (usually /usr/local/lib/libmcrypt) +;mcrypt.modes_dir= + +[dba] +;dba.default_handler= + +; Local Variables: +; tab-width: 4 +; End: From 4b931c3d7359185f3eb1f22d1cee2ffa58ab7ae6 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 00:15:16 +0000 Subject: [PATCH 04/49] Qual: Removed errors and warnings reported by codesniffer --- htdocs/document.php | 8 ++++++-- htdocs/viewimage.php | 8 ++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/htdocs/document.php b/htdocs/document.php index 78c7a098db9..8f4b32486b2 100644 --- a/htdocs/document.php +++ b/htdocs/document.php @@ -25,7 +25,7 @@ /** * \file htdocs/document.php * \brief Wrapper to download data files - * \version $Id: document.php,v 1.121 2011/06/28 13:42:06 hregis Exp $ + * \version $Id: document.php,v 1.122 2011/07/09 00:15:16 eldy Exp $ * \remarks Call of this wrapper is made with URL: * document.php?modulepart=repfichierconcerne&file=pathrelatifdufichier */ @@ -41,7 +41,11 @@ if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU','1'); if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML','1'); if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1'); -// C'est un wrapper, donc header vierge +/** + * Wrapper, donc header vierge + * + * @return null + */ function llxHeader() { } require("./main.inc.php"); // Load $user and permissions diff --git a/htdocs/viewimage.php b/htdocs/viewimage.php index 2a4dd7b2b92..488efb23137 100644 --- a/htdocs/viewimage.php +++ b/htdocs/viewimage.php @@ -23,7 +23,7 @@ * \file htdocs/viewimage.php * \brief Wrapper to show images into Dolibarr screens * \remarks Call to wrapper is '' - * \version $Id: viewimage.php,v 1.94 2011/07/06 16:56:01 eldy Exp $ + * \version $Id: viewimage.php,v 1.95 2011/07/09 00:15:16 eldy Exp $ */ // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP). @@ -44,7 +44,11 @@ if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1'); // Pour autre que companylogo, on charge environnement + info issus de logon comme le user if (($modulepart == 'companylogo') && ! defined("NOLOGIN")) define("NOLOGIN",'1'); -// C'est un wrapper, donc header vierge +/** + * Wrapper, donc header vierge + * + * @return null + */ function llxHeader() { } From 2a406e41cb63d3039e3f8b4457cae3aa29210201 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 01:39:07 +0000 Subject: [PATCH 05/49] Removed useless files to avoid warning in packages --- .../filemanager/connectors/asp/basexml.asp | 71 - .../connectors/asp/class_upload.asp | 353 ----- .../filemanager/connectors/asp/commands.asp | 202 --- .../filemanager/connectors/asp/config.asp | 128 -- .../filemanager/connectors/asp/connector.asp | 88 -- .../editor/filemanager/connectors/asp/io.asp | 247 --- .../filemanager/connectors/asp/upload.asp | 65 - .../filemanager/connectors/asp/util.asp | 55 - .../filemanager/connectors/aspx/config.ascx | 98 -- .../connectors/aspx/connector.aspx | 32 - .../filemanager/connectors/aspx/upload.aspx | 32 - .../connectors/cfm/ImageObject.cfc | 273 ---- .../connectors/cfm/cf5_connector.cfm | 336 ----- .../filemanager/connectors/cfm/cf5_upload.cfm | 324 ---- .../filemanager/connectors/cfm/cf_basexml.cfm | 72 - .../connectors/cfm/cf_commands.cfm | 240 --- .../connectors/cfm/cf_connector.cfm | 89 -- .../filemanager/connectors/cfm/cf_io.cfm | 299 ---- .../filemanager/connectors/cfm/cf_upload.cfm | 71 - .../filemanager/connectors/cfm/cf_util.cfm | 131 -- .../filemanager/connectors/cfm/config.cfm | 150 -- .../filemanager/connectors/cfm/connector.cfm | 32 - .../filemanager/connectors/cfm/image.cfc | 1324 ----------------- .../filemanager/connectors/cfm/upload.cfm | 31 - .../filemanager/connectors/lasso/config.lasso | 65 - .../connectors/lasso/connector.lasso | 330 ---- .../filemanager/connectors/lasso/upload.lasso | 178 --- .../filemanager/connectors/perl/basexml.pl | 68 - .../filemanager/connectors/perl/commands.pl | 200 --- .../filemanager/connectors/perl/config.pl | 39 - .../filemanager/connectors/perl/connector.cgi | 129 -- .../editor/filemanager/connectors/perl/io.pl | 141 -- .../filemanager/connectors/perl/upload.cgi | 87 -- .../filemanager/connectors/perl/upload_fck.pl | 686 --------- .../filemanager/connectors/perl/util.pl | 66 - .../filemanager/connectors/py/config.py | 146 -- .../filemanager/connectors/py/connector.py | 121 -- .../filemanager/connectors/py/fckcommands.py | 202 --- .../filemanager/connectors/py/fckconnector.py | 90 -- .../filemanager/connectors/py/fckoutput.py | 119 -- .../filemanager/connectors/py/fckutil.py | 130 -- .../filemanager/connectors/py/htaccess.txt | 23 - .../filemanager/connectors/py/upload.py | 88 -- .../editor/filemanager/connectors/py/wsgi.py | 58 - .../editor/filemanager/connectors/py/zope.py | 188 --- 45 files changed, 7897 deletions(-) delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/asp/basexml.asp delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/asp/class_upload.asp delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/asp/commands.asp delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/asp/config.asp delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/asp/connector.asp delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/asp/io.asp delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/asp/upload.asp delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/asp/util.asp delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/config.ascx delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/connector.aspx delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/upload.aspx delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/ImageObject.cfc delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf5_connector.cfm delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf5_upload.cfm delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_basexml.cfm delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_commands.cfm delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_connector.cfm delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_io.cfm delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_upload.cfm delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_util.cfm delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/config.cfm delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/connector.cfm delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/image.cfc delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/upload.cfm delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/config.lasso delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/connector.lasso delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/upload.lasso delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/perl/basexml.pl delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/perl/commands.pl delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/perl/config.pl delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/perl/connector.cgi delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/perl/io.pl delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/perl/upload.cgi delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/perl/upload_fck.pl delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/perl/util.pl delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/py/config.py delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/py/connector.py delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckcommands.py delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckconnector.py delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckoutput.py delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckutil.py delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/py/htaccess.txt delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/py/upload.py delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/py/wsgi.py delete mode 100644 htdocs/includes/fckeditor/editor/filemanager/connectors/py/zope.py diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/basexml.asp b/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/basexml.asp deleted file mode 100644 index e53e7333768..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/basexml.asp +++ /dev/null @@ -1,71 +0,0 @@ -<% - ' FCKeditor - The text editor for Internet - http://www.fckeditor.net - ' Copyright (C) 2003-2010 Frederico Caldeira Knabben - ' - ' == BEGIN LICENSE == - ' - ' Licensed under the terms of any of the following licenses at your - ' choice: - ' - ' - GNU General Public License Version 2 or later (the "GPL") - ' http://www.gnu.org/licenses/gpl.html - ' - ' - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - ' http://www.gnu.org/licenses/lgpl.html - ' - ' - Mozilla Public License Version 1.1 or later (the "MPL") - ' http://www.mozilla.org/MPL/MPL-1.1.html - ' - ' == END LICENSE == - ' - ' This file include the functions that create the base XML output. -%> -<% - -Sub SetXmlHeaders() - ' Cleans the response buffer. - Response.Clear() - - ' Prevent the browser from caching the result. - Response.CacheControl = "no-cache" - - ' Set the response format. - on error resume next - ' The CodePage property isn't supported in Windows 2000. #2604 - Response.CodePage = 65001 - on error goto 0 - - Response.CharSet = "UTF-8" - Response.ContentType = "text/xml" -End Sub - -Sub CreateXmlHeader( command, resourceType, currentFolder, url ) - ' Create the XML document header. - Response.Write "" - - ' Create the main "Connector" node. - Response.Write "" - - ' Add the current folder node. - Response.Write "" -End Sub - -Sub CreateXmlFooter() - Response.Write "" -End Sub - -Sub SendError( number, text ) - SetXmlHeaders - - ' Create the XML document header. - Response.Write "" - - If text <> "" then - Response.Write "" - else - Response.Write "" - end if - - Response.End -End Sub -%> diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/class_upload.asp b/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/class_upload.asp deleted file mode 100644 index 5634598d18d..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/class_upload.asp +++ /dev/null @@ -1,353 +0,0 @@ -<% - ' FCKeditor - The text editor for Internet - http://www.fckeditor.net - ' Copyright (C) 2003-2010 Frederico Caldeira Knabben - ' - ' == BEGIN LICENSE == - ' - ' Licensed under the terms of any of the following licenses at your - ' choice: - ' - ' - GNU General Public License Version 2 or later (the "GPL") - ' http://www.gnu.org/licenses/gpl.html - ' - ' - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - ' http://www.gnu.org/licenses/lgpl.html - ' - ' - Mozilla Public License Version 1.1 or later (the "MPL") - ' http://www.mozilla.org/MPL/MPL-1.1.html - ' - ' == END LICENSE == - ' - ' These are the classes used to handle ASP upload without using third - ' part components (OCX/DLL). -%> -<% -'********************************************** -' File: NetRube_Upload.asp -' Version: NetRube Upload Class Version 2.3 Build 20070528 -' Author: NetRube -' Email: NetRube@126.com -' Date: 05/28/2007 -' Comments: The code for the Upload. -' This can free usage, but please -' not to delete this copyright information. -' If you have a modification version, -' Please send out a duplicate to me. -'********************************************** -' 文件名: NetRube_Upload.asp -' 版本: NetRube Upload Class Version 2.3 Build 20070528 -' 作者: NetRube(网络乡巴佬) -' 电子邮件: NetRube@126.com -' 日期: 2007年05月28日 -' 声明: 文件上传类 -' 本上传类可以自由使用,但请保留此版权声明信息 -' 如果您对本上传类进行修改增强, -' 请发送一份给俺。 -'********************************************** - -Class NetRube_Upload - - Public File, Form - Private oSourceData - Private nMaxSize, nErr, sAllowed, sDenied, sHtmlExtensions - - Private Sub Class_Initialize - nErr = 0 - nMaxSize = 1048576 - - Set File = Server.CreateObject("Scripting.Dictionary") - File.CompareMode = 1 - Set Form = Server.CreateObject("Scripting.Dictionary") - Form.CompareMode = 1 - - Set oSourceData = Server.CreateObject("ADODB.Stream") - oSourceData.Type = 1 - oSourceData.Mode = 3 - oSourceData.Open - End Sub - - Private Sub Class_Terminate - Form.RemoveAll - Set Form = Nothing - File.RemoveAll - Set File = Nothing - - oSourceData.Close - Set oSourceData = Nothing - End Sub - - Public Property Get Version - Version = "NetRube Upload Class Version 2.3 Build 20070528" - End Property - - Public Property Get ErrNum - ErrNum = nErr - End Property - - Public Property Let MaxSize(nSize) - nMaxSize = nSize - End Property - - Public Property Let Allowed(sExt) - sAllowed = sExt - End Property - - Public Property Let Denied(sExt) - sDenied = sExt - End Property - - Public Property Let HtmlExtensions(sExt) - sHtmlExtensions = sExt - End Property - - Public Sub GetData - Dim aCType - aCType = Split(Request.ServerVariables("HTTP_CONTENT_TYPE"), ";") - if ( uBound(aCType) < 0 ) then - nErr = 1 - Exit Sub - end if - If aCType(0) <> "multipart/form-data" Then - nErr = 1 - Exit Sub - End If - - Dim nTotalSize - nTotalSize = Request.TotalBytes - If nTotalSize < 1 Then - nErr = 2 - Exit Sub - End If - If nMaxSize > 0 And nTotalSize > nMaxSize Then - nErr = 3 - Exit Sub - End If - - 'Thankful long(yrl031715@163.com) - 'Fix upload large file. - '********************************************** - ' 修正作者:long - ' 联系邮件: yrl031715@163.com - ' 修正时间:2007年5月6日 - ' 修正说明:由于iis6的Content-Length 头信息中包含的请求长度超过了 AspMaxRequestEntityAllowed 的值(默认200K), IIS 将返回一个 403 错误信息. - ' 直接导致在iis6下调试FCKeditor上传功能时,一旦文件超过200K,上传文件时文件管理器失去响应,受此影响,文件的快速上传功能也存在在缺陷。 - ' 在参考 宝玉 的 Asp无组件上传带进度条 演示程序后作出如下修改,以修正在iis6下的错误。 - - Dim nTotalBytes, nPartBytes, ReadBytes - ReadBytes = 0 - nTotalBytes = Request.TotalBytes - '循环分块读取 - Do While ReadBytes < nTotalBytes - '分块读取 - nPartBytes = 64 * 1024 '分成每块64k - If nPartBytes + ReadBytes > nTotalBytes Then - nPartBytes = nTotalBytes - ReadBytes - End If - oSourceData.Write Request.BinaryRead(nPartBytes) - ReadBytes = ReadBytes + nPartBytes - Loop - '********************************************** - oSourceData.Position = 0 - - Dim oTotalData, oFormStream, sFormHeader, sFormName, bCrLf, nBoundLen, nFormStart, nFormEnd, nPosStart, nPosEnd, sBoundary - - oTotalData = oSourceData.Read - bCrLf = ChrB(13) & ChrB(10) - sBoundary = MidB(oTotalData, 1, InStrB(1, oTotalData, bCrLf) - 1) - nBoundLen = LenB(sBoundary) + 2 - nFormStart = nBoundLen - - Set oFormStream = Server.CreateObject("ADODB.Stream") - - Do While (nFormStart + 2) < nTotalSize - nFormEnd = InStrB(nFormStart, oTotalData, bCrLf & bCrLf) + 3 - - With oFormStream - .Type = 1 - .Mode = 3 - .Open - oSourceData.Position = nFormStart - oSourceData.CopyTo oFormStream, nFormEnd - nFormStart - .Position = 0 - .Type = 2 - .CharSet = "UTF-8" - sFormHeader = .ReadText - .Close - End With - - nFormStart = InStrB(nFormEnd, oTotalData, sBoundary) - 1 - nPosStart = InStr(22, sFormHeader, " name=", 1) + 7 - nPosEnd = InStr(nPosStart, sFormHeader, """") - sFormName = Mid(sFormHeader, nPosStart, nPosEnd - nPosStart) - - If InStr(45, sFormHeader, " filename=", 1) > 0 Then - Set File(sFormName) = New NetRube_FileInfo - File(sFormName).FormName = sFormName - File(sFormName).Start = nFormEnd - File(sFormName).Size = nFormStart - nFormEnd - 2 - nPosStart = InStr(nPosEnd, sFormHeader, " filename=", 1) + 11 - nPosEnd = InStr(nPosStart, sFormHeader, """") - File(sFormName).ClientPath = Mid(sFormHeader, nPosStart, nPosEnd - nPosStart) - File(sFormName).Name = Mid(File(sFormName).ClientPath, InStrRev(File(sFormName).ClientPath, "\") + 1) - File(sFormName).Ext = LCase(Mid(File(sFormName).Name, InStrRev(File(sFormName).Name, ".") + 1)) - nPosStart = InStr(nPosEnd, sFormHeader, "Content-Type: ", 1) + 14 - nPosEnd = InStr(nPosStart, sFormHeader, vbCr) - File(sFormName).MIME = Mid(sFormHeader, nPosStart, nPosEnd - nPosStart) - Else - With oFormStream - .Type = 1 - .Mode = 3 - .Open - oSourceData.Position = nFormEnd - oSourceData.CopyTo oFormStream, nFormStart - nFormEnd - 2 - .Position = 0 - .Type = 2 - .CharSet = "UTF-8" - Form(sFormName) = .ReadText - .Close - End With - End If - - nFormStart = nFormStart + nBoundLen - Loop - - oTotalData = "" - Set oFormStream = Nothing - End Sub - - Public Sub SaveAs(sItem, sFileName) - If File(sItem).Size < 1 Then - nErr = 2 - Exit Sub - End If - - If Not IsAllowed(File(sItem).Ext) Then - nErr = 4 - Exit Sub - End If - - If InStr( LCase( sFileName ), "::$data" ) > 0 Then - nErr = 4 - Exit Sub - End If - - Dim sFileExt, iFileSize - sFileExt = File(sItem).Ext - iFileSize = File(sItem).Size - - ' Check XSS. - If Not IsHtmlExtension( sFileExt ) Then - ' Calculate the size of data to load (max 1Kb). - Dim iXSSSize - iXSSSize = iFileSize - - If iXSSSize > 1024 Then - iXSSSize = 1024 - End If - - ' Read the data. - Dim sData - oSourceData.Position = File(sItem).Start - sData = oSourceData.Read( iXSSSize ) ' Byte Array - sData = ByteArray2Text( sData ) ' String - - ' Sniff HTML data. - If SniffHtml( sData ) Then - nErr = 4 - Exit Sub - End If - End If - - Dim oFileStream - Set oFileStream = Server.CreateObject("ADODB.Stream") - With oFileStream - .Type = 1 - .Mode = 3 - .Open - oSourceData.Position = File(sItem).Start - oSourceData.CopyTo oFileStream, File(sItem).Size - .Position = 0 - .SaveToFile sFileName, 2 - .Close - End With - Set oFileStream = Nothing - End Sub - - Private Function IsAllowed(sExt) - Dim oRE - Set oRE = New RegExp - oRE.IgnoreCase = True - oRE.Global = True - - If sDenied = "" Then - oRE.Pattern = sAllowed - IsAllowed = (sAllowed = "") Or oRE.Test(sExt) - Else - oRE.Pattern = sDenied - IsAllowed = Not oRE.Test(sExt) - End If - - Set oRE = Nothing - End Function - - Private Function IsHtmlExtension( sExt ) - If sHtmlExtensions = "" Then - Exit Function - End If - - Dim oRE - Set oRE = New RegExp - oRE.IgnoreCase = True - oRE.Global = True - oRE.Pattern = sHtmlExtensions - - IsHtmlExtension = oRE.Test(sExt) - - Set oRE = Nothing - End Function - - Private Function SniffHtml( sData ) - - Dim oRE - Set oRE = New RegExp - oRE.IgnoreCase = True - oRE.Global = True - - Dim aPatterns - aPatterns = Array( " diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/commands.asp b/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/commands.asp deleted file mode 100644 index eba89a88f12..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/commands.asp +++ /dev/null @@ -1,202 +0,0 @@ -<% - ' FCKeditor - The text editor for Internet - http://www.fckeditor.net - ' Copyright (C) 2003-2010 Frederico Caldeira Knabben - ' - ' == BEGIN LICENSE == - ' - ' Licensed under the terms of any of the following licenses at your - ' choice: - ' - ' - GNU General Public License Version 2 or later (the "GPL") - ' http://www.gnu.org/licenses/gpl.html - ' - ' - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - ' http://www.gnu.org/licenses/lgpl.html - ' - ' - Mozilla Public License Version 1.1 or later (the "MPL") - ' http://www.mozilla.org/MPL/MPL-1.1.html - ' - ' == END LICENSE == - ' - ' This file include the functions that handle the Command requests - ' in the ASP Connector. -%> -<% -Sub GetFolders( resourceType, currentFolder ) - ' Map the virtual path to the local server path. - Dim sServerDir - sServerDir = ServerMapFolder( resourceType, currentFolder, "GetFolders" ) - - ' Open the "Folders" node. - Response.Write "" - - Dim oFSO, oCurrentFolder, oFolders, oFolder - Set oFSO = Server.CreateObject( "Scripting.FileSystemObject" ) - if not (oFSO.FolderExists( sServerDir ) ) then - Set oFSO = Nothing - SendError 102, currentFolder - end if - - Set oCurrentFolder = oFSO.GetFolder( sServerDir ) - Set oFolders = oCurrentFolder.SubFolders - - For Each oFolder in oFolders - Response.Write "" - Next - - Set oFSO = Nothing - - ' Close the "Folders" node. - Response.Write "" -End Sub - -Sub GetFoldersAndFiles( resourceType, currentFolder ) - ' Map the virtual path to the local server path. - Dim sServerDir - sServerDir = ServerMapFolder( resourceType, currentFolder, "GetFoldersAndFiles" ) - - Dim oFSO, oCurrentFolder, oFolders, oFolder, oFiles, oFile - Set oFSO = Server.CreateObject( "Scripting.FileSystemObject" ) - if not (oFSO.FolderExists( sServerDir ) ) then - Set oFSO = Nothing - SendError 102, currentFolder - end if - - Set oCurrentFolder = oFSO.GetFolder( sServerDir ) - Set oFolders = oCurrentFolder.SubFolders - Set oFiles = oCurrentFolder.Files - - ' Open the "Folders" node. - Response.Write "" - - For Each oFolder in oFolders - Response.Write "" - Next - - ' Close the "Folders" node. - Response.Write "" - - ' Open the "Files" node. - Response.Write "" - - For Each oFile in oFiles - Dim iFileSize - iFileSize = Round( oFile.size / 1024 ) - If ( iFileSize < 1 AND oFile.size <> 0 ) Then iFileSize = 1 - - Response.Write "" - Next - - ' Close the "Files" node. - Response.Write "" -End Sub - -Sub CreateFolder( resourceType, currentFolder ) - Dim sErrorNumber - - Dim sNewFolderName - sNewFolderName = Request.QueryString( "NewFolderName" ) - sNewFolderName = SanitizeFolderName( sNewFolderName ) - - If ( sNewFolderName = "" OR InStr( 1, sNewFolderName, ".." ) > 0 ) Then - sErrorNumber = "102" - Else - ' Map the virtual path to the local server path of the current folder. - Dim sServerDir - sServerDir = ServerMapFolder( resourceType, CombineLocalPaths(currentFolder, sNewFolderName), "CreateFolder" ) - - On Error Resume Next - - CreateServerFolder sServerDir - - Dim iErrNumber, sErrDescription - iErrNumber = err.number - sErrDescription = err.Description - - On Error Goto 0 - - Select Case iErrNumber - Case 0 - sErrorNumber = "0" - Case 52 - sErrorNumber = "102" ' Invalid Folder Name. - Case 70 - sErrorNumber = "103" ' Security Error. - Case 76 - sErrorNumber = "102" ' Path too long. - Case Else - sErrorNumber = "110" - End Select - End If - - ' Create the "Error" node. - Response.Write "" -End Sub - -Sub FileUpload( resourceType, currentFolder, sCommand ) - Dim oUploader - Set oUploader = New NetRube_Upload - oUploader.MaxSize = 0 - oUploader.Allowed = ConfigAllowedExtensions.Item( resourceType ) - oUploader.Denied = ConfigDeniedExtensions.Item( resourceType ) - oUploader.HtmlExtensions = ConfigHtmlExtensions - oUploader.GetData - - Dim sErrorNumber - sErrorNumber = "0" - - Dim sFileName, sOriginalFileName, sExtension - sFileName = "" - - If oUploader.ErrNum > 0 Then - sErrorNumber = "202" - Else - ' Map the virtual path to the local server path. - Dim sServerDir - sServerDir = ServerMapFolder( resourceType, currentFolder, sCommand ) - - Dim oFSO - Set oFSO = Server.CreateObject( "Scripting.FileSystemObject" ) - if not (oFSO.FolderExists( sServerDir ) ) then - sErrorNumber = "102" - else - ' Get the uploaded file name. - sFileName = oUploader.File( "NewFile" ).Name - sExtension = oUploader.File( "NewFile" ).Ext - sFileName = SanitizeFileName( sFileName ) - sOriginalFileName = sFileName - - Dim iCounter - iCounter = 0 - - Do While ( True ) - Dim sFilePath - sFilePath = CombineLocalPaths(sServerDir, sFileName) - - If ( oFSO.FileExists( sFilePath ) ) Then - iCounter = iCounter + 1 - sFileName = RemoveExtension( sOriginalFileName ) & "(" & iCounter & ")." & sExtension - sErrorNumber = "201" - Else - oUploader.SaveAs "NewFile", sFilePath - If oUploader.ErrNum > 0 Then sErrorNumber = "202" - Exit Do - End If - Loop - end if - End If - - Set oUploader = Nothing - - dim sFileUrl - sFileUrl = CombinePaths( GetResourceTypePath( resourceType, sCommand ) , currentFolder ) - sFileUrl = CombinePaths( sFileUrl, sFileName ) - - If ( sErrorNumber = "0" or sErrorNumber = "201" ) then - SendUploadResults sErrorNumber, sFileUrl, sFileName, "" - Else - SendUploadResults sErrorNumber, "", "", "" - End If -End Sub - -%> diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/config.asp b/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/config.asp deleted file mode 100644 index 8ce4f2a0b3e..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/config.asp +++ /dev/null @@ -1,128 +0,0 @@ -<% - ' FCKeditor - The text editor for Internet - http://www.fckeditor.net - ' Copyright (C) 2003-2010 Frederico Caldeira Knabben - ' - ' == BEGIN LICENSE == - ' - ' Licensed under the terms of any of the following licenses at your - ' choice: - ' - ' - GNU General Public License Version 2 or later (the "GPL") - ' http://www.gnu.org/licenses/gpl.html - ' - ' - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - ' http://www.gnu.org/licenses/lgpl.html - ' - ' - Mozilla Public License Version 1.1 or later (the "MPL") - ' http://www.mozilla.org/MPL/MPL-1.1.html - ' - ' == END LICENSE == - ' - ' Configuration file for the File Manager Connector for ASP. -%> -<% - -' SECURITY: You must explicitly enable this "connector" (set it to "True"). -' WARNING: don't just set "ConfigIsEnabled = true", you must be sure that only -' authenticated users can access this file or use some kind of session checking. -Dim ConfigIsEnabled -ConfigIsEnabled = False - -' Path to user files relative to the document root. -' This setting is preserved only for backward compatibility. -' You should look at the settings for each resource type to get the full potential -Dim ConfigUserFilesPath -ConfigUserFilesPath = "/userfiles/" - -' Due to security issues with Apache modules, it is recommended to leave the -' following setting enabled. -Dim ConfigForceSingleExtension -ConfigForceSingleExtension = true - -' What the user can do with this connector -Dim ConfigAllowedCommands -ConfigAllowedCommands = "QuickUpload|FileUpload|GetFolders|GetFoldersAndFiles|CreateFolder" - -' Allowed Resource Types -Dim ConfigAllowedTypes -ConfigAllowedTypes = "File|Image|Flash|Media" - -' For security, HTML is allowed in the first Kb of data for files having the -' following extensions only. -Dim ConfigHtmlExtensions -ConfigHtmlExtensions = "html|htm|xml|xsd|txt|js" -' -' Configuration settings for each Resource Type -' -' - AllowedExtensions: the possible extensions that can be allowed. -' If it is empty then any file type can be uploaded. -' -' - DeniedExtensions: The extensions that won't be allowed. -' If it is empty then no restrictions are done here. -' -' For a file to be uploaded it has to fulfill both the AllowedExtensions -' and DeniedExtensions (that's it: not being denied) conditions. -' -' - FileTypesPath: the virtual folder relative to the document root where -' these resources will be located. -' Attention: It must start and end with a slash: '/' -' -' - FileTypesAbsolutePath: the physical path to the above folder. It must be -' an absolute path. -' If it's an empty string then it will be autocalculated. -' Useful if you are using a virtual directory, symbolic link or alias. -' Examples: 'C:\\MySite\\userfiles\\' or '/root/mysite/userfiles/'. -' Attention: The above 'FileTypesPath' must point to the same directory. -' Attention: It must end with a slash: '/' -' -' - QuickUploadPath: the virtual folder relative to the document root where -' these resources will be uploaded using the Upload tab in the resources -' dialogs. -' Attention: It must start and end with a slash: '/' -' -' - QuickUploadAbsolutePath: the physical path to the above folder. It must be -' an absolute path. -' If it's an empty string then it will be autocalculated. -' Useful if you are using a virtual directory, symbolic link or alias. -' Examples: 'C:\\MySite\\userfiles\\' or '/root/mysite/userfiles/'. -' Attention: The above 'QuickUploadPath' must point to the same directory. -' Attention: It must end with a slash: '/' -' - -Dim ConfigAllowedExtensions, ConfigDeniedExtensions, ConfigFileTypesPath, ConfigFileTypesAbsolutePath, ConfigQuickUploadPath, ConfigQuickUploadAbsolutePath -Set ConfigAllowedExtensions = CreateObject( "Scripting.Dictionary" ) -Set ConfigDeniedExtensions = CreateObject( "Scripting.Dictionary" ) -Set ConfigFileTypesPath = CreateObject( "Scripting.Dictionary" ) -Set ConfigFileTypesAbsolutePath = CreateObject( "Scripting.Dictionary" ) -Set ConfigQuickUploadPath = CreateObject( "Scripting.Dictionary" ) -Set ConfigQuickUploadAbsolutePath = CreateObject( "Scripting.Dictionary" ) - -ConfigAllowedExtensions.Add "File", "7z|aiff|asf|avi|bmp|csv|doc|fla|flv|gif|gz|gzip|jpeg|jpg|mid|mov|mp3|mp4|mpc|mpeg|mpg|ods|odt|pdf|png|ppt|pxd|qt|ram|rar|rm|rmi|rmvb|rtf|sdc|sitd|swf|sxc|sxw|tar|tgz|tif|tiff|txt|vsd|wav|wma|wmv|xls|xml|zip" -ConfigDeniedExtensions.Add "File", "" -ConfigFileTypesPath.Add "File", ConfigUserFilesPath & "file/" -ConfigFileTypesAbsolutePath.Add "File", "" -ConfigQuickUploadPath.Add "File", ConfigUserFilesPath -ConfigQuickUploadAbsolutePath.Add "File", "" - -ConfigAllowedExtensions.Add "Image", "bmp|gif|jpeg|jpg|png" -ConfigDeniedExtensions.Add "Image", "" -ConfigFileTypesPath.Add "Image", ConfigUserFilesPath & "image/" -ConfigFileTypesAbsolutePath.Add "Image", "" -ConfigQuickUploadPath.Add "Image", ConfigUserFilesPath -ConfigQuickUploadAbsolutePath.Add "Image", "" - -ConfigAllowedExtensions.Add "Flash", "swf|flv" -ConfigDeniedExtensions.Add "Flash", "" -ConfigFileTypesPath.Add "Flash", ConfigUserFilesPath & "flash/" -ConfigFileTypesAbsolutePath.Add "Flash", "" -ConfigQuickUploadPath.Add "Flash", ConfigUserFilesPath -ConfigQuickUploadAbsolutePath.Add "Flash", "" - -ConfigAllowedExtensions.Add "Media", "aiff|asf|avi|bmp|fla|flv|gif|jpeg|jpg|mid|mov|mp3|mp4|mpc|mpeg|mpg|png|qt|ram|rm|rmi|rmvb|swf|tif|tiff|wav|wma|wmv" -ConfigDeniedExtensions.Add "Media", "" -ConfigFileTypesPath.Add "Media", ConfigUserFilesPath & "media/" -ConfigFileTypesAbsolutePath.Add "Media", "" -ConfigQuickUploadPath.Add "Media", ConfigUserFilesPath -ConfigQuickUploadAbsolutePath.Add "Media", "" - -%> diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/connector.asp b/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/connector.asp deleted file mode 100644 index 4c44bda06da..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/connector.asp +++ /dev/null @@ -1,88 +0,0 @@ -<%@ CodePage=65001 Language="VBScript"%> -<% -Option Explicit -Response.Buffer = True -%> -<% - ' FCKeditor - The text editor for Internet - http://www.fckeditor.net - ' Copyright (C) 2003-2010 Frederico Caldeira Knabben - ' - ' == BEGIN LICENSE == - ' - ' Licensed under the terms of any of the following licenses at your - ' choice: - ' - ' - GNU General Public License Version 2 or later (the "GPL") - ' http://www.gnu.org/licenses/gpl.html - ' - ' - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - ' http://www.gnu.org/licenses/lgpl.html - ' - ' - Mozilla Public License Version 1.1 or later (the "MPL") - ' http://www.mozilla.org/MPL/MPL-1.1.html - ' - ' == END LICENSE == - ' - ' This is the File Manager Connector for ASP. -%> - - - - - - -<% - -If ( ConfigIsEnabled = False ) Then - SendError 1, "This connector is disabled. Please check the ""editor/filemanager/connectors/asp/config.asp"" file" -End If - -DoResponse - -Sub DoResponse() - Dim sCommand, sResourceType, sCurrentFolder - - ' Get the main request information. - sCommand = Request.QueryString("Command") - - sResourceType = Request.QueryString("Type") - If ( sResourceType = "" ) Then sResourceType = "File" - - sCurrentFolder = GetCurrentFolder() - - ' Check if it is an allowed command - if ( Not IsAllowedCommand( sCommand ) ) then - SendError 1, "The """ & sCommand & """ command isn't allowed" - end if - - ' Check if it is an allowed resource type. - if ( Not IsAllowedType( sResourceType ) ) Then - SendError 1, "Invalid type specified" - end if - - ' File Upload doesn't have to Return XML, so it must be intercepted before anything. - If ( sCommand = "FileUpload" ) Then - FileUpload sResourceType, sCurrentFolder, sCommand - Exit Sub - End If - - SetXmlHeaders - - CreateXmlHeader sCommand, sResourceType, sCurrentFolder, GetUrlFromPath( sResourceType, sCurrentFolder, sCommand) - - ' Execute the required command. - Select Case sCommand - Case "GetFolders" - GetFolders sResourceType, sCurrentFolder - Case "GetFoldersAndFiles" - GetFoldersAndFiles sResourceType, sCurrentFolder - Case "CreateFolder" - CreateFolder sResourceType, sCurrentFolder - End Select - - CreateXmlFooter - - Response.End -End Sub - -%> diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/io.asp b/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/io.asp deleted file mode 100644 index 8f2f3f09fdf..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/io.asp +++ /dev/null @@ -1,247 +0,0 @@ -<% - ' FCKeditor - The text editor for Internet - http://www.fckeditor.net - ' Copyright (C) 2003-2010 Frederico Caldeira Knabben - ' - ' == BEGIN LICENSE == - ' - ' Licensed under the terms of any of the following licenses at your - ' choice: - ' - ' - GNU General Public License Version 2 or later (the "GPL") - ' http://www.gnu.org/licenses/gpl.html - ' - ' - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - ' http://www.gnu.org/licenses/lgpl.html - ' - ' - Mozilla Public License Version 1.1 or later (the "MPL") - ' http://www.mozilla.org/MPL/MPL-1.1.html - ' - ' == END LICENSE == - ' - ' This file include IO specific functions used by the ASP Connector. -%> -<% -function CombinePaths( sBasePath, sFolder) - sFolder = replace(sFolder, "\", "/") - CombinePaths = RemoveFromEnd( sBasePath, "/" ) & "/" & RemoveFromStart( sFolder, "/" ) -end function - -function CombineLocalPaths( sBasePath, sFolder) - sFolder = replace(sFolder, "/", "\") - ' The RemoveFrom* functions use RegExp, so we must escape the \ - CombineLocalPaths = RemoveFromEnd( sBasePath, "\\" ) & "\" & RemoveFromStart( sFolder, "\\" ) -end function - -Function GetResourceTypePath( resourceType, sCommand ) - if ( sCommand = "QuickUpload") then - GetResourceTypePath = ConfigQuickUploadPath.Item( resourceType ) - else - GetResourceTypePath = ConfigFileTypesPath.Item( resourceType ) - end if -end Function - -Function GetResourceTypeDirectory( resourceType, sCommand ) - if ( sCommand = "QuickUpload") then - - if ( ConfigQuickUploadAbsolutePath.Item( resourceType ) <> "" ) then - GetResourceTypeDirectory = ConfigQuickUploadAbsolutePath.Item( resourceType ) - else - ' Map the "UserFiles" path to a local directory. - GetResourceTypeDirectory = Server.MapPath( ConfigQuickUploadPath.Item( resourceType ) ) - end if - else - if ( ConfigFileTypesAbsolutePath.Item( resourceType ) <> "" ) then - GetResourceTypeDirectory = ConfigFileTypesAbsolutePath.Item( resourceType ) - else - ' Map the "UserFiles" path to a local directory. - GetResourceTypeDirectory = Server.MapPath( ConfigFileTypesPath.Item( resourceType ) ) - end if - end if -end Function - -Function GetUrlFromPath( resourceType, folderPath, sCommand ) - GetUrlFromPath = CombinePaths( GetResourceTypePath( resourceType, sCommand ), folderPath ) -End Function - -Function RemoveExtension( fileName ) - RemoveExtension = Left( fileName, InStrRev( fileName, "." ) - 1 ) -End Function - -Function ServerMapFolder( resourceType, folderPath, sCommand ) - Dim sResourceTypePath - ' Get the resource type directory. - sResourceTypePath = GetResourceTypeDirectory( resourceType, sCommand ) - - ' Ensure that the directory exists. - CreateServerFolder sResourceTypePath - - ' Return the resource type directory combined with the required path. - ServerMapFolder = CombineLocalPaths( sResourceTypePath, folderPath ) -End Function - -Sub CreateServerFolder( folderPath ) - Dim oFSO - Set oFSO = Server.CreateObject( "Scripting.FileSystemObject" ) - - Dim sParent - sParent = oFSO.GetParentFolderName( folderPath ) - - ' If folderPath is a network path (\\server\folder\) then sParent is an empty string. - ' Get out. - if (sParent = "") then exit sub - - ' Check if the parent exists, or create it. - If ( NOT oFSO.FolderExists( sParent ) ) Then CreateServerFolder( sParent ) - - If ( oFSO.FolderExists( folderPath ) = False ) Then - On Error resume next - oFSO.CreateFolder( folderPath ) - - if err.number<>0 then - dim sErrorNumber - Dim iErrNumber, sErrDescription - iErrNumber = err.number - sErrDescription = err.Description - - On Error Goto 0 - - Select Case iErrNumber - Case 52 - sErrorNumber = "102" ' Invalid Folder Name. - Case 70 - sErrorNumber = "103" ' Security Error. - Case 76 - sErrorNumber = "102" ' Path too long. - Case Else - sErrorNumber = "110" - End Select - - SendError sErrorNumber, "CreateServerFolder(" & folderPath & ") : " & sErrDescription - end if - - End If - - Set oFSO = Nothing -End Sub - -Function IsAllowedExt( extension, resourceType ) - Dim oRE - Set oRE = New RegExp - oRE.IgnoreCase = True - oRE.Global = True - - Dim sAllowed, sDenied - sAllowed = ConfigAllowedExtensions.Item( resourceType ) - sDenied = ConfigDeniedExtensions.Item( resourceType ) - - IsAllowedExt = True - - If sDenied <> "" Then - oRE.Pattern = sDenied - IsAllowedExt = Not oRE.Test( extension ) - End If - - If IsAllowedExt And sAllowed <> "" Then - oRE.Pattern = sAllowed - IsAllowedExt = oRE.Test( extension ) - End If - - Set oRE = Nothing -End Function - -Function IsAllowedType( resourceType ) - Dim oRE - Set oRE = New RegExp - oRE.IgnoreCase = False - oRE.Global = True - oRE.Pattern = "^(" & ConfigAllowedTypes & ")$" - - IsAllowedType = oRE.Test( resourceType ) - - Set oRE = Nothing -End Function - -Function IsAllowedCommand( sCommand ) - Dim oRE - Set oRE = New RegExp - oRE.IgnoreCase = True - oRE.Global = True - oRE.Pattern = "^(" & ConfigAllowedCommands & ")$" - - IsAllowedCommand = oRE.Test( sCommand ) - - Set oRE = Nothing -End Function - -function GetCurrentFolder() - dim sCurrentFolder - dim oRegex - - sCurrentFolder = Request.QueryString("CurrentFolder") - If ( sCurrentFolder = "" ) Then sCurrentFolder = "/" - - ' Check the current folder syntax (must begin and start with a slash). - If ( Right( sCurrentFolder, 1 ) <> "/" ) Then sCurrentFolder = sCurrentFolder & "/" - If ( Left( sCurrentFolder, 1 ) <> "/" ) Then sCurrentFolder = "/" & sCurrentFolder - - ' Check for invalid folder paths (..) - If ( InStr( 1, sCurrentFolder, ".." ) <> 0 OR InStr( 1, sCurrentFolder, "\" ) <> 0) Then - SendError 102, "" - End If - - Set oRegex = New RegExp - oRegex.Global = True - oRegex.Pattern = "(/\.)|(//)|([\\:\*\?\""\<\>\|]|[\u0000-\u001F]|\u007F)" - - if (oRegex.Test(sCurrentFolder)) Then - SendError 102, "" - End If - - GetCurrentFolder = sCurrentFolder -end function - -' Do a cleanup of the folder name to avoid possible problems -function SanitizeFolderName( sNewFolderName ) - Dim oRegex - Set oRegex = New RegExp - oRegex.Global = True - -' remove . \ / | : ? * " < > and control characters - oRegex.Pattern = "(\.|\\|\/|\||:|\?|\*|""|\<|\>|[\u0000-\u001F]|\u007F)" - SanitizeFolderName = oRegex.Replace( sNewFolderName, "_" ) - - Set oRegex = Nothing -end function - -' Do a cleanup of the file name to avoid possible problems -function SanitizeFileName( sNewFileName ) - Dim oRegex - Set oRegex = New RegExp - oRegex.Global = True - - if ( ConfigForceSingleExtension = True ) then - oRegex.Pattern = "\.(?![^.]*$)" - sNewFileName = oRegex.Replace( sNewFileName, "_" ) - end if - -' remove \ / | : ? * " < > and control characters - oRegex.Pattern = "(\\|\/|\||:|\?|\*|""|\<|\>|[\u0000-\u001F]|\u007F)" - SanitizeFileName = oRegex.Replace( sNewFileName, "_" ) - - Set oRegex = Nothing -end function - -' This is the function that sends the results of the uploading process. -Sub SendUploadResults( errorNumber, fileUrl, fileName, customMsg ) - Response.Clear - Response.Write "" - Response.End -End Sub - -%> diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/upload.asp b/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/upload.asp deleted file mode 100644 index 05ca3c4beb5..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/upload.asp +++ /dev/null @@ -1,65 +0,0 @@ -<%@ CodePage=65001 Language="VBScript"%> -<% -Option Explicit -Response.Buffer = True -%> -<% - ' FCKeditor - The text editor for Internet - http://www.fckeditor.net - ' Copyright (C) 2003-2010 Frederico Caldeira Knabben - ' - ' == BEGIN LICENSE == - ' - ' Licensed under the terms of any of the following licenses at your - ' choice: - ' - ' - GNU General Public License Version 2 or later (the "GPL") - ' http://www.gnu.org/licenses/gpl.html - ' - ' - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - ' http://www.gnu.org/licenses/lgpl.html - ' - ' - Mozilla Public License Version 1.1 or later (the "MPL") - ' http://www.mozilla.org/MPL/MPL-1.1.html - ' - ' == END LICENSE == - ' - ' This is the "File Uploader" for ASP. -%> - - - - - -<% - -Sub SendError( number, text ) - SendUploadResults number, "", "", text -End Sub - -' Check if this uploader has been enabled. -If ( ConfigIsEnabled = False ) Then - SendUploadResults "1", "", "", "This file uploader is disabled. Please check the ""editor/filemanager/connectors/asp/config.asp"" file" -End If - - Dim sCommand, sResourceType, sCurrentFolder - - sCommand = "QuickUpload" - - sResourceType = Request.QueryString("Type") - If ( sResourceType = "" ) Then sResourceType = "File" - - sCurrentFolder = "/" - - ' Is Upload enabled? - if ( Not IsAllowedCommand( sCommand ) ) then - SendUploadResults "1", "", "", "The """ & sCommand & """ command isn't allowed" - end if - - ' Check if it is an allowed resource type. - if ( Not IsAllowedType( sResourceType ) ) Then - SendUploadResults "1", "", "", "The " & sResourceType & " resource type isn't allowed" - end if - - FileUpload sResourceType, sCurrentFolder, sCommand - -%> diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/util.asp b/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/util.asp deleted file mode 100644 index 7c9190827c9..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/asp/util.asp +++ /dev/null @@ -1,55 +0,0 @@ -<% - ' FCKeditor - The text editor for Internet - http://www.fckeditor.net - ' Copyright (C) 2003-2010 Frederico Caldeira Knabben - ' - ' == BEGIN LICENSE == - ' - ' Licensed under the terms of any of the following licenses at your - ' choice: - ' - ' - GNU General Public License Version 2 or later (the "GPL") - ' http://www.gnu.org/licenses/gpl.html - ' - ' - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - ' http://www.gnu.org/licenses/lgpl.html - ' - ' - Mozilla Public License Version 1.1 or later (the "MPL") - ' http://www.mozilla.org/MPL/MPL-1.1.html - ' - ' == END LICENSE == - ' - ' This file include generic functions used by the ASP Connector. -%> -<% -Function RemoveFromStart( sourceString, charToRemove ) - Dim oRegex - Set oRegex = New RegExp - oRegex.Pattern = "^" & charToRemove & "+" - - RemoveFromStart = oRegex.Replace( sourceString, "" ) -End Function - -Function RemoveFromEnd( sourceString, charToRemove ) - Dim oRegex - Set oRegex = New RegExp - oRegex.Pattern = charToRemove & "+$" - - RemoveFromEnd = oRegex.Replace( sourceString, "" ) -End Function - -Function ConvertToXmlAttribute( value ) - ConvertToXmlAttribute = Replace( value, "&", "&" ) -End Function - -Function InArray( value, sourceArray ) - Dim i - For i = 0 to UBound( sourceArray ) - If sourceArray(i) = value Then - InArray = True - Exit Function - End If - Next - InArray = False -End Function - -%> diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/config.ascx b/htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/config.ascx deleted file mode 100644 index 23ee5daa81a..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/config.ascx +++ /dev/null @@ -1,98 +0,0 @@ -<%@ Control Language="C#" EnableViewState="false" AutoEventWireup="false" Inherits="FredCK.FCKeditorV2.FileBrowser.Config" %> -<%-- - * FCKeditor - The text editor for Internet - http://www.fckeditor.net - * Copyright (C) 2003-2010 Frederico Caldeira Knabben - * - * == BEGIN LICENSE == - * - * Licensed under the terms of any of the following licenses at your - * choice: - * - * - GNU General Public License Version 2 or later (the "GPL") - * http://www.gnu.org/licenses/gpl.html - * - * - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - * http://www.gnu.org/licenses/lgpl.html - * - * - Mozilla Public License Version 1.1 or later (the "MPL") - * http://www.mozilla.org/MPL/MPL-1.1.html - * - * == END LICENSE == - * - * Configuration file for the File Browser Connector for ASP.NET. ---%> - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/connector.aspx b/htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/connector.aspx deleted file mode 100644 index 896359d7011..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/connector.aspx +++ /dev/null @@ -1,32 +0,0 @@ -<%@ Page Language="c#" Trace="false" Inherits="FredCK.FCKeditorV2.FileBrowser.Connector" AutoEventWireup="false" %> -<%@ Register Src="config.ascx" TagName="Config" TagPrefix="FCKeditor" %> -<%-- - * FCKeditor - The text editor for Internet - http://www.fckeditor.net - * Copyright (C) 2003-2010 Frederico Caldeira Knabben - * - * == BEGIN LICENSE == - * - * Licensed under the terms of any of the following licenses at your - * choice: - * - * - GNU General Public License Version 2 or later (the "GPL") - * http://www.gnu.org/licenses/gpl.html - * - * - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - * http://www.gnu.org/licenses/lgpl.html - * - * - Mozilla Public License Version 1.1 or later (the "MPL") - * http://www.mozilla.org/MPL/MPL-1.1.html - * - * == END LICENSE == - * - * This is the File Browser Connector for ASP.NET. - * - * The code of this page if included in the FCKeditor.Net package, - * in the FredCK.FCKeditorV2.dll assembly file. So to use it you must - * include that DLL in your "bin" directory. - * - * To download the FCKeditor.Net package, go to our official web site: - * http://www.fckeditor.net ---%> - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/upload.aspx b/htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/upload.aspx deleted file mode 100644 index 37898b0aabb..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/aspx/upload.aspx +++ /dev/null @@ -1,32 +0,0 @@ -<%@ Page Language="c#" Trace="false" Inherits="FredCK.FCKeditorV2.FileBrowser.Uploader" AutoEventWireup="false" %> -<%@ Register Src="config.ascx" TagName="Config" TagPrefix="FCKeditor" %> -<%-- - * FCKeditor - The text editor for Internet - http://www.fckeditor.net - * Copyright (C) 2003-2010 Frederico Caldeira Knabben - * - * == BEGIN LICENSE == - * - * Licensed under the terms of any of the following licenses at your - * choice: - * - * - GNU General Public License Version 2 or later (the "GPL") - * http://www.gnu.org/licenses/gpl.html - * - * - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - * http://www.gnu.org/licenses/lgpl.html - * - * - Mozilla Public License Version 1.1 or later (the "MPL") - * http://www.mozilla.org/MPL/MPL-1.1.html - * - * == END LICENSE == - * - * This is the Uploader for ASP.NET. - * - * The code of this page if included in the FCKeditor.Net package, - * in the FredCK.FCKeditorV2.dll assemblyfile. So to use it you must - * include that DLL in your "bin" directory. - * - * To download the FCKeditor.Net package, go to our official web site: - * http://www.fckeditor.net ---%> - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/ImageObject.cfc b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/ImageObject.cfc deleted file mode 100644 index b9b919c7704..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/ImageObject.cfc +++ /dev/null @@ -1,273 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf5_connector.cfm b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf5_connector.cfm deleted file mode 100644 index b1769968d36..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf5_connector.cfm +++ /dev/null @@ -1,336 +0,0 @@ - - - - - - - - - - - - - - - - - - userFilesPath = config.userFilesPath; - - if ( userFilesPath eq "" ) - { - userFilesPath = "/userfiles/"; - } - - // make sure the user files path is correctly formatted - userFilesPath = replace(userFilesPath, "\", "/", "ALL"); - userFilesPath = replace(userFilesPath, '//', '/', 'ALL'); - if ( right(userFilesPath,1) NEQ "/" ) - { - userFilesPath = userFilesPath & "/"; - } - if ( left(userFilesPath,1) NEQ "/" ) - { - userFilesPath = "/" & userFilesPath; - } - - // make sure the current folder is correctly formatted - url.currentFolder = replace(url.currentFolder, "\", "/", "ALL"); - url.currentFolder = replace(url.currentFolder, '//', '/', 'ALL'); - if ( right(url.currentFolder,1) neq "/" ) - { - url.currentFolder = url.currentFolder & "/"; - } - if ( left(url.currentFolder,1) neq "/" ) - { - url.currentFolder = "/" & url.currentFolder; - } - - if ( find("/",getBaseTemplatePath()) neq 0 ) - { - fs = "/"; - } - else - { - fs = "\"; - } - - // Get the base physical path to the web root for this application. The code to determine the path automatically assumes that - // the "FCKeditor" directory in the http request path is directly off the web root for the application and that it's not a - // virtual directory or a symbolic link / junction. Use the serverPath config setting to force a physical path if necessary. - if ( len(config.serverPath) ) - { - serverPath = config.serverPath; - - if ( right(serverPath,1) neq fs ) - { - serverPath = serverPath & fs; - } - } - else - { - serverPath = replaceNoCase(getBaseTemplatePath(),replace(cgi.script_name,"/",fs,"all"),"") & replace(userFilesPath,"/",fs,"all"); - } - - rootPath = left( serverPath, Len(serverPath) - Len(userFilesPath) ) ; - xmlContent = ""; // append to this string to build content - invalidName = false; - - - - - - "> - -])', url.currentFolder)> - - - "> - - - - - '> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - "> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - i=1; - folders = ""; - while( i lte qDir.recordCount ) { - if( not compareNoCase( qDir.type[i], "FILE" )) - break; - if( not listFind(".,..", qDir.name[i]) ) - folders = folders & ''; - i=i+1; - } - - xmlContent = xmlContent & '' & folders & ''; - - - - - - - - - - - - i=1; - folders = ""; - files = ""; - while( i lte qDir.recordCount ) { - if( not compareNoCase( qDir.type[i], "DIR" ) and not listFind(".,..", qDir.name[i]) ) { - folders = folders & ''; - } else if( not compareNoCase( qDir.type[i], "FILE" ) ) { - fileSizeKB = round(qDir.size[i] / 1024); - files = files & ''; - } - i=i+1; - } - - xmlContent = xmlContent & '' & folders & ''; - xmlContent = xmlContent & '' & files & ''; - - - - - - - - - - - newFolderName = url.newFolderName; - if( reFind("[^A-Za-z0-9_\-\.]", newFolderName) ) { - // Munge folder name same way as we do the filename - // This means folder names are always US-ASCII so we don't have to worry about CF5 and UTF-8 - newFolderName = reReplace(newFolderName, "[^A-Za-z0-9\-\.]", "_", "all"); - newFolderName = reReplace(newFolderName, "_{2,}", "_", "all"); - newFolderName = reReplace(newFolderName, "([^_]+)_+$", "\1", "all"); - newFolderName = reReplace(newFolderName, "$_([^_]+)$", "\1", "all"); - newFolderName = reReplace(newFolderName, '\.+', "_", "all" ); - } - - - - - - - - - - - - - - - - - - - - - '> - - - - - - - - - - - - xmlHeader = ''; - if (invalidName) { - xmlHeader = xmlHeader & ''; - } - else { - xmlHeader = xmlHeader & ''; - xmlHeader = xmlHeader & ''; - } - xmlFooter = ''; - - - - - - -#xmlHeader##xmlContent##xmlFooter# diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf5_upload.cfm b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf5_upload.cfm deleted file mode 100644 index cbf86df036f..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf5_upload.cfm +++ /dev/null @@ -1,324 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - function SendUploadResults(errorNumber, fileUrl, fileName, customMsg) - { - WriteOutput(''); - } - - - - - - - - - - - - - - - - - - - - - - -])', url.currentFolder)> - - - - - - - userFilesPath = config.userFilesPath; - - if ( userFilesPath eq "" ) { - userFilesPath = "/userfiles/"; - } - - // make sure the user files path is correctly formatted - userFilesPath = replace(userFilesPath, "\", "/", "ALL"); - userFilesPath = replace(userFilesPath, '//', '/', 'ALL'); - if ( right(userFilesPath,1) NEQ "/" ) { - userFilesPath = userFilesPath & "/"; - } - if ( left(userFilesPath,1) NEQ "/" ) { - userFilesPath = "/" & userFilesPath; - } - - // make sure the current folder is correctly formatted - url.currentFolder = replace(url.currentFolder, "\", "/", "ALL"); - url.currentFolder = replace(url.currentFolder, '//', '/', 'ALL'); - if ( right(url.currentFolder,1) neq "/" ) { - url.currentFolder = url.currentFolder & "/"; - } - if ( left(url.currentFolder,1) neq "/" ) { - url.currentFolder = "/" & url.currentFolder; - } - - if (find("/",getBaseTemplatePath())) { - fs = "/"; - } else { - fs = "\"; - } - - // Get the base physical path to the web root for this application. The code to determine the path automatically assumes that - // the "FCKeditor" directory in the http request path is directly off the web root for the application and that it's not a - // virtual directory or a symbolic link / junction. Use the serverPath config setting to force a physical path if necessary. - if ( len(config.serverPath) ) { - serverPath = config.serverPath; - - if ( right(serverPath,1) neq fs ) { - serverPath = serverPath & fs; - } - } else { - serverPath = replaceNoCase(getBaseTemplatePath(),replace(cgi.script_name,"/",fs,"all"),"") & replace(userFilesPath,"/",fs,"all"); - } - - rootPath = left( serverPath, Len(serverPath) - Len(userFilesPath) ) ; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - errorNumber = 0; - fileName = cffile.ClientFileName ; - fileExt = cffile.ServerFileExt ; - fileExisted = false ; - - // munge filename for html download. Only a-z, 0-9, _, - and . are allowed - if( reFind("[^A-Za-z0-9_\-\.]", fileName) ) { - fileName = reReplace(fileName, "[^A-Za-z0-9\-\.]", "_", "ALL"); - fileName = reReplace(fileName, "_{2,}", "_", "ALL"); - fileName = reReplace(fileName, "([^_]+)_+$", "\1", "ALL"); - fileName = reReplace(fileName, "$_([^_]+)$", "\1", "ALL"); - } - - // remove additional dots from file name - if( isDefined("Config.ForceSingleExtension") and Config.ForceSingleExtension ) - fileName = replace( fileName, '.', "_", "all" ) ; - - // When the original filename already exists, add numbers (0), (1), (2), ... at the end of the filename. - counter = 0; - tmpFileName = fileName; - while( fileExists("#currentFolderPath##fileName#.#fileExt#") ) { - fileExisted = true ; - counter = counter + 1 ; - fileName = tmpFileName & '(#counter#)' ; - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_basexml.cfm b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_basexml.cfm deleted file mode 100644 index 0b67e17f488..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_basexml.cfm +++ /dev/null @@ -1,72 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_commands.cfm b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_commands.cfm deleted file mode 100644 index ec126537ae6..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_commands.cfm +++ /dev/null @@ -1,240 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - sFileExt = GetExtension( sFileName ) ; - sFilePart = RemoveExtension( sFileName ); - while( fileExists( sServerDir & sFileName ) ) - { - counter = counter + 1; - sFileName = sFilePart & '(#counter#).' & CFFILE.ClientFileExt; - errorNumber = 201; - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - while( i lte qDir.recordCount ) - { - if( compareNoCase( qDir.type[i], "FILE" ) and not listFind( ".,..", qDir.name[i] ) ) - { - folders = folders & '' ; - } - i = i + 1; - } - - #folders# - - - - - - - - - - - - - - - - while( i lte qDir.recordCount ) - { - if( not compareNoCase( qDir.type[i], "DIR" ) and not listFind( ".,..", qDir.name[i] ) ) - { - folders = folders & '' ; - } - else if( not compareNoCase( qDir.type[i], "FILE" ) ) - { - fileSizeKB = round(qDir.size[i] / 1024) ; - files = files & '' ; - } - i = i + 1 ; - } - - #folders# - #files# - - - - - - - - - - - - - - - - sNewFolderName = SanitizeFolderName( sNewFolderName ) ; - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_connector.cfm b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_connector.cfm deleted file mode 100644 index fda24221319..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_connector.cfm +++ /dev/null @@ -1,89 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_io.cfm b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_io.cfm deleted file mode 100644 index 3ba6bc29817..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_io.cfm +++ /dev/null @@ -1,299 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ])', sCurrentFolder)> - - - - - - - - - - - - - - - - +|[[:cntrl:]]+', "_", "all" )> - - - - - - - - - - var chunk = ""; - var fileReaderClass = ""; - var fileReader = ""; - var file = ""; - var done = false; - var counter = 0; - var byteArray = ""; - - if( not fileExists( ARGUMENTS.fileName ) ) - { - return "" ; - } - - if (REQUEST.CFVersion gte 8) - { - file = FileOpen( ARGUMENTS.fileName, "readbinary" ) ; - byteArray = FileRead( file, 1024 ) ; - chunk = toString( toBinary( toBase64( byteArray ) ) ) ; - FileClose( file ) ; - } - else - { - fileReaderClass = createObject("java", "java.io.FileInputStream"); - fileReader = fileReaderClass.init(fileName); - - while(not done) - { - char = fileReader.read(); - counter = counter + 1; - if ( char eq -1 or counter eq ARGUMENTS.bytes) - { - done = true; - } - else - { - chunk = chunk & chr(char) ; - } - } - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +|[[:cntrl:]]+', "_", "all" )> - - - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_upload.cfm b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_upload.cfm deleted file mode 100644 index 53375515006..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_upload.cfm +++ /dev/null @@ -1,71 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_util.cfm b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_util.cfm deleted file mode 100644 index 5d0bc4f6ef1..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/cf_util.cfm +++ /dev/null @@ -1,131 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - > - - - - - - - - - - - - - - - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/config.cfm b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/config.cfm deleted file mode 100644 index 1f5ad20da87..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/config.cfm +++ /dev/null @@ -1,150 +0,0 @@ - - - - - Config = StructNew() ; - - // SECURITY: You must explicitly enable this "connector". (Set enabled to "true") - Config.Enabled = false ; - - // Path to uploaded files relative to the document root. - Config.UserFilesPath = "/userfiles/" ; - - // Use this to force the server path if FCKeditor is not running directly off - // the root of the application or the FCKeditor directory in the URL is a virtual directory - // or a symbolic link / junction - // Example: C:\inetpub\wwwroot\myDocs\ - Config.ServerPath = "" ; - - // Due to security issues with Apache modules, it is recommended to leave the - // following setting enabled. - Config.ForceSingleExtension = true ; - - // Perform additional checks for image files - if set to true, validate image size - // (This feature works in MX 6.0 and above) - Config.SecureImageUploads = true; - - // What the user can do with this connector - Config.ConfigAllowedCommands = "QuickUpload,FileUpload,GetFolders,GetFoldersAndFiles,CreateFolder" ; - - //Allowed Resource Types - Config.ConfigAllowedTypes = "File,Image,Flash,Media" ; - - // For security, HTML is allowed in the first Kb of data for files having the - // following extensions only. - // (This feature works in MX 6.0 and above)) - Config.HtmlExtensions = "html,htm,xml,xsd,txt,js" ; - - //Due to known issues with GetTempDirectory function, it is - //recommended to set this vairiable to a valid directory - //instead of using the GetTempDirectory function - //(used by MX 6.0 and above) - Config.TempDirectory = GetTempDirectory(); - - - - - - - - - - - - - - - - -// Configuration settings for each Resource Type -// -// - AllowedExtensions: the possible extensions that can be allowed. -// If it is empty then any file type can be uploaded. -// - DeniedExtensions: The extensions that won't be allowed. -// If it is empty then no restrictions are done here. -// -// For a file to be uploaded it has to fulfill both the AllowedExtensions -// and DeniedExtensions (that's it: not being denied) conditions. -// -// - FileTypesPath: the virtual folder relative to the document root where -// these resources will be located. -// Attention: It must start and end with a slash: '/' -// -// - FileTypesAbsolutePath: the physical path to the above folder. It must be -// an absolute path. -// If it's an empty string then it will be autocalculated. -// Usefull if you are using a virtual directory, symbolic link or alias. -// Examples: 'C:\\MySite\\userfiles\\' or '/root/mysite/userfiles/'. -// Attention: The above 'FileTypesPath' must point to the same directory. -// Attention: It must end with a slash: '/' -// -// -// - QuickUploadPath: the virtual folder relative to the document root where -// these resources will be uploaded using the Upload tab in the resources -// dialogs. -// Attention: It must start and end with a slash: '/' -// -// - QuickUploadAbsolutePath: the physical path to the above folder. It must be -// an absolute path. -// If it's an empty string then it will be autocalculated. -// Usefull if you are using a virtual directory, symbolic link or alias. -// Examples: 'C:\\MySite\\userfiles\\' or '/root/mysite/userfiles/'. -// Attention: The above 'QuickUploadPath' must point to the same directory. -// Attention: It must end with a slash: '/' - - Config.AllowedExtensions = StructNew() ; - Config.DeniedExtensions = StructNew() ; - Config.FileTypesPath = StructNew() ; - Config.FileTypesAbsolutePath = StructNew() ; - Config.QuickUploadPath = StructNew() ; - Config.QuickUploadAbsolutePath = StructNew() ; - - Config.AllowedExtensions["File"] = "7z,aiff,asf,avi,bmp,csv,doc,fla,flv,gif,gz,gzip,jpeg,jpg,mid,mov,mp3,mp4,mpc,mpeg,mpg,ods,odt,pdf,png,ppt,pxd,qt,ram,rar,rm,rmi,rmvb,rtf,sdc,sitd,swf,sxc,sxw,tar,tgz,tif,tiff,txt,vsd,wav,wma,wmv,xls,xml,zip" ; - Config.DeniedExtensions["File"] = "" ; - Config.FileTypesPath["File"] = Config.UserFilesPath & 'file/' ; - Config.FileTypesAbsolutePath["File"] = iif( Config.ServerPath eq "", de(""), de(Config.ServerPath & 'file/') ) ; - Config.QuickUploadPath["File"] = Config.FileTypesPath["File"] ; - Config.QuickUploadAbsolutePath["File"] = Config.FileTypesAbsolutePath["File"] ; - - Config.AllowedExtensions["Image"] = "bmp,gif,jpeg,jpg,png" ; - Config.DeniedExtensions["Image"] = "" ; - Config.FileTypesPath["Image"] = Config.UserFilesPath & 'image/' ; - Config.FileTypesAbsolutePath["Image"] = iif( Config.ServerPath eq "", de(""), de(Config.ServerPath & 'image/') ) ; - Config.QuickUploadPath["Image"] = Config.FileTypesPath["Image"] ; - Config.QuickUploadAbsolutePath["Image"] = Config.FileTypesAbsolutePath["Image"] ; - - Config.AllowedExtensions["Flash"] = "swf,flv" ; - Config.DeniedExtensions["Flash"] = "" ; - Config.FileTypesPath["Flash"] = Config.UserFilesPath & 'flash/' ; - Config.FileTypesAbsolutePath["Flash"] = iif( Config.ServerPath eq "", de(""), de(Config.ServerPath & 'flash/') ) ; - Config.QuickUploadPath["Flash"] = Config.FileTypesPath["Flash"] ; - Config.QuickUploadAbsolutePath["Flash"] = Config.FileTypesAbsolutePath["Flash"] ; - - Config.AllowedExtensions["Media"] = "aiff,asf,avi,bmp,fla,flv,gif,jpeg,jpg,mid,mov,mp3,mp4,mpc,mpeg,mpg,png,qt,ram,rm,rmi,rmvb,swf,tif,tiff,wav,wma,wmv" ; - Config.DeniedExtensions["Media"] = "" ; - Config.FileTypesPath["Media"] = Config.UserFilesPath & 'media/' ; - Config.FileTypesAbsolutePath["Media"] = iif( Config.ServerPath eq "", de(""), de(Config.ServerPath & 'media/') ) ; - Config.QuickUploadPath["Media"] = Config.FileTypesPath["Media"] ; - Config.QuickUploadAbsolutePath["Media"] = Config.FileTypesAbsolutePath["Media"] ; - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/connector.cfm b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/connector.cfm deleted file mode 100644 index a0de684b211..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/connector.cfm +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - - - - - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/image.cfc b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/image.cfc deleted file mode 100644 index 378c4b4b959..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/image.cfc +++ /dev/null @@ -1,1324 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - paths = arrayNew(1); - paths[1] = expandPath("metadata-extractor-2.3.1.jar"); - loader = createObject("component", "javaloader.JavaLoader").init(paths); - - //at this stage we only have access to the class, but we don't have an instance - JpegMetadataReader = loader.create("com.drew.imaging.jpeg.JpegMetadataReader"); - - myMetaData = JpegMetadataReader.readMetadata(inFile); - directories = myMetaData.getDirectoryIterator(); - while (directories.hasNext()) { - currentDirectory = directories.next(); - tags = currentDirectory.getTagIterator(); - while (tags.hasNext()) { - currentTag = tags.next(); - if (currentTag.getTagName() DOES NOT CONTAIN "Unknown") { //leave out the junk data - queryAddRow(retQry); - querySetCell(retQry,"dirName",replace(currentTag.getDirectoryName(),' ','_','ALL')); - tagName = replace(currentTag.getTagName(),' ','','ALL'); - tagName = replace(tagName,'/','','ALL'); - querySetCell(retQry,"tagName",tagName); - querySetCell(retQry,"tagValue",currentTag.getDescription()); - } - } - } - return retQry; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - resizedImage = CreateObject("java", "java.awt.image.BufferedImage"); - at = CreateObject("java", "java.awt.geom.AffineTransform"); - op = CreateObject("java", "java.awt.image.AffineTransformOp"); - - w = img.getWidth(); - h = img.getHeight(); - - if (preserveAspect and cropToExact and newHeight gt 0 and newWidth gt 0) - { - if (w / h gt newWidth / newHeight){ - newWidth = 0; - } else if (w / h lt newWidth / newHeight){ - newHeight = 0; - } - } else if (preserveAspect and newHeight gt 0 and newWidth gt 0) { - if (w / h gt newWidth / newHeight){ - newHeight = 0; - } else if (w / h lt newWidth / newHeight){ - newWidth = 0; - } - } - if (newWidth gt 0 and newHeight eq 0) { - scale = newWidth / w; - w = newWidth; - h = round(h*scale); - } else if (newHeight gt 0 and newWidth eq 0) { - scale = newHeight / h; - h = newHeight; - w = round(w*scale); - } else if (newHeight gt 0 and newWidth gt 0) { - w = newWidth; - h = newHeight; - } else { - retVal = throw( retVal.errorMessage); - return retVal; - } - resizedImage.init(javacast("int",w),javacast("int",h),img.getType()); - - w = w / img.getWidth(); - h = h / img.getHeight(); - - - - op.init(at.getScaleInstance(javacast("double",w),javacast("double",h)), rh); - // resizedImage = op.createCompatibleDestImage(img, img.getColorModel()); - op.filter(img, resizedImage); - - imgInfo = getimageinfo(resizedImage, ""); - if (imgInfo.errorCode gt 0) - { - return imgInfo; - } - - cropOffsetX = max( Int( (imgInfo.width/2) - (newWidth/2) ), 0 ); - cropOffsetY = max( Int( (imgInfo.height/2) - (newHeight/2) ), 0 ); - // There is a chance that the image is exactly the correct - // width and height and don't need to be cropped - if - ( - preserveAspect and cropToExact - and - (imgInfo.width IS NOT specifiedWidth OR imgInfo.height IS NOT specifiedHeight) - ) - { - // Get the correct offset to get the center of the image - cropOffsetX = max( Int( (imgInfo.width/2) - (specifiedWidth/2) ), 0 ); - cropOffsetY = max( Int( (imgInfo.height/2) - (specifiedHeight/2) ), 0 ); - - cropImageResult = crop( resizedImage, "", "", cropOffsetX, cropOffsetY, specifiedWidth, specifiedHeight ); - if ( cropImageResult.errorCode GT 0) - { - return cropImageResult; - } else { - resizedImage = cropImageResult.img; - } - } - if (outputFile eq "") - { - retVal.img = resizedImage; - return retVal; - } else { - saveImage = writeImage(outputFile, resizedImage, jpegCompression); - if (saveImage.errorCode gt 0) - { - return saveImage; - } else { - return retVal; - } - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - if (fromX + newWidth gt img.getWidth() - OR - fromY + newHeight gt img.getHeight() - ) - { - retval = throw( "The cropped image dimensions go beyond the original image dimensions."); - return retVal; - } - croppedImage = img.getSubimage(javaCast("int", fromX), javaCast("int", fromY), javaCast("int", newWidth), javaCast("int", newHeight) ); - if (outputFile eq "") - { - retVal.img = croppedImage; - return retVal; - } else { - saveImage = writeImage(outputFile, croppedImage, jpegCompression); - if (saveImage.errorCode gt 0) - { - return saveImage; - } else { - return retVal; - } - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - rotatedImage = CreateObject("java", "java.awt.image.BufferedImage"); - at = CreateObject("java", "java.awt.geom.AffineTransform"); - op = CreateObject("java", "java.awt.image.AffineTransformOp"); - - iw = img.getWidth(); h = iw; - ih = img.getHeight(); w = ih; - - if(arguments.degrees eq 180) { w = iw; h = ih; } - - x = (w/2)-(iw/2); - y = (h/2)-(ih/2); - - rotatedImage.init(javacast("int",w),javacast("int",h),img.getType()); - - at.rotate(arguments.degrees * 0.0174532925,w/2,h/2); - at.translate(x,y); - op.init(at, rh); - - op.filter(img, rotatedImage); - - if (outputFile eq "") - { - retVal.img = rotatedImage; - return retVal; - } else { - saveImage = writeImage(outputFile, rotatedImage, jpegCompression); - if (saveImage.errorCode gt 0) - { - return saveImage; - } else { - return retVal; - } - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - if (outputFile eq "") - { - retVal = throw( "The convert method requires a valid output filename."); - return retVal; - } else { - saveImage = writeImage(outputFile, img, jpegCompression); - if (saveImage.errorCode gt 0) - { - return saveImage; - } else { - return retVal; - } - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - /* - JPEG output method handles compression - */ - out = createObject("java", "java.io.BufferedOutputStream"); - fos = createObject("java", "java.io.FileOutputStream"); - fos.init(tempOutputFile); - out.init(fos); - JPEGCodec = createObject("java", "com.sun.image.codec.jpeg.JPEGCodec"); - encoder = JPEGCodec.createJPEGEncoder(out); - param = encoder.getDefaultJPEGEncodeParam(img); - param.setQuality(quality, false); - encoder.setJPEGEncodeParam(param); - encoder.encode(img); - out.close(); - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - flippedImage = CreateObject("java", "java.awt.image.BufferedImage"); - at = CreateObject("java", "java.awt.geom.AffineTransform"); - op = CreateObject("java", "java.awt.image.AffineTransformOp"); - - flippedImage.init(img.getWidth(), img.getHeight(), img.getType()); - - if (direction eq "horizontal") { - at = at.getScaleInstance(-1, 1); - at.translate(-img.getWidth(), 0); - } else { - at = at.getScaleInstance(1,-1); - at.translate(0, -img.getHeight()); - } - op.init(at, rh); - op.filter(img, flippedImage); - - if (outputFile eq "") - { - retVal.img = flippedImage; - return retVal; - } else { - saveImage = writeImage(outputFile, flippedImage, jpegCompression); - if (saveImage.errorCode gt 0) - { - return saveImage; - } else { - return retVal; - } - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // initialize the blur filter - variables.blurFilter.init(arguments.blurAmount); - // move the source image into the destination image - // so we can repeatedly blur it. - destImage = srcImage; - - for (i=1; i lte iterations; i=i+1) - { - // do the blur i times - destImage = variables.blurFilter.filter(destImage); - } - - - if (outputFile eq "") - { - // return the image object - retVal.img = destImage; - return retVal; - } else { - // write the image object to the specified file. - saveImage = writeImage(outputFile, destImage, jpegCompression); - if (saveImage.errorCode gt 0) - { - return saveImage; - } else { - return retVal; - } - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // initialize the sharpen filter - variables.sharpenFilter.init(); - - destImage = variables.sharpenFilter.filter(srcImage); - - - if (outputFile eq "") - { - // return the image object - retVal.img = destImage; - return retVal; - } else { - // write the image object to the specified file. - saveImage = writeImage(outputFile, destImage, jpegCompression); - if (saveImage.errorCode gt 0) - { - return saveImage; - } else { - return retVal; - } - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // initialize the posterize filter - variables.posterizeFilter.init(arguments.amount); - - destImage = variables.posterizeFilter.filter(srcImage); - - - if (outputFile eq "") - { - // return the image object - retVal.img = destImage; - return retVal; - } else { - // write the image object to the specified file. - saveImage = writeImage(outputFile, destImage, jpegCompression); - if (saveImage.errorCode gt 0) - { - return saveImage; - } else { - return retVal; - } - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // load objects - bgImage = CreateObject("java", "java.awt.image.BufferedImage"); - fontImage = CreateObject("java", "java.awt.image.BufferedImage"); - overlayImage = CreateObject("java", "java.awt.image.BufferedImage"); - Color = CreateObject("java","java.awt.Color"); - font = createObject("java","java.awt.Font"); - font_stream = createObject("java","java.io.FileInputStream"); - ac = CreateObject("Java", "java.awt.AlphaComposite"); - - // set up basic needs - fontColor = Color.init(javacast("int", rgb.red), javacast("int", rgb.green), javacast("int", rgb.blue)); - - if (fontDetails.fontFile neq "") - { - font_stream.init(arguments.fontDetails.fontFile); - font = font.createFont(font.TRUETYPE_FONT, font_stream); - font = font.deriveFont(javacast("float",arguments.fontDetails.size)); - } else { - font.init(fontDetails.fontName, evaluate(fontDetails.style), fontDetails.size); - } - // get font metrics using a 1x1 bufferedImage - fontImage.init(1,1,img.getType()); - g2 = fontImage.createGraphics(); - g2.setRenderingHints(getRenderingHints()); - fc = g2.getFontRenderContext(); - bounds = font.getStringBounds(content,fc); - - g2 = img.createGraphics(); - g2.setRenderingHints(getRenderingHints()); - g2.setFont(font); - g2.setColor(fontColor); - // in case you want to change the alpha - // g2.setComposite(ac.getInstance(ac.SRC_OVER, 0.50)); - - // the location (arguments.fontDetails.size+y) doesn't really work - // the way I want it to. - g2.drawString(content,javacast("int",x),javacast("int",arguments.fontDetails.size+y)); - - if (outputFile eq "") - { - retVal.img = img; - return retVal; - } else { - saveImage = writeImage(outputFile, img, jpegCompression); - if (saveImage.errorCode gt 0) - { - return saveImage; - } else { - return retVal; - } - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - at = CreateObject("java", "java.awt.geom.AffineTransform"); - op = CreateObject("java", "java.awt.image.AffineTransformOp"); - ac = CreateObject("Java", "java.awt.AlphaComposite"); - gfx = originalImage.getGraphics(); - gfx.setComposite(ac.getInstance(ac.SRC_OVER, alpha)); - - at.init(); - // op.init(at,op.TYPE_BILINEAR); - op.init(at, rh); - - gfx.drawImage(wmImage, op, javaCast("int",arguments.placeAtX), javacast("int", arguments.placeAtY)); - - gfx.dispose(); - - if (outputFile eq "") - { - retVal.img = originalImage; - return retVal; - } else { - saveImage = writeImage(outputFile, originalImage, jpegCompression); - if (saveImage.errorCode gt 0) - { - return saveImage; - } else { - return retVal; - } - } - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - // convert the image to a specified BufferedImage type and return it - - var width = bImage.getWidth(); - var height = bImage.getHeight(); - var newImage = createObject("java","java.awt.image.BufferedImage").init(javacast("int",width), javacast("int",height), javacast("int",type)); - // int[] rgbArray = new int[width*height]; - var rgbArray = variables.arrObj.newInstance(variables.intClass, javacast("int",width*height)); - - bImage.getRGB( - javacast("int",0), - javacast("int",0), - javacast("int",width), - javacast("int",height), - rgbArray, - javacast("int",0), - javacast("int",width) - ); - newImage.setRGB( - javacast("int",0), - javacast("int",0), - javacast("int",width), - javacast("int",height), - rgbArray, - javacast("int",0), - javacast("int",width) - ); - return newImage; - - - - - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/upload.cfm b/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/upload.cfm deleted file mode 100644 index 72fac0db1cb..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/cfm/upload.cfm +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - - - - diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/config.lasso b/htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/config.lasso deleted file mode 100644 index d558dfa5dc6..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/config.lasso +++ /dev/null @@ -1,65 +0,0 @@ -[//lasso -/* - * FCKeditor - The text editor for Internet - http://www.fckeditor.net - * Copyright (C) 2003-2010 Frederico Caldeira Knabben - * - * == BEGIN LICENSE == - * - * Licensed under the terms of any of the following licenses at your - * choice: - * - * - GNU General Public License Version 2 or later (the "GPL") - * http://www.gnu.org/licenses/gpl.html - * - * - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - * http://www.gnu.org/licenses/lgpl.html - * - * - Mozilla Public License Version 1.1 or later (the "MPL") - * http://www.mozilla.org/MPL/MPL-1.1.html - * - * == END LICENSE == - * - * Configuration file for the File Manager Connector for Lasso. - */ - - /*..................................................................... - The connector uses the file tags, which require authentication. Enter a - valid username and password from Lasso admin for a group with file tags - permissions for uploads and the path you define in UserFilesPath below. - */ - - var('connection') = array( - -username='xxxxxxxx', - -password='xxxxxxxx' - ); - - - /*..................................................................... - Set the base path for files that users can upload and browse (relative - to server root). - - Set which file extensions are allowed and/or denied for each file type. - */ - var('config') = map( - 'Enabled' = false, - 'UserFilesPath' = '/userfiles/', - 'Subdirectories' = map( - 'File' = 'File/', - 'Image' = 'Image/', - 'Flash' = 'Flash/', - 'Media' = 'Media/' - ), - 'AllowedExtensions' = map( - 'File' = array('7z','aiff','asf','avi','bmp','csv','doc','fla','flv','gif','gz','gzip','jpeg','jpg','mid','mov','mp3','mp4','mpc','mpeg','mpg','ods','odt','pdf','png','ppt','pxd','qt','ram','rar','rm','rmi','rmvb','rtf','sdc','sitd','swf','sxc','sxw','tar','tgz','tif','tiff','txt','vsd','wav','wma','wmv','xls','xml','zip'), - 'Image' = array('bmp','gif','jpeg','jpg','png'), - 'Flash' = array('swf','flv'), - 'Media' = array('aiff','asf','avi','bmp','fla','flv','gif','jpeg','jpg','mid','mov','mp3','mp4','mpc','mpeg','mpg','png','qt','ram','rm','rmi','rmvb','swf','tif','tiff','wav','wma','wmv') - ), - 'DeniedExtensions' = map( - 'File' = array(), - 'Image' = array(), - 'Flash' = array(), - 'Media' = array() - ) - ); -] diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/connector.lasso b/htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/connector.lasso deleted file mode 100644 index 98e3e4f89ab..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/connector.lasso +++ /dev/null @@ -1,330 +0,0 @@ -[//lasso -/* - * FCKeditor - The text editor for Internet - http://www.fckeditor.net - * Copyright (C) 2003-2010 Frederico Caldeira Knabben - * - * == BEGIN LICENSE == - * - * Licensed under the terms of any of the following licenses at your - * choice: - * - * - GNU General Public License Version 2 or later (the "GPL") - * http://www.gnu.org/licenses/gpl.html - * - * - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - * http://www.gnu.org/licenses/lgpl.html - * - * - Mozilla Public License Version 1.1 or later (the "MPL") - * http://www.mozilla.org/MPL/MPL-1.1.html - * - * == END LICENSE == - * - * This is the File Manager Connector for Lasso. - */ - - /*..................................................................... - Include global configuration. See config.lasso for details. - */ - include('config.lasso'); - - - /*..................................................................... - Translate current date/time to GMT for custom header. - */ - var('headerDate') = date_localtogmt(date)->format('%a, %d %b %Y %T GMT'); - - - /*..................................................................... - Convert query string parameters to variables and initialize output. - */ - var( - 'Command' = (Encode_HTML: action_param('Command')), - 'Type' = (Encode_HTML: action_param('Type')), - 'CurrentFolder' = action_param('CurrentFolder'), - 'ServerPath' = action_param('ServerPath'), - 'NewFolderName' = action_param('NewFolderName'), - 'NewFile' = null, - 'NewFileName' = string, - 'OrigFilePath' = string, - 'NewFilePath' = string, - 'commandData' = string, - 'folders' = '\t\n', - 'files' = '\t\n', - 'errorNumber' = integer, - 'responseType' = 'xml', - 'uploadResult' = '0' - ); - - /*..................................................................... - Custom tag sets the HTML response. - */ - - define_tag( - 'htmlreply', - -namespace='fck_', - -priority='replace', - -required='uploadResult', - -optional='NewFilePath', - -type='string', - -description='Sets the HTML response for the FCKEditor File Upload feature.' - ); - $__html_reply__ = '\ - - '; - else; - $__html_reply__ = $__html_reply__ + '\ - window.parent.OnUploadCompleted(' + $uploadResult + ',"",""); - - '; - /if; - /define_tag; - - - /*..................................................................... - Calculate the path to the current folder. - */ - $ServerPath == '' ? $ServerPath = $config->find('UserFilesPath'); - - var('currentFolderURL' = $ServerPath - + $config->find('Subdirectories')->find(action_param('Type')) - + $CurrentFolder - ); - - $currentFolderURL = string_replace($currentFolderURL, -find='//', -replace='/'); - - if (!$config->find('Subdirectories')->find(action_param('Type'))); - if($Command == 'FileUpload'); - $responseType = 'html'; - $uploadResult = '1'; - fck_htmlreply( - -uploadResult=$uploadResult - ); - else; - $errorNumber = 1; - $commandData += '\n'; - /if; - else if($CurrentFolder->(Find: '..') || (String_FindRegExp: $CurrentFolder, -Find='(/\\.)|(//)|[\\\\:\\*\\?\\""\\<\\>\\|]|\\000|[\u007F]|[\u0001-\u001F]')); - if($Command == 'FileUpload'); - $responseType = 'html'; - $uploadResult = '102'; - fck_htmlreply( - -uploadResult=$uploadResult - ); - else; - $errorNumber = 102; - $commandData += '\n'; - /if; - else; - - /*..................................................................... - Build the appropriate response per the 'Command' parameter. Wrap the - entire process in an inline for file tag permissions. - */ - if($config->find('Enabled')); - inline($connection); - select($Command); - /*............................................................. - List all subdirectories in the 'Current Folder' directory. - */ - case('GetFolders'); - $commandData += '\t\n'; - - iterate(file_listdirectory($currentFolderURL), local('this')); - #this->endswith('/') ? $commandData += '\t\t\n'; - /iterate; - - $commandData += '\t\n'; - - - /*............................................................. - List both files and folders in the 'Current Folder' directory. - Include the file sizes in kilobytes. - */ - case('GetFoldersAndFiles'); - iterate(file_listdirectory($currentFolderURL), local('this')); - if(#this->endswith('/')); - $folders += '\t\t\n'; - else; - local('size') = file_getsize($currentFolderURL + #this); - if($size>0); - $size = $size/1024; - if ($size==0); - $size = 1; - /if; - /if; - $files += '\t\t\n'; - /if; - /iterate; - - $folders += '\t\n'; - $files += '\t\n'; - - $commandData += $folders + $files; - - - /*............................................................. - Create a directory 'NewFolderName' within the 'Current Folder.' - */ - case('CreateFolder'); - $NewFolderName = (String_ReplaceRegExp: $NewFolderName, -find='\\.|\\\\|\\/|\\||\\:|\\?|\\*|"|<|>|\\000|[\u007F]|[\u0001-\u001F]', -replace='_'); - var('newFolder' = $currentFolderURL + $NewFolderName + '/'); - file_create($newFolder); - - - /*......................................................... - Map Lasso's file error codes to FCKEditor's error codes. - */ - select(file_currenterror( -errorcode)); - case(0); - $errorNumber = 0; - case( -9983); - $errorNumber = 101; - case( -9976); - $errorNumber = 102; - case( -9977); - $errorNumber = 102; - case( -9961); - $errorNumber = 103; - case; - $errorNumber = 110; - /select; - - $commandData += '\n'; - - - /*............................................................. - Process an uploaded file. - */ - case('FileUpload'); - /*......................................................... - This is the only command that returns an HTML response. - */ - $responseType = 'html'; - - - /*......................................................... - Was a file actually uploaded? - */ - if(file_uploads->size); - $NewFile = file_uploads->get(1); - else; - $uploadResult = '202'; - /if; - - if($uploadResult == '0'); - /*..................................................... - Split the file's extension from the filename in order - to follow the API's naming convention for duplicate - files. (Test.txt, Test(1).txt, Test(2).txt, etc.) - */ - $NewFileName = $NewFile->find('OrigName'); - $NewFileName = (String_ReplaceRegExp: $NewFileName, -find='\\\\|\\/|\\||\\:|\\?|\\*|"|<|>|\\000|[\u007F]|[\u0001-\u001F]', -replace='_'); - $NewFileName = (String_ReplaceRegExp: $NewFileName, -find='\\.(?![^.]*$)', -replace='_'); - $OrigFilePath = $currentFolderURL + $NewFileName; - $NewFilePath = $OrigFilePath; - local('fileExtension') = '.' + $NewFile->find('OrigExtension'); - #fileExtension = (String_ReplaceRegExp: #fileExtension, -find='\\\\|\\/|\\||\\:|\\?|\\*|"|<|>|\\000|[\u007F]|[\u0001-\u001F]', -replace='_'); - local('shortFileName') = $NewFileName->removetrailing(#fileExtension)&; - - - /*..................................................... - Make sure the file extension is allowed. - */ - local('allowedExt') = $config->find('AllowedExtensions')->find($Type); - local('deniedExt') = $config->find('DeniedExtensions')->find($Type); - if($allowedExt->Size > 0 && $allowedExt !>> $NewFile->find('OrigExtension')); - $uploadResult = '202'; - else($deniedExt->Size > 0 && $deniedExt >> $NewFile->find('OrigExtension')); - $uploadResult = '202'; - else; - /*................................................. - Rename the target path until it is unique. - */ - while(file_exists($NewFilePath)); - $NewFilePath = $currentFolderURL + #shortFileName + '(' + loop_count + ')' + #fileExtension; - /while; - - - /*................................................. - Copy the uploaded file to its final location. - */ - file_copy($NewFile->find('path'), $NewFilePath); - - - /*................................................. - Set the error code for the response. Note whether - the file had to be renamed. - */ - select(file_currenterror( -errorcode)); - case(0); - $OrigFilePath != $NewFilePath ? $uploadResult = 201; - case; - $uploadResult = file_currenterror( -errorcode); - /select; - /if; - /if; - fck_htmlreply( - -uploadResult=$uploadResult, - -NewFilePath=$NewFilePath - ); - case; - $errorNumber = 1; - $commandData += '\n'; - /select; - /inline; - else; - $errorNumber = 1; - $commandData += '\n'; - /if; - /if; - - /*..................................................................... - Send a custom header for xml responses. - */ - if($responseType == 'xml'); - header; -] -HTTP/1.0 200 OK -Date: [$headerDate] -Server: Lasso Professional [lasso_version( -lassoversion)] -Expires: Mon, 26 Jul 1997 05:00:00 GMT -Last-Modified: [$headerDate] -Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0 -Pragma: no-cache -Keep-Alive: timeout=15, max=98 -Connection: Keep-Alive -Content-Type: text/xml; charset=utf-8 -[//lasso -/header; - - /* - Set the content type encoding for Lasso. - */ - content_type('text/xml; charset=utf-8'); - - /* - Wrap the response as XML and output. - */ - $__html_reply__ = '\ -'; - - if($errorNumber != '102'); - $__html_reply__ += ''; - else; - $__html_reply__ += ''; - /if; - - if($errorNumber != '102'); - $__html_reply__ += ''; - /if; - - $__html_reply__ += $commandData + ' -'; - /if; -] diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/upload.lasso b/htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/upload.lasso deleted file mode 100644 index 66d563fdc1e..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/lasso/upload.lasso +++ /dev/null @@ -1,178 +0,0 @@ -[//lasso -/* - * FCKeditor - The text editor for Internet - http://www.fckeditor.net - * Copyright (C) 2003-2010 Frederico Caldeira Knabben - * - * == BEGIN LICENSE == - * - * Licensed under the terms of any of the following licenses at your - * choice: - * - * - GNU General Public License Version 2 or later (the "GPL") - * http://www.gnu.org/licenses/gpl.html - * - * - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - * http://www.gnu.org/licenses/lgpl.html - * - * - Mozilla Public License Version 1.1 or later (the "MPL") - * http://www.mozilla.org/MPL/MPL-1.1.html - * - * == END LICENSE == - * - * This is the "File Uploader" for Lasso. - */ - - /*..................................................................... - Include global configuration. See config.lasso for details. - */ - include('config.lasso'); - - - /*..................................................................... - Convert query string parameters to variables and initialize output. - */ - var( - 'Type' = (Encode_HTML: action_param('Type')), - 'CurrentFolder' = "/", - 'ServerPath' = action_param('ServerPath'), - 'NewFile' = null, - 'NewFileName' = string, - 'OrigFilePath' = string, - 'NewFilePath' = string, - 'errorNumber' = 0, - 'customMsg' = '' - ); - - $Type == '' ? $Type = 'File'; - - - /*..................................................................... - Calculate the path to the current folder. - */ - $ServerPath == '' ? $ServerPath = $config->find('UserFilesPath'); - - var('currentFolderURL' = $ServerPath - + $config->find('Subdirectories')->find(action_param('Type')) - + $CurrentFolder - ); - - $currentFolderURL = string_replace($currentFolderURL, -find='//', -replace='/'); - - /*..................................................................... - Custom tag sets the HTML response. - */ - - define_tag( - 'sendresults', - -namespace='fck_', - -priority='replace', - -required='errorNumber', - -type='integer', - -optional='fileUrl', - -type='string', - -optional='fileName', - -type='string', - -optional='customMsg', - -type='string', - -description='Sets the HTML response for the FCKEditor Quick Upload feature.' - ); - - $__html_reply__ = ' - '; - /define_tag; - - if($CurrentFolder->(Find: '..') || (String_FindRegExp: $CurrentFolder, -Find='(/\\.)|(//)|[\\\\:\\*\\?\\""\\<\\>\\|]|\\000|[\u007F]|[\u0001-\u001F]')); - $errorNumber = 102; - /if; - - if($config->find('Enabled')); - /*................................................................. - Process an uploaded file. - */ - inline($connection); - /*............................................................. - Was a file actually uploaded? - */ - if($errorNumber != '102'); - file_uploads->size ? $NewFile = file_uploads->get(1) | $errorNumber = 202; - /if; - - if($errorNumber == 0); - /*......................................................... - Split the file's extension from the filename in order - to follow the API's naming convention for duplicate - files. (Test.txt, Test(1).txt, Test(2).txt, etc.) - */ - $NewFileName = $NewFile->find('OrigName'); - $NewFileName = (String_ReplaceRegExp: $NewFileName, -find='\\\\|\\/|\\||\\:|\\?|\\*|"|<|>|\\000|[\u007F]|[\u0001-\u001F]', -replace='_'); - $NewFileName = (String_ReplaceRegExp: $NewFileName, -find='\\.(?![^.]*$)', -replace='_'); - $OrigFilePath = $currentFolderURL + $NewFileName; - $NewFilePath = $OrigFilePath; - local('fileExtension') = '.' + $NewFile->find('OrigExtension'); - local('shortFileName') = $NewFileName->removetrailing(#fileExtension)&; - - - /*......................................................... - Make sure the file extension is allowed. - */ - - local('allowedExt') = $config->find('AllowedExtensions')->find($Type); - local('deniedExt') = $config->find('DeniedExtensions')->find($Type); - if($allowedExt->Size > 0 && $allowedExt !>> $NewFile->find('OrigExtension')); - $errorNumber = 202; - else($deniedExt->Size > 0 && $deniedExt >> $NewFile->find('OrigExtension')); - $errorNumber = 202; - else; - /*..................................................... - Rename the target path until it is unique. - */ - while(file_exists($NewFilePath)); - $NewFileName = #shortFileName + '(' + loop_count + ')' + #fileExtension; - $NewFilePath = $currentFolderURL + $NewFileName; - /while; - - - /*..................................................... - Copy the uploaded file to its final location. - */ - file_copy($NewFile->find('path'), $NewFilePath); - - - /*..................................................... - Set the error code for the response. - */ - select(file_currenterror( -errorcode)); - case(0); - $OrigFilePath != $NewFilePath ? $errorNumber = 201; - case; - $errorNumber = 202; - /select; - /if; - /if; - if ($errorNumber != 0 && $errorNumber != 201); - $NewFilePath = ""; - /if; - /inline; - else; - $errorNumber = 1; - $customMsg = 'This file uploader is disabled. Please check the "editor/filemanager/upload/lasso/config.lasso" file.'; - /if; - - fck_sendresults( - -errorNumber=$errorNumber, - -fileUrl=$NewFilePath, - -customMsg=$customMsg - ); -] diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/basexml.pl b/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/basexml.pl deleted file mode 100644 index e0835c3dd90..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/basexml.pl +++ /dev/null @@ -1,68 +0,0 @@ -##### -# FCKeditor - The text editor for Internet - http://www.fckeditor.net -# Copyright (C) 2003-2010 Frederico Caldeira Knabben -# -# == BEGIN LICENSE == -# -# Licensed under the terms of any of the following licenses at your -# choice: -# -# - GNU General Public License Version 2 or later (the "GPL") -# http://www.gnu.org/licenses/gpl.html -# -# - GNU Lesser General Public License Version 2.1 or later (the "LGPL") -# http://www.gnu.org/licenses/lgpl.html -# -# - Mozilla Public License Version 1.1 or later (the "MPL") -# http://www.mozilla.org/MPL/MPL-1.1.html -# -# == END LICENSE == -# -# This is the File Manager Connector for Perl. -##### - -sub CreateXmlHeader -{ - local($command,$resourceType,$currentFolder) = @_; - - # Create the XML document header. - print ''; - - # Create the main "Connector" node. - print ''; - - # Add the current folder node. - print ''; -} - -sub CreateXmlFooter -{ - print ''; -} - -sub SendError -{ - local( $number, $text ) = @_; - - print << "_HTML_HEAD_"; -Content-Type:text/xml; charset=utf-8 -Pragma: no-cache -Cache-Control: no-cache -Expires: Thu, 01 Dec 1994 16:00:00 GMT - -_HTML_HEAD_ - - # Create the XML document header - print '' ; - - if ($text) { - print '' ; - } - else { - print '' ; - } - - exit ; -} - -1; diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/commands.pl b/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/commands.pl deleted file mode 100644 index 66b4d6da0a7..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/commands.pl +++ /dev/null @@ -1,200 +0,0 @@ -##### -# FCKeditor - The text editor for Internet - http://www.fckeditor.net -# Copyright (C) 2003-2010 Frederico Caldeira Knabben -# -# == BEGIN LICENSE == -# -# Licensed under the terms of any of the following licenses at your -# choice: -# -# - GNU General Public License Version 2 or later (the "GPL") -# http://www.gnu.org/licenses/gpl.html -# -# - GNU Lesser General Public License Version 2.1 or later (the "LGPL") -# http://www.gnu.org/licenses/lgpl.html -# -# - Mozilla Public License Version 1.1 or later (the "MPL") -# http://www.mozilla.org/MPL/MPL-1.1.html -# -# == END LICENSE == -# -# This is the File Manager Connector for Perl. -##### - -sub GetFolders -{ - - local($resourceType, $currentFolder) = @_; - - # Map the virtual path to the local server path. - $sServerDir = &ServerMapFolder($resourceType, $currentFolder); - print ""; # Open the "Folders" node. - - opendir(DIR,"$sServerDir"); - @files = grep(!/^\.\.?$/,readdir(DIR)); - closedir(DIR); - - foreach $sFile (@files) { - if($sFile != '.' && $sFile != '..' && (-d "$sServerDir$sFile")) { - $cnv_filename = &ConvertToXmlAttribute($sFile); - print ''; - } - } - print ""; # Close the "Folders" node. -} - -sub GetFoldersAndFiles -{ - - local($resourceType, $currentFolder) = @_; - # Map the virtual path to the local server path. - $sServerDir = &ServerMapFolder($resourceType,$currentFolder); - - # Initialize the output buffers for "Folders" and "Files". - $sFolders = ''; - $sFiles = ''; - - opendir(DIR,"$sServerDir"); - @files = grep(!/^\.\.?$/,readdir(DIR)); - closedir(DIR); - - foreach $sFile (@files) { - if($sFile ne '.' && $sFile ne '..') { - if(-d "$sServerDir$sFile") { - $cnv_filename = &ConvertToXmlAttribute($sFile); - $sFolders .= '' ; - } else { - ($iFileSize,$refdate,$filedate,$fileperm) = (stat("$sServerDir$sFile"))[7,8,9,2]; - if($iFileSize > 0) { - $iFileSize = int($iFileSize / 1024); - if($iFileSize < 1) { - $iFileSize = 1; - } - } - $cnv_filename = &ConvertToXmlAttribute($sFile); - $sFiles .= '' ; - } - } - } - print $sFolders ; - print ''; # Close the "Folders" node. - print $sFiles ; - print ''; # Close the "Files" node. -} - -sub CreateFolder -{ - - local($resourceType, $currentFolder) = @_; - $sErrorNumber = '0' ; - $sErrorMsg = '' ; - - if($FORM{'NewFolderName'} ne "") { - $sNewFolderName = $FORM{'NewFolderName'}; - $sNewFolderName =~ s/\.|\\|\/|\||\:|\?|\*|\"|<|>|[[:cntrl:]]/_/g; - # Map the virtual path to the local server path of the current folder. - $sServerDir = &ServerMapFolder($resourceType, $currentFolder); - if(-w $sServerDir) { - $sServerDir .= $sNewFolderName; - $sErrorMsg = &CreateServerFolder($sServerDir); - if($sErrorMsg == 0) { - $sErrorNumber = '0'; - } elsif($sErrorMsg eq 'Invalid argument' || $sErrorMsg eq 'No such file or directory') { - $sErrorNumber = '102'; #// Path too long. - } else { - $sErrorNumber = '110'; - } - } else { - $sErrorNumber = '103'; - } - } else { - $sErrorNumber = '102' ; - } - # Create the "Error" node. - $cnv_errmsg = &ConvertToXmlAttribute($sErrorMsg); - print ''; -} - -sub FileUpload -{ -eval("use File::Copy;"); - - local($resourceType, $currentFolder) = @_; - $allowedExtensions = $allowedExtensions{$resourceType}; - - $sErrorNumber = '0' ; - $sFileName = '' ; - if($new_fname) { - # Map the virtual path to the local server path. - $sServerDir = &ServerMapFolder($resourceType,$currentFolder); - - # Get the uploaded file name. - $sFileName = $new_fname; - $sFileName =~ s/\\|\/|\||\:|\?|\*|\"|<|>|[[:cntrl:]]/_/g; - $sFileName =~ s/\.(?![^.]*$)/_/g; - - $ext = ''; - if($sFileName =~ /([^\\\/]*)\.(.*)$/) { - $ext = $2; - } - - $allowedRegex = qr/^($allowedExtensions)$/i; - if (!($ext =~ $allowedRegex)) { - SendUploadResults('202', '', '', ''); - } - - $sOriginalFileName = $sFileName; - - $iCounter = 0; - while(1) { - $sFilePath = $sServerDir . $sFileName; - if(-e $sFilePath) { - $iCounter++ ; - ($path,$BaseName,$ext) = &RemoveExtension($sOriginalFileName); - $sFileName = $BaseName . '(' . $iCounter . ').' . $ext; - $sErrorNumber = '201'; - } else { - copy("$img_dir/$new_fname","$sFilePath"); - if (defined $CHMOD_ON_UPLOAD) { - if ($CHMOD_ON_UPLOAD) { - umask(000); - chmod($CHMOD_ON_UPLOAD,$sFilePath); - } - } - else { - umask(000); - chmod(0777,$sFilePath); - } - unlink("$img_dir/$new_fname"); - last; - } - } - } else { - $sErrorNumber = '202' ; - } - $sFileName =~ s/"/\\"/g; - - SendUploadResults($sErrorNumber, $GLOBALS{'UserFilesPath'}.$resourceType.$currentFolder.$sFileName, $sFileName, ''); -} - -sub SendUploadResults -{ - - local($sErrorNumber, $sFileUrl, $sFileName, $customMsg) = @_; - - # Minified version of the document.domain automatic fix script (#1919). - # The original script can be found at _dev/domain_fix_template.js - # Note: in Perl replace \ with \\ and $ with \$ - print < -(function(){var d=document.domain;while (true){try{var A=window.parent.document.domain;break;}catch(e) {};d=d.replace(/.*?(?:\\.|\$)/,'');if (d.length==0) break;try{document.domain=d;}catch (e){break;}}})(); - -EOF - print 'window.parent.OnUploadCompleted(' . $sErrorNumber . ',"' . JS_cnv($sFileUrl) . '","' . JS_cnv($sFileName) . '","' . JS_cnv($customMsg) . '") ;'; - print ''; - exit ; -} - -1; diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/config.pl b/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/config.pl deleted file mode 100644 index de85c7957d6..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/config.pl +++ /dev/null @@ -1,39 +0,0 @@ -##### -# FCKeditor - The text editor for Internet - http://www.fckeditor.net -# Copyright (C) 2003-2010 Frederico Caldeira Knabben -# -# == BEGIN LICENSE == -# -# Licensed under the terms of any of the following licenses at your -# choice: -# -# - GNU General Public License Version 2 or later (the "GPL") -# http://www.gnu.org/licenses/gpl.html -# -# - GNU Lesser General Public License Version 2.1 or later (the "LGPL") -# http://www.gnu.org/licenses/lgpl.html -# -# - Mozilla Public License Version 1.1 or later (the "MPL") -# http://www.mozilla.org/MPL/MPL-1.1.html -# -# == END LICENSE == -# -# This is the File Manager Connector for Perl. -##### - -## -# SECURITY: REMOVE/COMMENT THE FOLLOWING LINE TO ENABLE THIS CONNECTOR. -## -&SendError( 1, 'This connector is disabled. Please check the "editor/filemanager/connectors/perl/config.cgi" file' ) ; - -$GLOBALS{'UserFilesPath'} = '/userfiles/'; - -# Map the "UserFiles" path to a local directory. -$rootpath = &GetRootPath(); -$GLOBALS{'UserFilesDirectory'} = $rootpath . $GLOBALS{'UserFilesPath'}; - -%allowedExtensions = ("File", "7z|aiff|asf|avi|bmp|csv|doc|fla|flv|gif|gz|gzip|jpeg|jpg|mid|mov|mp3|mp4|mpc|mpeg|mpg|ods|odt|pdf|png|ppt|pxd|qt|ram|rar|rm|rmi|rmvb|rtf|sdc|sitd|swf|sxc|sxw|tar|tgz|tif|tiff|txt|vsd|wav|wma|wmv|xls|xml|zip", -"Image", "bmp|gif|jpeg|jpg|png", -"Flash", "swf|flv", -"Media", "aiff|asf|avi|bmp|fla|flv|gif|jpeg|jpg|mid|mov|mp3|mp4|mpc|mpeg|mpg|png|qt|ram|rm|rmi|rmvb|swf|tif|tiff|wav|wma|wmv" -); diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/connector.cgi b/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/connector.cgi deleted file mode 100644 index 990a92e6385..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/connector.cgi +++ /dev/null @@ -1,129 +0,0 @@ -#!/usr/bin/env perl - -##### -# FCKeditor - The text editor for Internet - http://www.fckeditor.net -# Copyright (C) 2003-2010 Frederico Caldeira Knabben -# -# == BEGIN LICENSE == -# -# Licensed under the terms of any of the following licenses at your -# choice: -# -# - GNU General Public License Version 2 or later (the "GPL") -# http://www.gnu.org/licenses/gpl.html -# -# - GNU Lesser General Public License Version 2.1 or later (the "LGPL") -# http://www.gnu.org/licenses/lgpl.html -# -# - Mozilla Public License Version 1.1 or later (the "MPL") -# http://www.mozilla.org/MPL/MPL-1.1.html -# -# == END LICENSE == -# -# This is the File Manager Connector for Perl. -##### - -## -# ATTENTION: To enable this connector, look for the "SECURITY" comment in config.pl. -## - -## START: Hack for Windows (Not important to understand the editor code... Perl specific). -if(Windows_check()) { - chdir(GetScriptPath($0)); -} - -sub Windows_check -{ - # IIS,PWS(NT/95) - $www_server_os = $^O; - # Win98 & NT(SP4) - if($www_server_os eq "") { $www_server_os= $ENV{'OS'}; } - # AnHTTPd/Omni/IIS - if($ENV{'SERVER_SOFTWARE'} =~ /AnWeb|Omni|IIS\//i) { $www_server_os= 'win'; } - # Win Apache - if($ENV{'WINDIR'} ne "") { $www_server_os= 'win'; } - if($www_server_os=~ /win/i) { return(1); } - return(0); -} - -sub GetScriptPath { - local($path) = @_; - if($path =~ /[\:\/\\]/) { $path =~ s/(.*?)[\/\\][^\/\\]+$/$1/; } else { $path = '.'; } - $path; -} -## END: Hack for IIS - -require 'util.pl'; -require 'io.pl'; -require 'basexml.pl'; -require 'commands.pl'; -require 'upload_fck.pl'; -require 'config.pl'; - -&read_input(); -&DoResponse(); - -sub DoResponse -{ - - if($FORM{'Command'} eq "" || $FORM{'Type'} eq "" || $FORM{'CurrentFolder'} eq "") { - return ; - } - # Get the main request informaiton. - $sCommand = &specialchar_cnv($FORM{'Command'}); - $sResourceType = &specialchar_cnv($FORM{'Type'}); - $sCurrentFolder = $FORM{'CurrentFolder'}; - - if ( !($sCommand =~ /^(FileUpload|GetFolders|GetFoldersAndFiles|CreateFolder)$/) ) { - SendError( 1, "Command not allowed" ) ; - } - - if ( !($sResourceType =~ /^(File|Image|Flash|Media)$/) ) { - SendError( 1, "Invalid type specified" ) ; - } - - # Check the current folder syntax (must begin and start with a slash). - if(!($sCurrentFolder =~ /\/$/)) { - $sCurrentFolder .= '/'; - } - if(!($sCurrentFolder =~ /^\//)) { - $sCurrentFolder = '/' . $sCurrentFolder; - } - - # Check for invalid folder paths (..) - if ( $sCurrentFolder =~ /(?:\.\.|\\)/ ) { - SendError( 102, "" ) ; - } - if ( $sCurrentFolder =~ /(\/\.)|[[:cntrl:]]|(\/\/)|(\\\\)|([\:\*\?\"\<\>\|])/ ) { - SendError( 102, "" ) ; - } - - # File Upload doesn't have to Return XML, so it must be intercepted before anything. - if($sCommand eq 'FileUpload') { - FileUpload($sResourceType,$sCurrentFolder); - return ; - } - - print << "_HTML_HEAD_"; -Content-Type:text/xml; charset=utf-8 -Pragma: no-cache -Cache-Control: no-cache -Expires: Thu, 01 Dec 1994 16:00:00 GMT - -_HTML_HEAD_ - - &CreateXmlHeader($sCommand,$sResourceType,$sCurrentFolder); - - # Execute the required command. - if($sCommand eq 'GetFolders') { - &GetFolders($sResourceType,$sCurrentFolder); - } elsif($sCommand eq 'GetFoldersAndFiles') { - &GetFoldersAndFiles($sResourceType,$sCurrentFolder); - } elsif($sCommand eq 'CreateFolder') { - &CreateFolder($sResourceType,$sCurrentFolder); - } - - &CreateXmlFooter(); - - exit ; -} diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/io.pl b/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/io.pl deleted file mode 100644 index 56e54812b1c..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/io.pl +++ /dev/null @@ -1,141 +0,0 @@ -##### -# FCKeditor - The text editor for Internet - http://www.fckeditor.net -# Copyright (C) 2003-2010 Frederico Caldeira Knabben -# -# == BEGIN LICENSE == -# -# Licensed under the terms of any of the following licenses at your -# choice: -# -# - GNU General Public License Version 2 or later (the "GPL") -# http://www.gnu.org/licenses/gpl.html -# -# - GNU Lesser General Public License Version 2.1 or later (the "LGPL") -# http://www.gnu.org/licenses/lgpl.html -# -# - Mozilla Public License Version 1.1 or later (the "MPL") -# http://www.mozilla.org/MPL/MPL-1.1.html -# -# == END LICENSE == -# -# This is the File Manager Connector for Perl. -##### - -sub GetUrlFromPath -{ - local($resourceType, $folderPath) = @_; - - if($resourceType eq '') { - $rmpath = &RemoveFromEnd($GLOBALS{'UserFilesPath'},'/'); - return("$rmpath$folderPath"); - } else { - return("$GLOBALS{'UserFilesPath'}$resourceType$folderPath"); - } -} - -sub RemoveExtension -{ - local($fileName) = @_; - local($path, $base, $ext); - if($fileName !~ /\./) { - $fileName .= '.'; - } - if($fileName =~ /([^\\\/]*)\.(.*)$/) { - $base = $1; - $ext = $2; - if($fileName =~ /(.*)$base\.$ext$/) { - $path = $1; - } - } - return($path,$base,$ext); - -} - -sub ServerMapFolder -{ - local($resourceType,$folderPath) = @_; - - # Get the resource type directory. - $sResourceTypePath = $GLOBALS{'UserFilesDirectory'} . $resourceType . '/'; - - # Ensure that the directory exists. - &CreateServerFolder($sResourceTypePath); - - # Return the resource type directory combined with the required path. - $rmpath = &RemoveFromStart($folderPath,'/'); - return("$sResourceTypePath$rmpath"); -} - -sub GetParentFolder -{ - local($folderPath) = @_; - - $folderPath =~ s/[\/][^\/]+[\/]?$//g; - return $folderPath; -} - -sub CreateServerFolder -{ - local($folderPath) = @_; - - $sParent = &GetParentFolder($folderPath); - # Check if the parent exists, or create it. - if(!(-e $sParent)) { - $sErrorMsg = &CreateServerFolder($sParent); - if($sErrorMsg == 1) { - return(1); - } - } - if(!(-e $folderPath)) { - if (defined $CHMOD_ON_FOLDER_CREATE && !$CHMOD_ON_FOLDER_CREATE) { - mkdir("$folderPath"); - } - else { - umask(000); - if (defined $CHMOD_ON_FOLDER_CREATE) { - mkdir("$folderPath",$CHMOD_ON_FOLDER_CREATE); - } - else { - mkdir("$folderPath",0777); - } - } - - return(0); - } else { - return(1); - } -} - -sub GetRootPath -{ -#use Cwd; - -# my $dir = getcwd; -# print $dir; -# $dir =~ s/$ENV{'DOCUMENT_ROOT'}//g; -# print $dir; -# return($dir); - -# $wk = $0; -# $wk =~ s/\/connector\.cgi//g; -# if($wk) { -# $current_dir = $wk; -# } else { -# $current_dir = `pwd`; -# } -# return($current_dir); -use Cwd; - - if($ENV{'DOCUMENT_ROOT'}) { - $dir = $ENV{'DOCUMENT_ROOT'}; - } else { - my $dir = getcwd; - $workdir =~ s/\/connector\.cgi//g; - $dir =~ s/$workdir//g; - } - return($dir); - - - -} -1; diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/upload.cgi b/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/upload.cgi deleted file mode 100644 index 38c5ea55092..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/upload.cgi +++ /dev/null @@ -1,87 +0,0 @@ -#!/usr/bin/env perl - -##### -# FCKeditor - The text editor for Internet - http://www.fckeditor.net -# Copyright (C) 2003-2010 Frederico Caldeira Knabben -# -# == BEGIN LICENSE == -# -# Licensed under the terms of any of the following licenses at your -# choice: -# -# - GNU General Public License Version 2 or later (the "GPL") -# http://www.gnu.org/licenses/gpl.html -# -# - GNU Lesser General Public License Version 2.1 or later (the "LGPL") -# http://www.gnu.org/licenses/lgpl.html -# -# - Mozilla Public License Version 1.1 or later (the "MPL") -# http://www.mozilla.org/MPL/MPL-1.1.html -# -# == END LICENSE == -# -# This is the File Manager Connector for Perl. -##### - -## -# ATTENTION: To enable this connector, look for the "SECURITY" comment in config.pl. -## - -## START: Hack for Windows (Not important to understand the editor code... Perl specific). -if(Windows_check()) { - chdir(GetScriptPath($0)); -} - -sub Windows_check -{ - # IIS,PWS(NT/95) - $www_server_os = $^O; - # Win98 & NT(SP4) - if($www_server_os eq "") { $www_server_os= $ENV{'OS'}; } - # AnHTTPd/Omni/IIS - if($ENV{'SERVER_SOFTWARE'} =~ /AnWeb|Omni|IIS\//i) { $www_server_os= 'win'; } - # Win Apache - if($ENV{'WINDIR'} ne "") { $www_server_os= 'win'; } - if($www_server_os=~ /win/i) { return(1); } - return(0); -} - -sub GetScriptPath { - local($path) = @_; - if($path =~ /[\:\/\\]/) { $path =~ s/(.*?)[\/\\][^\/\\]+$/$1/; } else { $path = '.'; } - $path; -} -## END: Hack for IIS - -require 'util.pl'; -require 'io.pl'; -require 'basexml.pl'; -require 'commands.pl'; -require 'upload_fck.pl'; -require 'config.pl'; - -&read_input(); -&DoResponse(); - -sub DoResponse -{ - # Get the main request information. - $sCommand = 'FileUpload'; - $sResourceType = &specialchar_cnv($FORM{'Type'}); - $sCurrentFolder = "/"; - - if ($sResourceType eq '') { - $sResourceType = 'File' ; - } - - if ( !($sResourceType =~ /^(File|Image|Flash|Media)$/) ) { - SendError( 1, "Invalid type specified" ) ; - } - - # File Upload doesn't have to Return XML, so it must be intercepted before anything. - if($sCommand eq 'FileUpload') { - FileUpload($sResourceType,$sCurrentFolder); - return ; - } - -} diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/upload_fck.pl b/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/upload_fck.pl deleted file mode 100644 index debdad639ef..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/upload_fck.pl +++ /dev/null @@ -1,686 +0,0 @@ -##### -# FCKeditor - The text editor for Internet - http://www.fckeditor.net -# Copyright (C) 2003-2010 Frederico Caldeira Knabben -# -# == BEGIN LICENSE == -# -# Licensed under the terms of any of the following licenses at your -# choice: -# -# - GNU General Public License Version 2 or later (the "GPL") -# http://www.gnu.org/licenses/gpl.html -# -# - GNU Lesser General Public License Version 2.1 or later (the "LGPL") -# http://www.gnu.org/licenses/lgpl.html -# -# - Mozilla Public License Version 1.1 or later (the "MPL") -# http://www.mozilla.org/MPL/MPL-1.1.html -# -# == END LICENSE == -# -# This is the File Manager Connector for Perl. -##### - -# image data save dir -$img_dir = './temp/'; - - -# File size max(unit KB) -$MAX_CONTENT_SIZE = 30000; - -# After file is uploaded, sometimes it is required to change its permissions -# so that it was possible to access it at the later time. -# If possible, it is recommended to set more restrictive permissions, like 0755. -# Set to 0 to disable this feature. -$CHMOD_ON_UPLOAD = 0777; - -# See comments above. -# Used when creating folders that does not exist. -$CHMOD_ON_FOLDER_CREATE = 0755; - -# Filelock (1=use,0=not use) -$PM{'flock'} = '1'; - - -# upload Content-Type list -my %UPLOAD_CONTENT_TYPE_LIST = ( - 'image/(x-)?png' => 'png', # PNG image - 'image/p?jpe?g' => 'jpg', # JPEG image - 'image/gif' => 'gif', # GIF image - 'image/x-xbitmap' => 'xbm', # XBM image - - 'image/(x-(MS-)?)?bmp' => 'bmp', # Windows BMP image - 'image/pict' => 'pict', # Macintosh PICT image - 'image/tiff' => 'tif', # TIFF image - 'application/pdf' => 'pdf', # PDF image - 'application/x-shockwave-flash' => 'swf', # Shockwave Flash - - 'video/(x-)?msvideo' => 'avi', # Microsoft Video - 'video/quicktime' => 'mov', # QuickTime Video - 'video/mpeg' => 'mpeg', # MPEG Video - 'video/x-mpeg2' => 'mpv2', # MPEG2 Video - - 'audio/(x-)?midi?' => 'mid', # MIDI Audio - 'audio/(x-)?wav' => 'wav', # WAV Audio - 'audio/basic' => 'au', # ULAW Audio - 'audio/mpeg' => 'mpga', # MPEG Audio - - 'application/(x-)?zip(-compressed)?' => 'zip', # ZIP Compress - - 'text/html' => 'html', # HTML - 'text/plain' => 'txt', # TEXT - '(?:application|text)/(?:rtf|richtext)' => 'rtf', # RichText - - 'application/msword' => 'doc', # Microsoft Word - 'application/vnd.ms-excel' => 'xls', # Microsoft Excel - - '' -); - -# Upload is permitted. -# A regular expression is possible. -my %UPLOAD_EXT_LIST = ( - 'png' => 'PNG image', - 'p?jpe?g|jpe|jfif|pjp' => 'JPEG image', - 'gif' => 'GIF image', - 'xbm' => 'XBM image', - - 'bmp|dib|rle' => 'Windows BMP image', - 'pi?ct' => 'Macintosh PICT image', - 'tiff?' => 'TIFF image', - 'pdf' => 'PDF image', - 'swf' => 'Shockwave Flash', - - 'avi' => 'Microsoft Video', - 'moo?v|qt' => 'QuickTime Video', - 'm(p(e?gv?|e|v)|1v)' => 'MPEG Video', - 'mp(v2|2v)' => 'MPEG2 Video', - - 'midi?|kar|smf|rmi|mff' => 'MIDI Audio', - 'wav' => 'WAVE Audio', - 'au|snd' => 'ULAW Audio', - 'mp(e?ga|2|a|3)|abs' => 'MPEG Audio', - - 'zip' => 'ZIP Compress', - 'lzh' => 'LZH Compress', - 'cab' => 'CAB Compress', - - 'd?html?' => 'HTML', - 'rtf|rtx' => 'RichText', - 'txt|text' => 'Text', - - '' -); - - -# sjis or euc -my $CHARCODE = 'sjis'; - -$TRANS_2BYTE_CODE = 0; - -############################################################################## -# Summary -# -# Form Read input -# -# Parameters -# Returns -# Memo -############################################################################## -sub read_input -{ -eval("use File::Copy;"); -eval("use File::Path;"); - - my ($FORM) = @_; - - if (defined $CHMOD_ON_FOLDER_CREATE && !$CHMOD_ON_FOLDER_CREATE) { - mkdir("$img_dir"); - } - else { - umask(000); - if (defined $CHMOD_ON_FOLDER_CREATE) { - mkdir("$img_dir",$CHMOD_ON_FOLDER_CREATE); - } - else { - mkdir("$img_dir",0777); - } - } - - undef $img_data_exists; - undef @NEWFNAMES; - undef @NEWFNAME_DATA; - - if($ENV{'CONTENT_LENGTH'} > 10000000 || $ENV{'CONTENT_LENGTH'} > $MAX_CONTENT_SIZE * 1024) { - &upload_error( - 'Size Error', - sprintf( - "Transmitting size is too large.MAX %d KB Now Size %d KB(%d bytes Over)", - $MAX_CONTENT_SIZE, - int($ENV{'CONTENT_LENGTH'} / 1024), - $ENV{'CONTENT_LENGTH'} - $MAX_CONTENT_SIZE * 1024 - ) - ); - } - - my $Buffer; - if($ENV{'CONTENT_TYPE'} =~ /multipart\/form-data/) { - # METHOD POST only - return unless($ENV{'CONTENT_LENGTH'}); - - binmode(STDIN); - # STDIN A pause character is detected.'(MacIE3.0 boundary of $ENV{'CONTENT_TYPE'} cannot be trusted.) - my $Boundary = ; - $Boundary =~ s/\x0D\x0A//; - $Boundary = quotemeta($Boundary); - while() { - if(/^\s*Content-Disposition:/i) { - my($name,$ContentType,$FileName); - # form data get - if(/\bname="([^"]+)"/i || /\bname=([^\s:;]+)/i) { - $name = $1; - $name =~ tr/+/ /; - $name =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg; - &Encode(\$name); - } - if(/\bfilename="([^"]*)"/i || /\bfilename=([^\s:;]*)/i) { - $FileName = $1 || 'unknown'; - } - # head read - while() { - last if(! /\w/); - if(/^\s*Content-Type:\s*"([^"]+)"/i || /^\s*Content-Type:\s*([^\s:;]+)/i) { - $ContentType = $1; - } - } - # body read - $value = ""; - while() { - last if(/^$Boundary/o); - $value .= $_; - }; - $lastline = $_; - $value =~s /\x0D\x0A$//; - if($value ne '') { - if($FileName || $ContentType) { - $img_data_exists = 1; - ( - $FileName, # - $Ext, # - $Length, # - $ImageWidth, # - $ImageHeight, # - $ContentName # - ) = &CheckContentType(\$value,$FileName,$ContentType); - - $FORM{$name} = $FileName; - $new_fname = $FileName; - push(@NEWFNAME_DATA,"$FileName\t$Ext\t$Length\t$ImageWidth\t$ImageHeight\t$ContentName"); - - # Multi-upload correspondence - push(@NEWFNAMES,$new_fname); - open(OUT,">$img_dir/$new_fname"); - binmode(OUT); - eval "flock(OUT,2);" if($PM{'flock'} == 1); - print OUT $value; - eval "flock(OUT,8);" if($PM{'flock'} == 1); - close(OUT); - - } elsif($name) { - $value =~ tr/+/ /; - $value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg; - &Encode(\$value,'trans'); - $FORM{$name} .= "\0" if(defined($FORM{$name})); - $FORM{$name} .= $value; - } - } - }; - last if($lastline =~ /^$Boundary\-\-/o); - } - } elsif($ENV{'CONTENT_LENGTH'}) { - read(STDIN,$Buffer,$ENV{'CONTENT_LENGTH'}); - } - foreach(split(/&/,$Buffer),split(/&/,$ENV{'QUERY_STRING'})) { - my($name, $value) = split(/=/); - $name =~ tr/+/ /; - $name =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg; - $value =~ tr/+/ /; - $value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg; - - &Encode(\$name); - &Encode(\$value,'trans'); - $FORM{$name} .= "\0" if(defined($FORM{$name})); - $FORM{$name} .= $value; - - } - -} - -############################################################################## -# Summary -# -# CheckContentType -# -# Parameters -# Returns -# Memo -############################################################################## -sub CheckContentType -{ - - my($DATA,$FileName,$ContentType) = @_; - my($Ext,$ImageWidth,$ImageHeight,$ContentName,$Infomation); - my $DataLength = length($$DATA); - - # An unknown file type - - $_ = $ContentType; - my $UnknownType = ( - !$_ - || /^application\/(x-)?macbinary$/i - || /^application\/applefile$/i - || /^application\/octet-stream$/i - || /^text\/plane$/i - || /^x-unknown-content-type/i - ); - - # MacBinary(Mac Unnecessary data are deleted.) - if($UnknownType || $ENV{'HTTP_USER_AGENT'} =~ /Macintosh|Mac_/) { - if($DataLength > 128 && !unpack("C",substr($$DATA,0,1)) && !unpack("C",substr($$DATA,74,1)) && !unpack("C",substr($$DATA,82,1)) ) { - my $MacBinary_ForkLength = unpack("N", substr($$DATA, 83, 4)); # ForkLength Get - my $MacBinary_FileName = quotemeta(substr($$DATA, 2, unpack("C",substr($$DATA, 1, 1)))); - if($MacBinary_FileName && $MacBinary_ForkLength && $DataLength >= $MacBinary_ForkLength + 128 - && ($FileName =~ /$MacBinary_FileName/i || substr($$DATA,102,4) eq 'mBIN')) { # DATA TOP 128byte MacBinary!! - $$DATA = substr($$DATA,128,$MacBinary_ForkLength); - my $ResourceLength = $DataLength - $MacBinary_ForkLength - 128; - $DataLength = $MacBinary_ForkLength; - } - } - } - - # A file name is changed into EUC. -# &jcode::convert(\$FileName,'euc',$FormCodeDefault); -# &jcode::h2z_euc(\$FileName); - $FileName =~ s/^.*\\//; # Windows, Mac - $FileName =~ s/^.*\///; # UNIX - $FileName =~ s/&/&/g; - $FileName =~ s/"/"/g; - $FileName =~ s//>/g; -# -# if($CHARCODE ne 'euc') { -# &jcode::convert(\$FileName,$CHARCODE,'euc'); -# } - - # An extension is extracted and it changes into a small letter. - my $FileExt; - if($FileName =~ /\.(\w+)$/) { - $FileExt = $1; - $FileExt =~ tr/A-Z/a-z/; - } - - # Executable file detection (ban on upload) - if($$DATA =~ /^MZ/) { - $Ext = 'exe'; - } - # text - if(!$Ext && ($UnknownType || $ContentType =~ /^text\//i || $ContentType =~ /^application\/(?:rtf|richtext)$/i || $ContentType =~ /^image\/x-xbitmap$/i) - && ! $$DATA =~ /[\000-\006\177\377]/) { -# $$DATA =~ s/\x0D\x0A/\n/g; -# $$DATA =~ tr/\x0D\x0A/\n\n/; -# -# if( -# $$DATA =~ /<\s*SCRIPT(?:.|\n)*?>/i -# || $$DATA =~ /<\s*(?:.|\n)*?\bONLOAD\s*=(?:.|\n)*?>/i -# || $$DATA =~ /<\s*(?:.|\n)*?\bONCLICK\s*=(?:.|\n)*?>/i -# ) { -# $Infomation = '(JavaScript contains)'; -# } -# if($$DATA =~ /<\s*TABLE(?:.|\n)*?>/i -# || $$DATA =~ /<\s*BLINK(?:.|\n)*?>/i -# || $$DATA =~ /<\s*MARQUEE(?:.|\n)*?>/i -# || $$DATA =~ /<\s*OBJECT(?:.|\n)*?>/i -# || $$DATA =~ /<\s*EMBED(?:.|\n)*?>/i -# || $$DATA =~ /<\s*FRAME(?:.|\n)*?>/i -# || $$DATA =~ /<\s*APPLET(?:.|\n)*?>/i -# || $$DATA =~ /<\s*FORM(?:.|\n)*?>/i -# || $$DATA =~ /<\s*(?:.|\n)*?\bSRC\s*=(?:.|\n)*?>/i -# || $$DATA =~ /<\s*(?:.|\n)*?\bDYNSRC\s*=(?:.|\n)*?>/i -# ) { -# $Infomation = '(the HTML tag which is not safe is included)'; -# } - - if($FileExt =~ /^txt$/i || $FileExt =~ /^cgi$/i || $FileExt =~ /^pl$/i) { # Text File - $Ext = 'txt'; - } elsif($ContentType =~ /^text\/html$/i || $FileExt =~ /html?/i || $$DATA =~ /<\s*HTML(?:.|\n)*?>/i) { # HTML File - $Ext = 'html'; - } elsif($ContentType =~ /^image\/x-xbitmap$/i || $FileExt =~ /^xbm$/i) { # XBM(x-BitMap) Image - my $XbmName = $1; - my ($XbmWidth, $XbmHeight); - if($$DATA =~ /\#define\s*$XbmName\_width\s*(\d+)/i) { - $XbmWidth = $1; - } - if($$DATA =~ /\#define\s*$XbmName\_height\s*(\d+)/i) { - $XbmHeight = $1; - } - if($XbmWidth && $XbmHeight) { - $Ext = 'xbm'; - $ImageWidth = $XbmWidth; - $ImageHeight = $XbmHeight; - } - } else { # - $Ext = 'txt'; - } - } - - # image - if(!$Ext && ($UnknownType || $ContentType =~ /^image\//i)) { - # PNG - if($$DATA =~ /^\x89PNG\x0D\x0A\x1A\x0A/) { - if(substr($$DATA, 12, 4) eq 'IHDR') { - $Ext = 'png'; - ($ImageWidth, $ImageHeight) = unpack("N2", substr($$DATA, 16, 8)); - } - } elsif($$DATA =~ /^GIF8(?:9|7)a/) { # GIF89a(modified), GIF89a, GIF87a - $Ext = 'gif'; - ($ImageWidth, $ImageHeight) = unpack("v2", substr($$DATA, 6, 4)); - } elsif($$DATA =~ /^II\x2a\x00\x08\x00\x00\x00/ || $$DATA =~ /^MM\x00\x2a\x00\x00\x00\x08/) { # TIFF - $Ext = 'tif'; - } elsif($$DATA =~ /^BM/) { # BMP - $Ext = 'bmp'; - } elsif($$DATA =~ /^\xFF\xD8\xFF/ || $$DATA =~ /JFIF/) { # JPEG - my $HeaderPoint = index($$DATA, "\xFF\xD8\xFF", 0); - my $Point = $HeaderPoint + 2; - while($Point < $DataLength) { - my($Maker, $MakerType, $MakerLength) = unpack("C2n",substr($$DATA,$Point,4)); - if($Maker != 0xFF || $MakerType == 0xd9 || $MakerType == 0xda) { - last; - } elsif($MakerType >= 0xC0 && $MakerType <= 0xC3) { - $Ext = 'jpg'; - ($ImageHeight, $ImageWidth) = unpack("n2", substr($$DATA, $Point + 5, 4)); - if($HeaderPoint > 0) { - $$DATA = substr($$DATA, $HeaderPoint); - $DataLength = length($$DATA); - } - last; - } else { - $Point += $MakerLength + 2; - } - } - } - } - - # audio - if(!$Ext && ($UnknownType || $ContentType =~ /^audio\//i)) { - # MIDI Audio - if($$DATA =~ /^MThd/) { - $Ext = 'mid'; - } elsif($$DATA =~ /^\x2esnd/) { # ULAW Audio - $Ext = 'au'; - } elsif($$DATA =~ /^RIFF/ || $$DATA =~ /^ID3/ && $$DATA =~ /RIFF/) { - my $HeaderPoint = index($$DATA, "RIFF", 0); - $_ = substr($$DATA, $HeaderPoint + 8, 8); - if(/^WAVEfmt $/) { - # WAVE - if(unpack("V",substr($$DATA, $HeaderPoint + 16, 4)) == 16) { - $Ext = 'wav'; - } else { # RIFF WAVE MP3 - $Ext = 'mp3'; - } - } elsif(/^RMIDdata$/) { # RIFF MIDI - $Ext = 'rmi'; - } elsif(/^RMP3data$/) { # RIFF MP3 - $Ext = 'rmp'; - } - if($ContentType =~ /^audio\//i) { - $Infomation .= '(RIFF '. substr($$DATA, $HeaderPoint + 8, 4). ')'; - } - } - } - - # a binary file - unless ($Ext) { - # PDF image - if($$DATA =~ /^\%PDF/) { - # Picture size is not measured. - $Ext = 'pdf'; - } elsif($$DATA =~ /^FWS/) { # Shockwave Flash - $Ext = 'swf'; - } elsif($$DATA =~ /^RIFF/ || $$DATA =~ /^ID3/ && $$DATA =~ /RIFF/) { - my $HeaderPoint = index($$DATA, "RIFF", 0); - $_ = substr($$DATA,$HeaderPoint + 8, 8); - # AVI - if(/^AVI LIST$/) { - $Ext = 'avi'; - } - if($ContentType =~ /^video\//i) { - $Infomation .= '(RIFF '. substr($$DATA, $HeaderPoint + 8, 4). ')'; - } - } elsif($$DATA =~ /^PK/) { # ZIP Compress File - $Ext = 'zip'; - } elsif($$DATA =~ /^MSCF/) { # CAB Compress File - $Ext = 'cab'; - } elsif($$DATA =~ /^Rar\!/) { # RAR Compress File - $Ext = 'rar'; - } elsif(substr($$DATA, 2, 5) =~ /^\-lh(\d+|d)\-$/) { # LHA Compress File - $Infomation .= "(lh$1)"; - $Ext = 'lzh'; - } elsif(substr($$DATA, 325, 25) eq "Apple Video Media Handler" || substr($$DATA, 325, 30) eq "Apple \x83\x72\x83\x66\x83\x49\x81\x45\x83\x81\x83\x66\x83\x42\x83\x41\x83\x6E\x83\x93\x83\x68\x83\x89") { - # QuickTime - $Ext = 'mov'; - } - } - - # Header analysis failure - unless ($Ext) { - # It will be followed if it applies for the MIME type from the browser. - foreach (keys %UPLOAD_CONTENT_TYPE_LIST) { - next unless ($_); - if($ContentType =~ /^$_$/i) { - $Ext = $UPLOAD_CONTENT_TYPE_LIST{$_}; - $ContentName = &CheckContentExt($Ext); - if( - grep {$_ eq $Ext;} ( - 'png', - 'gif', - 'jpg', - 'xbm', - 'tif', - 'bmp', - 'pdf', - 'swf', - 'mov', - 'zip', - 'cab', - 'lzh', - 'rar', - 'mid', - 'rmi', - 'au', - 'wav', - 'avi', - 'exe' - ) - ) { - $Infomation .= ' / Header analysis failure'; - } - if($Ext ne $FileExt && &CheckContentExt($FileExt) eq $ContentName) { - $Ext = $FileExt; - } - last; - } - } - # a MIME type is unknown--It judges from an extension. - unless ($Ext) { - $ContentName = &CheckContentExt($FileExt); - if($ContentName) { - $Ext = $FileExt; - $Infomation .= ' / MIME type is unknown('. $ContentType. ')'; - last; - } - } - } - -# $ContentName = &CheckContentExt($Ext) unless($ContentName); -# if($Ext && $ContentName) { -# $ContentName .= $Infomation; -# } else { -# &upload_error( -# 'Extension Error', -# "$FileName A not corresponding extension ($Ext)
The extension which can be responded ". join(',', sort values(%UPLOAD_EXT_LIST)) -# ); -# } - -# # SSI Tag Deletion -# if($Ext =~ /.?html?/ && $$DATA =~ /<\!/) { -# foreach ( -# 'config', -# 'echo', -# 'exec', -# 'flastmod', -# 'fsize', -# 'include' -# ) { -# $$DATA =~ s/\#\s*$_/\&\#35\;$_/ig -# } -# } - - return ( - $FileName, - $Ext, - int($DataLength / 1024 + 1), - $ImageWidth, - $ImageHeight, - $ContentName - ); -} - -############################################################################## -# Summary -# -# Extension discernment -# -# Parameters -# Returns -# Memo -############################################################################## - -sub CheckContentExt -{ - - my($Ext) = @_; - my $ContentName; - foreach (keys %UPLOAD_EXT_LIST) { - next unless ($_); - if($_ && $Ext =~ /^$_$/) { - $ContentName = $UPLOAD_EXT_LIST{$_}; - last; - } - } - return $ContentName; - -} - -############################################################################## -# Summary -# -# Form decode -# -# Parameters -# Returns -# Memo -############################################################################## -sub Encode -{ - - my($value,$Trans) = @_; - -# my $FormCode = &jcode::getcode($value) || $FormCodeDefault; -# $FormCodeDefault ||= $FormCode; -# -# if($Trans && $TRANS_2BYTE_CODE) { -# if($FormCode ne 'euc') { -# &jcode::convert($value, 'euc', $FormCode); -# } -# &jcode::tr( -# $value, -# "\xA3\xB0-\xA3\xB9\xA3\xC1-\xA3\xDA\xA3\xE1-\xA3\xFA", -# '0-9A-Za-z' -# ); -# if($CHARCODE ne 'euc') { -# &jcode::convert($value,$CHARCODE,'euc'); -# } -# } else { -# if($CHARCODE ne $FormCode) { -# &jcode::convert($value,$CHARCODE,$FormCode); -# } -# } -# if($CHARCODE eq 'euc') { -# &jcode::h2z_euc($value); -# } elsif($CHARCODE eq 'sjis') { -# &jcode::h2z_sjis($value); -# } - -} - -############################################################################## -# Summary -# -# Error Msg -# -# Parameters -# Returns -# Memo -############################################################################## - -sub upload_error -{ - - local($error_message) = $_[0]; - local($error_message2) = $_[1]; - - print "Content-type: text/html\n\n"; - print< - -Error Message - - - - - -
Error Message
-
    -

    $error_message

    -$error_message2
    -
- - -EOF - &rm_tmp_uploaded_files; # Image Temporary deletion - exit; -} - -############################################################################## -# Summary -# -# Image Temporary deletion -# -# Parameters -# Returns -# Memo -############################################################################## - -sub rm_tmp_uploaded_files -{ - if($img_data_exists == 1){ - sleep 1; - foreach $fname_list(@NEWFNAMES) { - if(-e "$img_dir/$fname_list") { - unlink("$img_dir/$fname_list"); - } - } - } - -} -1; diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/util.pl b/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/util.pl deleted file mode 100644 index c245a040231..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/perl/util.pl +++ /dev/null @@ -1,66 +0,0 @@ -##### -# FCKeditor - The text editor for Internet - http://www.fckeditor.net -# Copyright (C) 2003-2010 Frederico Caldeira Knabben -# -# == BEGIN LICENSE == -# -# Licensed under the terms of any of the following licenses at your -# choice: -# -# - GNU General Public License Version 2 or later (the "GPL") -# http://www.gnu.org/licenses/gpl.html -# -# - GNU Lesser General Public License Version 2.1 or later (the "LGPL") -# http://www.gnu.org/licenses/lgpl.html -# -# - Mozilla Public License Version 1.1 or later (the "MPL") -# http://www.mozilla.org/MPL/MPL-1.1.html -# -# == END LICENSE == -# -# This is the File Manager Connector for Perl. -##### - -sub RemoveFromStart -{ - local($sourceString, $charToRemove) = @_; - $sPattern = '^' . $charToRemove . '+' ; - $sourceString =~ s/^$charToRemove+//g; - return $sourceString; -} - -sub RemoveFromEnd -{ - local($sourceString, $charToRemove) = @_; - $sPattern = $charToRemove . '+$' ; - $sourceString =~ s/$charToRemove+$//g; - return $sourceString; -} - -sub ConvertToXmlAttribute -{ - local($value) = @_; - return(&specialchar_cnv($value)); -} - -sub specialchar_cnv -{ - local($ch) = @_; - - $ch =~ s/&/&/g; # & - $ch =~ s/\"/"/g; #" - $ch =~ s/\'/'/g; # ' - $ch =~ s//>/g; # > - return($ch); -} - -sub JS_cnv -{ - local($ch) = @_; - - $ch =~ s/\"/\\\"/g; #" - return($ch); -} - -1; diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/config.py b/htdocs/includes/fckeditor/editor/filemanager/connectors/py/config.py deleted file mode 100644 index 6ad1643395c..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/config.py +++ /dev/null @@ -1,146 +0,0 @@ -#!/usr/bin/env python -""" - * FCKeditor - The text editor for Internet - http://www.fckeditor.net - * Copyright (C) 2003-2010 Frederico Caldeira Knabben - * - * == BEGIN LICENSE == - * - * Licensed under the terms of any of the following licenses at your - * choice: - * - * - GNU General Public License Version 2 or later (the "GPL") - * http://www.gnu.org/licenses/gpl.html - * - * - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - * http://www.gnu.org/licenses/lgpl.html - * - * - Mozilla Public License Version 1.1 or later (the "MPL") - * http://www.mozilla.org/MPL/MPL-1.1.html - * - * == END LICENSE == - * - * Configuration file for the File Manager Connector for Python -""" - -# INSTALLATION NOTE: You must set up your server environment accordingly to run -# python scripts. This connector requires Python 2.4 or greater. -# -# Supported operation modes: -# * WSGI (recommended): You'll need apache + mod_python + modpython_gateway -# or any web server capable of the WSGI python standard -# * Plain Old CGI: Any server capable of running standard python scripts -# (although mod_python is recommended for performance) -# This was the previous connector version operation mode -# -# If you're using Apache web server, replace the htaccess.txt to to .htaccess, -# and set the proper options and paths. -# For WSGI and mod_python, you may need to download modpython_gateway from: -# http://projects.amor.org/misc/svn/modpython_gateway.py and copy it in this -# directory. - - -# SECURITY: You must explicitly enable this "connector". (Set it to "True"). -# WARNING: don't just set "ConfigIsEnabled = True", you must be sure that only -# authenticated users can access this file or use some kind of session checking. -Enabled = False - -# Path to user files relative to the document root. -UserFilesPath = '/userfiles/' - -# Fill the following value it you prefer to specify the absolute path for the -# user files directory. Useful if you are using a virtual directory, symbolic -# link or alias. Examples: 'C:\\MySite\\userfiles\\' or '/root/mysite/userfiles/'. -# Attention: The above 'UserFilesPath' must point to the same directory. -# WARNING: GetRootPath may not work in virtual or mod_python configurations, and -# may not be thread safe. Use this configuration parameter instead. -UserFilesAbsolutePath = '' - -# Due to security issues with Apache modules, it is recommended to leave the -# following setting enabled. -ForceSingleExtension = True - -# What the user can do with this connector -ConfigAllowedCommands = [ 'QuickUpload', 'FileUpload', 'GetFolders', 'GetFoldersAndFiles', 'CreateFolder' ] - -# Allowed Resource Types -ConfigAllowedTypes = ['File', 'Image', 'Flash', 'Media'] - -# After file is uploaded, sometimes it is required to change its permissions -# so that it was possible to access it at the later time. -# If possible, it is recommended to set more restrictive permissions, like 0755. -# Set to 0 to disable this feature. -# Note: not needed on Windows-based servers. -ChmodOnUpload = 0755 - -# See comments above. -# Used when creating folders that does not exist. -ChmodOnFolderCreate = 0755 - -# Do not touch this 3 lines, see "Configuration settings for each Resource Type" -AllowedExtensions = {}; DeniedExtensions = {}; -FileTypesPath = {}; FileTypesAbsolutePath = {}; -QuickUploadPath = {}; QuickUploadAbsolutePath = {}; - -# Configuration settings for each Resource Type -# -# - AllowedExtensions: the possible extensions that can be allowed. -# If it is empty then any file type can be uploaded. -# - DeniedExtensions: The extensions that won't be allowed. -# If it is empty then no restrictions are done here. -# -# For a file to be uploaded it has to fulfill both the AllowedExtensions -# and DeniedExtensions (that's it: not being denied) conditions. -# -# - FileTypesPath: the virtual folder relative to the document root where -# these resources will be located. -# Attention: It must start and end with a slash: '/' -# -# - FileTypesAbsolutePath: the physical path to the above folder. It must be -# an absolute path. -# If it's an empty string then it will be autocalculated. -# Useful if you are using a virtual directory, symbolic link or alias. -# Examples: 'C:\\MySite\\userfiles\\' or '/root/mysite/userfiles/'. -# Attention: The above 'FileTypesPath' must point to the same directory. -# Attention: It must end with a slash: '/' -# -# -# - QuickUploadPath: the virtual folder relative to the document root where -# these resources will be uploaded using the Upload tab in the resources -# dialogs. -# Attention: It must start and end with a slash: '/' -# -# - QuickUploadAbsolutePath: the physical path to the above folder. It must be -# an absolute path. -# If it's an empty string then it will be autocalculated. -# Useful if you are using a virtual directory, symbolic link or alias. -# Examples: 'C:\\MySite\\userfiles\\' or '/root/mysite/userfiles/'. -# Attention: The above 'QuickUploadPath' must point to the same directory. -# Attention: It must end with a slash: '/' - -AllowedExtensions['File'] = ['7z','aiff','asf','avi','bmp','csv','doc','fla','flv','gif','gz','gzip','jpeg','jpg','mid','mov','mp3','mp4','mpc','mpeg','mpg','ods','odt','pdf','png','ppt','pxd','qt','ram','rar','rm','rmi','rmvb','rtf','sdc','sitd','swf','sxc','sxw','tar','tgz','tif','tiff','txt','vsd','wav','wma','wmv','xls','xml','zip'] -DeniedExtensions['File'] = [] -FileTypesPath['File'] = UserFilesPath + 'file/' -FileTypesAbsolutePath['File'] = (not UserFilesAbsolutePath == '') and (UserFilesAbsolutePath + 'file/') or '' -QuickUploadPath['File'] = FileTypesPath['File'] -QuickUploadAbsolutePath['File'] = FileTypesAbsolutePath['File'] - -AllowedExtensions['Image'] = ['bmp','gif','jpeg','jpg','png'] -DeniedExtensions['Image'] = [] -FileTypesPath['Image'] = UserFilesPath + 'image/' -FileTypesAbsolutePath['Image'] = (not UserFilesAbsolutePath == '') and UserFilesAbsolutePath + 'image/' or '' -QuickUploadPath['Image'] = FileTypesPath['Image'] -QuickUploadAbsolutePath['Image']= FileTypesAbsolutePath['Image'] - -AllowedExtensions['Flash'] = ['swf','flv'] -DeniedExtensions['Flash'] = [] -FileTypesPath['Flash'] = UserFilesPath + 'flash/' -FileTypesAbsolutePath['Flash'] = ( not UserFilesAbsolutePath == '') and UserFilesAbsolutePath + 'flash/' or '' -QuickUploadPath['Flash'] = FileTypesPath['Flash'] -QuickUploadAbsolutePath['Flash']= FileTypesAbsolutePath['Flash'] - -AllowedExtensions['Media'] = ['aiff','asf','avi','bmp','fla', 'flv','gif','jpeg','jpg','mid','mov','mp3','mp4','mpc','mpeg','mpg','png','qt','ram','rm','rmi','rmvb','swf','tif','tiff','wav','wma','wmv'] -DeniedExtensions['Media'] = [] -FileTypesPath['Media'] = UserFilesPath + 'media/' -FileTypesAbsolutePath['Media'] = ( not UserFilesAbsolutePath == '') and UserFilesAbsolutePath + 'media/' or '' -QuickUploadPath['Media'] = FileTypesPath['Media'] -QuickUploadAbsolutePath['Media']= FileTypesAbsolutePath['Media'] diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/connector.py b/htdocs/includes/fckeditor/editor/filemanager/connectors/py/connector.py deleted file mode 100644 index fe989b90d83..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/connector.py +++ /dev/null @@ -1,121 +0,0 @@ -#!/usr/bin/env python - -""" -FCKeditor - The text editor for Internet - http://www.fckeditor.net -Copyright (C) 2003-2010 Frederico Caldeira Knabben - -== BEGIN LICENSE == - -Licensed under the terms of any of the following licenses at your -choice: - - - GNU General Public License Version 2 or later (the "GPL") - http://www.gnu.org/licenses/gpl.html - - - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - http://www.gnu.org/licenses/lgpl.html - - - Mozilla Public License Version 1.1 or later (the "MPL") - http://www.mozilla.org/MPL/MPL-1.1.html - -== END LICENSE == - -Connector for Python (CGI and WSGI). - -See config.py for configuration settings - -""" -import os - -from fckutil import * -from fckcommands import * # default command's implementation -from fckoutput import * # base http, xml and html output mixins -from fckconnector import FCKeditorConnectorBase # import base connector -import config as Config - -class FCKeditorConnector( FCKeditorConnectorBase, - GetFoldersCommandMixin, - GetFoldersAndFilesCommandMixin, - CreateFolderCommandMixin, - UploadFileCommandMixin, - BaseHttpMixin, BaseXmlMixin, BaseHtmlMixin ): - "The Standard connector class." - def doResponse(self): - "Main function. Process the request, set headers and return a string as response." - s = "" - # Check if this connector is disabled - if not(Config.Enabled): - return self.sendError(1, "This connector is disabled. Please check the connector configurations in \"editor/filemanager/connectors/py/config.py\" and try again.") - # Make sure we have valid inputs - for key in ("Command","Type","CurrentFolder"): - if not self.request.has_key (key): - return - # Get command, resource type and current folder - command = self.request.get("Command") - resourceType = self.request.get("Type") - currentFolder = getCurrentFolder(self.request.get("CurrentFolder")) - # Check for invalid paths - if currentFolder is None: - if (command == "FileUpload"): - return self.sendUploadResults( errorNo = 102, customMsg = "" ) - else: - return self.sendError(102, "") - - # Check if it is an allowed command - if ( not command in Config.ConfigAllowedCommands ): - return self.sendError( 1, 'The %s command isn\'t allowed' % command ) - - if ( not resourceType in Config.ConfigAllowedTypes ): - return self.sendError( 1, 'Invalid type specified' ) - - # Setup paths - if command == "QuickUpload": - self.userFilesFolder = Config.QuickUploadAbsolutePath[resourceType] - self.webUserFilesFolder = Config.QuickUploadPath[resourceType] - else: - self.userFilesFolder = Config.FileTypesAbsolutePath[resourceType] - self.webUserFilesFolder = Config.FileTypesPath[resourceType] - - if not self.userFilesFolder: # no absolute path given (dangerous...) - self.userFilesFolder = mapServerPath(self.environ, - self.webUserFilesFolder) - # Ensure that the directory exists. - if not os.path.exists(self.userFilesFolder): - try: - self.createServerFolder( self.userFilesFolder ) - except: - return self.sendError(1, "This connector couldn\'t access to local user\'s files directories. Please check the UserFilesAbsolutePath in \"editor/filemanager/connectors/py/config.py\" and try again. ") - - # File upload doesn't have to return XML, so intercept here - if (command == "FileUpload"): - return self.uploadFile(resourceType, currentFolder) - - # Create Url - url = combinePaths( self.webUserFilesFolder, currentFolder ) - - # Begin XML - s += self.createXmlHeader(command, resourceType, currentFolder, url) - # Execute the command - selector = {"GetFolders": self.getFolders, - "GetFoldersAndFiles": self.getFoldersAndFiles, - "CreateFolder": self.createFolder, - } - s += selector[command](resourceType, currentFolder) - s += self.createXmlFooter() - return s - -# Running from command line (plain old CGI) -if __name__ == '__main__': - try: - # Create a Connector Instance - conn = FCKeditorConnector() - data = conn.doResponse() - for header in conn.headers: - print '%s: %s' % header - print - print data - except: - print "Content-Type: text/plain" - print - import cgi - cgi.print_exception() diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckcommands.py b/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckcommands.py deleted file mode 100644 index f9e7b824b65..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckcommands.py +++ /dev/null @@ -1,202 +0,0 @@ -#!/usr/bin/env python - -""" -FCKeditor - The text editor for Internet - http://www.fckeditor.net -Copyright (C) 2003-2010 Frederico Caldeira Knabben - -== BEGIN LICENSE == - -Licensed under the terms of any of the following licenses at your -choice: - -- GNU General Public License Version 2 or later (the "GPL") -http://www.gnu.org/licenses/gpl.html - -- GNU Lesser General Public License Version 2.1 or later (the "LGPL") -http://www.gnu.org/licenses/lgpl.html - -- Mozilla Public License Version 1.1 or later (the "MPL") -http://www.mozilla.org/MPL/MPL-1.1.html - -== END LICENSE == - -Connector for Python (CGI and WSGI). - -""" - -import os -try: # Windows needs stdio set for binary mode for file upload to work. - import msvcrt - msvcrt.setmode (0, os.O_BINARY) # stdin = 0 - msvcrt.setmode (1, os.O_BINARY) # stdout = 1 -except ImportError: - pass - -from fckutil import * -from fckoutput import * -import config as Config - -class GetFoldersCommandMixin (object): - def getFolders(self, resourceType, currentFolder): - """ - Purpose: command to recieve a list of folders - """ - # Map the virtual path to our local server - serverPath = mapServerFolder(self.userFilesFolder,currentFolder) - s = """""" # Open the folders node - for someObject in os.listdir(serverPath): - someObjectPath = mapServerFolder(serverPath, someObject) - if os.path.isdir(someObjectPath): - s += """""" % ( - convertToXmlAttribute(someObject) - ) - s += """""" # Close the folders node - return s - -class GetFoldersAndFilesCommandMixin (object): - def getFoldersAndFiles(self, resourceType, currentFolder): - """ - Purpose: command to recieve a list of folders and files - """ - # Map the virtual path to our local server - serverPath = mapServerFolder(self.userFilesFolder,currentFolder) - # Open the folders / files node - folders = """""" - files = """""" - for someObject in os.listdir(serverPath): - someObjectPath = mapServerFolder(serverPath, someObject) - if os.path.isdir(someObjectPath): - folders += """""" % ( - convertToXmlAttribute(someObject) - ) - elif os.path.isfile(someObjectPath): - size = os.path.getsize(someObjectPath) - if size > 0: - size = round(size/1024) - if size < 1: - size = 1 - files += """""" % ( - convertToXmlAttribute(someObject), - size - ) - # Close the folders / files node - folders += """""" - files += """""" - return folders + files - -class CreateFolderCommandMixin (object): - def createFolder(self, resourceType, currentFolder): - """ - Purpose: command to create a new folder - """ - errorNo = 0; errorMsg =''; - if self.request.has_key("NewFolderName"): - newFolder = self.request.get("NewFolderName", None) - newFolder = sanitizeFolderName (newFolder) - try: - newFolderPath = mapServerFolder(self.userFilesFolder, combinePaths(currentFolder, newFolder)) - self.createServerFolder(newFolderPath) - except Exception, e: - errorMsg = str(e).decode('iso-8859-1').encode('utf-8') # warning with encodigns!!! - if hasattr(e,'errno'): - if e.errno==17: #file already exists - errorNo=0 - elif e.errno==13: # permission denied - errorNo = 103 - elif e.errno==36 or e.errno==2 or e.errno==22: # filename too long / no such file / invalid name - errorNo = 102 - else: - errorNo = 110 - else: - errorNo = 102 - return self.sendErrorNode ( errorNo, errorMsg ) - - def createServerFolder(self, folderPath): - "Purpose: physically creates a folder on the server" - # No need to check if the parent exists, just create all hierachy - - try: - permissions = Config.ChmodOnFolderCreate - if not permissions: - os.makedirs(folderPath) - except AttributeError: #ChmodOnFolderCreate undefined - permissions = 0755 - - if permissions: - oldumask = os.umask(0) - os.makedirs(folderPath,mode=0755) - os.umask( oldumask ) - -class UploadFileCommandMixin (object): - def uploadFile(self, resourceType, currentFolder): - """ - Purpose: command to upload files to server (same as FileUpload) - """ - errorNo = 0 - if self.request.has_key("NewFile"): - # newFile has all the contents we need - newFile = self.request.get("NewFile", "") - # Get the file name - newFileName = newFile.filename - newFileName = sanitizeFileName( newFileName ) - newFileNameOnly = removeExtension(newFileName) - newFileExtension = getExtension(newFileName).lower() - allowedExtensions = Config.AllowedExtensions[resourceType] - deniedExtensions = Config.DeniedExtensions[resourceType] - - if (allowedExtensions): - # Check for allowed - isAllowed = False - if (newFileExtension in allowedExtensions): - isAllowed = True - elif (deniedExtensions): - # Check for denied - isAllowed = True - if (newFileExtension in deniedExtensions): - isAllowed = False - else: - # No extension limitations - isAllowed = True - - if (isAllowed): - # Upload to operating system - # Map the virtual path to the local server path - currentFolderPath = mapServerFolder(self.userFilesFolder, currentFolder) - i = 0 - while (True): - newFilePath = os.path.join (currentFolderPath,newFileName) - if os.path.exists(newFilePath): - i += 1 - newFileName = "%s(%d).%s" % ( - newFileNameOnly, i, newFileExtension - ) - errorNo= 201 # file renamed - else: - # Read file contents and write to the desired path (similar to php's move_uploaded_file) - fout = file(newFilePath, 'wb') - while (True): - chunk = newFile.file.read(100000) - if not chunk: break - fout.write (chunk) - fout.close() - - if os.path.exists ( newFilePath ): - doChmod = False - try: - doChmod = Config.ChmodOnUpload - permissions = Config.ChmodOnUpload - except AttributeError: #ChmodOnUpload undefined - doChmod = True - permissions = 0755 - if ( doChmod ): - oldumask = os.umask(0) - os.chmod( newFilePath, permissions ) - os.umask( oldumask ) - - newFileUrl = combinePaths(self.webUserFilesFolder, currentFolder) + newFileName - - return self.sendUploadResults( errorNo , newFileUrl, newFileName ) - else: - return self.sendUploadResults( errorNo = 202, customMsg = "" ) - else: - return self.sendUploadResults( errorNo = 202, customMsg = "No File" ) diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckconnector.py b/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckconnector.py deleted file mode 100644 index c439939d8dd..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckconnector.py +++ /dev/null @@ -1,90 +0,0 @@ -#!/usr/bin/env python - -""" -FCKeditor - The text editor for Internet - http://www.fckeditor.net -Copyright (C) 2003-2010 Frederico Caldeira Knabben - -== BEGIN LICENSE == - -Licensed under the terms of any of the following licenses at your -choice: - -- GNU General Public License Version 2 or later (the "GPL") -http://www.gnu.org/licenses/gpl.html - -- GNU Lesser General Public License Version 2.1 or later (the "LGPL") -http://www.gnu.org/licenses/lgpl.html - -- Mozilla Public License Version 1.1 or later (the "MPL") -http://www.mozilla.org/MPL/MPL-1.1.html - -== END LICENSE == - -Base Connector for Python (CGI and WSGI). - -See config.py for configuration settings - -""" -import cgi, os - -from fckutil import * -from fckcommands import * # default command's implementation -from fckoutput import * # base http, xml and html output mixins -import config as Config - -class FCKeditorConnectorBase( object ): - "The base connector class. Subclass it to extend functionality (see Zope example)" - - def __init__(self, environ=None): - "Constructor: Here you should parse request fields, initialize variables, etc." - self.request = FCKeditorRequest(environ) # Parse request - self.headers = [] # Clean Headers - if environ: - self.environ = environ - else: - self.environ = os.environ - - # local functions - - def setHeader(self, key, value): - self.headers.append ((key, value)) - return - -class FCKeditorRequest(object): - "A wrapper around the request object" - def __init__(self, environ): - if environ: # WSGI - self.request = cgi.FieldStorage(fp=environ['wsgi.input'], - environ=environ, - keep_blank_values=1) - self.environ = environ - else: # plain old cgi - self.environ = os.environ - self.request = cgi.FieldStorage() - if 'REQUEST_METHOD' in self.environ and 'QUERY_STRING' in self.environ: - if self.environ['REQUEST_METHOD'].upper()=='POST': - # we are in a POST, but GET query_string exists - # cgi parses by default POST data, so parse GET QUERY_STRING too - self.get_request = cgi.FieldStorage(fp=None, - environ={ - 'REQUEST_METHOD':'GET', - 'QUERY_STRING':self.environ['QUERY_STRING'], - }, - ) - else: - self.get_request={} - - def has_key(self, key): - return self.request.has_key(key) or self.get_request.has_key(key) - - def get(self, key, default=None): - if key in self.request.keys(): - field = self.request[key] - elif key in self.get_request.keys(): - field = self.get_request[key] - else: - return default - if hasattr(field,"filename") and field.filename: #file upload, do not convert return value - return field - else: - return field.value diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckoutput.py b/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckoutput.py deleted file mode 100644 index 3740a015540..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckoutput.py +++ /dev/null @@ -1,119 +0,0 @@ -#!/usr/bin/env python - -""" -FCKeditor - The text editor for Internet - http://www.fckeditor.net -Copyright (C) 2003-2010 Frederico Caldeira Knabben - -== BEGIN LICENSE == - -Licensed under the terms of any of the following licenses at your -choice: - -- GNU General Public License Version 2 or later (the "GPL") -http://www.gnu.org/licenses/gpl.html - -- GNU Lesser General Public License Version 2.1 or later (the "LGPL") -http://www.gnu.org/licenses/lgpl.html - -- Mozilla Public License Version 1.1 or later (the "MPL") -http://www.mozilla.org/MPL/MPL-1.1.html - -== END LICENSE == - -Connector for Python (CGI and WSGI). - -""" - -from time import gmtime, strftime -import string - -def escape(text, replace=string.replace): - """ - Converts the special characters '<', '>', and '&'. - - RFC 1866 specifies that these characters be represented - in HTML as < > and & respectively. In Python - 1.5 we use the new string.replace() function for speed. - """ - text = replace(text, '&', '&') # must be done 1st - text = replace(text, '<', '<') - text = replace(text, '>', '>') - text = replace(text, '"', '"') - return text - -def convertToXmlAttribute(value): - if (value is None): - value = "" - return escape(value) - -class BaseHttpMixin(object): - def setHttpHeaders(self, content_type='text/xml'): - "Purpose: to prepare the headers for the xml to return" - # Prevent the browser from caching the result. - # Date in the past - self.setHeader('Expires','Mon, 26 Jul 1997 05:00:00 GMT') - # always modified - self.setHeader('Last-Modified',strftime("%a, %d %b %Y %H:%M:%S GMT", gmtime())) - # HTTP/1.1 - self.setHeader('Cache-Control','no-store, no-cache, must-revalidate') - self.setHeader('Cache-Control','post-check=0, pre-check=0') - # HTTP/1.0 - self.setHeader('Pragma','no-cache') - - # Set the response format. - self.setHeader( 'Content-Type', content_type + '; charset=utf-8' ) - return - -class BaseXmlMixin(object): - def createXmlHeader(self, command, resourceType, currentFolder, url): - "Purpose: returns the xml header" - self.setHttpHeaders() - # Create the XML document header - s = """""" - # Create the main connector node - s += """""" % ( - command, - resourceType - ) - # Add the current folder node - s += """""" % ( - convertToXmlAttribute(currentFolder), - convertToXmlAttribute(url), - ) - return s - - def createXmlFooter(self): - "Purpose: returns the xml footer" - return """""" - - def sendError(self, number, text): - "Purpose: in the event of an error, return an xml based error" - self.setHttpHeaders() - return ("""""" + - """""" + - self.sendErrorNode (number, text) + - """""" ) - - def sendErrorNode(self, number, text): - if number != 1: - return """""" % (number) - else: - return """""" % (number, convertToXmlAttribute(text)) - -class BaseHtmlMixin(object): - def sendUploadResults( self, errorNo = 0, fileUrl = '', fileName = '', customMsg = '' ): - self.setHttpHeaders("text/html") - "This is the function that sends the results of the uploading process" - - "Minified version of the document.domain automatic fix script (#1919)." - "The original script can be found at _dev/domain_fix_template.js" - return """""" % { - 'errorNumber': errorNo, - 'fileUrl': fileUrl.replace ('"', '\\"'), - 'fileName': fileName.replace ( '"', '\\"' ) , - 'customMsg': customMsg.replace ( '"', '\\"' ), - } diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckutil.py b/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckutil.py deleted file mode 100644 index b7528051400..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/fckutil.py +++ /dev/null @@ -1,130 +0,0 @@ -#!/usr/bin/env python - -""" -FCKeditor - The text editor for Internet - http://www.fckeditor.net -Copyright (C) 2003-2010 Frederico Caldeira Knabben - -== BEGIN LICENSE == - -Licensed under the terms of any of the following licenses at your -choice: - -- GNU General Public License Version 2 or later (the "GPL") -http://www.gnu.org/licenses/gpl.html - -- GNU Lesser General Public License Version 2.1 or later (the "LGPL") -http://www.gnu.org/licenses/lgpl.html - -- Mozilla Public License Version 1.1 or later (the "MPL") -http://www.mozilla.org/MPL/MPL-1.1.html - -== END LICENSE == - -Utility functions for the File Manager Connector for Python - -""" - -import string, re -import os -import config as Config - -# Generic manipulation functions - -def removeExtension(fileName): - index = fileName.rindex(".") - newFileName = fileName[0:index] - return newFileName - -def getExtension(fileName): - index = fileName.rindex(".") + 1 - fileExtension = fileName[index:] - return fileExtension - -def removeFromStart(string, char): - return string.lstrip(char) - -def removeFromEnd(string, char): - return string.rstrip(char) - -# Path functions - -def combinePaths( basePath, folder ): - return removeFromEnd( basePath, '/' ) + '/' + removeFromStart( folder, '/' ) - -def getFileName(filename): - " Purpose: helper function to extrapolate the filename " - for splitChar in ["/", "\\"]: - array = filename.split(splitChar) - if (len(array) > 1): - filename = array[-1] - return filename - -def sanitizeFolderName( newFolderName ): - "Do a cleanup of the folder name to avoid possible problems" - # Remove . \ / | : ? * " < > and control characters - return re.sub( '\\.|\\\\|\\/|\\||\\:|\\?|\\*|"|<|>|[\x00-\x1f\x7f-\x9f]', '_', newFolderName ) - -def sanitizeFileName( newFileName ): - "Do a cleanup of the file name to avoid possible problems" - # Replace dots in the name with underscores (only one dot can be there... security issue). - if ( Config.ForceSingleExtension ): # remove dots - newFileName = re.sub ( '\\.(?![^.]*$)', '_', newFileName ) ; - newFileName = newFileName.replace('\\','/') # convert windows to unix path - newFileName = os.path.basename (newFileName) # strip directories - # Remove \ / | : ? * - return re.sub ( '\\\\|\\/|\\||\\:|\\?|\\*|"|<|>|[\x00-\x1f\x7f-\x9f]/', '_', newFileName ) - -def getCurrentFolder(currentFolder): - if not currentFolder: - currentFolder = '/' - - # Check the current folder syntax (must begin and end with a slash). - if (currentFolder[-1] <> "/"): - currentFolder += "/" - if (currentFolder[0] <> "/"): - currentFolder = "/" + currentFolder - - # Ensure the folder path has no double-slashes - while '//' in currentFolder: - currentFolder = currentFolder.replace('//','/') - - # Check for invalid folder paths (..) - if '..' in currentFolder or '\\' in currentFolder: - return None - - # Check for invalid folder paths (..) - if re.search( '(/\\.)|(//)|([\\\\:\\*\\?\\""\\<\\>\\|]|[\x00-\x1F]|[\x7f-\x9f])', currentFolder ): - return None - - return currentFolder - -def mapServerPath( environ, url): - " Emulate the asp Server.mapPath function. Given an url path return the physical directory that it corresponds to " - # This isn't correct but for the moment there's no other solution - # If this script is under a virtual directory or symlink it will detect the problem and stop - return combinePaths( getRootPath(environ), url ) - -def mapServerFolder(resourceTypePath, folderPath): - return combinePaths ( resourceTypePath , folderPath ) - -def getRootPath(environ): - "Purpose: returns the root path on the server" - # WARNING: this may not be thread safe, and doesn't work w/ VirtualServer/mod_python - # Use Config.UserFilesAbsolutePath instead - - if environ.has_key('DOCUMENT_ROOT'): - return environ['DOCUMENT_ROOT'] - else: - realPath = os.path.realpath( './' ) - selfPath = environ['SCRIPT_FILENAME'] - selfPath = selfPath [ : selfPath.rfind( '/' ) ] - selfPath = selfPath.replace( '/', os.path.sep) - - position = realPath.find(selfPath) - - # This can check only that this script isn't run from a virtual dir - # But it avoids the problems that arise if it isn't checked - raise realPath - if ( position < 0 or position <> len(realPath) - len(selfPath) or realPath[ : position ]==''): - raise Exception('Sorry, can\'t map "UserFilesPath" to a physical path. You must set the "UserFilesAbsolutePath" value in "editor/filemanager/connectors/py/config.py".') - return realPath[ : position ] diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/htaccess.txt b/htdocs/includes/fckeditor/editor/filemanager/connectors/py/htaccess.txt deleted file mode 100644 index 82374196a9d..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/htaccess.txt +++ /dev/null @@ -1,23 +0,0 @@ -# replace the name of this file to .htaccess (if using apache), -# and set the proper options and paths according your enviroment - -Allow from all - -# If using mod_python uncomment this: -PythonPath "[r'C:\Archivos de programa\Apache Software Foundation\Apache2.2\htdocs\fckeditor\editor\filemanager\connectors\py'] + sys.path" - - -# Recomended: WSGI application running with mod_python and modpython_gateway -SetHandler python-program -PythonHandler modpython_gateway::handler -PythonOption wsgi.application wsgi::App - - -# Emulated CGI with mod_python and cgihandler -#AddHandler mod_python .py -#PythonHandler mod_python.cgihandler - - -# Plain old CGI -#Options +ExecCGI -#AddHandler cgi-script py diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/upload.py b/htdocs/includes/fckeditor/editor/filemanager/connectors/py/upload.py deleted file mode 100644 index 1a7aa009bb7..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/upload.py +++ /dev/null @@ -1,88 +0,0 @@ -#!/usr/bin/env python - -""" -FCKeditor - The text editor for Internet - http://www.fckeditor.net -Copyright (C) 2003-2010 Frederico Caldeira Knabben - -== BEGIN LICENSE == - -Licensed under the terms of any of the following licenses at your -choice: - -- GNU General Public License Version 2 or later (the "GPL") -http://www.gnu.org/licenses/gpl.html - -- GNU Lesser General Public License Version 2.1 or later (the "LGPL") -http://www.gnu.org/licenses/lgpl.html - -- Mozilla Public License Version 1.1 or later (the "MPL") -http://www.mozilla.org/MPL/MPL-1.1.html - -== END LICENSE == - -This is the "File Uploader" for Python - -""" -import os - -from fckutil import * -from fckcommands import * # default command's implementation -from fckconnector import FCKeditorConnectorBase # import base connector -import config as Config - -class FCKeditorQuickUpload( FCKeditorConnectorBase, - UploadFileCommandMixin, - BaseHttpMixin, BaseHtmlMixin): - def doResponse(self): - "Main function. Process the request, set headers and return a string as response." - # Check if this connector is disabled - if not(Config.Enabled): - return self.sendUploadResults(1, "This file uploader is disabled. Please check the \"editor/filemanager/connectors/py/config.py\"") - command = 'QuickUpload' - # The file type (from the QueryString, by default 'File'). - resourceType = self.request.get('Type','File') - currentFolder = "/" - # Check for invalid paths - if currentFolder is None: - return self.sendUploadResults(102, '', '', "") - - # Check if it is an allowed command - if ( not command in Config.ConfigAllowedCommands ): - return self.sendUploadResults( 1, '', '', 'The %s command isn\'t allowed' % command ) - - if ( not resourceType in Config.ConfigAllowedTypes ): - return self.sendUploadResults( 1, '', '', 'Invalid type specified' ) - - # Setup paths - self.userFilesFolder = Config.QuickUploadAbsolutePath[resourceType] - self.webUserFilesFolder = Config.QuickUploadPath[resourceType] - if not self.userFilesFolder: # no absolute path given (dangerous...) - self.userFilesFolder = mapServerPath(self.environ, - self.webUserFilesFolder) - - # Ensure that the directory exists. - if not os.path.exists(self.userFilesFolder): - try: - self.createServerFoldercreateServerFolder( self.userFilesFolder ) - except: - return self.sendError(1, "This connector couldn\'t access to local user\'s files directories. Please check the UserFilesAbsolutePath in \"editor/filemanager/connectors/py/config.py\" and try again. ") - - # File upload doesn't have to return XML, so intercept here - return self.uploadFile(resourceType, currentFolder) - -# Running from command line (plain old CGI) -if __name__ == '__main__': - try: - # Create a Connector Instance - conn = FCKeditorQuickUpload() - data = conn.doResponse() - for header in conn.headers: - if not header is None: - print '%s: %s' % header - print - print data - except: - print "Content-Type: text/plain" - print - import cgi - cgi.print_exception() diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/wsgi.py b/htdocs/includes/fckeditor/editor/filemanager/connectors/py/wsgi.py deleted file mode 100644 index 829ede6fa5e..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/wsgi.py +++ /dev/null @@ -1,58 +0,0 @@ -#!/usr/bin/env python - -""" -FCKeditor - The text editor for Internet - http://www.fckeditor.net -Copyright (C) 2003-2010 Frederico Caldeira Knabben - -== BEGIN LICENSE == - -Licensed under the terms of any of the following licenses at your -choice: - - - GNU General Public License Version 2 or later (the "GPL") - http://www.gnu.org/licenses/gpl.html - - - GNU Lesser General Public License Version 2.1 or later (the "LGPL") - http://www.gnu.org/licenses/lgpl.html - - - Mozilla Public License Version 1.1 or later (the "MPL") - http://www.mozilla.org/MPL/MPL-1.1.html - -== END LICENSE == - -Connector/QuickUpload for Python (WSGI wrapper). - -See config.py for configuration settings - -""" - -from connector import FCKeditorConnector -from upload import FCKeditorQuickUpload - -import cgitb -from cStringIO import StringIO - -# Running from WSGI capable server (recomended) -def App(environ, start_response): - "WSGI entry point. Run the connector" - if environ['SCRIPT_NAME'].endswith("connector.py"): - conn = FCKeditorConnector(environ) - elif environ['SCRIPT_NAME'].endswith("upload.py"): - conn = FCKeditorQuickUpload(environ) - else: - start_response ("200 Ok", [('Content-Type','text/html')]) - yield "Unknown page requested: " - yield environ['SCRIPT_NAME'] - return - try: - # run the connector - data = conn.doResponse() - # Start WSGI response: - start_response ("200 Ok", conn.headers) - # Send response text - yield data - except: - start_response("500 Internal Server Error",[("Content-type","text/html")]) - file = StringIO() - cgitb.Hook(file = file).handle() - yield file.getvalue() diff --git a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/zope.py b/htdocs/includes/fckeditor/editor/filemanager/connectors/py/zope.py deleted file mode 100644 index 0b9a2bf2d1c..00000000000 --- a/htdocs/includes/fckeditor/editor/filemanager/connectors/py/zope.py +++ /dev/null @@ -1,188 +0,0 @@ -#!/usr/bin/env python - -""" -FCKeditor - The text editor for Internet - http://www.fckeditor.net -Copyright (C) 2003-2010 Frederico Caldeira Knabben - -== BEGIN LICENSE == - -Licensed under the terms of any of the following licenses at your -choice: - -- GNU General Public License Version 2 or later (the "GPL") -http://www.gnu.org/licenses/gpl.html - -- GNU Lesser General Public License Version 2.1 or later (the "LGPL") -http://www.gnu.org/licenses/lgpl.html - -- Mozilla Public License Version 1.1 or later (the "MPL") -http://www.mozilla.org/MPL/MPL-1.1.html - -== END LICENSE == - -Connector for Python and Zope. - -This code was not tested at all. -It just was ported from pre 2.5 release, so for further reference see -\editor\filemanager\browser\default\connectors\py\connector.py in previous -releases. - -""" - -from fckutil import * -from connector import * -import config as Config - -class FCKeditorConnectorZope(FCKeditorConnector): - """ - Zope versiof FCKeditorConnector - """ - # Allow access (Zope) - __allow_access_to_unprotected_subobjects__ = 1 - - def __init__(self, context=None): - """ - Constructor - """ - FCKeditorConnector.__init__(self, environ=None) # call superclass constructor - # Instance Attributes - self.context = context - self.request = FCKeditorRequest(context) - - def getZopeRootContext(self): - if self.zopeRootContext is None: - self.zopeRootContext = self.context.getPhysicalRoot() - return self.zopeRootContext - - def getZopeUploadContext(self): - if self.zopeUploadContext is None: - folderNames = self.userFilesFolder.split("/") - c = self.getZopeRootContext() - for folderName in folderNames: - if (folderName <> ""): - c = c[folderName] - self.zopeUploadContext = c - return self.zopeUploadContext - - def setHeader(self, key, value): - self.context.REQUEST.RESPONSE.setHeader(key, value) - - def getFolders(self, resourceType, currentFolder): - # Open the folders node - s = "" - s += """""" - zopeFolder = self.findZopeFolder(resourceType, currentFolder) - for (name, o) in zopeFolder.objectItems(["Folder"]): - s += """""" % ( - convertToXmlAttribute(name) - ) - # Close the folders node - s += """""" - return s - - def getZopeFoldersAndFiles(self, resourceType, currentFolder): - folders = self.getZopeFolders(resourceType, currentFolder) - files = self.getZopeFiles(resourceType, currentFolder) - s = folders + files - return s - - def getZopeFiles(self, resourceType, currentFolder): - # Open the files node - s = "" - s += """""" - zopeFolder = self.findZopeFolder(resourceType, currentFolder) - for (name, o) in zopeFolder.objectItems(["File","Image"]): - s += """""" % ( - convertToXmlAttribute(name), - ((o.get_size() / 1024) + 1) - ) - # Close the files node - s += """""" - return s - - def findZopeFolder(self, resourceType, folderName): - # returns the context of the resource / folder - zopeFolder = self.getZopeUploadContext() - folderName = self.removeFromStart(folderName, "/") - folderName = self.removeFromEnd(folderName, "/") - if (resourceType <> ""): - try: - zopeFolder = zopeFolder[resourceType] - except: - zopeFolder.manage_addProduct["OFSP"].manage_addFolder(id=resourceType, title=resourceType) - zopeFolder = zopeFolder[resourceType] - if (folderName <> ""): - folderNames = folderName.split("/") - for folderName in folderNames: - zopeFolder = zopeFolder[folderName] - return zopeFolder - - def createFolder(self, resourceType, currentFolder): - # Find out where we are - zopeFolder = self.findZopeFolder(resourceType, currentFolder) - errorNo = 0 - errorMsg = "" - if self.request.has_key("NewFolderName"): - newFolder = self.request.get("NewFolderName", None) - zopeFolder.manage_addProduct["OFSP"].manage_addFolder(id=newFolder, title=newFolder) - else: - errorNo = 102 - return self.sendErrorNode ( errorNo, errorMsg ) - - def uploadFile(self, resourceType, currentFolder, count=None): - zopeFolder = self.findZopeFolder(resourceType, currentFolder) - file = self.request.get("NewFile", None) - fileName = self.getFileName(file.filename) - fileNameOnly = self.removeExtension(fileName) - fileExtension = self.getExtension(fileName).lower() - if (count): - nid = "%s.%s.%s" % (fileNameOnly, count, fileExtension) - else: - nid = fileName - title = nid - try: - zopeFolder.manage_addProduct['OFSP'].manage_addFile( - id=nid, - title=title, - file=file.read() - ) - except: - if (count): - count += 1 - else: - count = 1 - return self.zopeFileUpload(resourceType, currentFolder, count) - return self.sendUploadResults( 0 ) - -class FCKeditorRequest(object): - "A wrapper around the request object" - def __init__(self, context=None): - r = context.REQUEST - self.request = r - - def has_key(self, key): - return self.request.has_key(key) - - def get(self, key, default=None): - return self.request.get(key, default) - -""" -Running from zope, you will need to modify this connector. -If you have uploaded the FCKeditor into Zope (like me), you need to -move this connector out of Zope, and replace the "connector" with an -alias as below. The key to it is to pass the Zope context in, as -we then have a like to the Zope context. - -## Script (Python) "connector.py" -##bind container=container -##bind context=context -##bind namespace= -##bind script=script -##bind subpath=traverse_subpath -##parameters=*args, **kws -##title=ALIAS -## - -import Products.zope as connector -return connector.FCKeditorConnectorZope(context=context).doResponse() -""" From 1f9fb64bc9c82ff41af6d49ba1f112f91761ab84 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 02:41:36 +0000 Subject: [PATCH 06/49] Prepare packaging for debian --- build/deb/config | 2 + build/deb/control | 13 +++-- build/deb/copyright | 1 + build/deb/rules | 100 +------------------------------------ build/deb/templates | 12 ++--- build/makepack-dolibarr.pl | 47 +++++++++++------ 6 files changed, 45 insertions(+), 130 deletions(-) create mode 100644 build/deb/copyright diff --git a/build/deb/config b/build/deb/config index 74220322386..e006ebda186 100644 --- a/build/deb/config +++ b/build/deb/config @@ -1,6 +1,8 @@ #!/bin/sh # Debian install package run: config, preinst, prerm, postinst, postrm # +# lintian package To test a package +# # dpkg -l list all packages # dpkg -b is to build package # dpkg -c package.deb list content of package diff --git a/build/deb/control b/build/deb/control index 819a8b1668e..19eb51664e7 100644 --- a/build/deb/control +++ b/build/deb/control @@ -4,17 +4,16 @@ Architecture: all Maintainer: Laurent Destailleur Essential: no Installed-Size: 31200 -Depends: apache2, libapache2-mod-php5, php5, php5-cgi, php5-curl, php5-gd, php5-ldap, php5-mysql, mysql-server, perl +Depends: apache2, libapache2-mod-php5, php5, php5-cli, php5-cgi, php5-curl, php5-gd, php5-ldap, php5-mysql, mysql-server, perl Section: web Priority: optional Recommends: mozilla | netscape Homepage: http://www.dolibarr.org -Description: Dolibarr ERP & CRM - Dolibarr ERP/CRM is an open source/free software for - small and medium companies, foundations or freelances. It includes - different features for Enterprise Resource Planning (ERP) and Customer - Relationship Management (CRM) but also other features for different - activities. +Description: An ERP & CRM software to manage your activity. + Dolibarr ERP & CRM is an easy to use open source/free software for small + and medium companies, foundations or freelances. It includes different + features for Enterprise Resource Planning (ERP) and Customer Relationship + Management (CRM) but also other features for different activities. . Dolibarr features are activated by modules. Most common modules are: . diff --git a/build/deb/copyright b/build/deb/copyright new file mode 100644 index 00000000000..74752ea4864 --- /dev/null +++ b/build/deb/copyright @@ -0,0 +1 @@ +See file /usr/share/common-licenses/GPL-2 \ No newline at end of file diff --git a/build/deb/rules b/build/deb/rules index 6ac50a11ba1..df233257ac4 100644 --- a/build/deb/rules +++ b/build/deb/rules @@ -1,100 +1,4 @@ -#!/usr/bin/make -f -# Sample debian/rules that uses debhelper. -# GNU copyright 1997 to 1999 by Joey Hess. # -# This script is not used. The script used to build the root -# for making Debian pakcage is build/makepack-dolibarr.pl +# Sample debian/rules # - -# Uncomment this to turn on verbose mode. -#export DH_VERBOSE=1 - -# This is the debhelper compatability version to use. -export DH_COMPAT=3 - -configure: configure-stamp -configure-stamp: - dh_testdir - # Add here commands to configure the package. - - touch configure-stamp - -build: configure-stamp build-stamp -build-stamp: - dh_testdir - - # Add here commands to compile the package. - - touch build-stamp - -clean: - dh_testdir - dh_testroot - rm -f build-stamp configure-stamp - - # Add here commands to clean up after the build process. - - dh_clean - -install: build - dh_testdir - dh_testroot - dh_clean -k - dh_installdirs - - @# Add here commands to install the package into debian/dolibarr - - install --mode=644 -D --group=www-data --owner=www-data \ - DEBIAN/apache.conf \ - debian/dolibarr/etc/dolibarr/apache.conf - - mkdir -p debian/dolibarr/usr/share/dolibarr - cp -rp htdocs/* debian/dolibarr/usr/share/dolibarr/htdocs - mkdir -p debian/dolibarr/usr/share/dolibarr/documents - chmod -R 644 debian/dolibarr/usr/share/dolibarr - - find debian/dolibarr/usr/share/dolibarr -type d | xargs chmod 755 - - find debian/dolibarr \( -name CVS -o -name .cvsignore \) | xargs rm -fr - - mkdir -p debian/dolibarr/usr/lib/dolibarr - cp -rp scripts/* debian/dolibarr/usr/lib/dolibarr - -# Build architecture-independent files here. -binary-indep: build install -# We have nothing to do by default. - -# Build architecture-dependent files here. -binary-arch: build install - dh_testdir - dh_testroot -# dh_movefiles - - dh_installdebconf - dh_installdocs -# dh_installexamples -# dh_installmenu -# dh_installlogrotate -# dh_installemacsen -# dh_installpam -# dh_installmime -# dh_installinit -# dh_installcron - dh_installman -# dh_installinfo -# dh_undocumented -# dh_installchangelogs - dh_link - dh_strip - dh_compress - dh_fixperms -# dh_makeshlibs - dh_installdeb -# dh_perl -# dh_shlibdeps - dh_gencontrol - dh_md5sums - dh_builddeb - -binary: binary-indep binary-arch -.PHONY: build clean binary-indep binary-arch binary install configure +# This script is not used, so is empty. diff --git a/build/deb/templates b/build/deb/templates index 703aa9fc2db..82fcaa1ba48 100644 --- a/build/deb/templates +++ b/build/deb/templates @@ -1,6 +1,6 @@ Template: dolibarr/configuration/note Type: note -Description: Package configuration note. +Description: Package configuration note Dolibarr can be and should be configured entirely via web, so, in the following configuration steps, I'm going to prompt you for the passwords that Dolibarr uses for web configuration and some default values for the @@ -19,15 +19,9 @@ Description: Which Web Server are you running? Dolibarr supports any web server with PHP capabilities, but this configuration process only supports Apache and Apache-SSL. -Template: dolibarr/db/setup/skip -Type: boolean -Default: false -Description: DB setup skipped. - DB setup will be skipped. - Template: dolibarr/db Type: text -Description: Dolibarr DB setup NOTE. +Description: Dolibarr DB setup note Now you should specify the DBMS settings. You must provide the host name on which the DBMS server is installed, the type (i.e. MySql), the DB name, the DBMS administrator user-name, etc. @@ -71,7 +65,7 @@ Description: Please, retype the password to access the DB: Template: dolibarr/db/user/password/mismatch Type: text -Description: Passwords mismatch. +Description: Passwords mismatch The DB access passwords you inserted mismatch. Please, try again. Template: dolibarr/db/admin/name diff --git a/build/makepack-dolibarr.pl b/build/makepack-dolibarr.pl index 5ad1e1653b3..799a17c5ff4 100644 --- a/build/makepack-dolibarr.pl +++ b/build/makepack-dolibarr.pl @@ -2,7 +2,7 @@ #---------------------------------------------------------------------------- # \file build/makepack-dolibarr.pl # \brief Dolibarr package builder (tgz, zip, rpm, deb, exe, aps) -# \version $Id: makepack-dolibarr.pl,v 1.105 2011/06/26 11:41:50 eldy Exp $ +# \version $Id: makepack-dolibarr.pl,v 1.106 2011/07/09 02:41:37 eldy Exp $ # \author (c)2004-2011 Laurent Destailleur #---------------------------------------------------------------------------- @@ -48,7 +48,7 @@ if (-d "/usr/src/RPM") { use vars qw/ $REVISION $VERSION /; -$REVISION='$Revision: 1.105 $'; $REVISION =~ /\s(.*)\s/; $REVISION=$1; +$REVISION='$Revision: 1.106 $'; $REVISION =~ /\s(.*)\s/; $REVISION=$1; $VERSION="1.0 (build $REVISION)"; @@ -277,9 +277,13 @@ if ($nboftargetok) { $ret=`rm -fr $BUILDROOT/$PROJECT/Thumbs.db $BUILDROOT/$PROJECT/*/Thumbs.db $BUILDROOT/$PROJECT/*/*/Thumbs.db $BUILDROOT/$PROJECT/*/*/*/Thumbs.db $BUILDROOT/$PROJECT/*/*/*/*/Thumbs.db`; $ret=`rm -fr $BUILDROOT/$PROJECT/CVS* $BUILDROOT/$PROJECT/*/CVS* $BUILDROOT/$PROJECT/*/*/CVS* $BUILDROOT/$PROJECT/*/*/*/CVS* $BUILDROOT/$PROJECT/*/*/*/*/CVS* $BUILDROOT/$PROJECT/*/*/*/*/*/CVS*`; $ret=`rm -fr $BUILDROOT/$PROJECT/.cvsignore $BUILDROOT/$PROJECT/*/.cvsignore $BUILDROOT/$PROJECT/*/*/.cvsignore $BUILDROOT/$PROJECT/*/*/*/.cvsignore $BUILDROOT/$PROJECT/*/*/*/*/.cvsignore $BUILDROOT/$PROJECT/*/*/*/*/*/.cvsignore $BUILDROOT/$PROJECT/*/*/*/*/*/*/.cvsignore`; - $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/phpexcel/PHPExcel/Shared/PDF/fonts/utils/freetype6.dll`; - $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/phpexcel/PHPExcel/Shared/PDF/fonts/utils/zlib1.dll`; - $ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/php_writeexcel/php.bmp`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/php_writeexcel/php.bmp`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/phpexcel/PHPExcel/Shared/PDF/fonts/utils/freetype6.dll`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/phpexcel/PHPExcel/Shared/PDF/fonts/utils/zlib1.dll`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/phpexcel/PHPExcel/Shared/PDF/fonts/utils/pfm2afm`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/phpexcel/PHPExcel/Shared/PDF/fonts/utils/ttf2ufm`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/tcpdf/fonts/utils/pfm2afm`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/tcpdf/fonts/utils/ttf2ufm`; } # Build package for each target @@ -402,7 +406,7 @@ if ($nboftargetok) { $ret=`$cmd`; print "Remove other files\n"; - $ret=`rm -f $BUILDROOT/$FILENAMETGZ2/*.dll $BUILDROOT/$FILENAMETGZ2/*/*.dll $BUILDROOT/$FILENAMETGZ2/*/*/*.dll $BUILDROOT/$FILENAMETGZ2/*/*/*/*.dll $BUILDROOT/$FILENAMETGZ2/*/*/*/*/*.dll $BUILDROOT/$FILENAMETGZ2/*/*/*/*/*/*.dll $BUILDROOT/$FILENAMETGZ2/*/*/*/*/*/*/*.dll`; + $ret=`rm -f $BUILDROOT/$FILENAMETGZ2/htdocs/includes/barcode/php-barcode/genbarcode/genbarcode`; print "Compress $FILENAMETGZ2 into $FILENAMETGZ2.tgz...\n"; $ret=`tar --exclude-from "$SOURCE/build/tgz/tar_exclude.txt" --directory "$BUILDROOT" -czvf "$BUILDROOT/$FILENAMETGZ2.tgz" $FILENAMETGZ2`; @@ -436,11 +440,11 @@ if ($nboftargetok) { if ($target eq 'DEB') { $newbuild = $BUILD; - $newbuild =~ s/(dev|alpha)/0/gi; # dev - $newbuild =~ s/beta/1/gi; # beta - $newbuild =~ s/rc./2/gi; # rc - if ($newbuild !~ /-/) { $newbuild.='-3'; } # finale - # now newbuild is 0-0 or 0-3 for example + $newbuild =~ s/(dev|alpha)/1/gi; # dev + $newbuild =~ s/beta/2/gi; # beta + $newbuild =~ s/rc./3/gi; # rc + if ($newbuild !~ /-/) { $newbuild.='-4'; } # finale + # now newbuild is 0-1 or 0-4 for example print "Version is $MAJOR.$MINOR.$newbuild\n"; print "Remove target $FILENAMEDEB.deb...\n"; @@ -475,6 +479,7 @@ if ($nboftargetok) { $ret=`rm -fr $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/doc/tshirt`; $ret=`rm -fr $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/doc/rollup`; $ret=`rm -fr $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/test`; + $ret=`rm -f $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/htdocs/includes/barcode/php-barcode/genbarcode/genbarcode`; # To remove once stable $ret=`rm -fr $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/htdocs/htdocs/theme/bureau2crea`; @@ -493,17 +498,25 @@ if ($nboftargetok) { $ret=`mkdir -p "$BUILDROOT/$PROJECT.tmp/usr/share/applications"`; print "Copy desktop file into $BUILDROOT/$PROJECT.tmp/usr/share/applications/dolibarr.desktop\n"; $ret=`cp "$SOURCE/build/deb/dolibarr.desktop" "$BUILDROOT/$PROJECT.tmp/usr/share/applications/dolibarr.desktop"`; - + $ret=`chmod 444 $BUILDROOT/$PROJECT.tmp/usr/share/applications/dolibarr.desktop`; + print "Create directory $BUILDROOT/$PROJECT.tmp/usr/share/pixmaps\n"; $ret=`mkdir -p "$BUILDROOT/$PROJECT.tmp/usr/share/pixmaps"`; print "Copy pixmap file into $BUILDROOT/$PROJECT.tmp/usr/share/pixmaps/dolibarr.xpm\n"; $ret=`cp "$SOURCE/doc/images/dolibarr.xpm" "$BUILDROOT/$PROJECT.tmp/usr/share/pixmaps/dolibarr.xpm"`; + $ret=`chmod 444 $BUILDROOT/$PROJECT.tmp/usr/share/pixmaps/dolibarr.xpm`; + print "Create directory $BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT\n"; + $ret=`mkdir -p "$BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT"`; + print "Copy README file into $BUILDROOT/$PROJECT.tmp/DEBIAN\n"; $ret=`cp "$SOURCE/README" "$BUILDROOT/$PROJECT.tmp/DEBIAN/README"`; + $ret=`cp "$SOURCE/README" "$BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT/README"`; - print "Copy copyright file into $BUILDROOT/$PROJECT.tmp/DEBIAN\n"; - $ret=`cp "$SOURCE/COPYRIGHT" "$BUILDROOT/$PROJECT.tmp/DEBIAN/copyright"`; + print "Copy copyright file into $BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT/copyright\n"; + $ret=`cp "$BUILDROOT/$PROJECT.tmp/DEBIAN/copyright" "$BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT/copyright"`; + + $ret=`gzip -c $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/ChangeLog > $BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT/changelog.Debian.gz`; print "Create directory $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/documents\n"; $ret=`mkdir -p "$BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/documents"`; @@ -514,8 +527,10 @@ if ($nboftargetok) { $ret=`chmod -R 555 $BUILDROOT/$PROJECT.tmp`; $ret=`chmod 755 $BUILDROOT/$PROJECT.tmp`; $ret=`chmod -R 755 $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/documents`; - $ret=`chmod -R 755 $BUILDROOT/$PROJECT.tmp/DEBIAN`; - + $ret=`chmod -R 755 $BUILDROOT/$PROJECT.tmp/DEBIAN`; + $ret=`chmod 644 $BUILDROOT/$PROJECT.tmp/DEBIAN/control`; + $ret=`chmod 644 $BUILDROOT/$PROJECT.tmp/DEBIAN/templates`; + print "Go to directory $BUILDROOT\n"; $olddir=getcwd(); chdir("$BUILDROOT"); From 10d027436f94969d7962da05c2d33f53f87ed1d1 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Sat, 9 Jul 2011 05:28:41 +0000 Subject: [PATCH 07/49] Fix: remove deprecated constant --- htdocs/admin/mails.php | 27 ++------------------------- htdocs/core/class/conf.class.php | 3 +-- htdocs/langs/ca_ES/admin.lang | 1 - htdocs/langs/el_GR/admin.lang | 1 - htdocs/langs/en_US/admin.lang | 1 - htdocs/langs/es_ES/admin.lang | 1 - htdocs/langs/fr_FR/admin.lang | 2 +- htdocs/langs/it_IT/admin.lang | 1 - 8 files changed, 4 insertions(+), 33 deletions(-) diff --git a/htdocs/admin/mails.php b/htdocs/admin/mails.php index 6f6bb746336..ab12d1419b6 100644 --- a/htdocs/admin/mails.php +++ b/htdocs/admin/mails.php @@ -20,7 +20,7 @@ /** * \file htdocs/admin/mails.php * \brief Page to setup emails sending - * \version $Id: mails.php,v 1.70 2011/07/02 16:48:31 eldy Exp $ + * \version $Id: mails.php,v 1.71 2011/07/09 05:28:41 hregis Exp $ */ require("../main.inc.php"); @@ -61,7 +61,6 @@ if (isset($_POST["action"]) && $_POST["action"] == 'update' && empty($_POST["can if (isset($_POST["MAIN_MAIL_SMTPS_ID"])) dolibarr_set_const($db, "MAIN_MAIL_SMTPS_ID", $_POST["MAIN_MAIL_SMTPS_ID"],'chaine',0,'',0); if (isset($_POST["MAIN_MAIL_SMTPS_PW"])) dolibarr_set_const($db, "MAIN_MAIL_SMTPS_PW", $_POST["MAIN_MAIL_SMTPS_PW"],'chaine',0,'',0); if (isset($_POST["MAIN_MAIL_EMAIL_TLS"])) dolibarr_set_const($db, "MAIN_MAIL_EMAIL_TLS", $_POST["MAIN_MAIL_EMAIL_TLS"],'chaine',0,'',0); - dolibarr_set_const($db, "MAIN_MAIL_EMAIL_INLINE_IMAGES", $_POST["MAIN_MAIL_EMAIL_INLINE_IMAGES"],'chaine',0,'',0); dolibarr_set_const($db, "MAIN_MAIL_EMAIL_FROM", $_POST["MAIN_MAIL_EMAIL_FROM"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_MAIL_AUTOCOPY_TO", $_POST["MAIN_MAIL_AUTOCOPY_TO"],'chaine',0,'',$conf->entity); @@ -283,8 +282,6 @@ if (isset($_GET["action"]) && $_GET["action"] == 'edit') jQuery(".drag").hide(); jQuery("#MAIN_MAIL_EMAIL_TLS").val(0); jQuery("#MAIN_MAIL_EMAIL_TLS").attr(\'disabled\', \'disabled\'); - jQuery("#MAIN_MAIL_EMAIL_INLINE_IMAGES").val('.$conf->global->MAIN_MAIL_EMAIL_INLINE_IMAGES.'); - jQuery("#MAIN_MAIL_EMAIL_INLINE_IMAGES").removeAttr(\'disabled\'); '; if ($linuxlike) { @@ -300,8 +297,6 @@ if (isset($_GET["action"]) && $_GET["action"] == 'edit') jQuery("#MAIN_MAIL_EMAIL_TLS").removeAttr(\'disabled\'); jQuery("#MAIN_MAIL_SMTP_SERVER").removeAttr(\'disabled\'); jQuery("#MAIN_MAIL_SMTP_PORT").removeAttr(\'disabled\'); - jQuery("#MAIN_MAIL_EMAIL_INLINE_IMAGES").val(0); - jQuery("#MAIN_MAIL_EMAIL_INLINE_IMAGES").attr(\'disabled\', \'disabled\'); } } initfields(); @@ -463,15 +458,6 @@ if (isset($_GET["action"]) && $_GET["action"] == 'edit') else print yn(0).' ('.$langs->trans("NotSupported").')'; print ''; - // Inline images - if ($conf->global->MAIN_FEATURES_LEVEL > 0) - { - $var=!$var; - print ''.$langs->trans("MAIN_MAIL_EMAIL_INLINE_IMAGES").''; - print $html->selectyesno('MAIN_MAIL_EMAIL_INLINE_IMAGES',$conf->global->MAIN_MAIL_EMAIL_INLINE_IMAGES,1); - print ''; - } - // Separator $var=!$var; print ' '; @@ -571,15 +557,6 @@ else else print yn(0).' ('.$langs->trans("NotSupported").')'; print ''; - // Inline images - if ($conf->global->MAIN_FEATURES_LEVEL > 0) - { - $var=!$var; - print ''.$langs->trans("MAIN_MAIL_EMAIL_INLINE_IMAGES").''; - print yn($conf->global->MAIN_MAIL_EMAIL_INLINE_IMAGES,1,0); - print ''; - } - // Separator $var=!$var; print ' '; @@ -746,5 +723,5 @@ else $db->close(); -llxFooter('$Date: 2011/07/02 16:48:31 $ - $Revision: 1.70 $'); +llxFooter('$Date: 2011/07/09 05:28:41 $ - $Revision: 1.71 $'); ?> diff --git a/htdocs/core/class/conf.class.php b/htdocs/core/class/conf.class.php index 6cd0d6761b8..e9e0a507b7e 100644 --- a/htdocs/core/class/conf.class.php +++ b/htdocs/core/class/conf.class.php @@ -25,7 +25,7 @@ * \ingroup core * \brief Fichier de la classe de stockage de la config courante * \remarks La config est stockee dans le fichier conf/conf.php - * \version $Id: conf.class.php,v 1.59 2011/07/01 23:06:06 eldy Exp $ + * \version $Id: conf.class.php,v 1.60 2011/07/09 05:28:42 hregis Exp $ */ @@ -363,7 +363,6 @@ class Conf // Defini MAIN_GRAPH_LIBRARY if (empty($this->global->MAIN_GRAPH_LIBRARY)) $this->global->MAIN_GRAPH_LIBRARY = 'artichow'; - if (! isset($this->global->MAIN_MAIL_EMAIL_INLINE_IMAGES)) $this->global->MAIN_MAIL_EMAIL_INLINE_IMAGES=1; if (! isset($this->global->FCKEDITOR_EDITORNAME)) $this->global->FCKEDITOR_EDITORNAME='ckeditor'; // fckeditor to switch // Format for date (used by default when not found or searched in lang) diff --git a/htdocs/langs/ca_ES/admin.lang b/htdocs/langs/ca_ES/admin.lang index 69698125f47..848deab542a 100644 --- a/htdocs/langs/ca_ES/admin.lang +++ b/htdocs/langs/ca_ES/admin.lang @@ -236,7 +236,6 @@ MAIN_MAIL_SENDMODE=Mètode d'enviament d'e-mails MAIN_MAIL_SMTPS_ID=ID d'autenticació SMTP si es requereix autenticació SMTP MAIN_MAIL_SMTPS_PW=Contrasenya autentificació SMTP si es requereix autenticació SMTP MAIN_MAIL_EMAIL_TLS=Ús d'encriptació TLS (SSL) -MAIN_MAIL_EMAIL_INLINE_IMAGES=Possibilitat d'integrar les imatges en els correus electrònics MAIN_DISABLE_ALL_SMS=Desactivar globalment tot enviament de SMS (per mode de proves o demo) MAIN_SMS_SENDMODE=Mètode d'enviament de SMS MAIN_MAIL_SMS_FROM=Número de telèfon per defecte per als enviaments SMS diff --git a/htdocs/langs/el_GR/admin.lang b/htdocs/langs/el_GR/admin.lang index 3836ec79775..a9fe2695958 100755 --- a/htdocs/langs/el_GR/admin.lang +++ b/htdocs/langs/el_GR/admin.lang @@ -1234,7 +1234,6 @@ RunCommandSummaryToLaunch=Backup μπορεί να ξεκινήσει με τη ImportPostgreSqlDesc=Για την εισαγωγή ενός αντιγράφου ασφαλείας, πρέπει να χρησιμοποιήσετε pg_restore εντολή από την γραμμή εντολών: ImportPostgreSqlCommand=Sssss sssss mybackupfile.sql FullPathToPostgreSQLdumpCommand=Η πλήρης διαδρομή προς pg_dump εντολή -MAIN_MAIL_EMAIL_INLINE_IMAGES=Δυνατότητα για την ενσωμάτωση εικόνων σε μηνύματα ηλεκτρονικού ταχυδρομείου MAIN_DISABLE_ALL_SMS=Απενεργοποίηση όλων σας αποστολές SMS (για λόγους δοκιμής ή demos) MAIN_SMS_SENDMODE=Μέθοδος να χρησιμοποιήσετε για την αποστολή SMS MAIN_MAIL_SMS_FROM=Προεπιλογή αριθμού τηλεφώνου αποστολέα για την αποστολή SMS diff --git a/htdocs/langs/en_US/admin.lang b/htdocs/langs/en_US/admin.lang index 2058244178c..9f153916ea5 100644 --- a/htdocs/langs/en_US/admin.lang +++ b/htdocs/langs/en_US/admin.lang @@ -235,7 +235,6 @@ MAIN_MAIL_SENDMODE=Method to use to send EMails MAIN_MAIL_SMTPS_ID=SMTP ID if authentication required MAIN_MAIL_SMTPS_PW=SMTP Password if authentication required MAIN_MAIL_EMAIL_TLS= Use TLS (SSL) encrypt -MAIN_MAIL_EMAIL_INLINE_IMAGES= Ability to integrate images in emails MAIN_DISABLE_ALL_SMS=Disable all SMS sendings (for test purposes or demos) MAIN_SMS_SENDMODE=Method to use to send SMS MAIN_MAIL_SMS_FROM=Default sender phone number for Sms sending diff --git a/htdocs/langs/es_ES/admin.lang b/htdocs/langs/es_ES/admin.lang index 21869c2e3d2..5645bd6ff6f 100644 --- a/htdocs/langs/es_ES/admin.lang +++ b/htdocs/langs/es_ES/admin.lang @@ -236,7 +236,6 @@ MAIN_MAIL_SENDMODE=Método de envío de e-mails MAIN_MAIL_SMTPS_ID=ID de autentificación SMTP si se requiere autenticación SMTP MAIN_MAIL_SMTPS_PW=Contraseña autentificación SMTP si se requiere autentificación SMTP MAIN_MAIL_EMAIL_TLS=Uso de encriptación TLS (SSL) -MAIN_MAIL_EMAIL_INLINE_IMAGES=Posibilidad de integrar las imágenes en los e-mails MAIN_DISABLE_ALL_SMS=Desactivar globalmente todo envío de SMS (para modo de pruebas o demo) MAIN_SMS_SENDMODE=Método de envío de SMS MAIN_MAIL_SMS_FROM=Número de teléfono por defecto para los envíos SMS diff --git a/htdocs/langs/fr_FR/admin.lang b/htdocs/langs/fr_FR/admin.lang index d03c568bef9..2729073a3b8 100644 --- a/htdocs/langs/fr_FR/admin.lang +++ b/htdocs/langs/fr_FR/admin.lang @@ -236,7 +236,6 @@ MAIN_MAIL_SENDMODE= Méthode d'envoi des mails MAIN_MAIL_SMTPS_ID= SMTP Authentification ID si authentification SMTP requise MAIN_MAIL_SMTPS_PW= SMTP Authentification Password si authentification SMTP requise MAIN_MAIL_EMAIL_TLS= Utilisation du cryptage TLS (SSL) -MAIN_MAIL_EMAIL_INLINE_IMAGES= Possibilité d'intégrer les images dans les mails MAIN_DISABLE_ALL_SMS=Désactiver globalement tout envoi de Sms (pour mode test ou démos) MAIN_SMS_SENDMODE=Méthode d'envoi des SMS MAIN_MAIL_SMS_FROM=Numéro de téléphone par défaut pour envoi Sms @@ -854,6 +853,7 @@ MAIN_PROXY_USER=Login pour passer le serveur proxy mandataire MAIN_PROXY_PASS=Mot de passe pour passer le serveur proxy mandataire DefineHereComplementaryAttributes=Definissez ici la liste des attributs supplémentaire, non disponible en standard, et que vous voulez voir gérez sur les %s. ExtraFields=Attributs suplémentaires +SendingMailSetup=Configuration de l'envoi par mail ##### Module password generation= undefined PasswordGenerationStandard= Renvoie un mot de passe généré selon algorithme interne Dolibarr: 8 caractères, chiffres et caractères en minuscules mélangés. diff --git a/htdocs/langs/it_IT/admin.lang b/htdocs/langs/it_IT/admin.lang index 7293a1f5af7..776f38f948c 100644 --- a/htdocs/langs/it_IT/admin.lang +++ b/htdocs/langs/it_IT/admin.lang @@ -1250,7 +1250,6 @@ ImportPostgreSqlCommand=%s %s mybackupfile.sql FullPathToPostgreSQLdumpCommand=Percorso completo pg_dump comando CurrentMenuHandler=Menu gestore corrente CurrentSmartphoneMenuHandler=Attuale gestore menu smartphone -MAIN_MAIL_EMAIL_INLINE_IMAGES=Capacità di integrare le immagini nelle e-mail MAIN_DISABLE_ALL_SMS=Disabilitare tutti spedizioni SMS (per scopi di test o demo) MAIN_SMS_SENDMODE=Metodo da utilizzare per inviare SMS MAIN_MAIL_SMS_FROM=Predefinito numero di telefono del mittente per l'invio di Sms From 2433e88a3c8120f7bc6186a32be5de1f195df824 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Sat, 9 Jul 2011 06:10:04 +0000 Subject: [PATCH 08/49] Fix: add possibility to force mail errors-to to all mails sent --- htdocs/admin/mails.php | 18 ++++++++++++++++-- htdocs/core/class/html.formmail.class.php | 9 +++++---- htdocs/langs/en_US/admin.lang | 1 + htdocs/langs/fr_FR/admin.lang | 1 + htdocs/lib/CMailFile.class.php | 4 ++-- 5 files changed, 25 insertions(+), 8 deletions(-) diff --git a/htdocs/admin/mails.php b/htdocs/admin/mails.php index ab12d1419b6..05b12ff10b8 100644 --- a/htdocs/admin/mails.php +++ b/htdocs/admin/mails.php @@ -20,7 +20,7 @@ /** * \file htdocs/admin/mails.php * \brief Page to setup emails sending - * \version $Id: mails.php,v 1.71 2011/07/09 05:28:41 hregis Exp $ + * \version $Id: mails.php,v 1.72 2011/07/09 06:10:06 hregis Exp $ */ require("../main.inc.php"); @@ -63,6 +63,7 @@ if (isset($_POST["action"]) && $_POST["action"] == 'update' && empty($_POST["can if (isset($_POST["MAIN_MAIL_EMAIL_TLS"])) dolibarr_set_const($db, "MAIN_MAIL_EMAIL_TLS", $_POST["MAIN_MAIL_EMAIL_TLS"],'chaine',0,'',0); dolibarr_set_const($db, "MAIN_MAIL_EMAIL_FROM", $_POST["MAIN_MAIL_EMAIL_FROM"],'chaine',0,'',$conf->entity); + dolibarr_set_const($db, "MAIN_MAIL_ERRORS_TO", $_POST["MAIN_MAIL_ERRORS_TO"],'chaine',0,'',$conf->entity); dolibarr_set_const($db, "MAIN_MAIL_AUTOCOPY_TO", $_POST["MAIN_MAIL_AUTOCOPY_TO"],'chaine',0,'',$conf->entity); Header("Location: ".$_SERVER["PHP_SELF"]."?mainmenu=home&leftmenu=setup"); @@ -467,6 +468,12 @@ if (isset($_GET["action"]) && $_GET["action"] == 'edit') print ''.$langs->trans("MAIN_MAIL_EMAIL_FROM",ini_get('sendmail_from')?ini_get('sendmail_from'):$langs->transnoentities("Undefined")).''; print ''; + + // From + $var=!$var; + print ''.$langs->trans("MAIN_MAIL_ERRORS_TO").''; + print ''; // Autocopy to $var=!$var; @@ -567,6 +574,13 @@ else print ''.$conf->global->MAIN_MAIL_EMAIL_FROM; if (!empty($conf->global->MAIN_MAIL_EMAIL_FROM) && ! isValidEmail($conf->global->MAIN_MAIL_EMAIL_FROM)) print img_warning($langs->trans("ErrorBadEMail")); print ''; + + // Errors To + $var=!$var; + print ''.$langs->trans("MAIN_MAIL_ERRORS_TO").''; + print ''.$conf->global->MAIN_MAIL_ERRORS_TO; + if (!empty($conf->global->MAIN_MAIL_ERRORS_TO) && ! isValidEmail($conf->global->MAIN_MAIL_ERRORS_TO)) print img_warning($langs->trans("ErrorBadEMail")); + print ''; // Autocopy to $var=!$var; @@ -723,5 +737,5 @@ else $db->close(); -llxFooter('$Date: 2011/07/09 05:28:41 $ - $Revision: 1.71 $'); +llxFooter('$Date: 2011/07/09 06:10:06 $ - $Revision: 1.72 $'); ?> diff --git a/htdocs/core/class/html.formmail.class.php b/htdocs/core/class/html.formmail.class.php index ebfdded98da..25c96d54498 100644 --- a/htdocs/core/class/html.formmail.class.php +++ b/htdocs/core/class/html.formmail.class.php @@ -21,7 +21,7 @@ * \file htdocs/core/class/html.formmail.class.php * \ingroup core * \brief Fichier de la classe permettant la generation du formulaire html d'envoi de mail unitaire - * \version $Id: html.formmail.class.php,v 1.28 2011/07/07 15:54:03 simnandez Exp $ + * \version $Id: html.formmail.class.php,v 1.29 2011/07/09 06:10:07 hregis Exp $ */ require_once(DOL_DOCUMENT_ROOT ."/core/class/html.form.class.php"); @@ -309,17 +309,18 @@ class FormMail if ($this->witherrorsto) { //if (! $this->errorstomail) $this->errorstomail=$this->frommail; + $errorstomail = (! empty($conf->global->MAIN_MAIL_ERRORS_TO) ? $conf->global->MAIN_MAIL_ERRORS_TO : $this->errorstomail); if ($this->witherrorstoreadonly) { - $out.= ''; + $out.= ''; $out.= ''.$langs->trans("MailErrorsTo").''; - $out.= $this->errorstomail; + $out.= $errorstomail; $out.= "\n"; } else { $out.= ''.$langs->trans("MailErrorsTo").''; - $out.= ''; + $out.= ''; $out.= "\n"; } } diff --git a/htdocs/langs/en_US/admin.lang b/htdocs/langs/en_US/admin.lang index 9f153916ea5..0f43c1c9e82 100644 --- a/htdocs/langs/en_US/admin.lang +++ b/htdocs/langs/en_US/admin.lang @@ -229,6 +229,7 @@ MAIN_MAIL_SMTP_SERVER=SMTP/SMTPS Host (By default in php.ini: %s) MAIN_MAIL_SMTP_PORT_NotAvailableOnLinuxLike=SMTP/SMTPS Port (Not defined into PHP on Unix like systems) MAIN_MAIL_SMTP_SERVER_NotAvailableOnLinuxLike=SMTP/SMTPS Host (Not defined into PHP on Unix like systems) MAIN_MAIL_EMAIL_FROM=Sender e-mail for automatic emails (By default in php.ini: %s) +MAIN_MAIL_ERRORS_TO=Sender e-mail used for error returns emails sent MAIN_MAIL_AUTOCOPY_TO= Send systematically a hidden carbon-copy of all sent emails to MAIN_DISABLE_ALL_MAILS=Disable all e-mails sendings (for test purposes or demos) MAIN_MAIL_SENDMODE=Method to use to send EMails diff --git a/htdocs/langs/fr_FR/admin.lang b/htdocs/langs/fr_FR/admin.lang index 2729073a3b8..3cb19e89ba8 100644 --- a/htdocs/langs/fr_FR/admin.lang +++ b/htdocs/langs/fr_FR/admin.lang @@ -230,6 +230,7 @@ MAIN_MAIL_SMTP_SERVER= Nom host ou ip du serveur SMTP/SMTPS (Par défaut dans ph MAIN_MAIL_SMTP_PORT_NotAvailableOnLinuxLike= Port du serveur SMTP/SMTPS (Non défini dans le PHP sur les systèmes de type Unix) MAIN_MAIL_SMTP_SERVER_NotAvailableOnLinuxLike= Nom host ou ip du serveur SMTP/SMTPS (Non défini dans le PHP sur les systèmes de type Unix) MAIN_MAIL_EMAIL_FROM= EMail émetteur pour envoi emails automatiques (Par défaut dans php.ini: %s) +MAIN_MAIL_ERRORS_TO=EMail utilisé pour les retours d'erreurs des mails envoyés MAIN_MAIL_AUTOCOPY_TO= Envoyer systématiquement une copie cachée des mails envoyés à MAIN_DISABLE_ALL_MAILS= Désactiver globalement tout envoi de mails (pour mode test ou démos) MAIN_MAIL_SENDMODE= Méthode d'envoi des mails diff --git a/htdocs/lib/CMailFile.class.php b/htdocs/lib/CMailFile.class.php index 020c8c45aae..bc068114740 100644 --- a/htdocs/lib/CMailFile.class.php +++ b/htdocs/lib/CMailFile.class.php @@ -25,7 +25,7 @@ /** * \file htdocs/lib/CMailFile.class.php * \brief File of class to send emails (with attachments or not) - * \version $Id: CMailFile.class.php,v 1.144 2011/07/08 17:33:00 hregis Exp $ + * \version $Id: CMailFile.class.php,v 1.145 2011/07/09 06:10:04 hregis Exp $ * \author Dan Potter. * \author Eric Seigne * \author Laurent Destailleur. @@ -349,7 +349,7 @@ class CMailFile // le return-path dans les header ne fonctionne pas avec tous les MTA // Le passage par -f est donc possible si la constante MAIN_MAIL_ALLOW_SENDMAIL_F est definie. // La variable definie pose des pb avec certains sendmail securisee (option -f refusee car dangereuse) - $bounce = $this->addr_from != '' ? '-f' . $this->addr_from : ''; + $bounce = (! empty($conf->global->MAIN_MAIL_ERRORS_TO) ? '-f' . $conf->global->MAIN_MAIL_ERRORS_TO : ($this->addr_from != '' ? '-f' . $this->addr_from : '') ); } $this->message=stripslashes($this->message); From f281bd56fabc30a505b14c8cae32bd3d6901ab38 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Sat, 9 Jul 2011 08:05:08 +0000 Subject: [PATCH 09/49] New: add jquery method for random generation --- htdocs/core/ajaxsecurity.php | 59 ++++++++++++++++++++++++++++++++++ htdocs/lib/security.lib.php | 9 ++++-- htdocs/paypal/admin/paypal.php | 27 +++++++++++----- 3 files changed, 84 insertions(+), 11 deletions(-) create mode 100644 htdocs/core/ajaxsecurity.php diff --git a/htdocs/core/ajaxsecurity.php b/htdocs/core/ajaxsecurity.php new file mode 100644 index 00000000000..896e04bddc4 --- /dev/null +++ b/htdocs/core/ajaxsecurity.php @@ -0,0 +1,59 @@ + + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + */ + +/** + * \file htdocs/core/ajaxsecurity.php + * \brief File for return security data + * \version $Id: ajaxsecurity.php,v 1.1 2011/07/09 08:05:08 hregis Exp $ + */ + +if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL','1'); // Disables token renewal +if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU','1'); +if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML','1'); +if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1'); +if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1'); +if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1'); + +require('../main.inc.php'); +require_once(DOL_DOCUMENT_ROOT."/lib/security.lib.php"); + + +/* + * View + */ + +// Ajout directives pour resoudre bug IE +//header('Cache-Control: Public, must-revalidate'); +//header('Pragma: public'); + +//top_htmlhead("", "", 1); // Replaced with top_httphead. An ajax page does not need html header. +top_httphead(); + +//print ''."\n"; + +// Registering the location of boxes +if(isset($_GET['action']) && ! empty($_GET['action'])) +{ + if ($_GET['action'] == 'getrandompassword' && $user->admin) + { + $generic = $_GET['generic']; + echo getRandomPassword($generic); + } +} + +?> diff --git a/htdocs/lib/security.lib.php b/htdocs/lib/security.lib.php index 04f4a578d75..8c8a2331259 100644 --- a/htdocs/lib/security.lib.php +++ b/htdocs/lib/security.lib.php @@ -21,7 +21,7 @@ /** * \file htdocs/lib/security.lib.php * \brief Set of function used for dolibarr security - * \version $Id: security.lib.php,v 1.123 2011/07/04 09:01:38 eldy Exp $ + * \version $Id: security.lib.php,v 1.124 2011/07/09 08:05:08 hregis Exp $ */ @@ -540,14 +540,16 @@ function dol_efc_config() /** * Return a generated password using default module + * @param generic Create generic password * @return string New value for password */ -function getRandomPassword() +function getRandomPassword($generic=false) { global $db,$conf,$langs,$user; $generated_password=''; - if ($conf->global->USER_PASSWORD_GENERATED) + if ($generic) $generated_password=dol_hash(mt_rand()); + else if ($conf->global->USER_PASSWORD_GENERATED) { $nomclass="modGeneratePass".ucfirst($conf->global->USER_PASSWORD_GENERATED); $nomfichier=$nomclass.".class.php"; @@ -557,6 +559,7 @@ function getRandomPassword() $generated_password=$genhandler->getNewGeneratedPassword(); unset($genhandler); } + return $generated_password; } diff --git a/htdocs/paypal/admin/paypal.php b/htdocs/paypal/admin/paypal.php index f55c86c60bf..37ca979071a 100644 --- a/htdocs/paypal/admin/paypal.php +++ b/htdocs/paypal/admin/paypal.php @@ -21,7 +21,7 @@ /** \file htdocs/paypal/admin/paypal.php * \ingroup paypal * \brief Page to setup paypal module - * \version $Id: paypal.php,v 1.21 2011/07/08 18:08:27 hregis Exp $ + * \version $Id: paypal.php,v 1.22 2011/07/09 08:05:08 hregis Exp $ */ require("../../main.inc.php"); @@ -89,11 +89,21 @@ print $langs->trans("PaypalDesc")."
\n"; if ($conf->use_javascript_ajax) { print "\n".''; @@ -177,7 +187,8 @@ print ''; $var=!$var; print ''; print $langs->trans("SecurityToken").''; -print ''; +print ''; +print ' '.img_picto($langs->trans('Generate'), 'refresh', 'id="generate_token" class="linkobject"'); print ''; $var=!$var; @@ -262,5 +273,5 @@ print info_admin($langs->trans("YouCanAddTagOnUrl")); $db->close(); -llxFooter('$Date: 2011/07/08 18:08:27 $ - $Revision: 1.21 $'); +llxFooter('$Date: 2011/07/09 08:05:08 $ - $Revision: 1.22 $'); ?> From 277bb451618a36010ec47db083c7e7c9a3ea2349 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Sat, 9 Jul 2011 10:26:19 +0000 Subject: [PATCH 10/49] Fix: add div for jquery --- htdocs/core/class/html.formmail.class.php | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/htdocs/core/class/html.formmail.class.php b/htdocs/core/class/html.formmail.class.php index 25c96d54498..0de9a763c66 100644 --- a/htdocs/core/class/html.formmail.class.php +++ b/htdocs/core/class/html.formmail.class.php @@ -1,5 +1,6 @@ +/* Copyright (C) 2005-2011 Laurent Destailleur + * Copyright (C) 2005-2011 Regis Houssin * Copyright (C) 2010-2011 Juanjo Menent * * This program is free software; you can redistribute it and/or modify @@ -21,7 +22,7 @@ * \file htdocs/core/class/html.formmail.class.php * \ingroup core * \brief Fichier de la classe permettant la generation du formulaire html d'envoi de mail unitaire - * \version $Id: html.formmail.class.php,v 1.29 2011/07/09 06:10:07 hregis Exp $ + * \version $Id: html.formmail.class.php,v 1.30 2011/07/09 10:26:19 hregis Exp $ */ require_once(DOL_DOCUMENT_ROOT ."/core/class/html.form.class.php"); @@ -509,9 +510,10 @@ class FormMail { foreach($listofpaths as $key => $val) { - $out.= img_mime($listofnames[$key]).' '.$listofnames[$key]; - if (! $this->withfilereadonly) $out.= ' '; - $out.= '
'; + $out.= '
'; + $out.= img_mime($listofnames[$key]).' '.$listofnames[$key]; + if (! $this->withfilereadonly) $out.= ' '; + $out.= '
'; } } else From 0bac871cf077a12be51133071b69b51b6dd5a5f7 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 11:24:32 +0000 Subject: [PATCH 11/49] Fix: Set x bit required to directories --- htdocs/lib/functions.lib.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/lib/functions.lib.php b/htdocs/lib/functions.lib.php index e7dd9035a33..c02064d9e0b 100644 --- a/htdocs/lib/functions.lib.php +++ b/htdocs/lib/functions.lib.php @@ -29,7 +29,7 @@ * \file htdocs/lib/functions.lib.php * \brief A set of functions for Dolibarr * This file contains all frequently used functions. - * \version $Id: functions.lib.php,v 1.545 2011/07/08 13:07:44 eldy Exp $ + * \version $Id: functions.lib.php,v 1.546 2011/07/09 11:24:32 eldy Exp $ */ // For compatibility during upgrade @@ -3326,7 +3326,7 @@ function dol_mkdir($dir) umask(0); $dirmaskdec=octdec('0755'); if (! empty($conf->global->MAIN_UMASK)) $dirmaskdec=octdec($conf->global->MAIN_UMASK); - $dirmaskdec |= octdec('0110'); + $dirmaskdec |= octdec('0111'); // Set x bit required for directories if (! @mkdir($ccdir_osencoded, $dirmaskdec)) { // Si le is_dir a renvoye une fausse info, alors on passe ici. From 7246ab4b780fb12dada699de84c387310663c97d Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 14:11:40 +0000 Subject: [PATCH 12/49] Qual: A lot of fixes to enhance package quality --- build/deb/apache.conf | 6 ++ build/deb/changelog | 4 ++ build/deb/control | 2 +- build/deb/copyright | 3 + build/deb/install.forced.php.install | 5 +- build/deb/postinst | 62 +++++-------------- build/deb/postrm | 59 ++++-------------- build/deb/templates | 4 +- dev/initdata/generate-commande.php | 3 +- dev/initdata/generate-facture.php | 5 +- dev/initdata/generate-produit.php | 3 +- dev/initdata/generate-propale.php | 5 +- dev/initdata/generate-societe.php | 3 +- dev/samples/create_invoice.php | 7 ++- dev/samples/create_order.php | 7 ++- dev/samples/create_product.php | 7 ++- dev/skeletons/build_class_from_table.php | 5 +- dev/skeletons/build_webservice_from_class.php | 5 +- dev/skeletons/skeleton_script.php | 7 ++- dev/translation/autotranslator.php | 7 ++- scripts/banks/build-graph-sold-example.php | 4 +- .../company/export-contacts-xls-example.php | 7 ++- .../company/sync_contacts_dolibarr2ldap.php | 7 ++- ...ail_unpaid_invoices_to_representatives.php | 4 +- scripts/invoices/rebuild_merge_pdf.php | 6 +- .../members/sync_members_dolibarr2ldap.php | 7 ++- .../members/sync_members_ldap2dolibarr.php | 7 ++- scripts/user/sync_groups_dolibarr2ldap.php | 7 ++- scripts/user/sync_users_dolibarr2ldap.php | 7 ++- scripts/withdrawals/build_withdrawal_file.php | 7 ++- 30 files changed, 121 insertions(+), 151 deletions(-) create mode 100644 build/deb/changelog diff --git a/build/deb/apache.conf b/build/deb/apache.conf index 05b21148f8d..d37b433fb98 100644 --- a/build/deb/apache.conf +++ b/build/deb/apache.conf @@ -60,3 +60,9 @@ Alias /dolibarr /usr/share/dolibarr/htdocs Order deny,allow Allow from all + + + AllowOverride All + Order deny,allow + Allow from all + diff --git a/build/deb/changelog b/build/deb/changelog new file mode 100644 index 00000000000..182110624de --- /dev/null +++ b/build/deb/changelog @@ -0,0 +1,4 @@ + dolibarr 3.1.0 unstable; urgency=low + * New 3.1.0 release + More information into /usr/share/dolibarr/ChangeLog file. + -- maintainer Laurent Destailleur 2011-07-09 \ No newline at end of file diff --git a/build/deb/control b/build/deb/control index 19eb51664e7..3f564f5608f 100644 --- a/build/deb/control +++ b/build/deb/control @@ -9,7 +9,7 @@ Section: web Priority: optional Recommends: mozilla | netscape Homepage: http://www.dolibarr.org -Description: An ERP & CRM software to manage your activity. +Description: ERP & CRM software to manage your activity. Dolibarr ERP & CRM is an easy to use open source/free software for small and medium companies, foundations or freelances. It includes different features for Enterprise Resource Planning (ERP) and Customer Relationship diff --git a/build/deb/copyright b/build/deb/copyright index 74752ea4864..00aafd563b1 100644 --- a/build/deb/copyright +++ b/build/deb/copyright @@ -1 +1,4 @@ +Copyright 2011 Laurent Destailleur + +This software is distributed under GPL v2 licence. See file /usr/share/common-licenses/GPL-2 \ No newline at end of file diff --git a/build/deb/install.forced.php.install b/build/deb/install.forced.php.install index 4b92d7681d6..198565d3211 100755 --- a/build/deb/install.forced.php.install +++ b/build/deb/install.forced.php.install @@ -4,11 +4,12 @@ // This file must be present into htdocs/install directory // during install process to be used. // -// $Id: install.forced.php.install,v 1.5 2011/06/26 11:41:50 eldy Exp $ +// $Id: install.forced.php.install,v 1.6 2011/07/09 14:11:40 eldy Exp $ // $force_install_noedit=1; $force_install_message='KeepDefaultValuesDeb'; -$force_install_main_data_root='/usr/share/dolibarr/documents'; +#$force_install_main_data_root='/usr/share/dolibarr/documents'; +$force_install_main_data_root='/var/lib/dolibarr'; $force_install_type='mysqli'; $force_install_dbserver='localhost'; $force_install_port='3306'; diff --git a/build/deb/postinst b/build/deb/postinst index 0fbb8c73d7e..4d065f58ca0 100644 --- a/build/deb/postinst +++ b/build/deb/postinst @@ -51,7 +51,7 @@ case "$1" in # Create /var/lib/dolibarr/documents mkdir -p /var/lib/dolibarr/documents - chown -R www-data.www-data /var/lib/dolibarr/documents; + chown -R www-data:www-data /var/lib/dolibarr/documents; chmod -R 775 /var/lib/dolibarr/documents; chmod -R g+s /var/lib/dolibarr/documents; @@ -60,15 +60,15 @@ case "$1" in then echo Create empty file /usr/share/dolibarr/htdocs/conf/conf.php touch /usr/share/dolibarr/htdocs/conf/conf.php - chown -R www-data.www-data /usr/share/dolibarr/htdocs/conf/conf.php; + chown -R www-data:www-data /usr/share/dolibarr/htdocs/conf/conf.php; chmod -R 750 /usr/share/dolibarr/htdocs/conf/conf.php; fi #db_reset "dolibarr/webserver" # Get the web server type (use db_get for interactive mode). -# db_get "dolibarr/webserver" # Read value for webserver. -# webserver="$RET" + #db_get "dolibarr/webserver" # Read value for webserver. + #webserver="$RET" case $webserver in Apache) webservers="apache2" ;; @@ -81,23 +81,10 @@ case "$1" in for server in $webservers ; do echo Complete config of server $server - # Add info for PHP (obsolete) - #typestr='application/x-httpd-php' - #extension='.php' - #. /usr/share/wwwconfig-common/apache-addtype_all.sh - - # Enable PHP module (obsolete) - #. /usr/share/wwwconfig-common/apache-php.sh - #echo Result of enabling PHP modules: $status - # Detect webuser and webgroup webuser= webgroup= - # Search in httpd.conf (obsolete) - #. /usr/share/wwwconfig-common/apache-run.get - #echo Web user.group found is $webuser.$webgroup - if [ -z "$webuser" ] ; then webuser=www-data fi @@ -111,22 +98,12 @@ case "$1" in # That may lead to problems if apache & apache-ssl do # not have the same user/group. # - chown -R $webuser.$webgroup /usr/share/dolibarr + chown -R $webuser:$webgroup /usr/share/dolibarr - # Put content of conf file into apache httpd.conf main file (/etc/apache2/httpd.conf) - #includefile="/etc/dolibarr/apache.conf" - #. /usr/share/dolibarr/build/deb/apache-include_all.sh - #test "$status" = "uncomment" -o "$status" = "include" && restart="$server $restart" - # Add link to config file echo Setup web server $server to add dolibarr config file - ln -fs /etc/dolibarr/apache.conf /etc/apache2/conf.d + ln -fs /etc/dolibarr/apache.conf /etc/apache2/conf.d/dolibarr.conf - # (useless) - #for index in index.php; do - # . /usr/share/wwwconfig-common/apache-index_all.sh - # test "$status" = "added" && restart="$server $restart" - #done done # Copy icon file @@ -157,22 +134,17 @@ case "$1" in # Restart servers servers="apache2-ssl apache2 mysql" - if [ -f /usr/share/wwwconfig-common/restart.sh ] ; - then - echo Restart web servers running /usr/share/wwwconfig-common/restart.sh - . /usr/share/wwwconfig-common/restart.sh - else - # Another way to restart - for server in $servers ; do - echo Restart web server $server - if [ -x /usr/sbin/invoke-rc.d ]; then - # This on works with Debian (5.05,...) and Ubuntu (9.10,10.04,...) - invoke-rc.d $server reload || true - else - /etc/init.d/$server reload || true - fi - done - fi + # Another way to restart + for server in $servers ; do + if [ -x /usr/sbin/invoke-rc.d ]; then + echo Restart web server $server using invoke-rc.d + # This works with Debian (5.05,...) and Ubuntu (9.10,10.04,...) + invoke-rc.d $server reload || true + else + echo Restart web server $server using $server reload + /etc/init.d/$server reload || true + fi + done echo ---------- echo "Call Dolibarr page http://localhost/dolibarr/ to complete the installation and use Dolibarr." diff --git a/build/deb/postrm b/build/deb/postrm index 610f67772ac..c4d1c790e5d 100644 --- a/build/deb/postrm +++ b/build/deb/postrm @@ -72,10 +72,6 @@ case "$1" in echo postrm Mysql superuser found to use is $superuserlogin dbadmin="$superuserlogin" dbadmpass="$superuserpassword" - #db_get "dolibarr/db/admin/name" - #dbadmin="$RET" - #db_get "dolibarr/db/admin/password" - #dbadmpass="$RET" dbtype="mysql" # To delete a mysql user (disabled) @@ -149,30 +145,6 @@ case "$1" in # Remove include files for server in $webservers ; do - - # Old usage - #export conffile="/etc/$server/httpd.conf" - #export error="" - #echo "postrm conffile=$conffile" - #if [ -f $conffile ] ; - #then - # if [ -s $conffile ] ; - # then - # echo postrm remove dolibarr include from /etc/dolibarr/apache.conf - # # We disable set -e to avoid premature end of script if error - # set +e - # GREP="Include[[:space:]]\+$includefile\b" - # if grep -e "$GREP" $conffile > /dev/null 2>&1; then - # log="${log}Include of $includefile found in $conffile file, purging." - # status=purge - # grep -v -e "$GREP" < $conffile > $conffile.purg - # mv $conffile.purg $conffile - # fi - # # We restore blocking errors - # set -e - # fi - #fi - # New usage export conffile="/etc/$server/conf.d/dolibarr.conf" if [ -f $conffile ] ; @@ -189,25 +161,18 @@ case "$1" in rm -rf /etc/dolibarr # Restart servers - servers="apache2-ssl apache2 mysql" - if [ -f /usr/share/wwwconfig-common/restart.sh ] ; - then - . /usr/share/wwwconfig-common/restart.sh - else - # Another way to restart - for server in $servers ; do - # We disable blocking errors - set +e - echo "Restart server $server if exists" - if [ -x /usr/sbin/invoke-rc.d ]; then - invoke-rc.d $server reload || true - else - /etc/init.d/$server reload || true - fi - # We restore blocking errors - set -e - done - fi + for server in $servers ; do + # We disable blocking errors + set +e + echo "Restart server $server if exists" + if [ -x /usr/sbin/invoke-rc.d ]; then + invoke-rc.d $server reload || true + else + /etc/init.d/$server reload || true + fi + # We restore blocking errors + set -e + done # Remove file and conf file for dir in /usr/share/dolibarr ; do diff --git a/build/deb/templates b/build/deb/templates index 82fcaa1ba48..3b370ee68f2 100644 --- a/build/deb/templates +++ b/build/deb/templates @@ -91,6 +91,6 @@ Template: dolibarr/postrm Type: boolean Default: true Description: Delete database ? - Do I have to delete also the Dolibarr MySQL database and all its datas - (datas subjected to this quetion are the Dolibarr DBMS account and all + Answer yes if you want to delete also the Dolibarr MySQL database and all + its datas (datas subjected to this quetion are the Dolibarr DBMS account and all Dolibarr tables) ? diff --git a/dev/initdata/generate-commande.php b/dev/initdata/generate-commande.php index 98305ee38dd..a0b65ca05b3 100644 --- a/dev/initdata/generate-commande.php +++ b/dev/initdata/generate-commande.php @@ -1,3 +1,4 @@ +#!/usr/bin/php * Copyright (C) 2004-2007 Laurent Destailleur @@ -22,7 +23,7 @@ /** \file htdocs/dev/generate-commande.php \brief Script de generation de donnees aleatoires pour les commandes - \version $Id$ + \version $Id: generate-commande.php,v 1.17 2011/07/09 14:11:40 eldy Exp $ */ // Test si mode batch diff --git a/dev/initdata/generate-facture.php b/dev/initdata/generate-facture.php index 354f724fc62..7653d65ce41 100644 --- a/dev/initdata/generate-facture.php +++ b/dev/initdata/generate-facture.php @@ -1,4 +1,5 @@ - * * This program is free software; you can redistribute it and/or modify @@ -21,7 +22,7 @@ /** * \file htdocs/dev/generate-facture.php * \brief Script de generation de donnees aleatoires pour les factures - * \version $Id$ + * \version $Id: generate-facture.php,v 1.14 2011/07/09 14:11:40 eldy Exp $ */ // Test si mode batch diff --git a/dev/initdata/generate-produit.php b/dev/initdata/generate-produit.php index 37c7557b327..6bbc92b812e 100644 --- a/dev/initdata/generate-produit.php +++ b/dev/initdata/generate-produit.php @@ -1,3 +1,4 @@ +#!/usr/bin/php * Copyright (C) 2004-2010 Laurent Destailleur @@ -22,7 +23,7 @@ /** * \file htdocs/dev/generate-produit.php * \brief Script de generation de donnees aleatoires pour les produits - * \version $Id$ + * \version $Id: generate-produit.php,v 1.16 2011/07/09 14:11:40 eldy Exp $ */ // Test si mode batch diff --git a/dev/initdata/generate-propale.php b/dev/initdata/generate-propale.php index 16bd4d7d9a8..56c6debdad2 100644 --- a/dev/initdata/generate-propale.php +++ b/dev/initdata/generate-propale.php @@ -1,4 +1,5 @@ - * Copyright (C) 2007 Laurent Destailleur * @@ -22,7 +23,7 @@ /** * \file htdocs/dev/generate-propale.php * \brief Script de generation de donnees aleatoires pour les propales - * \version $Id$ + * \version $Id: generate-propale.php,v 1.15 2011/07/09 14:11:40 eldy Exp $ */ // Test si mode batch diff --git a/dev/initdata/generate-societe.php b/dev/initdata/generate-societe.php index 58fe6269eff..ed6cb9edce2 100644 --- a/dev/initdata/generate-societe.php +++ b/dev/initdata/generate-societe.php @@ -1,3 +1,4 @@ +#!/usr/bin/php * Copyright (C) 2006-2010 Laurent Destailleur @@ -22,7 +23,7 @@ /** * \file htdocs/dev/generate-societe.php * \brief Script de generation de donnees aleatoires pour les societes - * \version $Id$ + * \version $Id: generate-societe.php,v 1.16 2011/07/09 14:11:40 eldy Exp $ */ // Test si mode batch diff --git a/dev/samples/create_invoice.php b/dev/samples/create_invoice.php index 25c70fc1fe6..47cd61cac1b 100644 --- a/dev/samples/create_invoice.php +++ b/dev/samples/create_invoice.php @@ -1,4 +1,5 @@ - * * This program is free software; you can redistribute it and/or modify @@ -19,7 +20,7 @@ /** * \file dev/samples/manage_order.php * \brief This file is an example for a command line script - * \version $Id$ + * \version $Id: create_invoice.php,v 1.5 2011/07/09 14:11:41 eldy Exp $ * \author Put author name here * \remarks Put here some comments */ @@ -35,7 +36,7 @@ if (substr($sapi_type, 0, 3) == 'cgi') { } // Global variables -$version='$Revision$'; +$version='$Revision: 1.5 $'; $error=0; diff --git a/dev/samples/create_order.php b/dev/samples/create_order.php index d099fd29ae9..d955f35d0d4 100644 --- a/dev/samples/create_order.php +++ b/dev/samples/create_order.php @@ -1,4 +1,5 @@ - * * This program is free software; you can redistribute it and/or modify @@ -19,7 +20,7 @@ /** * \file dev/samples/manage_order.php * \brief This file is an example for a command line script - * \version $Id$ + * \version $Id: create_order.php,v 1.9 2011/07/09 14:11:41 eldy Exp $ * \author Put author name here * \remarks Put here some comments */ @@ -35,7 +36,7 @@ if (substr($sapi_type, 0, 3) == 'cgi') { } // Global variables -$version='$Revision$'; +$version='$Revision: 1.9 $'; $error=0; diff --git a/dev/samples/create_product.php b/dev/samples/create_product.php index 055d28aa4cd..fbf4c5ab835 100644 --- a/dev/samples/create_product.php +++ b/dev/samples/create_product.php @@ -1,4 +1,5 @@ - * * This program is free software; you can redistribute it and/or modify @@ -19,7 +20,7 @@ /** * \file dev/samples/create_product.php * \brief This file is an example for a command line script - * \version $Id$ + * \version $Id: create_product.php,v 1.8 2011/07/09 14:11:41 eldy Exp $ * \author Put author name here * \remarks Put here some comments */ @@ -35,7 +36,7 @@ if (substr($sapi_type, 0, 3) == 'cgi') { } // Global variables -$version='$Revision$'; +$version='$Revision: 1.8 $'; $error=0; diff --git a/dev/skeletons/build_class_from_table.php b/dev/skeletons/build_class_from_table.php index d228068d99f..c50f3ac4ec4 100644 --- a/dev/skeletons/build_class_from_table.php +++ b/dev/skeletons/build_class_from_table.php @@ -1,3 +1,4 @@ +#!/usr/bin/php * @@ -20,7 +21,7 @@ * \file dev/skeletons/build_class_from_table.php * \ingroup core * \brief Create a complete class file from a table in database - * \version $Id$ + * \version $Id: build_class_from_table.php,v 1.32 2011/07/09 14:11:40 eldy Exp $ */ $sapi_type = php_sapi_name(); @@ -38,7 +39,7 @@ require_once($path."../../htdocs/master.inc.php"); // After this $db is a defined handler to database. // Main -$version='$Revision$'; +$version='$Revision: 1.32 $'; @set_time_limit(0); $error=0; diff --git a/dev/skeletons/build_webservice_from_class.php b/dev/skeletons/build_webservice_from_class.php index 8a890118ab7..03c1f254ab7 100644 --- a/dev/skeletons/build_webservice_from_class.php +++ b/dev/skeletons/build_webservice_from_class.php @@ -1,3 +1,4 @@ +#!/usr/bin/php * @@ -20,7 +21,7 @@ * \file dev/skeletons/build_webservice_from_class.php * \ingroup core * \brief Create a complete webservice file from CRUD functions of a PHP class - * \version $Id$ + * \version $Id: build_webservice_from_class.php,v 1.6 2011/07/09 14:11:40 eldy Exp $ */ $sapi_type = php_sapi_name(); @@ -38,7 +39,7 @@ require_once($path."../../htdocs/master.inc.php"); // After this $db is a defined handler to database. // Main -$version='$Revision$'; +$version='$Revision: 1.6 $'; @set_time_limit(0); $error=0; diff --git a/dev/skeletons/skeleton_script.php b/dev/skeletons/skeleton_script.php index 8e1d2c7824e..eaffb1e1357 100644 --- a/dev/skeletons/skeleton_script.php +++ b/dev/skeletons/skeleton_script.php @@ -1,5 +1,6 @@ +#!/usr/bin/php +/* Copyright (C) 2007-2011 Laurent Destailleur * Copyright (C) ---Put here your own copyright and developer email--- * * This program is free software; you can redistribute it and/or modify @@ -21,7 +22,7 @@ * \file dev/skeletons/skeleton_script.php * \ingroup mymodule othermodule1 othermodule2 * \brief This file is an example for a command line script - * \version $Id$ + * \version $Id: skeleton_script.php,v 1.27 2011/07/09 14:11:41 eldy Exp $ * \author Put author name here * \remarks Put here some comments */ @@ -37,7 +38,7 @@ if (substr($sapi_type, 0, 3) == 'cgi') { } // Global variables -$version='$Revision$'; +$version='$Revision: 1.27 $'; $error=0; diff --git a/dev/translation/autotranslator.php b/dev/translation/autotranslator.php index b7f01926b06..0b43ca0c34f 100644 --- a/dev/translation/autotranslator.php +++ b/dev/translation/autotranslator.php @@ -1,4 +1,5 @@ - * * This program is free software; you can redistribute it and/or modify @@ -20,7 +21,7 @@ * \file dev/translation/autotranslator.php * \ingroup mymodule othermodule1 othermodule2 * \brief This file is an example for a command line script - * \version $Id: autotranslator.php,v 1.11 2011/06/26 18:52:49 eldy Exp $ + * \version $Id: autotranslator.php,v 1.12 2011/07/09 14:11:41 eldy Exp $ * \author Put author name here * \remarks Put here some comments */ @@ -44,7 +45,7 @@ require_once($path.'../../htdocs/lib/files.lib.php'); $langs->load("main"); // Global variables -$version='$Revision: 1.11 $'; +$version='$Revision: 1.12 $'; $error=0; diff --git a/scripts/banks/build-graph-sold-example.php b/scripts/banks/build-graph-sold-example.php index de00b5c1c04..08cf68fd6bb 100644 --- a/scripts/banks/build-graph-sold-example.php +++ b/scripts/banks/build-graph-sold-example.php @@ -1,5 +1,5 @@ #!/usr/bin/php - * Copyright (C) 2006-2009 Laurent Destailleur @@ -24,7 +24,7 @@ * \ingroup banque * \brief Script to build graph of sold for each bank account * \deprecated Ce script n'est plus utilise car les graphiques sont generes dynamiquement maintenant. - * \version $Id: build-graph-sold-example.php,v 1.9 2011/07/08 14:54:35 eldy Exp $ + * \version $Id: build-graph-sold-example.php,v 1.10 2011/07/09 14:11:41 eldy Exp $ */ $sapi_type = php_sapi_name(); diff --git a/scripts/company/export-contacts-xls-example.php b/scripts/company/export-contacts-xls-example.php index 24c07fe61c9..009f7d6b482 100644 --- a/scripts/company/export-contacts-xls-example.php +++ b/scripts/company/export-contacts-xls-example.php @@ -1,4 +1,5 @@ - * Copyright (C) 2009 Laurent Destailleur @@ -22,7 +23,7 @@ * \file scripts/company/export-contacts-xls-example.php * \ingroup company * \brief Export third parties' contacts with emails - * \version $Id$ + * \version $Id: export-contacts-xls-example.php,v 1.7 2011/07/09 14:11:42 eldy Exp $ */ $sapi_type = php_sapi_name(); @@ -42,7 +43,7 @@ if (! isset($argv[1]) || ! $argv[1]) { $now=$argv[1]; // Recupere env dolibarr -$version='$Revision$'; +$version='$Revision: 1.7 $'; require_once("../../htdocs/master.inc.php"); require_once(PHP_WRITEEXCEL_PATH."/class.writeexcel_workbook.inc.php"); diff --git a/scripts/company/sync_contacts_dolibarr2ldap.php b/scripts/company/sync_contacts_dolibarr2ldap.php index 7d7c2f84ec7..2dd446eb842 100644 --- a/scripts/company/sync_contacts_dolibarr2ldap.php +++ b/scripts/company/sync_contacts_dolibarr2ldap.php @@ -1,4 +1,5 @@ - * Copyright (C) 2006-2009 Laurent Destailleur @@ -22,7 +23,7 @@ * \file scripts/company/sync_contacts_dolibarr2ldap.php * \ingroup ldap company * \brief Script to update all contacts from Dolibarr into a LDAP database - * \version $Id$ + * \version $Id: sync_contacts_dolibarr2ldap.php,v 1.23 2011/07/09 14:11:42 eldy Exp $ */ $sapi_type = php_sapi_name(); @@ -42,7 +43,7 @@ if (! isset($argv[1]) || ! $argv[1]) { $now=$argv[1]; // Recupere env dolibarr -$version='$Revision$'; +$version='$Revision: 1.23 $'; require_once($path."../../htdocs/master.inc.php"); require_once(DOL_DOCUMENT_ROOT."/contact/class/contact.class.php"); diff --git a/scripts/invoices/email_unpaid_invoices_to_representatives.php b/scripts/invoices/email_unpaid_invoices_to_representatives.php index 6dc9046bfc5..8ee631df756 100644 --- a/scripts/invoices/email_unpaid_invoices_to_representatives.php +++ b/scripts/invoices/email_unpaid_invoices_to_representatives.php @@ -1,5 +1,5 @@ #!/usr/bin/php - * Copyright (C) 2005-2009 Laurent Destailleur @@ -23,7 +23,7 @@ * \file scripts/invoices/email_unpaid_invoices_to_representatives.php * \ingroup facture * \brief Script to send a mail to dolibarr users linked to companies with unpaid invoices - * \version $Id$ + * \version $Id: email_unpaid_invoices_to_representatives.php,v 1.9 2011/07/09 14:11:41 eldy Exp $ */ $sapi_type = php_sapi_name(); diff --git a/scripts/invoices/rebuild_merge_pdf.php b/scripts/invoices/rebuild_merge_pdf.php index edfa13ac705..631f4475be6 100644 --- a/scripts/invoices/rebuild_merge_pdf.php +++ b/scripts/invoices/rebuild_merge_pdf.php @@ -1,5 +1,5 @@ #!/usr/bin/php - * @@ -22,7 +22,7 @@ * \file scripts/invoices/rebuild_merge_pdf.php * \ingroup facture * \brief Script to rebuild PDF and merge PDF files into one - * \version $Id$ + * \version $Id: rebuild_merge_pdf.php,v 1.20 2011/07/09 14:11:41 eldy Exp $ */ $sapi_type = php_sapi_name(); @@ -49,7 +49,7 @@ require_once(DOL_DOCUMENT_ROOT.'/lib/pdf.lib.php'); $langs->load("main"); // Global variables -$version='$Revision$'; +$version='$Revision: 1.20 $'; $error=0; diff --git a/scripts/members/sync_members_dolibarr2ldap.php b/scripts/members/sync_members_dolibarr2ldap.php index 42ee711fc3f..3481510fdd3 100644 --- a/scripts/members/sync_members_dolibarr2ldap.php +++ b/scripts/members/sync_members_dolibarr2ldap.php @@ -1,4 +1,5 @@ - * Copyright (C) 2006-2008 Laurent Destailleur @@ -22,7 +23,7 @@ * \file scripts/members/sync_members_dolibarr2ldap.php * \ingroup ldap member * \brief Script de mise a jour des adherents dans LDAP depuis base Dolibarr - * \version $Id$ + * \version $Id: sync_members_dolibarr2ldap.php,v 1.9 2011/07/09 14:11:41 eldy Exp $ */ $sapi_type = php_sapi_name(); @@ -36,7 +37,7 @@ if (substr($sapi_type, 0, 3) == 'cgi') { } // Main -$version='$Revision$'; +$version='$Revision: 1.9 $'; $path=str_replace($script_file,'',$_SERVER["PHP_SELF"]); @set_time_limit(0); $error=0; diff --git a/scripts/members/sync_members_ldap2dolibarr.php b/scripts/members/sync_members_ldap2dolibarr.php index 359ec7cd662..47aacc54898 100644 --- a/scripts/members/sync_members_ldap2dolibarr.php +++ b/scripts/members/sync_members_ldap2dolibarr.php @@ -1,4 +1,5 @@ - * Copyright (C) 2006-2010 Laurent Destailleur @@ -22,7 +23,7 @@ * \file scripts/members/sync_members_ldap2dolibarr.php * \ingroup ldap member * \brief Script de mise a jour des adherents dans Dolibarr depuis LDAP - * \version $Id$ + * \version $Id: sync_members_ldap2dolibarr.php,v 1.12 2011/07/09 14:11:41 eldy Exp $ */ $sapi_type = php_sapi_name(); @@ -36,7 +37,7 @@ if (substr($sapi_type, 0, 3) == 'cgi') { } // Main -$version='$Revision$'; +$version='$Revision: 1.12 $'; @set_time_limit(0); $error=0; $forcecommit=0; diff --git a/scripts/user/sync_groups_dolibarr2ldap.php b/scripts/user/sync_groups_dolibarr2ldap.php index 046225bcf8f..c98720713c3 100644 --- a/scripts/user/sync_groups_dolibarr2ldap.php +++ b/scripts/user/sync_groups_dolibarr2ldap.php @@ -1,4 +1,5 @@ - * Copyright (C) 2006 Laurent Destailleur @@ -22,7 +23,7 @@ * \file scripts/user/sync_groups_dolibarr2ldap.php * \ingroup ldap core * \brief Script de mise a jour des groupes dans LDAP depuis base Dolibarr - * \version $Id$ + * \version $Id: sync_groups_dolibarr2ldap.php,v 1.8 2011/07/09 14:11:42 eldy Exp $ */ $sapi_type = php_sapi_name(); @@ -42,7 +43,7 @@ if (! isset($argv[1]) || ! $argv[1]) { $now=$argv[1]; // Recupere env dolibarr -$version='$Revision$'; +$version='$Revision: 1.8 $'; require_once($path."../../htdocs/master.inc.php"); require_once(DOL_DOCUMENT_ROOT."/lib/ldap.class.php"); diff --git a/scripts/user/sync_users_dolibarr2ldap.php b/scripts/user/sync_users_dolibarr2ldap.php index 56d3ed149f2..cb18a18979a 100644 --- a/scripts/user/sync_users_dolibarr2ldap.php +++ b/scripts/user/sync_users_dolibarr2ldap.php @@ -1,4 +1,5 @@ - * Copyright (C) 2006 Laurent Destailleur @@ -22,7 +23,7 @@ * \file scripts/user/sync_users_dolibarr2ldap.php * \ingroup ldap core * \brief Script de mise a jour des users dans LDAP depuis base Dolibarr - * \version $Id$ + * \version $Id: sync_users_dolibarr2ldap.php,v 1.11 2011/07/09 14:11:42 eldy Exp $ */ $sapi_type = php_sapi_name(); @@ -42,7 +43,7 @@ if (! isset($argv[1]) || ! $argv[1]) { $now=$argv[1]; // Recupere env dolibarr -$version='$Revision$'; +$version='$Revision: 1.11 $'; require_once($path."../../htdocs/master.inc.php"); require_once(DOL_DOCUMENT_ROOT."/lib/ldap.class.php"); diff --git a/scripts/withdrawals/build_withdrawal_file.php b/scripts/withdrawals/build_withdrawal_file.php index b5bbf50eab5..d5853858189 100644 --- a/scripts/withdrawals/build_withdrawal_file.php +++ b/scripts/withdrawals/build_withdrawal_file.php @@ -1,4 +1,5 @@ - * Copyright (C) 2005-2010 Laurent Destailleur @@ -22,7 +23,7 @@ * \file scripts/withdrawals/build_withdrawal_file.php * \ingroup prelevement * \brief Script de prelevement - * \version $Id$ + * \version $Id: build_withdrawal_file.php,v 1.4 2011/07/09 14:11:41 eldy Exp $ */ $sapi_type = php_sapi_name(); @@ -36,7 +37,7 @@ if (substr($sapi_type, 0, 3) == 'cgi') { } // Recupere env dolibarr -$version='$Revision$'; +$version='$Revision: 1.4 $'; require_once($path."../../htdocs/master.inc.php"); require_once(DOL_DOCUMENT_ROOT."/compta/prelevement/class/bon-prelevement.class.php"); From 1ed7901d5793d7f53b85d671d938f4281c18d5dd Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 15:48:19 +0000 Subject: [PATCH 13/49] Qual: A lot of fixes to enhance package quality --- build/deb/apache.conf | 8 ++++++ build/deb/changelog | 2 +- build/deb/control | 20 ++++++++------- build/deb/install.forced.php.install | 7 +++--- build/deb/postinst | 16 ++++++------ build/deb/templates | 15 ++++++++--- build/makepack-dolibarr.pl | 37 ++++++++++++++++------------ 7 files changed, 66 insertions(+), 39 deletions(-) diff --git a/build/deb/apache.conf b/build/deb/apache.conf index d37b433fb98..568dd605dca 100644 --- a/build/deb/apache.conf +++ b/build/deb/apache.conf @@ -13,6 +13,7 @@ Alias /dolibarr /usr/share/dolibarr/htdocs # CustomLog logs/ldap.example.com-access.log common # +# Directory for web pages DirectoryIndex index.php Options +FollowSymLinks +Indexes @@ -55,12 +56,19 @@ Alias /dolibarr /usr/share/dolibarr/htdocs +# Directory for public pages AllowOverride All Order deny,allow Allow from all +# Directory for data files + + AllowOverride All + Order deny,allow + Allow from all + AllowOverride All Order deny,allow diff --git a/build/deb/changelog b/build/deb/changelog index 182110624de..d75fd100a60 100644 --- a/build/deb/changelog +++ b/build/deb/changelog @@ -1,4 +1,4 @@ - dolibarr 3.1.0 unstable; urgency=low +dolibarr 3.1.0 unstable; urgency=low * New 3.1.0 release More information into /usr/share/dolibarr/ChangeLog file. -- maintainer Laurent Destailleur 2011-07-09 \ No newline at end of file diff --git a/build/deb/control b/build/deb/control index 3f564f5608f..07a08b7d045 100644 --- a/build/deb/control +++ b/build/deb/control @@ -7,31 +7,32 @@ Installed-Size: 31200 Depends: apache2, libapache2-mod-php5, php5, php5-cli, php5-cgi, php5-curl, php5-gd, php5-ldap, php5-mysql, mysql-server, perl Section: web Priority: optional -Recommends: mozilla | netscape +Recommends: firefox Homepage: http://www.dolibarr.org -Description: ERP & CRM software to manage your activity. +Description: Easy to use ERP & CRM software to manage your activity. Dolibarr ERP & CRM is an easy to use open source/free software for small and medium companies, foundations or freelances. It includes different features for Enterprise Resource Planning (ERP) and Customer Relationship - Management (CRM) but also other features for different activities. + Management (CRM) but also for different other activities. . - Dolibarr features are activated by modules. Most common modules are: + Only features you need are visible, depending on which module were activated. + Most common used modules are: . - * Products and services catalog - * Stock management - * Bank accounts management * Customers, Suppliers or Prospects directory * Contacts directory * Orders management * Commercial proposals management * Invoices management + * Products and services catalog + * Stock management + * Foundations members management + * Bank accounts management * Point of Sale * Payments management * Commercial actions management * Contracts management * Standing orders management * Shipping management - * Foundations members management * Donations management * Bookmarks management * Mass Emailings @@ -39,4 +40,5 @@ Description: ERP & CRM software to manage your activity. * Data export and import tools * LDAP connectivity * PDF exports - * And a lot of other modules + * And a lot of more modules... +You can also add third parties external modules or develop yours. \ No newline at end of file diff --git a/build/deb/install.forced.php.install b/build/deb/install.forced.php.install index 198565d3211..1166abe41ae 100755 --- a/build/deb/install.forced.php.install +++ b/build/deb/install.forced.php.install @@ -4,12 +4,13 @@ // This file must be present into htdocs/install directory // during install process to be used. // -// $Id: install.forced.php.install,v 1.6 2011/07/09 14:11:40 eldy Exp $ +// $Id: install.forced.php.install,v 1.7 2011/07/09 15:48:19 eldy Exp $ // + $force_install_noedit=1; $force_install_message='KeepDefaultValuesDeb'; -#$force_install_main_data_root='/usr/share/dolibarr/documents'; -$force_install_main_data_root='/var/lib/dolibarr'; +$force_install_main_data_root='/usr/share/dolibarr/documents'; +#$force_install_main_data_root='/var/lib/dolibarr'; $force_install_type='mysqli'; $force_install_dbserver='localhost'; $force_install_port='3306'; diff --git a/build/deb/postinst b/build/deb/postinst index 4d065f58ca0..12e3fdbd07a 100644 --- a/build/deb/postinst +++ b/build/deb/postinst @@ -49,19 +49,21 @@ case "$1" in cat $fileorig | sed -e 's/__SUPERUSERLOGIN__/'$superuserlogin'/g' | sed -e 's/__SUPERUSERPASSWORD__/'$superuserpassword'/g' > $config fi - # Create /var/lib/dolibarr/documents - mkdir -p /var/lib/dolibarr/documents - chown -R www-data:www-data /var/lib/dolibarr/documents; - chmod -R 775 /var/lib/dolibarr/documents; - chmod -R g+s /var/lib/dolibarr/documents; + # Create document directory + #docdir='/var/lib/dolibarr/documents' + docdir='/usr/share/dolibarr/documents' + mkdir -p $docdir + chown -R www-data:www-data $docdir + chmod -R 775 $docdir + chmod -R g+s $docdir # Create an empty conf.php with permission to web server if [ ! -f /usr/share/dolibarr/htdocs/conf/conf.php ] then echo Create empty file /usr/share/dolibarr/htdocs/conf/conf.php touch /usr/share/dolibarr/htdocs/conf/conf.php - chown -R www-data:www-data /usr/share/dolibarr/htdocs/conf/conf.php; - chmod -R 750 /usr/share/dolibarr/htdocs/conf/conf.php; + chown -R www-data:www-data /usr/share/dolibarr/htdocs/conf/conf.php + chmod -R 750 /usr/share/dolibarr/htdocs/conf/conf.php fi #db_reset "dolibarr/webserver" diff --git a/build/deb/templates b/build/deb/templates index 3b370ee68f2..1d1c133f99a 100644 --- a/build/deb/templates +++ b/build/deb/templates @@ -15,7 +15,7 @@ Description: Package configuration note Template: dolibarr/webserver Type: select Choices: Apache, Apache-ssl, Both, None -Description: Which Web Server are you running? +Description: Which Web Server are you running ? Dolibarr supports any web server with PHP capabilities, but this configuration process only supports Apache and Apache-SSL. @@ -91,6 +91,15 @@ Template: dolibarr/postrm Type: boolean Default: true Description: Delete database ? - Answer yes if you want to delete also the Dolibarr MySQL database and all - its datas (datas subjected to this quetion are the Dolibarr DBMS account and all + Delete the Dolibarr MySQL database and all its datas (datas related + to this quetion are the Dolibarr DBMS account and all Dolibarr tables) ? + +Template: dolibarr/postrmfile +Type: boolean +Default: true +Description: Delete attached files ? + Delete also all uploaded and generated files (datas related + to this quetion are all files found into /usr/share/dolibarr/documents, + uploaded or generated when using Dolibarr) ? + \ No newline at end of file diff --git a/build/makepack-dolibarr.pl b/build/makepack-dolibarr.pl index 799a17c5ff4..2cc4b0b880e 100644 --- a/build/makepack-dolibarr.pl +++ b/build/makepack-dolibarr.pl @@ -2,7 +2,7 @@ #---------------------------------------------------------------------------- # \file build/makepack-dolibarr.pl # \brief Dolibarr package builder (tgz, zip, rpm, deb, exe, aps) -# \version $Id: makepack-dolibarr.pl,v 1.106 2011/07/09 02:41:37 eldy Exp $ +# \version $Id: makepack-dolibarr.pl,v 1.107 2011/07/09 15:48:19 eldy Exp $ # \author (c)2004-2011 Laurent Destailleur #---------------------------------------------------------------------------- @@ -48,7 +48,7 @@ if (-d "/usr/src/RPM") { use vars qw/ $REVISION $VERSION /; -$REVISION='$Revision: 1.106 $'; $REVISION =~ /\s(.*)\s/; $REVISION=$1; +$REVISION='$Revision: 1.107 $'; $REVISION =~ /\s(.*)\s/; $REVISION=$1; $VERSION="1.0 (build $REVISION)"; @@ -98,7 +98,7 @@ if (! $TEMP || ! -d $TEMP) { $BUILDROOT="$TEMP/buildroot"; -my $copyalreadydone=0; +my $copyalreadydone=0; # Use - before number of choice to avoid copy my $batch=0; for (0..@ARGV-1) { @@ -457,7 +457,6 @@ if ($nboftargetok) { print "Copy $BUILDROOT/$PROJECT to $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT\n"; $cmd="cp -pr \"$BUILDROOT/$PROJECT\" \"$BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT\""; $ret=`$cmd`; - print "Create directory $BUILDROOT/$PROJECT.tmp/DEBIAN\n"; $ret=`mkdir "$BUILDROOT/$PROJECT.tmp/DEBIAN"`; print "Copy $SOURCE/build/deb/* to $BUILDROOT/$PROJECT.tmp/DEBIAN\n"; @@ -498,13 +497,11 @@ if ($nboftargetok) { $ret=`mkdir -p "$BUILDROOT/$PROJECT.tmp/usr/share/applications"`; print "Copy desktop file into $BUILDROOT/$PROJECT.tmp/usr/share/applications/dolibarr.desktop\n"; $ret=`cp "$SOURCE/build/deb/dolibarr.desktop" "$BUILDROOT/$PROJECT.tmp/usr/share/applications/dolibarr.desktop"`; - $ret=`chmod 444 $BUILDROOT/$PROJECT.tmp/usr/share/applications/dolibarr.desktop`; print "Create directory $BUILDROOT/$PROJECT.tmp/usr/share/pixmaps\n"; $ret=`mkdir -p "$BUILDROOT/$PROJECT.tmp/usr/share/pixmaps"`; print "Copy pixmap file into $BUILDROOT/$PROJECT.tmp/usr/share/pixmaps/dolibarr.xpm\n"; $ret=`cp "$SOURCE/doc/images/dolibarr.xpm" "$BUILDROOT/$PROJECT.tmp/usr/share/pixmaps/dolibarr.xpm"`; - $ret=`chmod 444 $BUILDROOT/$PROJECT.tmp/usr/share/pixmaps/dolibarr.xpm`; print "Create directory $BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT\n"; $ret=`mkdir -p "$BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT"`; @@ -516,20 +513,28 @@ if ($nboftargetok) { print "Copy copyright file into $BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT/copyright\n"; $ret=`cp "$BUILDROOT/$PROJECT.tmp/DEBIAN/copyright" "$BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT/copyright"`; - $ret=`gzip -c $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/ChangeLog > $BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT/changelog.Debian.gz`; + #$ret=`gzip -9 -c $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/ChangeLog > $BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT/changelog.Debian.gz`; + $ret=`gzip -9 -c $BUILDROOT/$PROJECT.tmp/DEBIAN/changelog > $BUILDROOT/$PROJECT.tmp/usr/share/doc/$PROJECT/changelog.Debian.gz`; - print "Create directory $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/documents\n"; - $ret=`mkdir -p "$BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/documents"`; - - print "Set permissions/owners on files/dir\n"; + print "Set owners on files/dir\n"; $ret=`chown -R root.root $BUILDROOT/$PROJECT.tmp`; - $ret=`chown -R www-data.www-data $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/documents`; - $ret=`chmod -R 555 $BUILDROOT/$PROJECT.tmp`; - $ret=`chmod 755 $BUILDROOT/$PROJECT.tmp`; - $ret=`chmod -R 755 $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/documents`; - $ret=`chmod -R 755 $BUILDROOT/$PROJECT.tmp/DEBIAN`; + + print "Set permissions on files/dir\n"; + $ret=`chmod -R 755 $BUILDROOT/$PROJECT.tmp`; + $cmd="find $BUILDROOT/$PROJECT.tmp -type f -exec chmod 644 {} \\; "; + $ret=`$cmd`; + $cmd="find $BUILDROOT/$PROJECT.tmp/DEBIAN -type f -exec chmod 755 {} \\; "; + $ret=`$cmd`; $ret=`chmod 644 $BUILDROOT/$PROJECT.tmp/DEBIAN/control`; $ret=`chmod 644 $BUILDROOT/$PROJECT.tmp/DEBIAN/templates`; + $cmd="find $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/build -name *.php -type f -exec chmod 755 {} \\; "; + $ret=`$cmd`; + $cmd="find $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/build -name *.pl -type f -exec chmod 755 {} \\; "; + $ret=`$cmd`; + $cmd="find $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/dev -name *.php -type f -exec chmod 755 {} \\; "; + $ret=`$cmd`; + $cmd="find $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/scripts -name *.php -type f -exec chmod 755 {} \\; "; + $ret=`$cmd`; print "Go to directory $BUILDROOT\n"; $olddir=getcwd(); From 5e6409e02e72aadbaf9ad03d72f6d575726f7dd2 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 17:42:07 +0000 Subject: [PATCH 14/49] Work on packaging RPM & DEB --- build/deb/README | 15 ++++++++++++++- build/deb/config | 11 ----------- build/deb/control | 7 +++++-- build/deb/dolibarr.desktop | 17 +++++++++++------ build/deb/postinst | 6 ------ build/rpm/README | 9 ++++++++- build/rpm/dolibarr.desktop | 23 +++++++++++++++++++++++ build/rpm/dolibarr.spec | 28 +++++++++++++++++++++++++++- 8 files changed, 88 insertions(+), 28 deletions(-) create mode 100755 build/rpm/dolibarr.desktop diff --git a/build/deb/README b/build/deb/README index 09c64853215..e898dd43821 100644 --- a/build/deb/README +++ b/build/deb/README @@ -5,4 +5,17 @@ DEB Package tools This directory contains files used by makepack-dolibarr.pl script to build a package, ready to be distributed, -with format .DEB (for Debian, Ubuntu, ...). \ No newline at end of file +with format .DEB (for Debian, Ubuntu, ...). + +# This is standard command to work on Debian packaging: +# +# lintian package To test a package +# +# dpkg -l List all packages +# dpkg -b To build package +# dpkg -c package.deb List content of package +# dpkg -I package.deb Give informations on package +# dpkg -i package.deb Install a package +# +# dpkg -L packagename List content of installed package +# dpkg --purge Remove config files and interactive saved answers diff --git a/build/deb/config b/build/deb/config index e006ebda186..1965ef73cc5 100644 --- a/build/deb/config +++ b/build/deb/config @@ -1,17 +1,6 @@ #!/bin/sh # Debian install package run: config, preinst, prerm, postinst, postrm # -# lintian package To test a package -# -# dpkg -l list all packages -# dpkg -b is to build package -# dpkg -c package.deb list content of package -# dpkg -I package.deb give informations on package -# dpkg -i package.deb install a package -# -# dpkg -L packagename list content of installed package -# dpkg --purge remove interactive saved answers -# set -e diff --git a/build/deb/control b/build/deb/control index 07a08b7d045..3d8878f4569 100644 --- a/build/deb/control +++ b/build/deb/control @@ -3,7 +3,7 @@ Version: __VERSION__ Architecture: all Maintainer: Laurent Destailleur Essential: no -Installed-Size: 31200 +Installed-Size: 61200 Depends: apache2, libapache2-mod-php5, php5, php5-cli, php5-cgi, php5-curl, php5-gd, php5-ldap, php5-mysql, mysql-server, perl Section: web Priority: optional @@ -14,6 +14,7 @@ Description: Easy to use ERP & CRM software to manage your activity. and medium companies, foundations or freelances. It includes different features for Enterprise Resource Planning (ERP) and Customer Relationship Management (CRM) but also for different other activities. + Dolibarr was designed to provide only features you need and be easy to use. . Only features you need are visible, depending on which module were activated. Most common used modules are: @@ -41,4 +42,6 @@ Description: Easy to use ERP & CRM software to manage your activity. * LDAP connectivity * PDF exports * And a lot of more modules... -You can also add third parties external modules or develop yours. \ No newline at end of file + . + You can also add third parties external modules or develop yours. + \ No newline at end of file diff --git a/build/deb/dolibarr.desktop b/build/deb/dolibarr.desktop index 7ae7d4d8a7a..5d11eb40ffb 100644 --- a/build/deb/dolibarr.desktop +++ b/build/deb/dolibarr.desktop @@ -3,15 +3,20 @@ # It must be saved into directory /usr/share/applications Version=1.0 Encoding=UTF-8 -Name=Dolibarr ERP/CRM -GenericName=Dolibarr ERP/CRM -Comment=The easy to use manager for small and medium enterprises or foundations -# xdg-open use default bowser to open url (exo-open for xfde, gnome-open for gnome, ...) -Exec=xdg-open http://localhost/dolibarr +Name=Dolibarr ERP & CRM +Name[fr]=Dolibarr ERP & CRM +GenericName=Dolibarr ERP & CRM +Comment=The easy to use manager (ERP & CRM) for small and medium enterprises or foundations +Comment[fr]=L'ERP & CRM simple pour la gestion des PME et associations +# Command to open an URL +# For Fedora: xdg-open +# For Debian/Ubuntu: x-www-browser +# (exo-open for xfde, gnome-open for gnome, ...) +Exec=x-www-browser http://localhost/dolibarr Icon=dolibarr Terminal=false Type=Application -Category=Application;Office; +Categories=Office StartupNotify=true InitialPreference=5 #NoDisplay=true diff --git a/build/deb/postinst b/build/deb/postinst index 12e3fdbd07a..be9fb7521b7 100644 --- a/build/deb/postinst +++ b/build/deb/postinst @@ -108,12 +108,6 @@ case "$1" in done - # Copy icon file - #echo "Copy icon file" - #fileorig="/usr/share/dolibarr/doc/images/dolibarr.xpm" - #target="/usr/share/pixmaps/" - #cp -f $fileorig $target - #echo "Install menu entry" # This one is for Gnome ubuntu #fileorig="/usr/share/dolibarr/build/deb/dolibarr.desktop" diff --git a/build/rpm/README b/build/rpm/README index 395ba283fa9..1b2d4745dc4 100644 --- a/build/rpm/README +++ b/build/rpm/README @@ -5,4 +5,11 @@ RPM Package tools This directory contains files used by makepack-dolibarr.pl script to build a package, ready to be distributed, -with format RPM (for Redhat, Mandriva, ...). \ No newline at end of file +with format RPM (for Redhat, Mandriva, ...). + + +# This is standard command to work on Debian packaging: +# +# yum install dolibarr To remove package +# yum erase dolibarr To remove package +# diff --git a/build/rpm/dolibarr.desktop b/build/rpm/dolibarr.desktop new file mode 100755 index 00000000000..e3be821080c --- /dev/null +++ b/build/rpm/dolibarr.desktop @@ -0,0 +1,23 @@ +[Desktop Entry] +# This file is used to add Ubuntu menu entry +# It must be saved into directory /usr/share/applications +Version=1.0 +Encoding=UTF-8 +Name=Dolibarr ERP & CRM +Name[fr]=Dolibarr ERP & CRM +GenericName=Dolibarr ERP & CRM +Comment=The easy to use manager (ERP & CRM) for small and medium enterprises or foundations +Comment[fr]=L'ERP & CRM simple pour la gestion des PME et associations +# Command to open an URL +# For Fedora: xdg-open +# For Debian/Ubuntu: x-www-browser +# (exo-open for xfde, gnome-open for gnome, ...) +Exec=xdg-open http://localhost/dolibarr +Icon=dolibarr +Terminal=false +Type=Application +Categories=Office +StartupNotify=true +InitialPreference=5 +#NoDisplay=true +#OnlyShowIn=GNOME diff --git a/build/rpm/dolibarr.spec b/build/rpm/dolibarr.spec index d8bad08806c..b1def13ae37 100644 --- a/build/rpm/dolibarr.spec +++ b/build/rpm/dolibarr.spec @@ -36,7 +36,12 @@ AutoReqProv: yes %description -Dolibarr ERP & CRM +Dolibarr ERP & CRM is an easy to use open source/free software for small +and medium companies, foundations or freelances. It includes different +features for Enterprise Resource Planning (ERP) and Customer Relationship +Management (CRM) but also for different other activities. +Dolibarr was designed to provide only features you need and be easy to +use. %description -l fr Dolibarr ERP & CRM est un logiciel de gestion de PME/PMI, autoentrepreneurs, @@ -67,6 +72,11 @@ mkdir -p $RPM_BUILD_ROOT/var/www/dolibarr/scripts #mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/dolibarr #mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/cron.daily +mkdir -p $RPM_BUILD_ROOT%{_datadir}/pixmaps +cp doc/images/dolibarr_48x48.png $RPM_BUILD_ROOT%{_datadir}/pixmaps/dolibarr.png +mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications +cp build/rpm/dolibarr.desktop $RPM_BUILD_ROOT/%{_datadir}/applications/dolibarr.desktop + install -m 444 README $RPM_BUILD_ROOT/var/www/dolibarr/README install -m 444 COPYRIGHT $RPM_BUILD_ROOT/var/www/dolibarr/COPYRIGHT cp -pr build $RPM_BUILD_ROOT/var/www/dolibarr @@ -74,6 +84,17 @@ cp -pr doc $RPM_BUILD_ROOT/var/www/dolibarr cp -pr htdocs $RPM_BUILD_ROOT/var/www/dolibarr cp -pr scripts $RPM_BUILD_ROOT/var/www/dolibarr +# menu +#%{__install} -d $RPM_BUILD_ROOT%{_menudir} +#%{__cat} <$RPM_BUILD_ROOT%{_menudir}/%{name} +#?package(%{name}):\ +#command="Dolibarr" \ +#section="Office" \ +#title="Dolibarr" \ +#icon="dolibarr_48x48.png" \ +#longtitle="Dolibarr ERP & CRM" +#EOF + #---- clean %clean @@ -89,6 +110,8 @@ rm -rf $RPM_BUILD_ROOT %dir /var/www/dolibarr/build %dir /var/www/dolibarr/htdocs %dir /var/www/dolibarr/scripts +%_datadir/pixmaps/* +%_datadir/applications/%{name}.desktop /var/www/dolibarr/build/* /var/www/dolibarr/htdocs/* /var/www/dolibarr/scripts/* @@ -96,8 +119,10 @@ rm -rf $RPM_BUILD_ROOT /var/www/dolibarr/COPYRIGHT #%config /var/www/dolibarr/htdocs/conf/conf.php + #---- post (after install) %post +%update_menus # Dolibarr files are stored into /var/www export targetdir='/var/www/dolibarr' @@ -187,6 +212,7 @@ echo #---- postun (after uninstall) %postun +%clean_menus # Dolibarr files are stored into /var/www export targetdir='/var/www/dolibarr' From 5406b00d7cefc38add288c204def590cc2b54b51 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 18:29:46 +0000 Subject: [PATCH 15/49] Work on packaging RPM & DEB --- build/makepack-dolibarr.pl | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/build/makepack-dolibarr.pl b/build/makepack-dolibarr.pl index 2cc4b0b880e..532bf16a2da 100644 --- a/build/makepack-dolibarr.pl +++ b/build/makepack-dolibarr.pl @@ -2,7 +2,7 @@ #---------------------------------------------------------------------------- # \file build/makepack-dolibarr.pl # \brief Dolibarr package builder (tgz, zip, rpm, deb, exe, aps) -# \version $Id: makepack-dolibarr.pl,v 1.107 2011/07/09 15:48:19 eldy Exp $ +# \version $Id: makepack-dolibarr.pl,v 1.108 2011/07/09 18:29:46 eldy Exp $ # \author (c)2004-2011 Laurent Destailleur #---------------------------------------------------------------------------- @@ -48,7 +48,7 @@ if (-d "/usr/src/RPM") { use vars qw/ $REVISION $VERSION /; -$REVISION='$Revision: 1.107 $'; $REVISION =~ /\s(.*)\s/; $REVISION=$1; +$REVISION='$Revision: 1.108 $'; $REVISION =~ /\s(.*)\s/; $REVISION=$1; $VERSION="1.0 (build $REVISION)"; @@ -529,8 +529,8 @@ if ($nboftargetok) { $ret=`chmod 644 $BUILDROOT/$PROJECT.tmp/DEBIAN/templates`; $cmd="find $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/build -name *.php -type f -exec chmod 755 {} \\; "; $ret=`$cmd`; - $cmd="find $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/build -name *.pl -type f -exec chmod 755 {} \\; "; - $ret=`$cmd`; + #$cmd="find $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/build -name *.pl -type f -exec chmod 755 {} \\; "; + #$ret=`$cmd`; $cmd="find $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/dev -name *.php -type f -exec chmod 755 {} \\; "; $ret=`$cmd`; $cmd="find $BUILDROOT/$PROJECT.tmp/usr/share/$PROJECT/scripts -name *.php -type f -exec chmod 755 {} \\; "; From 9e2d3f4df10f80c3e6386ee7d035eb1b545f2157 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 22:18:50 +0000 Subject: [PATCH 16/49] Prepare release 3.1 --- build/pad/DoliWamp.pml | 45 +++++++++------ build/pad/Dolibarr developpers.cml | 62 ++++++++++----------- build/pad/Dolibarr.pml | 64 ++++++++++++---------- build/pad/pad_dolibarr.xml | 88 ++++++++++++++---------------- build/pad/pad_doliwamp.xml | 47 +++++++++------- 5 files changed, 162 insertions(+), 144 deletions(-) diff --git a/build/pad/DoliWamp.pml b/build/pad/DoliWamp.pml index 757924a6f49..beb13bbae0d 100644 --- a/build/pad/DoliWamp.pml +++ b/build/pad/DoliWamp.pml @@ -4,9 +4,9 @@ DoliWamp - 3.0.0 - 01 - 16 + 3.1.0 + 07 + 09 2011 @@ -14,7 +14,7 @@ Freeware Major Update Install and Uninstall - Win2000,Win7 x32,Win7 x64,Win98,WinOther,WinServer,WinVista,WinVista x64,WinXP + Win2000,Win7 x32,Win7 x64,Win98,WinOther,WinServer,WinVista,WinVista x64,WinXP,Other English,Arabic,Catalan,Chinese,Dutch,Finnish,French,German,Icelandic,Italian,Norwegian,Polish,Portuguese,Romanian,Russian,Slovenian,Spanish,Swedish,Turkish http://www.dolibarr.org Business @@ -42,16 +42,25 @@ DoliWamp, the easy to use Dolibarr for Windows to manage your company,foundation DoliWamp is the Dolibarr ERP/CRM for Windows, the easy to use open source software to manage your activity (invoices, customers, suppliers, contracts, agenda, emailings...) and any other things a small or mid-sized business or a foundation needs. DoliWamp is the Dolibarr ERP/CRM autoinstaller for Windows users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. Dolibarr ERP/CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations. - DoliWamp is the Dolibarr ERP/CRM for Windows. - -Dolibarr ERP & CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations (You can manage or follow contacts, invoices, orders, commercial proposals, products, stock management, agenda, mass emailings, members of a foundation, bank accounts...). - -It's an OpenSource project, based on a WAMP, MAMP or LAMP server (Apache, Mysql, PHP for all Operating Systems). Dolibarr differs from other ERP or CRM softwares (like OpenAguila, OpenBravo, OpenERP, Neogia, Compiere, etc) because everything was made to be more simple: Simple to install, Simple to use, Simple to develop. - -DoliWamp is the auto-installer for Windows users with no technical knowledge to install Dolibarr ERP/CRM and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. - - + DoliWamp is the Dolibarr ERP/CRM for Windows. Dolibarr ERP & CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations (You can manage or follow contacts, invoices, orders, commercial proposals, products, stock management, agenda, mass emailings, members of a foundation, bank accounts...). Based on a WAMP, MAMP or LAMP server (Apache, Mysql, PHP for all Operating Systems), you can install it as a standalone program or use it from anywhere with any web browser. Dolibarr is an OpenSource project. It differs from other ERP or CRM softwares (like OpenAguila, OpenBravo, OpenERP, Neogia, Compiere, etc) because everything was made to be more simple: Simple to install, Simple to use, Simple to develop. +DoliWamp is the auto-installer for Windows users with no technical knowledge to install Dolibarr ERP/CRM and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. + + doliwamp, dolibarr, erp, crm, factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations, entreprises, PME, TPE + DoliWamp, Dolibarr ERP/CRM pour Windows + DoliWamp, la distribution de Dolibarr pour gérer votre entreprise ou association + DoliWamp est la version spécialisée pour Windows de Dolibarr ERP-CRM, le logiciel simple et OpenSource pour gérer votre activité (factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations) + DoliWamp est la version spécialisée pour Windows de Dolibarr ERP-CRM, le logiciel simple et OpenSource pour gérer votre activité (factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations) + DoliWamp est la version spécialisée pour Windows de Dolibarr ERP-CRM, le logiciel simple et OpenSource pour gérer votre activité (factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations) + + + doliwamp, dolibarr, erp, crm, gestionale, medie imprese, fondazioni + DoliWamp, Dolibarr ERP/CRM per Windows + Gestionale open source e gratuito per piccole e medie imprese, fondazioni + Dolibarr è un a gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. + Dolibarr è un programma gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. Dolibar è progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. + Dolibarr è un programma gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. Dolibar è progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. Dolibar è completamente web-based, progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. + @@ -72,11 +81,6 @@ DoliWamp is the auto-installer for Windows users with no technical knowledge to GNU GPL GNU GPL - - Y - N - - Y 1.4 @@ -183,4 +187,9 @@ DoliWamp is the auto-installer for Windows users with no technical knowledge to + + Y + N + + diff --git a/build/pad/Dolibarr developpers.cml b/build/pad/Dolibarr developpers.cml index d784baa2c1e..06be3b4770f 100644 --- a/build/pad/Dolibarr developpers.cml +++ b/build/pad/Dolibarr developpers.cml @@ -1,31 +1,31 @@ - - - PADGen 3.0.1.38 - - Dolibarr team - 61 Boulevard Vauban - - Montigny-le-Bretonneux - - 78180 - FRANCE - http://www.dolibarr.org - - Dolibarr team - Dolibarr team - dolibarr-dev@nongnu.org - Dolibarr team - Dolibarr team - dolibarr-dev@nongnu.org - - - dolibarr-dev@nongnu.org - dolibarr-dev@nongnu.org - dolibarr-dev@nongnu.org - - - - - - - + + + PADGen 3.1.1.47 + + Dolibarr team + 11 rue raymond Queneau + + Rueil Malmaison + + 92500 + FRANCE + http://www.dolibarr.org + + Dolibarr team + Dolibarr team + dolibarr-dev@nongnu.org + Dolibarr team + Dolibarr team + dolibarr-dev@nongnu.org + + + dolibarr-dev@nongnu.org + dolibarr-dev@nongnu.org + dolibarr-dev@nongnu.org + + + + + + + diff --git a/build/pad/Dolibarr.pml b/build/pad/Dolibarr.pml index 58e00f77c9d..2e342d34a0a 100644 --- a/build/pad/Dolibarr.pml +++ b/build/pad/Dolibarr.pml @@ -4,9 +4,9 @@ Dolibarr - 3.0.0 - 01 - 16 + 3.1..0 + 07 + 09 2011 @@ -38,28 +38,36 @@ dolibarr, erp, crm, invoices, commercial proposals, orders, accounting, stock, products, agenda, bank, business, company, foundation, management, sme, doliwamp - Dolibarr ERP/CRM - Dolibarr ERP/CRM, the easy to use open source software to manage your activity - Dolibarr ERP/CRM, the easy to use open source software to manage your activity (invoices, customers, suppliers, contracts, agenda, emailings...) and any other things a small or mid-sized business or a foundation needs to follow. - Dolibarr ERP/CRM is a software built by modules addition (you enable only features you need), to manage small or medium companies, freelancers or foundations. We can say Dolibarr is an ERP or CRM. Dolibarr is also available with an auto-installer for Windows users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. See DoliWamp software for this. - Dolibarr ERP/CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations. We can say Dolibarr is an ERP or CRM (or both depending on activated modules). - - - -It's an OpenSource project base on a WAMP, MAMP or LAMP server (Apache, Mysql, PHP for all Operating Systems). Dolibarr differs from other ERP or CRM softwares (like OpenAguila, OpenBravo, OpenERP, Neogia, Compiere, etc) because everything was made to be more simple: - - - - * Simple to install - - * Simple to use - - * Simple to develop - - - + Dolibarr ERP & CRM + Dolibarr ERP & CRM, the easy to use open source software to manage your activity + Dolibarr ERP & CRM, the easy to use open source software to manage your activity (invoices, customers, suppliers, contracts, agenda, emailings...) and any other things a small or mid-sized business or a foundation needs to follow. + Dolibarr ERP & CRM is a software built by modules addition (you enable only features you need), to manage small or medium companies, freelancers or foundations. We can say Dolibarr is an ERP or CRM. Dolibarr is also available with an auto-installer for Windows users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. See DoliWamp software for this. + Dolibarr ERP & CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations. We can say Dolibarr is an ERP or CRM (or both depending on activated modules). It's an OpenSource project base on a WAMP, MAMP or LAMP server (Apache, Mysql, PHP for all Operating Systems). Dolibarr differs from other ERP or CRM softwares (like OpenAguila, OpenBravo, OpenERP, Neogia, Compiere, etc) because everything was made to be more simple: +Simple to install +Simple to use +Simple to develop Note that Dolibarr is also available with an auto-installer for Windows or Ubuntu users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. This version is called DoliWamp (for Windows) or DoliBuntu (for Ubuntu/Debian). + + erp, crm, gestionale, medie imprese, fondazioni + Gestionale open source e gratuito + Gestionale open source e gratuito per piccole e medie imprese, fondazioni + Dolibarr è un a gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. + Dolibarr è un programma gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. Dolibar è progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. + Dolibarr è un programma gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. Dolibar è progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. Dolibar è completamente web-based, progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. + + + dolibarr, erp, crm, invoices, commercial proposals, orders, accounting, stock, products, agenda, bank, business, company, foundation, management, sme, doliwamp + Dolibarr ERP & CRM + Dolibarr ERP & CRM, le gestionnaire simple pour gérer votre activité + Dolibarr ERP & CRM, le logiciel simple et OpenSource pour gérer votre activité (factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations) + Dolibarr ERP/CRM est un logiciel modulaire (on n'active que les fonctions que l'on désire) de gestions de TPE/PME, d'indépendants, d'entrepreneurs ou d'associations. En terme plus techniques, c'est un ERP et CRM. C'est un projet OpenSource qui s'exécute au sein d'un serveur Web et peut donc être accessible depuis n'importe quel lieu disposant d'une connexion Internet (Projet basé sur un serveur WAMP, MAMP ou LAMP: Apache, MySQL, PHP). + Dolibarr ERP/CRM est un logiciel modulaire (on n'active que les fonctions que l'on désire) de gestions de TPE/PME, d'indépendants, d'entrepreneurs ou d'associations. En terme plus techniques, c'est un ERP et CRM. C'est un projet OpenSource qui s'exécute au sein d'un serveur Web et peut donc être accessible depuis n'importe quel lieu disposant d'une connexion Internet (Projet basé sur un serveur WAMP, MAMP ou LAMP: Apache, MySQL, PHP). Dolibarr vient compléter les offres déjà nombreuses de logiciels de cette catégorie (comme OpenBravo, OpenERP, SugarCRM, Neogia, Compiere, etc.) mais se démarque par le fait qu'ici tout est fait pour offrir de la simplicité (règle des 3 S): +Simple pour l'installation (avec au choix des installeurs clé en main pour ceux qui ignorent comment installer un serveur Web, ou une installation manuelle) +Simple pour l'utilisation (fonctions modulaires pour ne pas surcharger les menus, informations claires à la saisie) +Simple pour le développement (pas de frameworks lourds). +Dolibarr intègre en effet sa propre architecture (design patterns) permettant à tout développeur d'être tout de suite opérationnel sans connaissances particulières autre que le PHP. + @@ -80,11 +88,6 @@ Note that Dolibarr is also available with an auto-installer for Windows or Ubunt GNU GPL GNU GPL - - Y - N - - Y 1.4 @@ -191,4 +194,9 @@ Note that Dolibarr is also available with an auto-installer for Windows or Ubunt + + Y + N + + diff --git a/build/pad/pad_dolibarr.xml b/build/pad/pad_dolibarr.xml index 98b1367d97b..972de244b79 100644 --- a/build/pad/pad_dolibarr.xml +++ b/build/pad/pad_dolibarr.xml @@ -1,4 +1,4 @@ - + 3.11 @@ -7,11 +7,11 @@ Dolibarr team - 61 Boulevard Vauban + 11 rue raymond Queneau - Montigny-le-Bretonneux + Rueil Malmaison - 78180 + 92500 FRANCE http://www.dolibarr.org @@ -34,9 +34,9 @@ Dolibarr - 3.0.0 - 01 - 16 + 3.1..0 + 07 + 09 2011 @@ -68,44 +68,36 @@ dolibarr, erp, crm, invoices, commercial proposals, orders, accounting, stock, products, agenda, bank, business, company, foundation, management, sme, doliwamp - Dolibarr ERP/CRM - Dolibarr ERP/CRM, the easy to use open source software to manage your activity - Dolibarr ERP/CRM, the easy to use open source software to manage your activity (invoices, customers, suppliers, contracts, agenda, emailings...) and any other things a small or mid-sized business or a foundation needs to follow. - Dolibarr ERP/CRM is a software built by modules addition (you enable only features you need), to manage small or medium companies, freelancers or foundations. We can say Dolibarr is an ERP or CRM. Dolibarr is also available with an auto-installer for Windows users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. See DoliWamp software for this. - Dolibarr ERP/CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations. We can say Dolibarr is an ERP or CRM (or both depending on activated modules). - - - - - - - -It's an OpenSource project base on a WAMP, MAMP or LAMP server (Apache, Mysql, PHP for all Operating Systems). Dolibarr differs from other ERP or CRM softwares (like OpenAguila, OpenBravo, OpenERP, Neogia, Compiere, etc) because everything was made to be more simple: - - - - - - - - * Simple to install - - - - * Simple to use - - - - * Simple to develop - - - - - - - + Dolibarr ERP & CRM + Dolibarr ERP & CRM, the easy to use open source software to manage your activity + Dolibarr ERP & CRM, the easy to use open source software to manage your activity (invoices, customers, suppliers, contracts, agenda, emailings...) and any other things a small or mid-sized business or a foundation needs to follow. + Dolibarr ERP & CRM is a software built by modules addition (you enable only features you need), to manage small or medium companies, freelancers or foundations. We can say Dolibarr is an ERP or CRM. Dolibarr is also available with an auto-installer for Windows users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. See DoliWamp software for this. + Dolibarr ERP & CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations. We can say Dolibarr is an ERP or CRM (or both depending on activated modules). It's an OpenSource project base on a WAMP, MAMP or LAMP server (Apache, Mysql, PHP for all Operating Systems). Dolibarr differs from other ERP or CRM softwares (like OpenAguila, OpenBravo, OpenERP, Neogia, Compiere, etc) because everything was made to be more simple: +Simple to install +Simple to use +Simple to develop Note that Dolibarr is also available with an auto-installer for Windows or Ubuntu users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. This version is called DoliWamp (for Windows) or DoliBuntu (for Ubuntu/Debian). + + dolibarr, erp, crm, invoices, commercial proposals, orders, accounting, stock, products, agenda, bank, business, company, foundation, management, sme, doliwamp + Dolibarr ERP & CRM + Dolibarr ERP & CRM, le gestionnaire simple pour gérer votre activité + Dolibarr ERP & CRM, le logiciel simple et OpenSource pour gérer votre activité (factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations) + Dolibarr ERP/CRM est un logiciel modulaire (on n'active que les fonctions que l'on désire) de gestions de TPE/PME, d'indépendants, d'entrepreneurs ou d'associations. En terme plus techniques, c'est un ERP et CRM. C'est un projet OpenSource qui s'exécute au sein d'un serveur Web et peut donc être accessible depuis n'importe quel lieu disposant d'une connexion Internet (Projet basé sur un serveur WAMP, MAMP ou LAMP: Apache, MySQL, PHP). + Dolibarr ERP/CRM est un logiciel modulaire (on n'active que les fonctions que l'on désire) de gestions de TPE/PME, d'indépendants, d'entrepreneurs ou d'associations. En terme plus techniques, c'est un ERP et CRM. C'est un projet OpenSource qui s'exécute au sein d'un serveur Web et peut donc être accessible depuis n'importe quel lieu disposant d'une connexion Internet (Projet basé sur un serveur WAMP, MAMP ou LAMP: Apache, MySQL, PHP). Dolibarr vient compléter les offres déjà nombreuses de logiciels de cette catégorie (comme OpenBravo, OpenERP, SugarCRM, Neogia, Compiere, etc.) mais se démarque par le fait qu'ici tout est fait pour offrir de la simplicité (règle des 3 S): +Simple pour l'installation (avec au choix des installeurs clé en main pour ceux qui ignorent comment installer un serveur Web, ou une installation manuelle) +Simple pour l'utilisation (fonctions modulaires pour ne pas surcharger les menus, informations claires à la saisie) +Simple pour le développement (pas de frameworks lourds). +Dolibarr intègre en effet sa propre architecture (design patterns) permettant à tout développeur d'être tout de suite opérationnel sans connaissances particulières autre que le PHP. + + + erp, crm, gestionale, medie imprese, fondazioni + Gestionale open source e gratuito + Gestionale open source e gratuito per piccole e medie imprese, fondazioni + Dolibarr è un a gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. + Dolibarr è un programma gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. Dolibar è progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. + Dolibarr è un programma gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. Dolibar è progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. Dolibar è completamente web-based, progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. + @@ -126,11 +118,6 @@ Note that Dolibarr is also available with an auto-installer for Windows or Ubunt GNU GPL GNU GPL - - Y - N - - Y 1.4 @@ -237,4 +224,9 @@ Note that Dolibarr is also available with an auto-installer for Windows or Ubunt + + Y + N + + diff --git a/build/pad/pad_doliwamp.xml b/build/pad/pad_doliwamp.xml index bfa0c1b79f6..6e860da929b 100644 --- a/build/pad/pad_doliwamp.xml +++ b/build/pad/pad_doliwamp.xml @@ -1,4 +1,4 @@ - + 3.11 @@ -34,9 +34,9 @@ DoliWamp - 3.0.0 - 01 - 16 + 3.1.0 + 07 + 09 2011 @@ -44,7 +44,7 @@ Freeware Major Update Install and Uninstall - Win2000,Win7 x32,Win7 x64,Win98,WinOther,WinServer,WinVista,WinVista x64,WinXP + Win2000,Win7 x32,Win7 x64,Win98,WinOther,WinServer,WinVista,WinVista x64,WinXP,Other English,Arabic,Catalan,Chinese,Dutch,Finnish,French,German,Icelandic,Italian,Norwegian,Polish,Portuguese,Romanian,Russian,Slovenian,Spanish,Swedish,Turkish http://www.dolibarr.org Business @@ -72,16 +72,25 @@ DoliWamp, the easy to use Dolibarr for Windows to manage your company,foundation DoliWamp is the Dolibarr ERP/CRM for Windows, the easy to use open source software to manage your activity (invoices, customers, suppliers, contracts, agenda, emailings...) and any other things a small or mid-sized business or a foundation needs. DoliWamp is the Dolibarr ERP/CRM autoinstaller for Windows users with no technical knowledge to install Dolibarr and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. Dolibarr ERP/CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations. - DoliWamp is the Dolibarr ERP/CRM for Windows. - -Dolibarr ERP & CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations (You can manage or follow contacts, invoices, orders, commercial proposals, products, stock management, agenda, mass emailings, members of a foundation, bank accounts...). - -It's an OpenSource project, based on a WAMP, MAMP or LAMP server (Apache, Mysql, PHP for all Operating Systems). Dolibarr differs from other ERP or CRM softwares (like OpenAguila, OpenBravo, OpenERP, Neogia, Compiere, etc) because everything was made to be more simple: Simple to install, Simple to use, Simple to develop. - -DoliWamp is the auto-installer for Windows users with no technical knowledge to install Dolibarr ERP/CRM and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. - - + DoliWamp is the Dolibarr ERP/CRM for Windows. Dolibarr ERP & CRM is a software built by modules addition (you enable only features you need), to manage small or mid-sized businesses, freelancers or foundations (You can manage or follow contacts, invoices, orders, commercial proposals, products, stock management, agenda, mass emailings, members of a foundation, bank accounts...). Based on a WAMP, MAMP or LAMP server (Apache, Mysql, PHP for all Operating Systems), you can install it as a standalone program or use it from anywhere with any web browser. Dolibarr is an OpenSource project. It differs from other ERP or CRM softwares (like OpenAguila, OpenBravo, OpenERP, Neogia, Compiere, etc) because everything was made to be more simple: Simple to install, Simple to use, Simple to develop. +DoliWamp is the auto-installer for Windows users with no technical knowledge to install Dolibarr ERP/CRM and all its prerequisites (Apache, Mysql, PHP) with just one auto-exe file. + + doliwamp, dolibarr, erp, crm, factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations, entreprises, PME, TPE + DoliWamp, Dolibarr ERP/CRM pour Windows + DoliWamp, la distribution de Dolibarr pour gérer votre entreprise ou association + DoliWamp est la version spécialisée pour Windows de Dolibarr ERP-CRM, le logiciel simple et OpenSource pour gérer votre activité (factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations) + DoliWamp est la version spécialisée pour Windows de Dolibarr ERP-CRM, le logiciel simple et OpenSource pour gérer votre activité (factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations) + DoliWamp est la version spécialisée pour Windows de Dolibarr ERP-CRM, le logiciel simple et OpenSource pour gérer votre activité (factures, devis, facturation, commandes, compta, trésorerie, stocks, produits, agenda, comptes bancaires, associations) + + + doliwamp, dolibarr, erp, crm, gestionale, medie imprese, fondazioni + DoliWamp, Dolibarr ERP/CRM per Windows + Gestionale open source e gratuito per piccole e medie imprese, fondazioni + Dolibarr è un a gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. + Dolibarr è un programma gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. Dolibar è progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. + Dolibarr è un programma gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti. Include varie funzionalità per Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori attività. Dolibar è progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. Dolibar è completamente web-based, progettato per poter fornire solo ciò di cui hai bisogno ed essere facile da usare. + @@ -102,11 +111,6 @@ DoliWamp is the auto-installer for Windows users with no technical knowledge to GNU GPL GNU GPL - - Y - N - - Y 1.4 @@ -213,4 +217,9 @@ DoliWamp is the auto-installer for Windows users with no technical knowledge to + + Y + N + + From b77252a7624aa9eb3377eea99f888175835e0793 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 22:26:53 +0000 Subject: [PATCH 17/49] Work on packaging RPM & DEB --- build/deb/control | 2 ++ 1 file changed, 2 insertions(+) diff --git a/build/deb/control b/build/deb/control index 3d8878f4569..2d356fc7b2b 100644 --- a/build/deb/control +++ b/build/deb/control @@ -14,6 +14,8 @@ Description: Easy to use ERP & CRM software to manage your activity. and medium companies, foundations or freelances. It includes different features for Enterprise Resource Planning (ERP) and Customer Relationship Management (CRM) but also for different other activities. + It's a web software you can install as a standalone program or on any web + hosting provider to use it from anywhere with any web browser. Dolibarr was designed to provide only features you need and be easy to use. . Only features you need are visible, depending on which module were activated. From 09d191390b0013a46bd9d48c76c5973b584ec936 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 9 Jul 2011 22:33:27 +0000 Subject: [PATCH 18/49] Work on packaging RPM & DEB --- build/rpm/dolibarr.desktop | 5 ++++- build/rpm/dolibarr.spec | 22 ++++++++++++++++++++++ 2 files changed, 26 insertions(+), 1 deletion(-) diff --git a/build/rpm/dolibarr.desktop b/build/rpm/dolibarr.desktop index e3be821080c..ab2a758867f 100755 --- a/build/rpm/dolibarr.desktop +++ b/build/rpm/dolibarr.desktop @@ -5,9 +5,12 @@ Version=1.0 Encoding=UTF-8 Name=Dolibarr ERP & CRM Name[fr]=Dolibarr ERP & CRM +Name[it]=Dolibarr ERP & CRM GenericName=Dolibarr ERP & CRM Comment=The easy to use manager (ERP & CRM) for small and medium enterprises or foundations -Comment[fr]=L'ERP & CRM simple pour la gestion des PME et associations +Comment[fr]=L'ERP & CRM simple pour la gestion des TPE, PME, associations et auto-entrepreneurs +Comment[it]=Programma gestionale open source e gratuito per piccole e medie imprese, fondazioni e liberi professionisti +Comment[es]=Software para gestión de PYMES, profesionales independientes, auto emprendedores ó asociaciones # Command to open an URL # For Fedora: xdg-open # For Debian/Ubuntu: x-www-browser diff --git a/build/rpm/dolibarr.spec b/build/rpm/dolibarr.spec index b1def13ae37..4bfbcfaae65 100644 --- a/build/rpm/dolibarr.spec +++ b/build/rpm/dolibarr.spec @@ -43,12 +43,34 @@ Management (CRM) but also for different other activities. Dolibarr was designed to provide only features you need and be easy to use. +%description -l es +Dolibarr ERP/CRM es un software completamente modular (sólo activaremos las funciones +que deseemos) para gestión de PYMES, profesionales independientes, auto emprendedores +ó asociaciones. En términos más técnicos, es un ERP y CRM. Es un proyecto OpenSource +que se ejecuta en el seno de un servidor Web, siendo pues accesible desde cualquier +lugar disponiendo de una conexión a Internet. +Dolibarr viene a completar la oferta de numerosas aplicaciones de esta categoría, +pero desmarcándose por el hecho de que se hace todo lo posible para proporcionar simplicidad: +Simple de instalar (con instaladores para los que ignoran como instalar un servidor Web). +Simple de usar (funciones modulares para no sobrecargar los menús, informaciones claras y concisas). +Simple de desarrollar (sin frameworks pesados). + %description -l fr Dolibarr ERP & CRM est un logiciel de gestion de PME/PMI, autoentrepreneurs, artisans ou associations. Il permet de gérer vos clients, prospect, fournisseurs, devis, factures, comptes bancaires, agenda, campagne emailings et bien d'autres choses dans une interface pensée pour la simplicité. +%description -l it +Dolibarr è un programma gestionale open source e gratuito per piccole e medie +imprese, fondazioni e liberi professionisti. Include varie funzionalità per +Enterprise Resource Planning e gestione dei clienti (CRM), ma anche ulteriori +attività. Dolibar è progettato per poter fornire solo ciò di cui hai bisogno +ed essere facile da usare. +Dolibar è completamente web-based, progettato per poter fornire solo ciò di +cui hai bisogno ed essere facile da usare. + + #---- prep %prep From 1e6d6fd524d3ef7cb39a196c0be78ad5b621b4f9 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 10 Jul 2011 13:33:53 +0000 Subject: [PATCH 19/49] Use global option if local not defined --- htdocs/comm/mailing/fiche.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/comm/mailing/fiche.php b/htdocs/comm/mailing/fiche.php index 687a5e9053d..994d9d97303 100644 --- a/htdocs/comm/mailing/fiche.php +++ b/htdocs/comm/mailing/fiche.php @@ -21,7 +21,7 @@ * \file htdocs/comm/mailing/fiche.php * \ingroup mailing * \brief Fiche mailing, onglet general - * \version $Id: fiche.php,v 1.121 2011/07/02 16:48:32 eldy Exp $ + * \version $Id: fiche.php,v 1.122 2011/07/10 13:33:53 eldy Exp $ */ require("../../main.inc.php"); @@ -617,7 +617,7 @@ if ($_GET["action"] == 'create') print ''; print ''; print ''; - print ''; + print ''; print '
'.$langs->trans("MailTitle").'
'.$langs->trans("MailFrom").'
'.$langs->trans("MailErrorsTo").'
'.$langs->trans("MailErrorsTo").'
'; print '

'; @@ -1073,5 +1073,5 @@ else $db->close(); -llxFooter('$Date: 2011/07/02 16:48:32 $ - $Revision: 1.121 $'); +llxFooter('$Date: 2011/07/10 13:33:53 $ - $Revision: 1.122 $'); ?> From b7a2aaa0264af97e4ea6ba63b5b3bd437b181bd5 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 10 Jul 2011 13:39:34 +0000 Subject: [PATCH 20/49] Add comment --- htdocs/core/tpl/ajaxfileupload.tpl.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/htdocs/core/tpl/ajaxfileupload.tpl.php b/htdocs/core/tpl/ajaxfileupload.tpl.php index c55f6d319bd..42ece24a3b8 100644 --- a/htdocs/core/tpl/ajaxfileupload.tpl.php +++ b/htdocs/core/tpl/ajaxfileupload.tpl.php @@ -15,11 +15,12 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * - * $Id: ajaxfileupload.tpl.php,v 1.9 2011/07/08 14:00:08 hregis Exp $ + * $Id: ajaxfileupload.tpl.php,v 1.10 2011/07/10 13:39:34 eldy Exp $ */ ?> + '."\n"; if (sizeof($listofpaths)) { foreach($listofpaths as $key => $val) { $out.= '
'; $out.= img_mime($listofnames[$key]).' '.$listofnames[$key]; - if (! $this->withfilereadonly) $out.= ' '; + if (! $this->withfilereadonly) + { + $out.= ' '; + //$out.= ' '.img_delete($langs->trans("Delete").''; + } $out.= '
'; } } @@ -522,11 +534,9 @@ class FormMail } if ($this->withfile == 2) // Can add other files { - //print ''; $out.= ''; $out.= ' '; $out.= ''; - //print ''; } $out.= "\n"; } @@ -546,7 +556,7 @@ class FormMail if ($this->param["models"]=='invoice_supplier_send') { $defaultmessage=$langs->transnoentities("PredefinedMailContentSendSupplierInvoice"); } if ($this->param["models"]=='shipping_send') { $defaultmessage=$langs->transnoentities("PredefinedMailContentSendShipping"); } if ($this->param["models"]=='fichinter_send') { $defaultmessage=$langs->transnoentities("PredefinedMailContentSendFichInter"); } - + if ($conf->paypal->enabled && $conf->global->PAYPAL_ADD_PAYMENT_URL) { require_once(DOL_DOCUMENT_ROOT."/paypal/lib/paypal.lib.php"); diff --git a/htdocs/expedition/fiche.php b/htdocs/expedition/fiche.php index 4eda7ddacb4..c4e2f0c25ff 100644 --- a/htdocs/expedition/fiche.php +++ b/htdocs/expedition/fiche.php @@ -25,7 +25,7 @@ * \file htdocs/expedition/fiche.php * \ingroup expedition * \brief Fiche descriptive d'une expedition - * \version $Id: fiche.php,v 1.209 2011/07/07 21:32:19 eldy Exp $ + * \version $Id: fiche.php,v 1.210 2011/07/10 20:03:39 eldy Exp $ */ require("../main.inc.php"); @@ -291,9 +291,9 @@ if ($_POST['addfile']) // Set tmp user directory TODO Use a dedicated directory for temp mails files $vardir=$conf->user->dir_output."/".$user->id; - $upload_dir = $vardir.'/temp/'; + $upload_dir_tmp = $vardir.'/temp'; - $mesg=dol_add_file_process($upload_dir,0,0); + $mesg=dol_add_file_process($upload_dir_tmp,0,0); $action ='presend'; } @@ -307,7 +307,7 @@ if (! empty($_POST['removedfile'])) // Set tmp user directory $vardir=$conf->user->dir_output."/".$user->id; - $upload_dir = $vardir.'/temp/'; + $upload_dir_tmp = $vardir.'/temp'; $mesg=dol_remove_file_process($_POST['removedfile'],0); @@ -1381,5 +1381,5 @@ else $db->close(); -llxFooter('$Date: 2011/07/07 21:32:19 $ - $Revision: 1.209 $'); +llxFooter('$Date: 2011/07/10 20:03:39 $ - $Revision: 1.210 $'); ?> diff --git a/htdocs/fichinter/fiche.php b/htdocs/fichinter/fiche.php index 0442cdb6125..26399ef51fe 100644 --- a/htdocs/fichinter/fiche.php +++ b/htdocs/fichinter/fiche.php @@ -23,7 +23,7 @@ * \file htdocs/fichinter/fiche.php * \brief Fichier fiche intervention * \ingroup ficheinter - * \version $Id: fiche.php,v 1.170 2011/07/07 22:02:48 eldy Exp $ + * \version $Id: fiche.php,v 1.171 2011/07/10 20:03:39 eldy Exp $ */ require("../main.inc.php"); @@ -444,6 +444,39 @@ if ($action == 'down' && $user->rights->ficheinter->creer) exit; } + +/* + * Add file in email form + */ +if ($_POST['addfile']) +{ + require_once(DOL_DOCUMENT_ROOT."/lib/files.lib.php"); + + // Set tmp user directory TODO Use a dedicated directory for temp mails files + $vardir=$conf->user->dir_output."/".$user->id; + $upload_dir_tmp = $vardir.'/temp'; + + $mesg=dol_add_file_process($upload_dir_tmp,0,0); + + $action='presend'; +} + +/* + * Remove file in email form + */ +if (! empty($_POST['removedfile'])) +{ + require_once(DOL_DOCUMENT_ROOT."/lib/files.lib.php"); + + // Set tmp user directory + $vardir=$conf->user->dir_output."/".$user->id; + $upload_dir_tmp = $vardir.'/temp'; + + $mesg=dol_remove_file_process($_POST['removedfile'],0); + + $action='presend'; +} + /* * Send mail */ @@ -1148,7 +1181,7 @@ elseif ($fichinterid) $formmail = new FormMail($db); $formmail->fromtype = 'user'; $formmail->fromid = $user->id; - $formmail->fromname = $user->fullname; + $formmail->fromname = $user->getFullName($langs); $formmail->frommail = $user->email; $formmail->withfrom=1; $formmail->withto=empty($_POST["sendto"])?1:$_POST["sendto"]; @@ -1158,7 +1191,7 @@ elseif ($fichinterid) $formmail->withtoccc=$conf->global->MAIN_EMAIL_USECCC; $formmail->withtocccsocid=0; $formmail->withtopic=$langs->trans('SendInterventionRef','__FICHINTERREF__'); - $formmail->withfile=1; + $formmail->withfile=2; $formmail->withbody=1; $formmail->withdeliveryreceipt=1; $formmail->withcancel=1; @@ -1186,5 +1219,5 @@ elseif ($fichinterid) $db->close(); -llxFooter('$Date: 2011/07/07 22:02:48 $ - $Revision: 1.170 $'); +llxFooter('$Date: 2011/07/10 20:03:39 $ - $Revision: 1.171 $'); ?> diff --git a/htdocs/fourn/commande/fiche.php b/htdocs/fourn/commande/fiche.php index e634bbb50b1..b977bfe42a1 100644 --- a/htdocs/fourn/commande/fiche.php +++ b/htdocs/fourn/commande/fiche.php @@ -25,7 +25,7 @@ * \file htdocs/fourn/commande/fiche.php * \ingroup supplier, order * \brief Card supplier order - * \version $Id: fiche.php,v 1.231 2011/07/07 21:32:21 eldy Exp $ + * \version $Id: fiche.php,v 1.232 2011/07/10 20:03:40 eldy Exp $ */ require("../../main.inc.php"); @@ -578,9 +578,9 @@ if ($_POST['addfile']) // Set tmp user directory TODO Use a dedicated directory for temp mails files $vardir=$conf->user->dir_output."/".$user->id; - $upload_dir = $vardir.'/temp/'; + $upload_dir_tmp = $vardir.'/temp'; - $mesg=dol_add_file_process($upload_dir,0,0); + $mesg=dol_add_file_process($upload_dir_tmp,0,0); $action='presend'; } @@ -594,7 +594,7 @@ if (! empty($_POST['removedfile'])) // Set tmp user directory $vardir=$conf->user->dir_output."/".$user->id; - $upload_dir = $vardir.'/temp/'; + $upload_dir_tmp = $vardir.'/temp'; $mesg=dol_remove_file_process($_POST['removedfile'],0); @@ -1545,5 +1545,5 @@ if ($id > 0 || ! empty($ref)) $db->close(); -llxFooter('$Date: 2011/07/07 21:32:21 $ - $Revision: 1.231 $'); +llxFooter('$Date: 2011/07/10 20:03:40 $ - $Revision: 1.232 $'); ?> diff --git a/htdocs/fourn/facture/fiche.php b/htdocs/fourn/facture/fiche.php index 027f32a4c98..e2821a326ab 100644 --- a/htdocs/fourn/facture/fiche.php +++ b/htdocs/fourn/facture/fiche.php @@ -25,7 +25,7 @@ * \file htdocs/fourn/facture/fiche.php * \ingroup facture, fournisseur * \brief Page for supplier invoice card (view, edit, validate) - * \version $Id: fiche.php,v 1.260 2011/07/07 21:32:19 eldy Exp $ + * \version $Id: fiche.php,v 1.261 2011/07/10 20:03:39 eldy Exp $ */ require("../../main.inc.php"); @@ -629,9 +629,9 @@ if ($_POST['addfile']) // Set tmp user directory TODO Use a dedicated directory for temp mails files $vardir=$conf->user->dir_output."/".$user->id; - $upload_dir = $vardir.'/temp/'; + $upload_dir_tmp = $vardir.'/temp'; - $mesg=dol_add_file_process($upload_dir,0,0); + $mesg=dol_add_file_process($upload_dir_tmp,0,0); $_GET["action"]='presend'; $_POST["action"]='presend'; @@ -646,7 +646,7 @@ if (! empty($_POST['removedfile'])) // Set tmp user directory $vardir=$conf->user->dir_output."/".$user->id; - $upload_dir = $vardir.'/temp/'; + $upload_dir_tmp = $vardir.'/temp'; $mesg=dol_remove_file_process($_POST['removedfile'],0); @@ -1916,5 +1916,5 @@ else $db->close(); -llxFooter('$Date: 2011/07/07 21:32:19 $ - $Revision: 1.260 $'); +llxFooter('$Date: 2011/07/10 20:03:39 $ - $Revision: 1.261 $'); ?> diff --git a/htdocs/langs/fr_FR/other.lang b/htdocs/langs/fr_FR/other.lang index 26a04f20d51..53195d78899 100644 --- a/htdocs/langs/fr_FR/other.lang +++ b/htdocs/langs/fr_FR/other.lang @@ -53,7 +53,7 @@ PredefinedMailContentSendOrder=Veuillez trouver ci-joint la commande __ORDERREF_ PredefinedMailContentSendSupplierOrder=Veuillez trouver ci-joint notre commande __ORDERREF__\n\nCordialement\n\n PredefinedMailContentSendSupplierInvoice=Veuillez trouver ci-joint la facture __FACREF__\n\nCordialement\n\n PredefinedMailContentSendShipping=Veuillez trouver ci-joint le bon d'expédition __SHIPPINGREF__\n\nCordialement\n\n -PredefinedMailContentSendFichInter=Veuillez trouver ci-joint le intervention __FICHINTERREF__\n\nCordialement\n\n +PredefinedMailContentSendFichInter=Veuillez trouver ci-joint la fiche d'intervention __FICHINTERREF__\n\nCordialement\n\n DemoDesc=Dolibarr est un logiciel de gestion d'activité (professionnelle ou associative) composé de modules fonctionnels indépendants et optionnels. Une démonstration qui inclut tous ces modules n'a pas de sens car les modules ne sont jamais tous utilisés en même temps. Aussi, plusieurs profils type de démo sont disponibles. ChooseYourDemoProfil=Veuillez choisir le profil de démo qui correspond le mieux à votre activité... DemoFundation=Gestion des adhérents d'une association diff --git a/htdocs/lib/files.lib.php b/htdocs/lib/files.lib.php index d14de3b804d..8b6ea639ec8 100644 --- a/htdocs/lib/files.lib.php +++ b/htdocs/lib/files.lib.php @@ -20,7 +20,7 @@ /** * \file htdocs/lib/files.lib.php * \brief Library for file managing functions - * \version $Id: files.lib.php,v 1.66 2011/07/06 16:56:01 eldy Exp $ + * \version $Id: files.lib.php,v 1.67 2011/07/10 20:03:41 eldy Exp $ */ /** @@ -709,7 +709,7 @@ function dol_add_file_process($upload_dir,$allowoverwrite=0,$donotupdatesession= if (! empty($_FILES['addedfile']['tmp_name'])) { - if (create_exdir($upload_dir) >= 0) + if (dol_mkdir($upload_dir) >= 0) { $resupload = dol_move_uploaded_file($_FILES['addedfile']['tmp_name'], $upload_dir . "/" . $_FILES['addedfile']['name'],$allowoverwrite,0, $_FILES['addedfile']['error']); if (is_numeric($resupload) && $resupload > 0) @@ -755,10 +755,11 @@ function dol_add_file_process($upload_dir,$allowoverwrite=0,$donotupdatesession= * Remove an uploaded file (for example after submitting a new file a mail form). * All information used are in db, conf, langs, user and _FILES. * @param filenb File nb to delete - * @param donotupdatesession 1=Do no edit _SESSION variable + * @param donotupdatesession 1=Do not edit _SESSION variable + * @param donotdeletefile 1=Do not delete physically file * @return string Message with result of upload and store. */ -function dol_remove_file_process($filenb,$donotupdatesession=0) +function dol_remove_file_process($filenb,$donotupdatesession=0,$donotdeletefile=0) { global $db,$user,$conf,$langs,$_FILES; @@ -778,14 +779,16 @@ function dol_remove_file_process($filenb,$donotupdatesession=0) { $pathtodelete=$listofpaths[$keytodelete]; $filetodelete=$listofnames[$keytodelete]; - $result = dol_delete_file($pathtodelete,1); + if (empty($donotdeletefile)) $result = dol_delete_file($pathtodelete,1); + else $result=0; if ($result >= 0) { - $langs->load("other"); - - $mesg = '
'.$langs->trans("FileWasRemoved",$filetodelete).'
'; - //print_r($_FILES); - + if (empty($donotdeletefile)) + { + $langs->load("other"); + $mesg = '
'.$langs->trans("FileWasRemoved",$filetodelete).'
'; + //print_r($_FILES); + } if (empty($donotupdatesession)) { include_once(DOL_DOCUMENT_ROOT.'/core/class/html.formmail.class.php'); From 23fcb58f934f181c038d17aad9609bd7c7eab85d Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 10 Jul 2011 21:17:14 +0000 Subject: [PATCH 26/49] Fix: Missing name on form --- htdocs/core/class/html.formfile.class.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/htdocs/core/class/html.formfile.class.php b/htdocs/core/class/html.formfile.class.php index e6ac2d294b9..5d928870560 100644 --- a/htdocs/core/class/html.formfile.class.php +++ b/htdocs/core/class/html.formfile.class.php @@ -22,7 +22,7 @@ * \file htdocs/core/class/html.formfile.class.php * \ingroup core * \brief File of class to offer components to list and upload files - * \version $Id: html.formfile.class.php,v 1.46 2011/07/06 21:12:34 eldy Exp $ + * \version $Id: html.formfile.class.php,v 1.47 2011/07/10 21:17:14 eldy Exp $ */ @@ -185,6 +185,7 @@ class FormFile global $langs,$bc,$conf; + $forname='builddoc'; $out=''; $var=true; @@ -386,7 +387,7 @@ class FormFile $buttonlabeltoshow=$buttonlabel; if (empty($buttonlabel)) $buttonlabel=$langs->trans('Generate'); - if (empty($noform)) $out.= '
'; + if (empty($noform)) $out.= ''; $out.= ''; $out.= ''; @@ -436,8 +437,7 @@ class FormFile // Button $out.= ''; - $out.= ' Date: Sun, 10 Jul 2011 22:45:44 +0000 Subject: [PATCH 27/49] Work on packaging RPM & DEB --- build/rpm/README | 12 +++++-- build/rpm/dolibarr.spec | 70 +++++++++++++++++++++++++++++------------ 2 files changed, 60 insertions(+), 22 deletions(-) diff --git a/build/rpm/README b/build/rpm/README index 1b2d4745dc4..f2077ceac36 100644 --- a/build/rpm/README +++ b/build/rpm/README @@ -10,6 +10,14 @@ with format RPM (for Redhat, Mandriva, ...). # This is standard command to work on Debian packaging: # -# yum install dolibarr To remove package -# yum erase dolibarr To remove package +# On Fedora +# yum install dolibarr-...rpm To install package and dependencies +# yum erase dolibarr To remove package # +# On OpenSuse +# yast --install dolibarr-...rpm To install package and dependencies +# yast --remove dolibarr To remove package +# +# On Mageia +# urpmi dolibarr-...rpm To install package and dependencies +# urpme dolibarr To remove package \ No newline at end of file diff --git a/build/rpm/dolibarr.spec b/build/rpm/dolibarr.spec index 4bfbcfaae65..a9003afcac3 100644 --- a/build/rpm/dolibarr.spec +++ b/build/rpm/dolibarr.spec @@ -44,16 +44,13 @@ Dolibarr was designed to provide only features you need and be easy to use. %description -l es -Dolibarr ERP/CRM es un software completamente modular (sólo activaremos las funciones -que deseemos) para gestión de PYMES, profesionales independientes, auto emprendedores -ó asociaciones. En términos más técnicos, es un ERP y CRM. Es un proyecto OpenSource -que se ejecuta en el seno de un servidor Web, siendo pues accesible desde cualquier -lugar disponiendo de una conexión a Internet. -Dolibarr viene a completar la oferta de numerosas aplicaciones de esta categoría, -pero desmarcándose por el hecho de que se hace todo lo posible para proporcionar simplicidad: -Simple de instalar (con instaladores para los que ignoran como instalar un servidor Web). -Simple de usar (funciones modulares para no sobrecargar los menús, informaciones claras y concisas). -Simple de desarrollar (sin frameworks pesados). +Dolibarr ERP y CRM es un software open source/gratis para pequeñas y +medianas empresas, asociaciones o autónomos. Incluye diferentes +funcionalidades para la Planificación de Recursos Empresariales (ERP) y +Gestión de la Relación con los Clientes (CRM) así como para para otras +diferentes actividades. Dolibarr ha sido diseñado para suministrarle +solamente las funcionalidades que necesita y haciendo hincapié en su +facilidad de uso. %description -l fr Dolibarr ERP & CRM est un logiciel de gestion de PME/PMI, autoentrepreneurs, @@ -182,19 +179,35 @@ if [ ! -f %{_sysconfdir}/dolibarr/apache.conf ]; then chmod go-w %{_sysconfdir}/dolibarr/apache.conf fi -# Create a config link %{_sysconfdir}/httpd/conf.d/dolibarr.conf -if [ ! -f %{_sysconfdir}/httpd/conf.d/dolibarr.conf ]; then - echo Create dolibarr web server config link %{_sysconfdir}/httpd/conf.d/dolibarr.conf - ln -fs /etc/dolibarr/apache.conf %{_sysconfdir}/httpd/conf.d/dolibarr.conf + +# Detect OS +os='fedora'; +if [ -d %{_sysconfdir}/httpd/conf.d ]; then + export os='fedora'; + export conffile="%{_sysconfdir}/httpd/conf.d/dolibarr.conf" + apacheuser='apache'; + apachegroup='apache'; +fi +if [ -d %{_sysconfdir}/apache2/conf.d ]; then + export os='opensuse'; + export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" + apacheuser='wwwrun'; + apachegroup='wwwrun'; +fi + +# Create a config link dolibarr.conf for Fedora or Redhat +if [ ! -f $conffile ]; then + echo Create dolibarr web server config link $conffile + ln -fs /etc/dolibarr/apache.conf $conffile fi # Set permissions -echo Set permission on $targetdir -chown -R apache.apache $targetdir +echo Set permission to $apacheuser:$apachegroup on $targetdir +chown -R $apacheuser:$apachegroup $targetdir chmod -R a-w $targetdir -echo Set permission on $docdir -chown -R apache.apache $docdir +echo Set permission to $apacheuser:$apachegroup on $docdir +chown -R $apacheuser:$apachegroup $docdir chmod -R o-w $docdir # Create empty conf.php file for web installer @@ -205,7 +218,7 @@ if [ ! -s $targetdir/htdocs/conf/conf.php ]; then chmod ug+rw $targetdir/htdocs/conf/conf.php fi -if [ -s /usr/bin/chcon ]; then +if [ "x$os" = "xfedora" -a -s /usr/bin/chcon ]; then echo Set SELinux permissions # Warning: chcon seems not cumulative #chcon -R -h -t httpd_sys_content_t $targetdir @@ -220,6 +233,9 @@ echo Restart web server if [ -f %{_sysconfdir}/init.d/httpd ]; then %{_sysconfdir}/init.d/httpd restart fi +if [ -f %{_sysconfdir}/init.d/apache2 ]; then + %{_sysconfdir}/init.d/apache2 restart +fi # Show result echo @@ -236,12 +252,23 @@ echo %postun %clean_menus +# Detect OS +os='fedora'; +if [ -d %{_sysconfdir}/httpd/conf.d ]; then + export os='fedora'; + export conffile="%{_sysconfdir}/httpd/conf.d/dolibarr.conf" +fi +if [ -d %{_sysconfdir}/apache2/conf.d ]; then + export os='opensuse'; + export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" +fi + + # Dolibarr files are stored into /var/www export targetdir='/var/www/dolibarr' # Dolibarr uploaded files and generated documents are stored into /usr/share/dolibarr/documents export docdir='/usr/share/dolibarr/documents' -export conffile="%{_sysconfdir}/httpd/conf.d/dolibarr.conf" if [ -f $conffile ] ; then echo Delete apache config file for Dolibarr @@ -256,6 +283,9 @@ then if [ -f %{_sysconfdir}/init.d/httpd ]; then %{_sysconfdir}/init.d/httpd restart fi + if [ -f %{_sysconfdir}/init.d/apache2 ]; then + %{_sysconfdir}/init.d/apache2 restart + fi fi rm -rf /etc/dolibarr From 3e15db7e68ed9d821889fbf6898c96e1fbdfb616 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Mon, 11 Jul 2011 06:23:22 +0000 Subject: [PATCH 28/49] Fix: need complete object --- htdocs/lib/files.lib.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/htdocs/lib/files.lib.php b/htdocs/lib/files.lib.php index 8b6ea639ec8..3dbbef2c6b2 100644 --- a/htdocs/lib/files.lib.php +++ b/htdocs/lib/files.lib.php @@ -20,7 +20,7 @@ /** * \file htdocs/lib/files.lib.php * \brief Library for file managing functions - * \version $Id: files.lib.php,v 1.67 2011/07/10 20:03:41 eldy Exp $ + * \version $Id: files.lib.php,v 1.68 2011/07/11 06:23:22 hregis Exp $ */ /** @@ -561,9 +561,8 @@ function dol_move_uploaded_file($src_file, $dest_file, $allowoverwrite, $disable if (! empty($conf->global->MAIN_UMASK)) @chmod($file_name_osencoded, octdec($conf->global->MAIN_UMASK)); dol_syslog("Functions.lib::dol_move_uploaded_file Success to move ".$src_file." to ".$file_name." - Umask=".$conf->global->MAIN_UMASK, LOG_DEBUG); - if (! $notrigger) + if (! $notrigger && is_object($object)) { - if (! is_object($object)) $object=(object) 'dummy'; $object->src_file=$dest_file; // Appel des triggers From dc8757669ad3d5a76dbba4a8ba6340e34c1d0a12 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 11 Jul 2011 07:50:22 +0000 Subject: [PATCH 29/49] RPM works alos on ubuntu and debian --- build/rpm/dolibarr.spec | 57 +++++++++++++++++++++++------------------ 1 file changed, 32 insertions(+), 25 deletions(-) diff --git a/build/rpm/dolibarr.spec b/build/rpm/dolibarr.spec index a9003afcac3..46c0b734ca3 100644 --- a/build/rpm/dolibarr.spec +++ b/build/rpm/dolibarr.spec @@ -32,7 +32,8 @@ Group: Networking/WWW Group: Applications/Internet Requires: mysql-server mysql httpd php php-cli php-gd php-ldap php-imap php-mysql -AutoReqProv: yes +# Set yes to build test package, no for release (this disable need of /usr/bin/php not found by OpenSuse) +AutoReqProv: no %description @@ -103,17 +104,6 @@ cp -pr doc $RPM_BUILD_ROOT/var/www/dolibarr cp -pr htdocs $RPM_BUILD_ROOT/var/www/dolibarr cp -pr scripts $RPM_BUILD_ROOT/var/www/dolibarr -# menu -#%{__install} -d $RPM_BUILD_ROOT%{_menudir} -#%{__cat} <$RPM_BUILD_ROOT%{_menudir}/%{name} -#?package(%{name}):\ -#command="Dolibarr" \ -#section="Office" \ -#title="Dolibarr" \ -#icon="dolibarr_48x48.png" \ -#longtitle="Dolibarr ERP & CRM" -#EOF - #---- clean %clean @@ -181,19 +171,26 @@ fi # Detect OS -os='fedora'; +os='fedora-redhat'; if [ -d %{_sysconfdir}/httpd/conf.d ]; then - export os='fedora'; + export os='fedora-redhat'; export conffile="%{_sysconfdir}/httpd/conf.d/dolibarr.conf" - apacheuser='apache'; - apachegroup='apache'; + export apacheuser='apache'; + export apachegroup='apache'; fi -if [ -d %{_sysconfdir}/apache2/conf.d ]; then +if [ -d %{_sysconfdir}/apache2/conf.d -a `grep wwwrun /etc/passwd` ]; then export os='opensuse'; export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" - apacheuser='wwwrun'; - apachegroup='wwwrun'; + export apacheuser='wwwrun'; + export apachegroup='wwwrun'; fi +if [ -d %{_sysconfdir}/apache2/conf.d -a `grep www-data /etc/passwd` ]; then + export os='ubuntu-debian'; + export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" + export apacheuser='www-data'; + export apachegroup='www-data'; +fi +echo OS detected: $os # Create a config link dolibarr.conf for Fedora or Redhat if [ ! -f $conffile ]; then @@ -214,11 +211,11 @@ chmod -R o-w $docdir if [ ! -s $targetdir/htdocs/conf/conf.php ]; then echo Create empty Dolibarr conf.php file touch $targetdir/htdocs/conf/conf.php - chown apache.apache $targetdir/htdocs/conf/conf.php + chown $apacheuser:$apachegroup $targetdir/htdocs/conf/conf.php chmod ug+rw $targetdir/htdocs/conf/conf.php fi -if [ "x$os" = "xfedora" -a -s /usr/bin/chcon ]; then +if [ "x$os" = "xfedora-redhat" -a -s /usr/bin/chcon ]; then echo Set SELinux permissions # Warning: chcon seems not cumulative #chcon -R -h -t httpd_sys_content_t $targetdir @@ -253,16 +250,26 @@ echo %clean_menus # Detect OS -os='fedora'; +os='fedora-redhat'; if [ -d %{_sysconfdir}/httpd/conf.d ]; then - export os='fedora'; + export os='fedora-redhat'; export conffile="%{_sysconfdir}/httpd/conf.d/dolibarr.conf" + export apacheuser='apache'; + export apachegroup='apache'; fi -if [ -d %{_sysconfdir}/apache2/conf.d ]; then +if [ -d %{_sysconfdir}/apache2/conf.d -a `grep wwwrun /etc/passwd` ]; then export os='opensuse'; export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" + export apacheuser='wwwrun'; + export apachegroup='wwwrun'; fi - +if [ -d %{_sysconfdir}/apache2/conf.d -a `grep www-data /etc/passwd` ]; then + export os='ubuntu-debian'; + export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" + export apacheuser='www-data'; + export apachegroup='www-data'; +fi +echo OS detected: $os # Dolibarr files are stored into /var/www export targetdir='/var/www/dolibarr' From 1567a07083a6ded690d83aa56a7da5eaa9f116e1 Mon Sep 17 00:00:00 2001 From: Juanjo Menent Date: Mon, 11 Jul 2011 07:51:31 +0000 Subject: [PATCH 30/49] Trad: add possibility to force mail errors-to to all mails sent --- htdocs/langs/ca_ES/admin.lang | 1 + htdocs/langs/es_ES/admin.lang | 1 + 2 files changed, 2 insertions(+) diff --git a/htdocs/langs/ca_ES/admin.lang b/htdocs/langs/ca_ES/admin.lang index 848deab542a..b79ba3f2c77 100644 --- a/htdocs/langs/ca_ES/admin.lang +++ b/htdocs/langs/ca_ES/admin.lang @@ -230,6 +230,7 @@ MAIN_MAIL_SMTP_SERVER=Nom host o ip del servidor SMTP (Per defecte en php.ini: < MAIN_MAIL_SMTP_PORT_NotAvailableOnLinuxLike=Port del servidor SMTP (No definit en PHP en sistemes de tipus Unix) MAIN_MAIL_SMTP_SERVER_NotAvailableOnLinuxLike=Nom servidor o ip del servidor SMTP (No definit en PHP en sistemes de tipus Unix) MAIN_MAIL_EMAIL_FROM=Correu electrònic de l'emissor per trameses e automàtics (Per defecte en php.ini: %s) +MAIN_MAIL_ERRORS_TO=E-Mail usat per als retorns d'error dels e-mails enviats MAIN_MAIL_AUTOCOPY_TO=Enviar automàticament còpia oculta dels e-mails enviats a MAIN_DISABLE_ALL_MAILS=Desactivar globalment tot enviament de correus electrònics (per mode de proves) MAIN_MAIL_SENDMODE=Mètode d'enviament d'e-mails diff --git a/htdocs/langs/es_ES/admin.lang b/htdocs/langs/es_ES/admin.lang index 5645bd6ff6f..de8ec9133ef 100644 --- a/htdocs/langs/es_ES/admin.lang +++ b/htdocs/langs/es_ES/admin.lang @@ -230,6 +230,7 @@ MAIN_MAIL_SMTP_SERVER=Nombre host o ip del servidor SMTP (Por defecto en php.ini MAIN_MAIL_SMTP_PORT_NotAvailableOnLinuxLike=Puerto del servidor SMTP (No definido en PHP en sistemas de tipo Unix) MAIN_MAIL_SMTP_SERVER_NotAvailableOnLinuxLike=Nombre servidor o ip del servidor SMTP (No definido en PHP en sistemas de tipo Unix) MAIN_MAIL_EMAIL_FROM=E-Mail del emisor para envíos E-Mail automáticos (Por defecto en php.ini: %s) +MAIN_MAIL_ERRORS_TO=E-Mail usado para los retornos de error de los e-mails enviados MAIN_MAIL_AUTOCOPY_TO=Enviar automáticamente copia oculta de los e-mails enviados a MAIN_DISABLE_ALL_MAILS=Desactivar globalmente todo envío de correos electrónicos (para modo de pruebas o demo) MAIN_MAIL_SENDMODE=Método de envío de e-mails From d360e6f142bf47dc4784ef15673fe00bc4f1f9c5 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 11 Jul 2011 08:36:11 +0000 Subject: [PATCH 31/49] Work on packaging RPM & DEB --- build/rpm/README | 2 +- build/rpm/dolibarr.spec | 24 ++++++++++++++++++------ 2 files changed, 19 insertions(+), 7 deletions(-) diff --git a/build/rpm/README b/build/rpm/README index f2077ceac36..c072a212632 100644 --- a/build/rpm/README +++ b/build/rpm/README @@ -18,6 +18,6 @@ with format RPM (for Redhat, Mandriva, ...). # yast --install dolibarr-...rpm To install package and dependencies # yast --remove dolibarr To remove package # -# On Mageia +# On Mageia (after su - root) # urpmi dolibarr-...rpm To install package and dependencies # urpme dolibarr To remove package \ No newline at end of file diff --git a/build/rpm/dolibarr.spec b/build/rpm/dolibarr.spec index 46c0b734ca3..b3aaca1d494 100644 --- a/build/rpm/dolibarr.spec +++ b/build/rpm/dolibarr.spec @@ -171,20 +171,26 @@ fi # Detect OS -os='fedora-redhat'; +os='unknown'; if [ -d %{_sysconfdir}/httpd/conf.d ]; then export os='fedora-redhat'; export conffile="%{_sysconfdir}/httpd/conf.d/dolibarr.conf" export apacheuser='apache'; export apachegroup='apache'; fi -if [ -d %{_sysconfdir}/apache2/conf.d -a `grep wwwrun /etc/passwd` ]; then +if [ -d %{_sysconfdir}/apache2/conf.d -a `grep ^wwwrun /etc/passwd | wc -l` -ge 1 ]; then export os='opensuse'; export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" export apacheuser='wwwrun'; export apachegroup='wwwrun'; fi -if [ -d %{_sysconfdir}/apache2/conf.d -a `grep www-data /etc/passwd` ]; then +if [ -d %{_sysconfdir}/httpd/conf.d -a `grep -i "^mageia\|mandriva" /etc/issue | wc -l` -ge 1 ]; then + export os='mageia-mandriva'; + export conffile="%{_sysconfdir}/httpd/conf.d/dolibarr.conf" + export apacheuser='apache'; + export apachegroup='apache'; +fi +if [ -d %{_sysconfdir}/apache2/conf.d -a `grep ^www-data /etc/passwd | wc -l` -ge 1 ]; then export os='ubuntu-debian'; export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" export apacheuser='www-data'; @@ -250,20 +256,26 @@ echo %clean_menus # Detect OS -os='fedora-redhat'; +os='unknown'; if [ -d %{_sysconfdir}/httpd/conf.d ]; then export os='fedora-redhat'; export conffile="%{_sysconfdir}/httpd/conf.d/dolibarr.conf" export apacheuser='apache'; export apachegroup='apache'; fi -if [ -d %{_sysconfdir}/apache2/conf.d -a `grep wwwrun /etc/passwd` ]; then +if [ -d %{_sysconfdir}/apache2/conf.d -a `grep ^wwwrun /etc/passwd | wc -l` -ge 1 ]; then export os='opensuse'; export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" export apacheuser='wwwrun'; export apachegroup='wwwrun'; fi -if [ -d %{_sysconfdir}/apache2/conf.d -a `grep www-data /etc/passwd` ]; then +if [ -d %{_sysconfdir}/httpd/conf.d -a `grep -i "^mageia\|mandriva" /etc/issue | wc -l` -ge 1 ]; then + export os='mageia-mandriva'; + export conffile="%{_sysconfdir}/httpd/conf.d/dolibarr.conf" + export apacheuser='apache'; + export apachegroup='apache'; +fi +if [ -d %{_sysconfdir}/apache2/conf.d -a `grep ^www-data /etc/passwd | wc -l` -ge 1 ]; then export os='ubuntu-debian'; export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" export apacheuser='www-data'; From 1a49260b6f9f5fab8c9da347c9fc81383292ddc1 Mon Sep 17 00:00:00 2001 From: Juanjo Menent Date: Mon, 11 Jul 2011 08:38:02 +0000 Subject: [PATCH 32/49] Fix: Missing translation --- htdocs/langs/ca_ES/compta.lang | 2 ++ htdocs/langs/en_US/compta.lang | 3 +++ htdocs/langs/es_ES/compta.lang | 2 ++ htdocs/langs/fr_FR/compta.lang | 2 ++ 4 files changed, 9 insertions(+) diff --git a/htdocs/langs/ca_ES/compta.lang b/htdocs/langs/ca_ES/compta.lang index 8e77514697c..6af465d52a6 100644 --- a/htdocs/langs/ca_ES/compta.lang +++ b/htdocs/langs/ca_ES/compta.lang @@ -113,7 +113,9 @@ RulesVATDue=- Per als serveis, l'informe inclou l'IVA de les factures degudes, p OptionVatInfoModuleComptabilite=Nota: Per als béns materials, caldria utilitzar la data de lliurament per per ser més just. PercentOfInvoice=%%/factura NotUsedForGoods=No utilitzat per als béns +ProposalStats=Estadístiques de pressupostos OrderStats=Estadístiques de comandes +InvoiceStats=Estadístiques de factures Dispatch=Desglossament Dispatched=Desglossats ToDispatch=A desglossar diff --git a/htdocs/langs/en_US/compta.lang b/htdocs/langs/en_US/compta.lang index d664b32484f..a08d440d5ef 100644 --- a/htdocs/langs/en_US/compta.lang +++ b/htdocs/langs/en_US/compta.lang @@ -113,6 +113,9 @@ RulesVATDue=For services, the report includes VAT invoices due, paid or not, bas OptionVatInfoModuleComptabilite=Note: For material assets, it should use the date of delivery to be more fair. PercentOfInvoice=%%/invoice NotUsedForGoods=Not used on goods +ProposalStats=Statistics on proposals +OrderStats=Statistics on orders +InvoiceStats=Statistics on bills Dispatch=Dispatching Dispatched=Dispatched ToDispatch=To dispatch diff --git a/htdocs/langs/es_ES/compta.lang b/htdocs/langs/es_ES/compta.lang index 5715db90057..47df458f6f0 100644 --- a/htdocs/langs/es_ES/compta.lang +++ b/htdocs/langs/es_ES/compta.lang @@ -113,7 +113,9 @@ RulesVATDue=- Para los servicios, el informe incluye el IVA de las facturas debi OptionVatInfoModuleComptabilite=Nota: Para los bienes materiales, sería necesario utilizar la fecha de entrega para para ser más justo. PercentOfInvoice=%%/factura NotUsedForGoods=No utilizado para los bienes +ProposalStats=Estadísticas de presupuestos OrderStats=Estadísticas de pedidos +InvoiceStats=Estadísticas de facturas Dispatch=Desglose Dispatched=Desglosados ToDispatch=A desglosar diff --git a/htdocs/langs/fr_FR/compta.lang b/htdocs/langs/fr_FR/compta.lang index 499a2507cf6..143737924e3 100644 --- a/htdocs/langs/fr_FR/compta.lang +++ b/htdocs/langs/fr_FR/compta.lang @@ -113,7 +113,9 @@ RulesVATDue=- Pour les services, le rapport inclut les TVA des factures dues, pa OptionVatInfoModuleComptabilite=Remarque : Pour les biens matériels, il faudrait utiliser la date de livraison pour être plus juste. PercentOfInvoice=%%/facture NotUsedForGoods=Non utilisé pour les biens +ProposalStats=Statistiques sur les propales OrderStats=Statistiques sur les commandes +InvoiceStats=Statistiques sur les factures Dispatch=Ventilation Dispatched=Ventilés ToDispatch=A ventiler From 37b62bb4d5d075d5fb736c17a99de74c1b991ad3 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 11 Jul 2011 08:54:57 +0000 Subject: [PATCH 33/49] Work on packaging RPM & DEB --- build/deb/apache.conf | 18 ++++++----- build/rpm/httpd-dolibarr.conf | 61 ++++++++++++++++++++++++++++++++--- 2 files changed, 66 insertions(+), 13 deletions(-) diff --git a/build/deb/apache.conf b/build/deb/apache.conf index 568dd605dca..cfedcbc4dbb 100644 --- a/build/deb/apache.conf +++ b/build/deb/apache.conf @@ -14,7 +14,9 @@ Alias /dolibarr /usr/share/dolibarr/htdocs # # Directory for web pages - + + Order deny,allow + Allow from all DirectoryIndex index.php Options +FollowSymLinks +Indexes @@ -54,23 +56,23 @@ Alias /dolibarr /usr/share/dolibarr/htdocs #ExpiresByType application/x-javascript A2592000 #ExpiresByType application/javascript A2592000 - + # Directory for public pages - + AllowOverride All Order deny,allow Allow from all - + # Directory for data files - + AllowOverride All Order deny,allow Allow from all - - + + AllowOverride All Order deny,allow Allow from all - + diff --git a/build/rpm/httpd-dolibarr.conf b/build/rpm/httpd-dolibarr.conf index 38af8c4839e..e1fcb3f77e5 100644 --- a/build/rpm/httpd-dolibarr.conf +++ b/build/rpm/httpd-dolibarr.conf @@ -1,28 +1,79 @@ -Alias /dolibarr /var/www/dolibarr/htdocs +# Apache config file for Dolibarr - + +Alias /dolibarr /var/www/dolibarr/htdocs + + +# You can also use phpLDAPadmin as a VirtualHost +# +# ServerName mydolibarrhostname.com +# ServerAdmin root@example.com +# DocumentRoot /usr/share/dolibarr/ +# ErrorLog logs/ldap.example.com-error.log +# CustomLog logs/ldap.example.com-access.log common +# + +# Directory for web pages + + Order deny,allow + Allow from all + DirectoryIndex index.php Options +FollowSymLinks +Indexes - ErrorDocument 401 /public/error-401.html + ErrorDocument 401 /public/error-401.php ErrorDocument 404 /public/error-404.php php_flag magic_quotes_gpc Off + php_flag register_globals Off + php_flag magic_quotes_gpc Off + php_flag register_globals Off + + # OPTIMIZE: To use gzip compressed files (for Dolibarr already compressed files). + # Note that constant MAIN_OPTIMIZE_SPEED must have a value with bit 0 set. + #AddType text/javascript .jgz + #AddEncoding gzip .jgz + + # OPTIMIZE: To use gzip compression (on the fly). + # Note that you must also enable the module mod_deflate. + # You can also set this with constant MAIN_OPTIMIZE_SPEED and bit 2 set. + #TODO + + # OPTIMIZE: To use cache on static pages (A259200 = 1 month). + # Note that you must also enable the module mod_expires. + #ExpiresActive On + #ExpiresByType image/x-icon A2592000 + #ExpiresByType image/gif A2592000 + #ExpiresByType image/png A2592000 + #ExpiresByType image/jpeg A2592000 + #ExpiresByType text/css A2592000 + #ExpiresByType text/javascript A2592000 + #ExpiresByType application/x-javascript A2592000 + #ExpiresByType application/javascript A2592000 + - +# Directory for public pages + AllowOverride All Order deny,allow Allow from all - +# Directory for data files + AllowOverride All Order deny,allow Allow from all + + AllowOverride All + Order deny,allow + Allow from all + + From 3b27bdbcf8c1de7c4bce62ee4fb22c534392e594 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 11 Jul 2011 08:55:53 +0000 Subject: [PATCH 34/49] Work on packaging RPM & DEB --- build/deb/apache.conf | 2 +- build/rpm/httpd-dolibarr.conf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/build/deb/apache.conf b/build/deb/apache.conf index cfedcbc4dbb..fa29149ee59 100644 --- a/build/deb/apache.conf +++ b/build/deb/apache.conf @@ -4,7 +4,7 @@ Alias /dolibarr /usr/share/dolibarr/htdocs -# You can also use phpLDAPadmin as a VirtualHost +# You can also use dolibarr as a VirtualHost # # ServerName mydolibarrhostname.com # ServerAdmin root@example.com diff --git a/build/rpm/httpd-dolibarr.conf b/build/rpm/httpd-dolibarr.conf index e1fcb3f77e5..4a395f235a2 100644 --- a/build/rpm/httpd-dolibarr.conf +++ b/build/rpm/httpd-dolibarr.conf @@ -4,7 +4,7 @@ Alias /dolibarr /var/www/dolibarr/htdocs -# You can also use phpLDAPadmin as a VirtualHost +# You can also use dolibarr as a VirtualHost # # ServerName mydolibarrhostname.com # ServerAdmin root@example.com From 0dcff6f022df32360c06aec5ebdf04f32922222b Mon Sep 17 00:00:00 2001 From: cdelambert Date: Mon, 11 Jul 2011 09:32:35 +0000 Subject: [PATCH 35/49] Correction paiement Ajax --- htdocs/compta/ajaxpayment.php | 4 ++-- htdocs/compta/paiement.php | 23 ++++++++--------------- 2 files changed, 10 insertions(+), 17 deletions(-) diff --git a/htdocs/compta/ajaxpayment.php b/htdocs/compta/ajaxpayment.php index fa09707e543..9b23a1bd67a 100644 --- a/htdocs/compta/ajaxpayment.php +++ b/htdocs/compta/ajaxpayment.php @@ -22,8 +22,8 @@ * \version ajaxpayment.php,v 1.0 */ -if (! defined('NOREQUIREUSER')) define('NOREQUIREUSER','1'); -if (! defined('NOREQUIREDB')) define('NOREQUIREDB','1'); +//if (! defined('NOREQUIREUSER')) define('NOREQUIREUSER','1'); +//if (! defined('NOREQUIREDB')) define('NOREQUIREDB','1'); if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1'); //if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1'); if (! defined('NOCSRFCHECK')) define('NOCSRFCHECK','1'); diff --git a/htdocs/compta/paiement.php b/htdocs/compta/paiement.php index 997745b1754..64eaea3a7f4 100644 --- a/htdocs/compta/paiement.php +++ b/htdocs/compta/paiement.php @@ -24,7 +24,7 @@ * \file htdocs/compta/paiement.php * \ingroup compta * \brief Page to create a payment - * \version $Id: paiement.php,v 1.109 2011/07/04 16:39:48 cdelambert Exp $ + * \version $Id: paiement.php,v 1.110 2011/07/11 09:32:35 cdelambert Exp $ */ require('../main.inc.php'); @@ -272,14 +272,7 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie jQuery(\'.fieldrequireddyn\').removeClass(\'fieldrequired\'); } }); - }); - '."\n"; - } - - if (! empty($conf->global->MAIN_JS_ON_PAYMENT)) - { - print "\n".''."\n"; } - print ''; + print ''; print ''; print ''; print ''; @@ -367,18 +360,18 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie print ''.$langs->trans('Comments').''; $rowspan=5; - if (! empty($conf->global->MAIN_JS_ON_PAYMENT)) $rowspan++; + if ($conf->use_javascript_ajax) $rowspan++; // Payment mode print ''.$langs->trans('PaymentMode').''; $html->select_types_paiements((GETPOST('paiementcode')?GETPOST('paiementcode'):$facture->mode_reglement_code),'paiementcode','',2); print "\n"; print ''; - print ''; + print ''; print ''; // Payment amount - if (! empty($conf->global->MAIN_JS_ON_PAYMENT)) + if ($conf->use_javascript_ajax) { print ''.$langs->trans('AmountPayment').''; print ''; @@ -519,7 +512,7 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie if ($action != 'add_paiement') { - if (! empty($conf->global->MAIN_JS_ON_PAYMENT)) + if ($conf->use_javascript_ajax) { print img_picto($langs->trans('AddRemind'),'rightarrow.png','id="'.$objp->facid.'" "'); } @@ -678,5 +671,5 @@ if (! GETPOST('action')) $db->close(); -llxFooter('$Date: 2011/07/04 16:39:48 $ - $Revision: 1.109 $'); +llxFooter('$Date: 2011/07/11 09:32:35 $ - $Revision: 1.110 $'); ?> From 1f93b1978a255dcf30fc0a9659fc35a00147d18d Mon Sep 17 00:00:00 2001 From: Juanjo Menent Date: Mon, 11 Jul 2011 10:41:29 +0000 Subject: [PATCH 36/49] Trad: add translation --- htdocs/langs/ca_ES/paypal.lang | 3 ++- htdocs/langs/es_ES/paypal.lang | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/htdocs/langs/ca_ES/paypal.lang b/htdocs/langs/ca_ES/paypal.lang index cf81b6a25d0..140c0c23e5a 100644 --- a/htdocs/langs/ca_ES/paypal.lang +++ b/htdocs/langs/ca_ES/paypal.lang @@ -13,5 +13,6 @@ PAYPAL_API_INTEGRAL_OR_PAYPALONLY=Proposar pagament integral (Targeta+Paypal) o PAYPAL_CSS_URL=Url opcional del full d'estil CSS de la pàgina de pagament ThisIsTransactionId=Identificador de la transacció: %s PAYPAL_ADD_PAYMENT_URL=Afegir la url del pagament Paypal en enviar un document per e-mail +PAYPAL_IPN_MAIL_ADDRESS=Adreça e-mail per les notificacions instantànies de pagament (IPN) PredefinedMailContentSendOrderWithPaypalLink=Us adjuntem la comanda __ORDERREF__\n\nPodeu fer clic a l'enllaç assegurança de sota per realitzar el seu pagament a través de PayPal\n\n%s\n\nCordialment\n\n -PredefinedMailContentSendInvoiceWithPaypalLink=Us adjuntem la factura __FACREF__\n\nPodeu fer clic a l'enllaç assegurança de sota per realitzar el seu pagament a través de PayPal\n\n%s\n\nCordialment\n\n \ No newline at end of file +PredefinedMailContentSendInvoiceWithPaypalLink=Us adjuntem la factura __FACREF__\n\nPodeu fer clic a l'enllaç assegurança de sota per realitzar el seu pagament a través de PayPal\n\n%s\n\nCordialment\n\n diff --git a/htdocs/langs/es_ES/paypal.lang b/htdocs/langs/es_ES/paypal.lang index ea4365c90dd..250c13cd1fc 100644 --- a/htdocs/langs/es_ES/paypal.lang +++ b/htdocs/langs/es_ES/paypal.lang @@ -1,4 +1,4 @@ -# Dolibarr language file - es_ES - paypal +# Dolibarr language file - es_ES - paypal CHARSET=UTF-8 PaypalSetup=Configuración del módulo PayPal PaypalDesc=Este módulo ofrece una página de pago a través del proveedor Paypal para realizar cualquier pago o un pago en relación con un objeto Dolibarr (facturas, pedidos ...) @@ -13,5 +13,6 @@ PAYPAL_API_INTEGRAL_OR_PAYPALONLY=Proponer pago integral (Tarjeta+Paypal) o sól PAYPAL_CSS_URL=Url opcional de la hoja de estilo CSS de la página de pago ThisIsTransactionId=Identificador de la transacción: %s PAYPAL_ADD_PAYMENT_URL=Añadir la url del pago Paypal al enviar un documento por e-mail +PAYPAL_IPN_MAIL_ADDRESS=Dirección e-mail para las notificaciones instantáneas de pago (IPN) PredefinedMailContentSendOrderWithPaypalLink=Le adjuntamos el pedido __ORDERREF__\n\nPuede hacer clic en el enlace seguro de abajo para realizar su pago a través de PayPal\n\n%s\n\nCordialmente\n\n -PredefinedMailContentSendInvoiceWithPaypalLink=Le adjuntamos la factura __FACREF__\n\nPuede hacer clic en el enlace seguro de abajo para realizar su pago a través de PayPal\n\n%s\n\nCordialmente\n\n \ No newline at end of file +PredefinedMailContentSendInvoiceWithPaypalLink=Le adjuntamos la factura __FACREF__\n\nPuede hacer clic en el enlace seguro de abajo para realizar su pago a través de PayPal\n\n%s\n\nCordialmente\n\n From 63afe0d6a1ff5281f72401b4de6e5142a43cca59 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 11 Jul 2011 10:53:37 +0000 Subject: [PATCH 37/49] Fix: Removed install warning --- htdocs/install/inc.php | 31 ++++++++++++++++++++++--------- 1 file changed, 22 insertions(+), 9 deletions(-) diff --git a/htdocs/install/inc.php b/htdocs/install/inc.php index dcf9df92821..1fd1774d185 100644 --- a/htdocs/install/inc.php +++ b/htdocs/install/inc.php @@ -22,7 +22,7 @@ /** \file htdocs/install/inc.php * \ingroup core * \brief File that define environment for install pages - * \version $Id$ + * \version $Id: inc.php,v 1.134 2011/07/11 10:53:37 eldy Exp $ */ define('DOL_VERSION','3.1.0-alpha'); // Also defined in htdocs/master.inc.php (Ex: x.y.z-alpha, x.y.z) @@ -159,18 +159,31 @@ if (! empty($dolibarr_main_document_root_alt)) // Security check if (preg_match('/install.lock/i',$_SERVER["SCRIPT_FILENAME"])) { - print 'Install pages have been disabled for security reason (directory renamed with .lock).'; - print ''; - print 'Click here to go to Dolibarr'; - print ''; + print 'Install pages have been disabled for security reason (directory renamed with .lock suffix).'; + if (! empty($dolibarr_main_url_root)) + { + print 'Click on following link. '; + print ''; + print 'Click here to go to Dolibarr'; + print ''; + } exit; } if (file_exists('../../install.lock')) { - print 'Install pages have been disabled for security reason (by lock file install.lock in dolibarr root directory. Remove it manually if following link loops to this page).
'; - print ''; - print 'Click here to go to Dolibarr'; - print ''; + print 'Install pages have been disabled for security reason (by lock file install.lock into dolibarr root directory).
'; + if (! empty($dolibarr_main_url_root)) + { + print 'Click on following link. '; + print 'If you always reach this page, you must remove install.lock file manually.
'; + print ''; + print 'Click here to go to Dolibarr'; + print ''; + } + else + { + print 'If you always reach this page, you must remove install.lock file manually.
'; + } exit; } From cf47c38f6a372cef7856076d7b8a935cd3379995 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 11 Jul 2011 11:09:02 +0000 Subject: [PATCH 38/49] Work on packaging RPM & DEB --- build/makepack-dolibarr.pl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/build/makepack-dolibarr.pl b/build/makepack-dolibarr.pl index 532bf16a2da..8e0e3a0b1d1 100644 --- a/build/makepack-dolibarr.pl +++ b/build/makepack-dolibarr.pl @@ -2,7 +2,7 @@ #---------------------------------------------------------------------------- # \file build/makepack-dolibarr.pl # \brief Dolibarr package builder (tgz, zip, rpm, deb, exe, aps) -# \version $Id: makepack-dolibarr.pl,v 1.108 2011/07/09 18:29:46 eldy Exp $ +# \version $Id: makepack-dolibarr.pl,v 1.109 2011/07/11 11:09:02 eldy Exp $ # \author (c)2004-2011 Laurent Destailleur #---------------------------------------------------------------------------- @@ -48,7 +48,7 @@ if (-d "/usr/src/RPM") { use vars qw/ $REVISION $VERSION /; -$REVISION='$Revision: 1.108 $'; $REVISION =~ /\s(.*)\s/; $REVISION=$1; +$REVISION='$Revision: 1.109 $'; $REVISION =~ /\s(.*)\s/; $REVISION=$1; $VERSION="1.0 (build $REVISION)"; @@ -262,6 +262,7 @@ if ($nboftargetok) { $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/conf/conf.php.old`; $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/conf/conf.php.postgres`; $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/conf/conf*sav*`; + $ret=`rm -f $BUILDROOT/$PROJECT/htdocs/install/install.lock`; $ret=`rm -fr $BUILDROOT/$PROJECT/documents`; $ret=`rm -fr $BUILDROOT/$PROJECT/document`; From 7d2f7f7b4df5c0df443d8e719d5c7a749d40e98d Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 11 Jul 2011 12:31:38 +0000 Subject: [PATCH 39/49] Work on packaging RPM & DEB --- build/rpm/dolibarr.spec | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/build/rpm/dolibarr.spec b/build/rpm/dolibarr.spec index b3aaca1d494..44051435047 100644 --- a/build/rpm/dolibarr.spec +++ b/build/rpm/dolibarr.spec @@ -31,7 +31,13 @@ Group: Networking/WWW # For all other distrib Group: Applications/Internet +# Requires for Fedora-Redhat Requires: mysql-server mysql httpd php php-cli php-gd php-ldap php-imap php-mysql +# Requires for OpenSuse +#Requires: mysql-community-server mysql-community-server-client apache2 apache2-mod_php5 php5 php5-gd php5-ldap php5-imap php5-mysql php5-openssl +# Requires for Mageia +#Requires: mysql mysql-client apache-base apache-mod_php php-cgi php-cli php-bz2 php-gd php-ldap php-imap php-mysqli php-openssl + # Set yes to build test package, no for release (this disable need of /usr/bin/php not found by OpenSuse) AutoReqProv: no @@ -182,7 +188,7 @@ if [ -d %{_sysconfdir}/apache2/conf.d -a `grep ^wwwrun /etc/passwd | wc -l` -ge export os='opensuse'; export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" export apacheuser='wwwrun'; - export apachegroup='wwwrun'; + export apachegroup='www'; fi if [ -d %{_sysconfdir}/httpd/conf.d -a `grep -i "^mageia\|mandriva" /etc/issue | wc -l` -ge 1 ]; then export os='mageia-mandriva'; @@ -267,7 +273,7 @@ if [ -d %{_sysconfdir}/apache2/conf.d -a `grep ^wwwrun /etc/passwd | wc -l` -ge export os='opensuse'; export conffile="%{_sysconfdir}/apache2/conf.d/dolibarr.conf" export apacheuser='wwwrun'; - export apachegroup='wwwrun'; + export apachegroup='www'; fi if [ -d %{_sysconfdir}/httpd/conf.d -a `grep -i "^mageia\|mandriva" /etc/issue | wc -l` -ge 1 ]; then export os='mageia-mandriva'; @@ -307,9 +313,12 @@ then fi fi +# Removed dirs after apache restart +echo Removed remaining dirs rm -rf /etc/dolibarr rm -rf $targetdir/htdocs/conf rm -rf $targetdir/htdocs/install - +rmdir $targetdir/doc >/dev/null 2>&1 +rmdir $targetdir/htdocs >/dev/null 2>&1 %changelog From 494009b417e1d2f667574bea388a0fee6d829774 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 11 Jul 2011 21:16:25 +0000 Subject: [PATCH 40/49] Work on packaging RPM & DEB --- build/rpm/README | 1 + build/rpm/dolibarr.spec | 23 +++++++++++++---------- 2 files changed, 14 insertions(+), 10 deletions(-) diff --git a/build/rpm/README b/build/rpm/README index c072a212632..d868ed411b8 100644 --- a/build/rpm/README +++ b/build/rpm/README @@ -11,6 +11,7 @@ with format RPM (for Redhat, Mandriva, ...). # This is standard command to work on Debian packaging: # # On Fedora +# rpm -i --test dolibarr-...rpm To list dependencies of RPM # yum install dolibarr-...rpm To install package and dependencies # yum erase dolibarr To remove package # diff --git a/build/rpm/dolibarr.spec b/build/rpm/dolibarr.spec index 44051435047..11090951bdd 100644 --- a/build/rpm/dolibarr.spec +++ b/build/rpm/dolibarr.spec @@ -19,25 +19,30 @@ Packager: Laurent Destailleur (Eldy) Vendor: Dolibarr dev team URL: http://www.%{name}.org -#Source: http://sourceforge.net/projects/%{name}/files/Dolibarr%20ERP-CRM/%{version}/%{name}-%{version}.tgz/download Source: /usr/src/RPM/SOURCES/%{name}-%{version}.tgz #BuildArch: noarch #BuildArchitectures: noarch BuildRoot: /tmp/%{name}-buildroot #Icon: dolibarr_logo1.gif -# For Mandrake +# For Mandriva-Mageia Group: Networking/WWW # For all other distrib Group: Applications/Internet +# Requires can use lua to be defined dynamically (but still at build time) +# %{lua: if posix.access("/aaa") then print("Requires: bidon1 mysql-server mysql httpd php php-cli php-gd php-ldap php-imap php-mysql") end } + # Requires for Fedora-Redhat Requires: mysql-server mysql httpd php php-cli php-gd php-ldap php-imap php-mysql # Requires for OpenSuse #Requires: mysql-community-server mysql-community-server-client apache2 apache2-mod_php5 php5 php5-gd php5-ldap php5-imap php5-mysql php5-openssl -# Requires for Mageia +# Requires for Mandriva-Mageia #Requires: mysql mysql-client apache-base apache-mod_php php-cgi php-cli php-bz2 php-gd php-ldap php-imap php-mysqli php-openssl +#Requires(pre): +#Requires(postun): + # Set yes to build test package, no for release (this disable need of /usr/bin/php not found by OpenSuse) AutoReqProv: no @@ -95,19 +100,17 @@ mkdir -p $RPM_BUILD_ROOT/var/www/dolibarr/build mkdir -p $RPM_BUILD_ROOT/var/www/dolibarr/doc mkdir -p $RPM_BUILD_ROOT/var/www/dolibarr/htdocs mkdir -p $RPM_BUILD_ROOT/var/www/dolibarr/scripts -#mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/dolibarr -#mkdir -p $RPM_BUILD_ROOT/%{_sysconfdir}/cron.daily mkdir -p $RPM_BUILD_ROOT%{_datadir}/pixmaps cp doc/images/dolibarr_48x48.png $RPM_BUILD_ROOT%{_datadir}/pixmaps/dolibarr.png mkdir -p $RPM_BUILD_ROOT%{_datadir}/applications -cp build/rpm/dolibarr.desktop $RPM_BUILD_ROOT/%{_datadir}/applications/dolibarr.desktop +cp build/rpm/dolibarr.desktop $RPM_BUILD_ROOT/%{_datadir}/applications/dolibarr.desktop -install -m 444 README $RPM_BUILD_ROOT/var/www/dolibarr/README +install -m 444 README $RPM_BUILD_ROOT/var/www/dolibarr/README install -m 444 COPYRIGHT $RPM_BUILD_ROOT/var/www/dolibarr/COPYRIGHT -cp -pr build $RPM_BUILD_ROOT/var/www/dolibarr -cp -pr doc $RPM_BUILD_ROOT/var/www/dolibarr -cp -pr htdocs $RPM_BUILD_ROOT/var/www/dolibarr +cp -pr build $RPM_BUILD_ROOT/var/www/dolibarr +cp -pr doc $RPM_BUILD_ROOT/var/www/dolibarr +cp -pr htdocs $RPM_BUILD_ROOT/var/www/dolibarr cp -pr scripts $RPM_BUILD_ROOT/var/www/dolibarr From 3d4003de3375f5561034688dc23644c7ef8b0ff3 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Jul 2011 07:17:11 +0000 Subject: [PATCH 41/49] Fix: Uniformise code --- htdocs/commande/class/commande.class.php | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/htdocs/commande/class/commande.class.php b/htdocs/commande/class/commande.class.php index 0bad431057f..e5edf12a296 100644 --- a/htdocs/commande/class/commande.class.php +++ b/htdocs/commande/class/commande.class.php @@ -25,7 +25,7 @@ * \file htdocs/commande/class/commande.class.php * \ingroup commande * \brief Fichier des classes de commandes - * \version $Id: commande.class.php,v 1.118 2011/07/04 10:35:49 hregis Exp $ + * \version $Id: commande.class.php,v 1.119 2011/07/12 07:17:11 eldy Exp $ */ require_once(DOL_DOCUMENT_ROOT."/core/class/commonobject.class.php"); require_once(DOL_DOCUMENT_ROOT."/product/class/product.class.php"); @@ -259,7 +259,7 @@ class Commande extends CommonObject if (! $error) { $this->oldref=''; - + // Rename directory if dir was a temporary ref if (preg_match('/^[\(]?PROV/i', $this->ref)) { @@ -276,7 +276,7 @@ class Commande extends CommonObject if (@rename($dirsource, $dirdest)) { $this->oldref = $comref; - + dol_syslog("Rename ok"); // Suppression ancien fichier PDF dans nouveau rep dol_delete_file($conf->commande->dir_output.'/'.$snum.'/'.$comref.'.*'); @@ -733,7 +733,7 @@ class Commande extends CommonObject } } } - + if (! $notrigger) { // Appel des triggers @@ -3050,6 +3050,7 @@ class OrderLine if (empty($this->tva_tx)) $this->tva_tx=0; if (empty($this->localtax1_tx)) $this->localtax1_tx=0; if (empty($this->localtax2_tx)) $this->localtax2_tx=0; + if (empty($this->qty)) $this->qty=0; if (empty($this->total_localtax1)) $this->total_localtax1=0; if (empty($this->total_localtax2)) $this->total_localtax2=0; if (empty($this->marque_tx)) $this->marque_tx=0; @@ -3065,10 +3066,10 @@ class OrderLine // Mise a jour ligne en base $sql = "UPDATE ".MAIN_DB_PREFIX."commandedet SET"; $sql.= " description='".$this->db->escape($this->desc)."'"; - $sql.= " , tva_tx='".price2num($this->tva_tx)."'"; + $sql.= " , tva_tx=".price2num($this->tva_tx); $sql.= " , localtax1_tx=".price2num($this->localtax1_tx); $sql.= " , localtax2_tx=".price2num($this->localtax2_tx); - $sql.= " , qty='".price2num($this->qty)."'"; + $sql.= " , qty=".price2num($this->qty); $sql.= " , subprice=".price2num($this->subprice).""; $sql.= " , remise_percent=".price2num($this->remise_percent).""; $sql.= " , price=".price2num($this->price).""; // TODO A virer @@ -3080,8 +3081,8 @@ class OrderLine $sql.= " , total_tva=".price2num($this->total_tva).""; $sql.= " , total_ttc=".price2num($this->total_ttc).""; } - $sql.= " , total_localtax1='".price2num($this->total_localtax1)."'"; - $sql.= " , total_localtax2='".price2num($this->total_localtax2)."'"; + $sql.= " , total_localtax1=".price2num($this->total_localtax1); + $sql.= " , total_localtax2=".price2num($this->total_localtax2); $sql.= " , info_bits=".$this->info_bits; if ($this->date_start) { $sql.= " , date_start='".$this->db->idate($this->date_start)."'"; } else { $sql.=' , date_start=null'; } From 568770e21c3ffa586b33ecd7220171fc55a8bcb9 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Tue, 12 Jul 2011 08:07:59 +0000 Subject: [PATCH 42/49] Fix: update jstree plugin --- .../plugins/jstree/jquery.jstree.min.jgz | Bin 27688 -> 27707 bytes .../plugins/jstree/jquery.jstree.min.js | 97 +++++++++--------- 2 files changed, 48 insertions(+), 49 deletions(-) diff --git a/htdocs/includes/jquery/plugins/jstree/jquery.jstree.min.jgz b/htdocs/includes/jquery/plugins/jstree/jquery.jstree.min.jgz index 2fbed408bc1914303e4d0641e045172a82fad4fd..8ba61f32afcbc31f54a7ab8b5a9df2ec6a2c2a26 100644 GIT binary patch literal 27707 zcmV(mK=Z#JiwFqd{~JyM18Q+~Wpa5gYIAgQWo0gHX>KlRa{%qVYj@+ukudyu{VOO~ zD-tG1T@pK4axh9BXLI87Bu?J-)yNnZ=DtoM@Rg3_zsGtY4}*A z)w)=YH=o@lMJFpKS^8Ccoy^NLqL1I`kL&9*{xDiT3?C1Ncgg#tO5(@OSpFVP%QAkv zNvjF`7^%|5dY(>}$s&zr={&8{$@M(BiOSnFtpE_28LMBzD*tnSpB7&yW!ekJ2qCmL z!Td6&YS__#;OEm5e^XxcE;qh%gGizSFyBwAP z@3hK`H|dA!=%_Kv1~}Fup&2j+9mjE1tT|Z#o-Xpc6vq-ix+%SPA;ZKO+>TjPr*Kg* z8tekTQW%pQpb7eTv)O!hf15!qo!sxgy9~!RI-+DYYnn+hdjQ;_pedY_p_qH4Akz^S z_u-pIk}b=$sLZkH6x~?A+j;D4y3q*?mPW@#0ZhAGv|P{UR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+)DI?K}2NF4azDHl5C*LPxHsVNB#O8WH|iYXv|!L6x^&d5Ea zxSr@XEw2)IXi?8tl6-dqPl_z=-NOV+q^D={nS^RcRXzN2)b&v3-n4iSO`Tq!q2D9u zqQOCy^jHRECJ%lPk)^=QqJ!l9T~(}<4@pA+kM))GU6pDV!n@KIRgEk*3`du5nEe!} z8?0QvOhyX`2FM_?Sv_7^9x={oi1f1NO&rdbMIQRG=8f?x#IEV+9l05TX>|)PgmBR? zsA}Ll(a-`ftauJF>@igg*-!)hLPvox%DK(QSn0uf<78a05C1tZ`4_o#V}oGQZ@#7J z*2fl*iH>tD-D{qnHF&%-J)lc+)!vh1lE0?tKKKmRIubkfV$k|(E?w}h<|Dc01~D$1 zlAK9V1}soc7rjxMwT|)KZG@^psnkG%mnxz%ssL+SMzc}imeP)hi=NWoGn#(a)j9;p zGu9=wizZOefZ@T)a(ktVNrPu9JId$iR1wKZ&6{jVq@-TvQ02+D@zFA?r$l4=H~HYw n-y?H<2zX$xpa;YfH`Kt}Xo(^Z=XFo~j3@sebmuhcLkj``fbYgO diff --git a/htdocs/includes/jquery/plugins/jstree/jquery.jstree.min.js b/htdocs/includes/jquery/plugins/jstree/jquery.jstree.min.js index 84fc5d24d04..321ce99e990 100644 --- a/htdocs/includes/jquery/plugins/jstree/jquery.jstree.min.js +++ b/htdocs/includes/jquery/plugins/jstree/jquery.jstree.min.js @@ -15,15 +15,15 @@ else{tmp.appendChild(document.createTextNode(opts.str));document.getElementsByTa return tmp.sheet||tmp.styleSheet;} if(opts.url){if(document.createStyleSheet){try{tmp=document.createStyleSheet(opts.url);}catch(e){}} else{tmp=document.createElement('link');tmp.rel='stylesheet';tmp.type='text/css';tmp.media="all";tmp.href=opts.url;document.getElementsByTagName("head")[0].appendChild(tmp);return tmp.styleSheet;}}}};var instances=[],focused_instance=-1,plugins={},prepared_move={};$.fn.jstree=function(settings){var isMethodCall=(typeof settings=='string'),args=Array.prototype.slice.call(arguments,1),returnValue=this;if(isMethodCall){if(settings.substring(0,1)=='_'){return returnValue;} -this.each(function(){var instance=instances[$.data(this,"jstree-instance-id")],methodValue=(instance&&$.isFunction(instance[settings]))?instance[settings].apply(instance,args):instance;if(typeof methodValue!=="undefined"&&(settings.indexOf("is_")===0||(methodValue!==true&&methodValue!==false))){returnValue=methodValue;return false;}});} -else{this.each(function(){var instance_id=$.data(this,"jstree-instance-id"),a=[],b=settings?$.extend({},true,settings):{},c=$(this),s=false,t=[];a=a.concat(args);if(c.data("jstree")){a.push(c.data("jstree"));} +this.each(function(){var instance=instances[$.data(this,"jstree_instance_id")],methodValue=(instance&&$.isFunction(instance[settings]))?instance[settings].apply(instance,args):instance;if(typeof methodValue!=="undefined"&&(settings.indexOf("is_")===0||(methodValue!==true&&methodValue!==false))){returnValue=methodValue;return false;}});} +else{this.each(function(){var instance_id=$.data(this,"jstree_instance_id"),a=[],b=settings?$.extend({},true,settings):{},c=$(this),s=false,t=[];a=a.concat(args);if(c.data("jstree")){a.push(c.data("jstree"));} b=a.length?$.extend.apply(null,[true,b].concat(a)):b;if(typeof instance_id!=="undefined"&&instances[instance_id]){instances[instance_id].destroy();} -instance_id=parseInt(instances.push({}),10)-1;$.data(this,"jstree-instance-id",instance_id);b.plugins=$.isArray(b.plugins)?b.plugins:$.jstree.defaults.plugins.slice();b.plugins.unshift("core");b.plugins=b.plugins.sort().join(",,").replace(/(,|^)([^,]+)(,,\2)+(,|$)/g,"$1$2$4").replace(/,,+/g,",").replace(/,$/,"").split(",");s=$.extend(true,{},$.jstree.defaults,b);s.plugins=b.plugins;$.each(plugins,function(i,val){if($.inArray(i,s.plugins)===-1){s[i]=null;delete s[i];} -else{t.push(i);}});s.plugins=t;instances[instance_id]=new $.jstree._instance(instance_id,$(this).addClass("jstree jstree-"+instance_id),s);$.each(instances[instance_id]._get_settings().plugins,function(i,val){instances[instance_id].data[val]={};});$.each(instances[instance_id]._get_settings().plugins,function(i,val){if(plugins[val]){plugins[val].__init.apply(instances[instance_id]);}});setTimeout(function(){instances[instance_id].init();},0);});} +instance_id=parseInt(instances.push({}),10)-1;$.data(this,"jstree_instance_id",instance_id);b.plugins=$.isArray(b.plugins)?b.plugins:$.jstree.defaults.plugins.slice();b.plugins.unshift("core");b.plugins=b.plugins.sort().join(",,").replace(/(,|^)([^,]+)(,,\2)+(,|$)/g,"$1$2$4").replace(/,,+/g,",").replace(/,$/,"").split(",");s=$.extend(true,{},$.jstree.defaults,b);s.plugins=b.plugins;$.each(plugins,function(i,val){if($.inArray(i,s.plugins)===-1){s[i]=null;delete s[i];} +else{t.push(i);}});s.plugins=t;instances[instance_id]=new $.jstree._instance(instance_id,$(this).addClass("jstree jstree-"+instance_id),s);$.each(instances[instance_id]._get_settings().plugins,function(i,val){instances[instance_id].data[val]={};});$.each(instances[instance_id]._get_settings().plugins,function(i,val){if(plugins[val]){plugins[val].__init.apply(instances[instance_id]);}});setTimeout(function(){if(instances[instance_id]){instances[instance_id].init();}},0);});} return returnValue;};$.jstree={defaults:{plugins:[]},_focused:function(){return instances[focused_instance]||null;},_reference:function(needle){if(instances[needle]){return instances[needle];} var o=$(needle);if(!o.length&&typeof needle==="string"){o=$("#"+needle);} if(!o.length){return null;} -return instances[o.closest(".jstree").data("jstree-instance-id")]||null;},_instance:function(index,container,settings){this.data={core:{}};this.get_settings=function(){return $.extend(true,{},settings);};this._get_settings=function(){return settings;};this.get_index=function(){return index;};this.get_container=function(){return container;};this.get_container_ul=function(){return container.children("ul:eq(0)");};this._set_settings=function(s){settings=$.extend(true,{},settings,s);};},_fn:{},plugin:function(pname,pdata){pdata=$.extend({},{__init:$.noop,__destroy:$.noop,_fn:{},defaults:false},pdata);plugins[pname]=pdata;$.jstree.defaults[pname]=pdata.defaults;$.each(pdata._fn,function(i,val){val.plugin=pname;val.old=$.jstree._fn[i];$.jstree._fn[i]=function(){var rslt,func=val,args=Array.prototype.slice.call(arguments),evnt=new $.Event("before.jstree"),rlbk=false;if(this.data.core.locked===true&&i!=="unlock"&&i!=="is_locked"){return;} +return instances[o.closest(".jstree").data("jstree_instance_id")]||null;},_instance:function(index,container,settings){this.data={core:{}};this.get_settings=function(){return $.extend(true,{},settings);};this._get_settings=function(){return settings;};this.get_index=function(){return index;};this.get_container=function(){return container;};this.get_container_ul=function(){return container.children("ul:eq(0)");};this._set_settings=function(s){settings=$.extend(true,{},settings,s);};},_fn:{},plugin:function(pname,pdata){pdata=$.extend({},{__init:$.noop,__destroy:$.noop,_fn:{},defaults:false},pdata);plugins[pname]=pdata;$.jstree.defaults[pname]=pdata.defaults;$.each(pdata._fn,function(i,val){val.plugin=pname;val.old=$.jstree._fn[i];$.jstree._fn[i]=function(){var rslt,func=val,args=Array.prototype.slice.call(arguments),evnt=new $.Event("before.jstree"),rlbk=false;if(this.data.core.locked===true&&i!=="unlock"&&i!=="is_locked"){return;} do{if(func&&func.plugin&&$.inArray(func.plugin,this._get_settings().plugins)!==-1){break;} func=func.old;}while(func);if(!func){return;} if(i.indexOf("_")===0){rslt=func.apply(this,args);} @@ -36,7 +36,7 @@ css_string+=''+'.jstree li { height:18px; margin-left:0; margin-right:0; } '+'.j if(/msie/.test(u)&&parseInt(v,10)==7){is_ie7=true;css_string+='.jstree li a { border-width:0 !important; padding:0px 2px !important; } ';} if(!/compatible/.test(u)&&/mozilla/.test(u)&&parseFloat(v,10)<1.9){is_ff2=true;css_string+=''+'.jstree ins { display:-moz-inline-box; } '+'.jstree li { line-height:12px; } '+'.jstree a { display:-moz-inline-box; } '+'.jstree .jstree-no-icons .jstree-checkbox { display:-moz-inline-stack !important; } ';} $.vakata.css.add_sheet({str:css_string,title:"jstree"});});$.jstree.plugin("core",{__init:function(){this.data.core.locked=false;this.data.core.to_open=this.get_settings().core.initially_open;this.data.core.to_load=this.get_settings().core.initially_load;},defaults:{html_titles:false,animation:500,initially_open:[],initially_load:[],open_parents:true,notify_plugins:true,rtl:false,load_open:false,strings:{loading:"Loading ...",new_node:"New node",multiple_selection:"Multiple selection"}},_fn:{init:function(){this.set_focus();if(this._get_settings().core.rtl){this.get_container().addClass("jstree-rtl").css("direction","rtl");} -this.get_container().html("

");this.data.core.li_height=this.get_container_ul().find("li.jstree-closed, li.jstree-leaf").eq(0).height()||18;this.get_container().delegate("li > ins","click.jstree",$.proxy(function(event){var trgt=$(event.target);if(trgt.is("ins")&&event.pageY-trgt.offset().top
  •   "+this._get_string("loading")+"
  • ");this.data.core.li_height=this.get_container_ul().find("li.jstree-closed, li.jstree-leaf").eq(0).height()||18;this.get_container().delegate("li > ins","click.jstree",$.proxy(function(event){var trgt=$(event.target);this.toggle_node(trgt);},this)).bind("mousedown.jstree",$.proxy(function(){this.set_focus();},this)).bind("dblclick.jstree",function(event){var sel;if(document.selection&&document.selection.empty){document.selection.empty();} else{if(window.getSelection){sel=window.getSelection();try{sel.removeAllRanges();sel.collapse();}catch(err){}}}});if(this._get_settings().core.notify_plugins){this.get_container().bind("load_node.jstree",$.proxy(function(e,data){var o=this._get_node(data.rslt.obj),t=this;if(o===-1){o=this.get_container_ul();} if(!o.length){return;} o.find("li").each(function(){var th=$(this);if(th.data("jstree")){$.each(th.data("jstree"),function(plugin,values){if(t.data[plugin]&&$.isFunction(t["_"+plugin+"_notify"])){t["_"+plugin+"_notify"].call(t,th,values);}});}});},this));} @@ -45,7 +45,7 @@ if(!o.length){return;} o.find("li.jstree-open:not(:has(ul))").each(function(){t.load_node(this,$.noop,$.noop);});},this));} this.__callback();this.load_node(-1,function(){this.loaded();this.reload_nodes();});},destroy:function(){var i,n=this.get_index(),s=this._get_settings(),_this=this;$.each(s.plugins,function(i,val){try{plugins[val].__destroy.apply(_this);}catch(err){}});this.__callback();if(this.is_focused()){for(i in instances){if(instances.hasOwnProperty(i)&&i!=n){instances[i].set_focus();break;}}} if(n===focused_instance){focused_instance=-1;} -this.get_container().unbind(".jstree").undelegate(".jstree").removeData("jstree-instance-id").find("[class^='jstree']").andSelf().attr("class",function(){return this.className.replace(/jstree[^ ]*|$/ig,'');});$(document).unbind(".jstree-"+n).undelegate(".jstree-"+n);instances[n]=null;delete instances[n];},_core_notify:function(n,data){if(data.opened){this.open_node(n,false,true);}},lock:function(){this.data.core.locked=true;this.get_container().children("ul").addClass("jstree-locked").css("opacity","0.7");this.__callback({});},unlock:function(){this.data.core.locked=false;this.get_container().children("ul").removeClass("jstree-locked").css("opacity","1");this.__callback({});},is_locked:function(){return this.data.core.locked;},save_opened:function(){var _this=this;this.data.core.to_open=[];this.get_container_ul().find("li.jstree-open").each(function(){if(this.id){_this.data.core.to_open.push("#"+this.id.toString().replace(/^#/,"").replace(/\\\//g,"/").replace(/\//g,"\\\/").replace(/\\\./g,".").replace(/\./g,"\\.").replace(/\:/g,"\\:"));}});this.__callback(_this.data.core.to_open);},save_loaded:function(){},reload_nodes:function(is_callback){var _this=this,done=true,current=[],remaining=[];if(!is_callback){this.data.core.reopen=false;this.data.core.refreshing=true;this.data.core.to_open=$.map($.makeArray(this.data.core.to_open),function(n){return"#"+n.toString().replace(/^#/,"").replace(/\\\//g,"/").replace(/\//g,"\\\/").replace(/\\\./g,".").replace(/\./g,"\\.").replace(/\:/g,"\\:");});this.data.core.to_load=$.map($.makeArray(this.data.core.to_load),function(n){return"#"+n.toString().replace(/^#/,"").replace(/\\\//g,"/").replace(/\//g,"\\\/").replace(/\\\./g,".").replace(/\./g,"\\.").replace(/\:/g,"\\:");});if(this.data.core.to_open.length){this.data.core.to_load=this.data.core.to_load.concat(this.data.core.to_open);}} +this.get_container().unbind(".jstree").undelegate(".jstree").removeData("jstree_instance_id").find("[class^='jstree']").andSelf().attr("class",function(){return this.className.replace(/jstree[^ ]*|$/ig,'');});$(document).unbind(".jstree-"+n).undelegate(".jstree-"+n);instances[n]=null;delete instances[n];},_core_notify:function(n,data){if(data.opened){this.open_node(n,false,true);}},lock:function(){this.data.core.locked=true;this.get_container().children("ul").addClass("jstree-locked").css("opacity","0.7");this.__callback({});},unlock:function(){this.data.core.locked=false;this.get_container().children("ul").removeClass("jstree-locked").css("opacity","1");this.__callback({});},is_locked:function(){return this.data.core.locked;},save_opened:function(){var _this=this;this.data.core.to_open=[];this.get_container_ul().find("li.jstree-open").each(function(){if(this.id){_this.data.core.to_open.push("#"+this.id.toString().replace(/^#/,"").replace(/\\\//g,"/").replace(/\//g,"\\\/").replace(/\\\./g,".").replace(/\./g,"\\.").replace(/\:/g,"\\:"));}});this.__callback(_this.data.core.to_open);},save_loaded:function(){},reload_nodes:function(is_callback){var _this=this,done=true,current=[],remaining=[];if(!is_callback){this.data.core.reopen=false;this.data.core.refreshing=true;this.data.core.to_open=$.map($.makeArray(this.data.core.to_open),function(n){return"#"+n.toString().replace(/^#/,"").replace(/\\\//g,"/").replace(/\//g,"\\\/").replace(/\\\./g,".").replace(/\./g,"\\.").replace(/\:/g,"\\:");});this.data.core.to_load=$.map($.makeArray(this.data.core.to_load),function(n){return"#"+n.toString().replace(/^#/,"").replace(/\\\//g,"/").replace(/\//g,"\\\/").replace(/\\\./g,".").replace(/\./g,"\\.").replace(/\:/g,"\\:");});if(this.data.core.to_open.length){this.data.core.to_load=this.data.core.to_load.concat(this.data.core.to_open);}} if(this.data.core.to_load.length){$.each(this.data.core.to_load,function(i,val){if(val=="#"){return true;} if($(val).length){current.push(val);} else{remaining.push(val);}});if(current.length){this.data.core.to_load=remaining;$.each(current,function(i,val){if(!_this._is_loaded(val)){_this.load_node(val,function(){_this.reload_nodes(true);},function(){_this.reload_nodes(true);});done=false;}});}} @@ -107,7 +107,8 @@ if(typeof m=="string"){tmp.attr('href','#')[s.html_titles?"html":"text"](m);} else{if(!m.attr){m.attr={};} if(!m.attr.href){m.attr.href='#';} tmp.attr(m.attr)[s.html_titles?"html":"text"](m.title);if(m.language){tmp.addClass(m.language);}} -tmp.prepend(" ");if(m.icon){if(m.icon.indexOf("/")===-1){tmp.children("ins").addClass(m.icon);} +tmp.prepend(" ");if(!m.icon&&js.icon){m.icon=js.icon;} +if(m.icon){if(m.icon.indexOf("/")===-1){tmp.children("ins").addClass(m.icon);} else{tmp.children("ins").css("background","url('"+m.icon+"') center center no-repeat");}} d.append(tmp);});d.prepend(" ");if(obj===-1){obj=this.get_container();if(position==="before"){position="first";} if(position==="after"){position="last";}} @@ -217,34 +218,34 @@ else{this.hover_node(this._get_next(o));}} return false;},"space":function(){if(this.data.ui.hovered){this.data.ui.hovered.children("a:eq(0)").click();} return false;},"ctrl+space":function(event){event.type="click";if(this.data.ui.hovered){this.data.ui.hovered.children("a:eq(0)").trigger(event);} return false;},"shift+space":function(event){event.type="click";if(this.data.ui.hovered){this.data.ui.hovered.children("a:eq(0)").trigger(event);} -return false;},"f2":function(){this.rename(this.data.ui.hovered||this.data.ui.last_selected);},"del":function(){this.remove(this.data.ui.hovered||this._get_node(null));}},_fn:{enable_hotkeys:function(){this.data.hotkeys.enabled=true;},disable_hotkeys:function(){this.data.hotkeys.enabled=false;}}});})(jQuery);(function($){$.jstree.plugin("json_data",{__init:function(){var s=this._get_settings().json_data;if(s.progressive_unload){this.get_container().bind("after_close.jstree",function(e,data){data.rslt.obj.children("ul").remove();});}},defaults:{data:false,ajax:false,correct_state:true,progressive_render:false,progressive_unload:false},_fn:{load_node:function(obj,s_call,e_call){var _this=this;this.load_node_json(obj,function(){_this.__callback({"obj":_this._get_node(obj)});s_call.call(this);},e_call);},_is_loaded:function(obj){var s=this._get_settings().json_data;obj=this._get_node(obj);return obj==-1||!obj||(!s.ajax&&!s.progressive_render&&!$.isFunction(s.data))||obj.is(".jstree-open, .jstree-leaf")||obj.children("ul").children("li").length>0;},refresh:function(obj){obj=this._get_node(obj);var s=this._get_settings().json_data;if(obj&&obj!==-1&&s.progressive_unload&&($.isFunction(s.data)||!!s.ajax)){obj.removeData("jstree-children");} -return this.__call_old();},load_node_json:function(obj,s_call,e_call){var s=this.get_settings().json_data,d,error_func=function(){},success_func=function(){};obj=this._get_node(obj);if(obj&&obj!==-1&&(s.progressive_render||s.progressive_unload)&&!obj.is(".jstree-open, .jstree-leaf")&&obj.children("ul").children("li").length===0&&obj.data("jstree-children")){d=this._parse_json(obj.data("jstree-children"),obj);if(d){obj.append(d);if(!s.progressive_unload){obj.removeData("jstree-children");}} +return false;},"f2":function(){this.rename(this.data.ui.hovered||this.data.ui.last_selected);},"del":function(){this.remove(this.data.ui.hovered||this._get_node(null));}},_fn:{enable_hotkeys:function(){this.data.hotkeys.enabled=true;},disable_hotkeys:function(){this.data.hotkeys.enabled=false;}}});})(jQuery);(function($){$.jstree.plugin("json_data",{__init:function(){var s=this._get_settings().json_data;if(s.progressive_unload){this.get_container().bind("after_close.jstree",function(e,data){data.rslt.obj.children("ul").remove();});}},defaults:{data:false,ajax:false,correct_state:true,progressive_render:false,progressive_unload:false},_fn:{load_node:function(obj,s_call,e_call){var _this=this;this.load_node_json(obj,function(){_this.__callback({"obj":_this._get_node(obj)});s_call.call(this);},e_call);},_is_loaded:function(obj){var s=this._get_settings().json_data;obj=this._get_node(obj);return obj==-1||!obj||(!s.ajax&&!s.progressive_render&&!$.isFunction(s.data))||obj.is(".jstree-open, .jstree-leaf")||obj.children("ul").children("li").length>0;},refresh:function(obj){obj=this._get_node(obj);var s=this._get_settings().json_data;if(obj&&obj!==-1&&s.progressive_unload&&($.isFunction(s.data)||!!s.ajax)){obj.removeData("jstree_children");} +return this.__call_old();},load_node_json:function(obj,s_call,e_call){var s=this.get_settings().json_data,d,error_func=function(){},success_func=function(){};obj=this._get_node(obj);if(obj&&obj!==-1&&(s.progressive_render||s.progressive_unload)&&!obj.is(".jstree-open, .jstree-leaf")&&obj.children("ul").children("li").length===0&&obj.data("jstree_children")){d=this._parse_json(obj.data("jstree_children"),obj);if(d){obj.append(d);if(!s.progressive_unload){obj.removeData("jstree_children");}} this.clean_node(obj);if(s_call){s_call.call(this);} return;} -if(obj&&obj!==-1){if(obj.data("jstree-is-loading")){return;} -else{obj.data("jstree-is-loading",true);}} +if(obj&&obj!==-1){if(obj.data("jstree_is_loading")){return;} +else{obj.data("jstree_is_loading",true);}} switch(!0){case(!s.data&&!s.ajax):throw"Neither data nor ajax settings supplied.";case($.isFunction(s.data)):s.data.call(this,obj,$.proxy(function(d){d=this._parse_json(d,obj);if(!d){if(obj===-1||!obj){if(s.correct_state){this.get_container().children("ul").empty();}} -else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree-is-loading");if(s.correct_state){this.correct_state(obj);}} +else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree_is_loading");if(s.correct_state){this.correct_state(obj);}} if(e_call){e_call.call(this);}} else{if(obj===-1||!obj){this.get_container().children("ul").empty().append(d.children());} -else{obj.append(d).children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree-is-loading");} +else{obj.append(d).children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree_is_loading");} this.clean_node(obj);if(s_call){s_call.call(this);}}},this));break;case(!!s.data&&!s.ajax)||(!!s.data&&!!s.ajax&&(!obj||obj===-1)):if(!obj||obj==-1){d=this._parse_json(s.data,obj);if(d){this.get_container().children("ul").empty().append(d.children());this.clean_node();} else{if(s.correct_state){this.get_container().children("ul").empty();}}} if(s_call){s_call.call(this);} break;case(!s.data&&!!s.ajax)||(!!s.data&&!!s.ajax&&obj&&obj!==-1):error_func=function(x,t,e){var ef=this.get_settings().json_data.ajax.error;if(ef){ef.call(this,x,t,e);} -if(obj!=-1&&obj.length){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree-is-loading");if(t==="success"&&s.correct_state){this.correct_state(obj);}} +if(obj!=-1&&obj.length){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree_is_loading");if(t==="success"&&s.correct_state){this.correct_state(obj);}} else{if(t==="success"&&s.correct_state){this.get_container().children("ul").empty();}} if(e_call){e_call.call(this);}};success_func=function(d,t,x){var sf=this.get_settings().json_data.ajax.success;if(sf){d=sf.call(this,d,t,x)||d;} if(d===""||(d&&d.toString&&d.toString().replace(/^[\s\n]+$/,"")==="")||(!$.isArray(d)&&!$.isPlainObject(d))){return error_func.call(this,x,t,"");} d=this._parse_json(d,obj);if(d){if(obj===-1||!obj){this.get_container().children("ul").empty().append(d.children());} -else{obj.append(d).children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree-is-loading");} +else{obj.append(d).children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree_is_loading");} this.clean_node(obj);if(s_call){s_call.call(this);}} else{if(obj===-1||!obj){if(s.correct_state){this.get_container().children("ul").empty();if(s_call){s_call.call(this);}}} -else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree-is-loading");if(s.correct_state){this.correct_state(obj);if(s_call){s_call.call(this);}}}}};s.ajax.context=this;s.ajax.error=error_func;s.ajax.success=success_func;if(!s.ajax.dataType){s.ajax.dataType="json";} +else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree_is_loading");if(s.correct_state){this.correct_state(obj);if(s_call){s_call.call(this);}}}}};s.ajax.context=this;s.ajax.error=error_func;s.ajax.success=success_func;if(!s.ajax.dataType){s.ajax.dataType="json";} if($.isFunction(s.ajax.url)){s.ajax.url=s.ajax.url.call(this,obj);} if($.isFunction(s.ajax.data)){s.ajax.data=s.ajax.data.call(this,obj);} $.ajax(s.ajax);break;}},_parse_json:function(js,obj,is_callback){var d=false,p=this._get_settings(),s=p.json_data,t=p.core.html_titles,tmp,i,j,ul1,ul2;if(!js){return d;} -if(s.progressive_unload&&obj&&obj!==-1){obj.data("jstree-children",d);} +if(s.progressive_unload&&obj&&obj!==-1){obj.data("jstree_children",d);} if($.isArray(js)){d=$();if(!js.length){return false;} for(i=0,j=js.length;i ");if(!m.icon&&js.icon){m.icon=js.icon;} if(m.icon){if(m.icon.indexOf("/")===-1){tmp.children("ins").addClass(m.icon);} else{tmp.children("ins").css("background","url('"+m.icon+"') center center no-repeat");}} -d.append(tmp);});d.prepend(" ");if(js.children){if(s.progressive_render&&js.state!=="open"){d.addClass("jstree-closed").data("jstree-children",js.children);} -else{if(s.progressive_unload){d.data("jstree-children",js.children);} +d.append(tmp);});d.prepend(" ");if(js.children){if(s.progressive_render&&js.state!=="open"){d.addClass("jstree-closed").data("jstree_children",js.children);} +else{if(s.progressive_unload){d.data("jstree_children",js.children);} if($.isArray(js.children)&&js.children.length){tmp=this._parse_json(js.children,obj,true);if(tmp.length){ul2=$("
      ");ul2.append(tmp);d.append(ul2);}}}}} if(!is_callback){ul1=$("
        ");ul1.append(d);d=ul1;} return d;},get_json:function(obj,li_attr,a_attr,is_callback){var result=[],s=this._get_settings(),_this=this,tmp1,tmp2,li,a,t,lang;obj=this._get_node(obj);if(!obj||obj===-1){obj=this.get_container().find("> ul > li");} @@ -399,58 +400,56 @@ else{this.check_node(e.target);} if(this.data.ui&&this.data.checkbox.noui){this.save_selected();if(this.data.cookies){this.save_cookie("select_node");}} else{e.stopImmediatePropagation();return false;}},this));},defaults:{override_ui:false,two_state:false,real_checkboxes:false,checked_parent_open:true,real_checkboxes_names:function(n){return[("check_"+(n[0].id||Math.ceil(Math.random()*10000))),1];}},__destroy:function(){this.get_container().find("input.jstree-real-checkbox").removeClass("jstree-real-checkbox").end().find("ins.jstree-checkbox").remove();},_fn:{_checkbox_notify:function(n,data){if(data.checked){this.check_node(n,false);}},_prepare_checkboxes:function(obj){obj=!obj||obj==-1?this.get_container().find("> ul > li"):this._get_node(obj);if(obj===false){return;} var c,_this=this,t,ts=this._get_settings().checkbox.two_state,rc=this._get_settings().checkbox.real_checkboxes,rcn=this._get_settings().checkbox.real_checkboxes_names;obj.each(function(){t=$(this);c=t.is("li")&&(t.hasClass("jstree-checked")||(rc&&t.children(":checked").length))?"jstree-checked":"jstree-unchecked";t.find("li").andSelf().each(function(){var $t=$(this),nm;$t.children("a"+(_this.data.languages?"":":eq(0)")).not(":has(.jstree-checkbox)").prepend(" ").parent().not(".jstree-checked, .jstree-unchecked").addClass(ts?"jstree-unchecked":c);if(rc){if(!$t.children(":checkbox").length){nm=rcn.call(_this,$t);$t.prepend("");} -else{$t.children(":checkbox").addClass("jstree-real-checkbox");} -if(c==="jstree-checked"){$t.children(":checkbox").attr("checked","checked");}} -if(c==="jstree-checked"&&!ts){$t.find("li").addClass("jstree-checked");}});});if(!ts){if(obj.length===1&&obj.is("li")){this._repair_state(obj);} -if(obj.is("li")){obj.each(function(){_this._repair_state(this);});} -else{obj.find("> ul > li").each(function(){_this._repair_state(this);});} -obj.find(".jstree-checked").parent().parent().each(function(){_this._repair_state(this);});}},change_state:function(obj,state){obj=this._get_node(obj);var coll=false,rc=this._get_settings().checkbox.real_checkboxes;if(!obj||obj===-1){return false;} -state=(state===false||state===true)?state:obj.hasClass("jstree-checked");if(this._get_settings().checkbox.two_state){if(state){obj.removeClass("jstree-checked").addClass("jstree-unchecked");if(rc){obj.children(":checkbox").removeAttr("checked");}} -else{obj.removeClass("jstree-unchecked").addClass("jstree-checked");if(rc){obj.children(":checkbox").attr("checked","checked");}}} +else{$t.children(":checkbox").addClass("jstree-real-checkbox");}} +if(!ts){if(c==="jstree-checked"||$t.hasClass("jstree-checked")||$t.children(':checked').length){$t.find("li").andSelf().addClass("jstree-checked").children(":checkbox").prop("checked",true);}} +else{if($t.hasClass("jstree-checked")||$t.children(':checked').length){$t.addClass("jstree-checked").children(":checkbox").prop("checked",true);}}});});if(!ts){obj.find(".jstree-checked").parent().parent().each(function(){_this._repair_state(this);});}},change_state:function(obj,state){obj=this._get_node(obj);var coll=false,rc=this._get_settings().checkbox.real_checkboxes;if(!obj||obj===-1){return false;} +state=(state===false||state===true)?state:obj.hasClass("jstree-checked");if(this._get_settings().checkbox.two_state){if(state){obj.removeClass("jstree-checked").addClass("jstree-unchecked");if(rc){obj.children(":checkbox").prop("checked",false);}} +else{obj.removeClass("jstree-unchecked").addClass("jstree-checked");if(rc){obj.children(":checkbox").prop("checked",true);}}} else{if(state){coll=obj.find("li").andSelf();if(!coll.filter(".jstree-checked, .jstree-undetermined").length){return false;} -coll.removeClass("jstree-checked jstree-undetermined").addClass("jstree-unchecked");if(rc){coll.children(":checkbox").removeAttr("checked");}} +coll.removeClass("jstree-checked jstree-undetermined").addClass("jstree-unchecked");if(rc){coll.children(":checkbox").prop("checked",false);}} else{coll=obj.find("li").andSelf();if(!coll.filter(".jstree-unchecked, .jstree-undetermined").length){return false;} -coll.removeClass("jstree-unchecked jstree-undetermined").addClass("jstree-checked");if(rc){coll.children(":checkbox").attr("checked","checked");} +coll.removeClass("jstree-unchecked jstree-undetermined").addClass("jstree-checked");if(rc){coll.children(":checkbox").prop("checked",true);} if(this.data.ui){this.data.ui.last_selected=obj;} this.data.checkbox.last_selected=obj;} -obj.parentsUntil(".jstree","li").each(function(){var $this=$(this);if(state){if($this.children("ul").children("li.jstree-checked, li.jstree-undetermined").length){$this.parentsUntil(".jstree","li").andSelf().removeClass("jstree-checked jstree-unchecked").addClass("jstree-undetermined");if(rc){$this.parentsUntil(".jstree","li").andSelf().children(":checkbox").removeAttr("checked");} +obj.parentsUntil(".jstree","li").each(function(){var $this=$(this);if(state){if($this.children("ul").children("li.jstree-checked, li.jstree-undetermined").length){$this.parentsUntil(".jstree","li").andSelf().removeClass("jstree-checked jstree-unchecked").addClass("jstree-undetermined");if(rc){$this.parentsUntil(".jstree","li").andSelf().children(":checkbox").prop("checked",false);} return false;} -else{$this.removeClass("jstree-checked jstree-undetermined").addClass("jstree-unchecked");if(rc){$this.children(":checkbox").removeAttr("checked");}}} -else{if($this.children("ul").children("li.jstree-unchecked, li.jstree-undetermined").length){$this.parentsUntil(".jstree","li").andSelf().removeClass("jstree-checked jstree-unchecked").addClass("jstree-undetermined");if(rc){$this.parentsUntil(".jstree","li").andSelf().children(":checkbox").removeAttr("checked");} +else{$this.removeClass("jstree-checked jstree-undetermined").addClass("jstree-unchecked");if(rc){$this.children(":checkbox").prop("checked",false);}}} +else{if($this.children("ul").children("li.jstree-unchecked, li.jstree-undetermined").length){$this.parentsUntil(".jstree","li").andSelf().removeClass("jstree-checked jstree-unchecked").addClass("jstree-undetermined");if(rc){$this.parentsUntil(".jstree","li").andSelf().children(":checkbox").prop("checked",false);} return false;} -else{$this.removeClass("jstree-unchecked jstree-undetermined").addClass("jstree-checked");if(rc){$this.children(":checkbox").attr("checked","checked");}}}});} +else{$this.removeClass("jstree-unchecked jstree-undetermined").addClass("jstree-checked");if(rc){$this.children(":checkbox").prop("checked",true);}}}});} if(this.data.ui&&this.data.checkbox.noui){this.data.ui.selected=this.get_checked();} this.__callback(obj);return true;},check_node:function(obj){if(this.change_state(obj,false)){obj=this._get_node(obj);if(this._get_settings().checkbox.checked_parent_open){var t=this;obj.parents(".jstree-closed").each(function(){t.open_node(this,false,true);});} this.__callback({"obj":obj});}},uncheck_node:function(obj){if(this.change_state(obj,true)){this.__callback({"obj":this._get_node(obj)});}},check_all:function(){var _this=this,coll=this._get_settings().checkbox.two_state?this.get_container_ul().find("li"):this.get_container_ul().children("li");coll.each(function(){_this.change_state(this,false);});this.__callback();},uncheck_all:function(){var _this=this,coll=this._get_settings().checkbox.two_state?this.get_container_ul().find("li"):this.get_container_ul().children("li");coll.each(function(){_this.change_state(this,true);});this.__callback();},is_checked:function(obj){obj=this._get_node(obj);return obj.length?obj.is(".jstree-checked"):false;},get_checked:function(obj,get_all){obj=!obj||obj===-1?this.get_container():this._get_node(obj);return get_all||this._get_settings().checkbox.two_state?obj.find(".jstree-checked"):obj.find("> ul > .jstree-checked, .jstree-undetermined > ul > .jstree-checked");},get_unchecked:function(obj,get_all){obj=!obj||obj===-1?this.get_container():this._get_node(obj);return get_all||this._get_settings().checkbox.two_state?obj.find(".jstree-unchecked"):obj.find("> ul > .jstree-unchecked, .jstree-undetermined > ul > .jstree-unchecked");},show_checkboxes:function(){this.get_container().children("ul").removeClass("jstree-no-checkboxes");},hide_checkboxes:function(){this.get_container().children("ul").addClass("jstree-no-checkboxes");},_repair_state:function(obj){obj=this._get_node(obj);if(!obj.length){return;} +if(this._get_settings().checkbox.two_state){obj.find('li').andSelf().not('.jstree-checked').removeClass('jstree-undetermined').addClass('jstree-unchecked').children(':checkbox').prop('checked',true);return;} var rc=this._get_settings().checkbox.real_checkboxes,a=obj.find("> ul > .jstree-checked").length,b=obj.find("> ul > .jstree-undetermined").length,c=obj.find("> ul > li").length;if(c===0){if(obj.hasClass("jstree-undetermined")){this.change_state(obj,false);}} else if(a===0&&b===0){this.change_state(obj,true);} else if(a===c){this.change_state(obj,false);} -else{obj.parentsUntil(".jstree","li").andSelf().removeClass("jstree-checked jstree-unchecked").addClass("jstree-undetermined");if(rc){obj.parentsUntil(".jstree","li").andSelf().children(":checkbox").removeAttr("checked");}}},reselect:function(){if(this.data.ui&&this.data.checkbox.noui){var _this=this,s=this.data.ui.to_select;s=$.map($.makeArray(s),function(n){return"#"+n.toString().replace(/^#/,"").replace(/\\\//g,"/").replace(/\//g,"\\\/").replace(/\\\./g,".").replace(/\./g,"\\.").replace(/\:/g,"\\:");});this.deselect_all();$.each(s,function(i,val){_this.check_node(val);});this.__callback();} +else{obj.parentsUntil(".jstree","li").andSelf().removeClass("jstree-checked jstree-unchecked").addClass("jstree-undetermined");if(rc){obj.parentsUntil(".jstree","li").andSelf().children(":checkbox").prop("checked",false);}}},reselect:function(){if(this.data.ui&&this.data.checkbox.noui){var _this=this,s=this.data.ui.to_select;s=$.map($.makeArray(s),function(n){return"#"+n.toString().replace(/^#/,"").replace(/\\\//g,"/").replace(/\//g,"\\\/").replace(/\\\./g,".").replace(/\./g,"\\.").replace(/\:/g,"\\:");});this.deselect_all();$.each(s,function(i,val){_this.check_node(val);});this.__callback();} else{this.__call_old();}},save_loaded:function(){var _this=this;this.data.core.to_load=[];this.get_container_ul().find("li.jstree-closed.jstree-undetermined").each(function(){if(this.id){_this.data.core.to_load.push("#"+this.id);}});}}});$(function(){var css_string='.jstree .jstree-real-checkbox { display:none; } ';$.vakata.css.add_sheet({str:css_string,title:"jstree"});});})(jQuery);(function($){$.vakata.xslt=function(xml,xsl,callback){var rs="",xm,xs,processor,support;if(document.recalc){xm=document.createElement('xml');xs=document.createElement('xml');xm.innerHTML=xml;xs.innerHTML=xsl;$("body").append(xm).append(xs);setTimeout((function(xm,xs,callback){return function(){callback.call(null,xm.transformNode(xs.XMLDocument));setTimeout((function(xm,xs){return function(){$(xm).remove();$(xs).remove();};})(xm,xs),200);};})(xm,xs,callback),100);return true;} if(typeof window.DOMParser!=="undefined"&&typeof window.XMLHttpRequest!=="undefined"&&typeof window.XSLTProcessor==="undefined"){xml=new DOMParser().parseFromString(xml,"text/xml");xsl=new DOMParser().parseFromString(xsl,"text/xml");} if(typeof window.DOMParser!=="undefined"&&typeof window.XMLHttpRequest!=="undefined"&&typeof window.XSLTProcessor!=="undefined"){processor=new XSLTProcessor();support=$.isFunction(processor.transformDocument)?(typeof window.XMLSerializer!=="undefined"):true;if(!support){return false;} xml=new DOMParser().parseFromString(xml,"text/xml");xsl=new DOMParser().parseFromString(xsl,"text/xml");if($.isFunction(processor.transformDocument)){rs=document.implementation.createDocument("","",null);processor.transformDocument(xml,xsl,rs,null);callback.call(null,new XMLSerializer().serializeToString(rs));return true;} else{processor.importStylesheet(xsl);rs=processor.transformToFragment(xml,document);callback.call(null,$("
        ").append(rs).html());return true;}} -return false;};var xsl={'nest':'<'+'?xml version="1.0" encoding="utf-8" ?>'+''+''+''+' '+' '+' '+''+''+' '+' '+''+'','flat':'<'+'?xml version="1.0" encoding="utf-8" ?>'+''+''+''+'
          '+' '+' '+' '+' '+' '+' '+'
        '+'
        '+''+' '+' '+' '+'
      • '+' '+' jstree-last '+' '+' jstree-open '+' jstree-closed '+' jstree-leaf '+' '+' '+' '+' '+' '+' '+' '+' '+'  '+' '+' '+' '+' '+' '+' #'+' '+' '+' '+' '+' '+' '+' '+' '+' '+' '+' jstree-icon '+' '+' '+' background:url() center center no-repeat;'+'  '+' '+' '+' '+' '+' '+'
          '+' '+' '+' '+' '+' '+' '+'
        '+'
        '+'
      • '+'
        '+'
        '},escape_xml=function(string){return string.toString().replace(/&/g,'&').replace(//g,'>').replace(/"/g,'"').replace(/'/g,''');};$.jstree.plugin("xml_data",{defaults:{data:false,ajax:false,xsl:"flat",clean_node:false,correct_state:true,get_skip_empty:false,get_include_preamble:true},_fn:{load_node:function(obj,s_call,e_call){var _this=this;this.load_node_xml(obj,function(){_this.__callback({"obj":_this._get_node(obj)});s_call.call(this);},e_call);},_is_loaded:function(obj){var s=this._get_settings().xml_data;obj=this._get_node(obj);return obj==-1||!obj||(!s.ajax&&!$.isFunction(s.data))||obj.is(".jstree-open, .jstree-leaf")||obj.children("ul").children("li").size()>0;},load_node_xml:function(obj,s_call,e_call){var s=this.get_settings().xml_data,error_func=function(){},success_func=function(){};obj=this._get_node(obj);if(obj&&obj!==-1){if(obj.data("jstree-is-loading")){return;} -else{obj.data("jstree-is-loading",true);}} +return false;};var xsl={'nest':'<'+'?xml version="1.0" encoding="utf-8" ?>'+''+''+''+' '+' '+' '+''+''+' '+' '+''+'','flat':'<'+'?xml version="1.0" encoding="utf-8" ?>'+''+''+''+'
          '+' '+' '+' '+' '+' '+' '+'
        '+'
        '+''+' '+' '+' '+'
      • '+' '+' jstree-last '+' '+' jstree-open '+' jstree-closed '+' jstree-leaf '+' '+' '+' '+' '+' '+' '+' '+' '+'  '+' '+' '+' '+' '+' '+' #'+' '+' '+' '+' '+' '+' '+' '+' '+' '+' '+' jstree-icon '+' '+' '+' background:url() center center no-repeat;'+'  '+' '+' '+' '+' '+' '+'
          '+' '+' '+' '+' '+' '+' '+'
        '+'
        '+'
      • '+'
        '+'
        '},escape_xml=function(string){return string.toString().replace(/&/g,'&').replace(//g,'>').replace(/"/g,'"').replace(/'/g,''');};$.jstree.plugin("xml_data",{defaults:{data:false,ajax:false,xsl:"flat",clean_node:false,correct_state:true,get_skip_empty:false,get_include_preamble:true},_fn:{load_node:function(obj,s_call,e_call){var _this=this;this.load_node_xml(obj,function(){_this.__callback({"obj":_this._get_node(obj)});s_call.call(this);},e_call);},_is_loaded:function(obj){var s=this._get_settings().xml_data;obj=this._get_node(obj);return obj==-1||!obj||(!s.ajax&&!$.isFunction(s.data))||obj.is(".jstree-open, .jstree-leaf")||obj.children("ul").children("li").size()>0;},load_node_xml:function(obj,s_call,e_call){var s=this.get_settings().xml_data,error_func=function(){},success_func=function(){};obj=this._get_node(obj);if(obj&&obj!==-1){if(obj.data("jstree_is_loading")){return;} +else{obj.data("jstree_is_loading",true);}} switch(!0){case(!s.data&&!s.ajax):throw"Neither data nor ajax settings supplied.";case($.isFunction(s.data)):s.data.call(this,obj,$.proxy(function(d){this.parse_xml(d,$.proxy(function(d){if(d){d=d.replace(/ ?xmlns="[^"]*"/ig,"");if(d.length>10){d=$(d);if(obj===-1||!obj){this.get_container().children("ul").empty().append(d.children());} -else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.append(d);obj.removeData("jstree-is-loading");} +else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.append(d);obj.removeData("jstree_is_loading");} if(s.clean_node){this.clean_node(obj);} if(s_call){s_call.call(this);}} -else{if(obj&&obj!==-1){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree-is-loading");if(s.correct_state){this.correct_state(obj);if(s_call){s_call.call(this);}}} +else{if(obj&&obj!==-1){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree_is_loading");if(s.correct_state){this.correct_state(obj);if(s_call){s_call.call(this);}}} else{if(s.correct_state){this.get_container().children("ul").empty();if(s_call){s_call.call(this);}}}}}},this));},this));break;case(!!s.data&&!s.ajax)||(!!s.data&&!!s.ajax&&(!obj||obj===-1)):if(!obj||obj==-1){this.parse_xml(s.data,$.proxy(function(d){if(d){d=d.replace(/ ?xmlns="[^"]*"/ig,"");if(d.length>10){d=$(d);this.get_container().children("ul").empty().append(d.children());if(s.clean_node){this.clean_node(obj);} if(s_call){s_call.call(this);}}} else{if(s.correct_state){this.get_container().children("ul").empty();if(s_call){s_call.call(this);}}}},this));} break;case(!s.data&&!!s.ajax)||(!!s.data&&!!s.ajax&&obj&&obj!==-1):error_func=function(x,t,e){var ef=this.get_settings().xml_data.ajax.error;if(ef){ef.call(this,x,t,e);} -if(obj!==-1&&obj.length){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree-is-loading");if(t==="success"&&s.correct_state){this.correct_state(obj);}} +if(obj!==-1&&obj.length){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree_is_loading");if(t==="success"&&s.correct_state){this.correct_state(obj);}} else{if(t==="success"&&s.correct_state){this.get_container().children("ul").empty();}} if(e_call){e_call.call(this);}};success_func=function(d,t,x){d=x.responseText;var sf=this.get_settings().xml_data.ajax.success;if(sf){d=sf.call(this,d,t,x)||d;} if(d===""||(d&&d.toString&&d.toString().replace(/^[\s\n]+$/,"")==="")){return error_func.call(this,x,t,"");} this.parse_xml(d,$.proxy(function(d){if(d){d=d.replace(/ ?xmlns="[^"]*"/ig,"");if(d.length>10){d=$(d);if(obj===-1||!obj){this.get_container().children("ul").empty().append(d.children());} -else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.append(d);obj.removeData("jstree-is-loading");} +else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.append(d);obj.removeData("jstree_is_loading");} if(s.clean_node){this.clean_node(obj);} if(s_call){s_call.call(this);}} -else{if(obj&&obj!==-1){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree-is-loading");if(s.correct_state){this.correct_state(obj);if(s_call){s_call.call(this);}}} +else{if(obj&&obj!==-1){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree_is_loading");if(s.correct_state){this.correct_state(obj);if(s_call){s_call.call(this);}}} else{if(s.correct_state){this.get_container().children("ul").empty();if(s_call){s_call.call(this);}}}}}},this));};s.ajax.context=this;s.ajax.error=error_func;s.ajax.success=success_func;if(!s.ajax.dataType){s.ajax.dataType="xml";} if($.isFunction(s.ajax.url)){s.ajax.url=s.ajax.url.call(this,obj);} if($.isFunction(s.ajax.data)){s.ajax.data=s.ajax.data.call(this,obj);} @@ -539,28 +538,28 @@ js.attr[s.type_attr]=vc[0];} else{if($.inArray(js.attr[s.type_attr],vc)===-1){return false;}}} if(s.max_children!==-2&&mc!==-1){ch=p===-1?this.get_container().find("> ul > li").length:p.find("> ul > li").length;if(ch+1>mc){return false;}} if(s.max_depth!==-2&&md!==-1&&(md-1)<0){return false;}} -return this.__call_old(true,obj,position,js,callback,is_loaded,skip_check);}}});})(jQuery);(function($){$.jstree.plugin("html_data",{__init:function(){this.data.html_data.original_container_html=this.get_container().find(" > ul > li").clone(true);this.data.html_data.original_container_html.find("li").andSelf().contents().filter(function(){return this.nodeType==3;}).remove();},defaults:{data:false,ajax:false,correct_state:true},_fn:{load_node:function(obj,s_call,e_call){var _this=this;this.load_node_html(obj,function(){_this.__callback({"obj":_this._get_node(obj)});s_call.call(this);},e_call);},_is_loaded:function(obj){obj=this._get_node(obj);return obj==-1||!obj||(!this._get_settings().html_data.ajax&&!$.isFunction(this._get_settings().html_data.data))||obj.is(".jstree-open, .jstree-leaf")||obj.children("ul").children("li").size()>0;},load_node_html:function(obj,s_call,e_call){var d,s=this.get_settings().html_data,error_func=function(){},success_func=function(){};obj=this._get_node(obj);if(obj&&obj!==-1){if(obj.data("jstree-is-loading")){return;} -else{obj.data("jstree-is-loading",true);}} +return this.__call_old(true,obj,position,js,callback,is_loaded,skip_check);}}});})(jQuery);(function($){$.jstree.plugin("html_data",{__init:function(){this.data.html_data.original_container_html=this.get_container().find(" > ul > li").clone(true);this.data.html_data.original_container_html.find("li").andSelf().contents().filter(function(){return this.nodeType==3;}).remove();},defaults:{data:false,ajax:false,correct_state:true},_fn:{load_node:function(obj,s_call,e_call){var _this=this;this.load_node_html(obj,function(){_this.__callback({"obj":_this._get_node(obj)});s_call.call(this);},e_call);},_is_loaded:function(obj){obj=this._get_node(obj);return obj==-1||!obj||(!this._get_settings().html_data.ajax&&!$.isFunction(this._get_settings().html_data.data))||obj.is(".jstree-open, .jstree-leaf")||obj.children("ul").children("li").size()>0;},load_node_html:function(obj,s_call,e_call){var d,s=this.get_settings().html_data,error_func=function(){},success_func=function(){};obj=this._get_node(obj);if(obj&&obj!==-1){if(obj.data("jstree_is_loading")){return;} +else{obj.data("jstree_is_loading",true);}} switch(!0){case($.isFunction(s.data)):s.data.call(this,obj,$.proxy(function(d){if(d&&d!==""&&d.toString&&d.toString().replace(/^[\s\n]+$/,"")!==""){d=$(d);if(!d.is("ul")){d=$("
          ").append(d);} if(obj==-1||!obj){this.get_container().children("ul").empty().append(d.children()).find("li, a").filter(function(){return!this.firstChild||!this.firstChild.tagName||this.firstChild.tagName!=="INS";}).prepend(" ").end().filter("a").children("ins:first-child").not(".jstree-icon").addClass("jstree-icon");} -else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.append(d).children("ul").find("li, a").filter(function(){return!this.firstChild||!this.firstChild.tagName||this.firstChild.tagName!=="INS";}).prepend(" ").end().filter("a").children("ins:first-child").not(".jstree-icon").addClass("jstree-icon");obj.removeData("jstree-is-loading");} +else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.append(d).children("ul").find("li, a").filter(function(){return!this.firstChild||!this.firstChild.tagName||this.firstChild.tagName!=="INS";}).prepend(" ").end().filter("a").children("ins:first-child").not(".jstree-icon").addClass("jstree-icon");obj.removeData("jstree_is_loading");} this.clean_node(obj);if(s_call){s_call.call(this);}} -else{if(obj&&obj!==-1){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree-is-loading");if(s.correct_state){this.correct_state(obj);if(s_call){s_call.call(this);}}} +else{if(obj&&obj!==-1){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree_is_loading");if(s.correct_state){this.correct_state(obj);if(s_call){s_call.call(this);}}} else{if(s.correct_state){this.get_container().children("ul").empty();if(s_call){s_call.call(this);}}}}},this));break;case(!s.data&&!s.ajax):if(!obj||obj==-1){this.get_container().children("ul").empty().append(this.data.html_data.original_container_html).find("li, a").filter(function(){return!this.firstChild||!this.firstChild.tagName||this.firstChild.tagName!=="INS";}).prepend(" ").end().filter("a").children("ins:first-child").not(".jstree-icon").addClass("jstree-icon");this.clean_node();} if(s_call){s_call.call(this);} break;case(!!s.data&&!s.ajax)||(!!s.data&&!!s.ajax&&(!obj||obj===-1)):if(!obj||obj==-1){d=$(s.data);if(!d.is("ul")){d=$("
            ").append(d);} this.get_container().children("ul").empty().append(d.children()).find("li, a").filter(function(){return!this.firstChild||!this.firstChild.tagName||this.firstChild.tagName!=="INS";}).prepend(" ").end().filter("a").children("ins:first-child").not(".jstree-icon").addClass("jstree-icon");this.clean_node();} if(s_call){s_call.call(this);} break;case(!s.data&&!!s.ajax)||(!!s.data&&!!s.ajax&&obj&&obj!==-1):obj=this._get_node(obj);error_func=function(x,t,e){var ef=this.get_settings().html_data.ajax.error;if(ef){ef.call(this,x,t,e);} -if(obj!=-1&&obj.length){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree-is-loading");if(t==="success"&&s.correct_state){this.correct_state(obj);}} +if(obj!=-1&&obj.length){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree_is_loading");if(t==="success"&&s.correct_state){this.correct_state(obj);}} else{if(t==="success"&&s.correct_state){this.get_container().children("ul").empty();}} if(e_call){e_call.call(this);}};success_func=function(d,t,x){var sf=this.get_settings().html_data.ajax.success;if(sf){d=sf.call(this,d,t,x)||d;} if(d===""||(d&&d.toString&&d.toString().replace(/^[\s\n]+$/,"")==="")){return error_func.call(this,x,t,"");} if(d){d=$(d);if(!d.is("ul")){d=$("
              ").append(d);} if(obj==-1||!obj){this.get_container().children("ul").empty().append(d.children()).find("li, a").filter(function(){return!this.firstChild||!this.firstChild.tagName||this.firstChild.tagName!=="INS";}).prepend(" ").end().filter("a").children("ins:first-child").not(".jstree-icon").addClass("jstree-icon");} -else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.append(d).children("ul").find("li, a").filter(function(){return!this.firstChild||!this.firstChild.tagName||this.firstChild.tagName!=="INS";}).prepend(" ").end().filter("a").children("ins:first-child").not(".jstree-icon").addClass("jstree-icon");obj.removeData("jstree-is-loading");} +else{obj.children("a.jstree-loading").removeClass("jstree-loading");obj.append(d).children("ul").find("li, a").filter(function(){return!this.firstChild||!this.firstChild.tagName||this.firstChild.tagName!=="INS";}).prepend(" ").end().filter("a").children("ins:first-child").not(".jstree-icon").addClass("jstree-icon");obj.removeData("jstree_is_loading");} this.clean_node(obj);if(s_call){s_call.call(this);}} -else{if(obj&&obj!==-1){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree-is-loading");if(s.correct_state){this.correct_state(obj);if(s_call){s_call.call(this);}}} +else{if(obj&&obj!==-1){obj.children("a.jstree-loading").removeClass("jstree-loading");obj.removeData("jstree_is_loading");if(s.correct_state){this.correct_state(obj);if(s_call){s_call.call(this);}}} else{if(s.correct_state){this.get_container().children("ul").empty();if(s_call){s_call.call(this);}}}}};s.ajax.context=this;s.ajax.error=error_func;s.ajax.success=success_func;if(!s.ajax.dataType){s.ajax.dataType="html";} if($.isFunction(s.ajax.url)){s.ajax.url=s.ajax.url.call(this,obj);} if($.isFunction(s.ajax.data)){s.ajax.data=s.ajax.data.call(this,obj);} From f03857034d776f8dac51e08b861b179a6bb7abbb Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Jul 2011 20:16:03 +0000 Subject: [PATCH 43/49] Fix: Upgrade detection fails --- htdocs/main.inc.php | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index 0b67548495c..0a44842296f 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -26,7 +26,7 @@ * \file htdocs/main.inc.php * \ingroup core * \brief File that defines environment for Dolibarr pages only (variables not required by scripts) - * \version $Id: main.inc.php,v 1.753 2011/07/08 11:26:40 eldy Exp $ + * \version $Id: main.inc.php,v 1.754 2011/07/12 20:16:03 eldy Exp $ */ @ini_set('memory_limit', '64M'); // This may be useless if memory is hard limited by your PHP @@ -254,12 +254,14 @@ if (! empty($conf->global->MAIN_NOT_INSTALLED) || ! empty($conf->global->MAIN_NO if ((! empty($conf->global->MAIN_VERSION_LAST_UPGRADE) && ($conf->global->MAIN_VERSION_LAST_UPGRADE != DOL_VERSION)) || (empty($conf->global->MAIN_VERSION_LAST_UPGRADE) && ! empty($conf->global->MAIN_VERSION_LAST_INSTALL) && ($conf->global->MAIN_VERSION_LAST_INSTALL != DOL_VERSION))) { - require_once(DOL_DOCUMENT_ROOT ."/lib/admin.lib.php"); - $dolibarrversionlastupgrade=preg_split('/[.-]/',$conf->global->MAIN_VERSION_LAST_UPGRADE); + $versiontocompare=empty($conf->global->MAIN_VERSION_LAST_UPGRADE)?$conf->global->MAIN_VERSION_LAST_INSTALL:$conf->global->MAIN_VERSION_LAST_UPGRADE; + require_once(DOL_DOCUMENT_ROOT ."/lib/admin.lib.php"); + $dolibarrversionlastupgrade=preg_split('/[.-]/',$versiontocompare); $dolibarrversionprogram=preg_split('/[.-]/',DOL_VERSION); - if (versioncompare($dolibarrversionprogram,$dolibarrversionlastupgrade) > 0) // Programs have a version higher than database + $rescomp=versioncompare($dolibarrversionprogram,$dolibarrversionlastupgrade); + if ($rescomp > 0) // Programs have a version higher than database. We did not add "&& $rescomp < 3" because we want upgrade process for build upgrades { - dol_syslog("main.inc: database version ".$conf->global->MAIN_VERSION_LAST_UPGRADE." is lower than programs version ".DOL_VERSION.". Redirect to install page.", LOG_WARNING); + dol_syslog("main.inc: database version ".$versiontocompare." is lower than programs version ".DOL_VERSION.". Redirect to install page.", LOG_WARNING); Header("Location: ".DOL_URL_ROOT."/install/index.php"); exit; } From e31ae9c7a605e9be61be37936ba351a0d6dd888b Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Jul 2011 20:48:08 +0000 Subject: [PATCH 44/49] Fix: Upgrade detection fails --- htdocs/install/check.php | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/htdocs/install/check.php b/htdocs/install/check.php index 2daa2f0285f..0f6034488dd 100644 --- a/htdocs/install/check.php +++ b/htdocs/install/check.php @@ -23,7 +23,7 @@ * \file htdocs/install/check.php * \ingroup install * \brief Test if file conf can be modified and if does not exists, test if install process can create it - * \version $Id$ + * \version $Id: check.php,v 1.83 2011/07/12 20:48:08 eldy Exp $ */ include_once("./inc.php"); @@ -385,10 +385,15 @@ else foreach ($migrationscript as $migarray) { $count++; - $versionfrom=$migarray['from']; - $versionto=$migarray['to']; - $newversionfrom=preg_replace('/(\.[0-9]+)$/i','.*',$versionfrom); - $newversionto=preg_replace('/(\.[0-9]+)$/i','.*',$versionto); + $versionfrom=$migarray['from']; + $versionto=$migarray['to']; + $newversionfrom=preg_replace('/(\.[0-9]+)$/i','.*',$versionfrom); + $newversionto=preg_replace('/(\.[0-9]+)$/i','.*',$versionto); + $dolibarrversionfromarray=preg_split('/[\.-]/',$versionfrom); + $dolibarrversiontoarray=preg_split('/[\.-]/',$versionto); + $version=preg_split('/[\.-]/',DOL_VERSION); + $newversionfrombis=''; + if (versioncompare($dolibarrversiontoarray,$version) < 2) $newversionfrombis='/'.$versionto; print ''.$langs->trans("Upgrade").'
              '.$newversionfrom.' -> '.$newversionto.'
              '; print ''; print $langs->trans("UpgradeDesc"); @@ -396,8 +401,6 @@ else { if (sizeof($dolibarrlastupgradeversionarray) >= 2) // If a database access is available and a version x.y already available { - $dolibarrversionfromarray=preg_split('/[\.-]/',$versionfrom); - $dolibarrversiontoarray=preg_split('/[\.-]/',$versionto); // Now we check if this is the first qualified choice if ($allowupgrade && empty($foundrecommandedchoice) && versioncompare($dolibarrversiontoarray,$dolibarrlastupgradeversionarray) > 0) { From 2d775aed094f1028660ddc2bd83b5e3f724c040d Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Jul 2011 20:52:41 +0000 Subject: [PATCH 45/49] Fix: Upgrade detection fails --- htdocs/install/check.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/install/check.php b/htdocs/install/check.php index 0f6034488dd..9de8cdf662d 100644 --- a/htdocs/install/check.php +++ b/htdocs/install/check.php @@ -23,7 +23,7 @@ * \file htdocs/install/check.php * \ingroup install * \brief Test if file conf can be modified and if does not exists, test if install process can create it - * \version $Id: check.php,v 1.83 2011/07/12 20:48:08 eldy Exp $ + * \version $Id: check.php,v 1.84 2011/07/12 20:52:41 eldy Exp $ */ include_once("./inc.php"); @@ -393,7 +393,7 @@ else $dolibarrversiontoarray=preg_split('/[\.-]/',$versionto); $version=preg_split('/[\.-]/',DOL_VERSION); $newversionfrombis=''; - if (versioncompare($dolibarrversiontoarray,$version) < 2) $newversionfrombis='/'.$versionto; + if (versioncompare($dolibarrversiontoarray,$version) < -2) $newversionfrombis='/'.$versionto; print ''.$langs->trans("Upgrade").'
              '.$newversionfrom.' -> '.$newversionto.'
              '; print ''; print $langs->trans("UpgradeDesc"); From f721e77467c8d7802944133c2ee5e801ef003a29 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Jul 2011 21:07:24 +0000 Subject: [PATCH 46/49] Fix: Type of amount --- .../install/mysql/tables/llx_paiementfourn_facturefourn.sql | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/install/mysql/tables/llx_paiementfourn_facturefourn.sql b/htdocs/install/mysql/tables/llx_paiementfourn_facturefourn.sql index ee7314a82a0..b9ba378d81f 100644 --- a/htdocs/install/mysql/tables/llx_paiementfourn_facturefourn.sql +++ b/htdocs/install/mysql/tables/llx_paiementfourn_facturefourn.sql @@ -17,7 +17,7 @@ -- along with this program; if not, write to the Free Software -- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -- --- $Id$ +-- $Id: llx_paiementfourn_facturefourn.sql,v 1.5 2011/07/12 21:07:24 eldy Exp $ -- =========================================================================== create table llx_paiementfourn_facturefourn @@ -25,5 +25,5 @@ create table llx_paiementfourn_facturefourn rowid integer AUTO_INCREMENT PRIMARY KEY, fk_paiementfourn INTEGER DEFAULT NULL, fk_facturefourn INTEGER DEFAULT NULL, - amount DOUBLE DEFAULT '0' + amount double(24,8) DEFAULT 0 )ENGINE=innodb; \ No newline at end of file From 703a36561af182f5268117ec17e450d5e40a73e6 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Jul 2011 22:03:44 +0000 Subject: [PATCH 47/49] Fix: Add civility for all peopal tables --- htdocs/install/mysql/tables/llx_user.sql | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/htdocs/install/mysql/tables/llx_user.sql b/htdocs/install/mysql/tables/llx_user.sql index 307b3e136e5..28b28aeb762 100644 --- a/htdocs/install/mysql/tables/llx_user.sql +++ b/htdocs/install/mysql/tables/llx_user.sql @@ -17,7 +17,7 @@ -- along with this program; if not, write to the Free Software -- Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. -- --- $Id: llx_user.sql,v 1.8 2011/06/29 10:23:33 eldy Exp $ +-- $Id: llx_user.sql,v 1.9 2011/07/12 22:03:44 eldy Exp $ -- =========================================================================== create table llx_user @@ -33,6 +33,7 @@ create table llx_user pass varchar(32), pass_crypted varchar(128), pass_temp varchar(32), -- temporary password when asked for forget password + civilite varchar(6), name varchar(50), firstname varchar(50), office_phone varchar(20), From 6897356b4b1b9f0a203f61f5254883e498dee1bf Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Jul 2011 22:12:12 +0000 Subject: [PATCH 48/49] Fix: Add civility for all peopal tables --- htdocs/install/mysql/migration/3.0.0-3.1.0.sql | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/htdocs/install/mysql/migration/3.0.0-3.1.0.sql b/htdocs/install/mysql/migration/3.0.0-3.1.0.sql index d345126600d..bad27534494 100755 --- a/htdocs/install/mysql/migration/3.0.0-3.1.0.sql +++ b/htdocs/install/mysql/migration/3.0.0-3.1.0.sql @@ -1,5 +1,5 @@ -- --- $Id: 3.0.0-3.1.0.sql,v 1.78 2011/06/29 17:55:32 eldy Exp $ +-- $Id: 3.0.0-3.1.0.sql,v 1.79 2011/07/12 22:12:12 eldy Exp $ -- -- Be carefull to requests order. -- This file must be loaded by calling /install/index.php page @@ -440,3 +440,5 @@ ALTER TABLE llx_user ADD signature text DEFAULT NULL AFTER email; ALTER TABLE llx_don ADD phone_mobile varchar(24) after email; ALTER TABLE llx_don ADD phone varchar(24) after email; + +ALTER TABLE llx_user ADD civilite varchar(6) after entity; From 7cf2caec7e90030a0feb9365064a637b60340989 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 12 Jul 2011 22:19:02 +0000 Subject: [PATCH 49/49] Fix: Attachment fails if content was empty --- htdocs/includes/smtps/SMTPs.php | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/htdocs/includes/smtps/SMTPs.php b/htdocs/includes/smtps/SMTPs.php index f9767191c1a..ba174acec0a 100644 --- a/htdocs/includes/smtps/SMTPs.php +++ b/htdocs/includes/smtps/SMTPs.php @@ -32,11 +32,11 @@ * * @author Walter Torres [with a *lot* of help!] * - * @version $Revision$ + * @version $Revision: 1.15 $ * @copyright copyright information * @license GNU General Public Licence * - * $Id$ + * $Id: SMTPs.php,v 1.15 2011/07/12 22:19:02 eldy Exp $ * **/ @@ -1918,8 +1918,8 @@ class SMTPs */ function setBodyContent ( $strContent, $strType = 'plain' ) { - if ( $strContent ) - { + //if ( $strContent ) + //{ if ( $strType == 'html' ) $strMimeType = 'text/html'; else @@ -1937,7 +1937,7 @@ class SMTPs if ( $this->getMD5flag() ) $this->_msgContent[$strType]['md5'] = md5($strContent); - } + //} } /** @@ -2520,7 +2520,10 @@ class SMTPs // ** CSV Version Control Info /** - * $Log$ + * $Log: SMTPs.php,v $ + * Revision 1.15 2011/07/12 22:19:02 eldy + * Fix: Attachment fails if content was empty + * * Revision 1.14 2011/06/20 23:17:50 hregis * Fix: use best structure of mail *