Changeset 14335
- Timestamp:
- 01/09/08 17:07:17 (9 months ago)
- Files:
-
- trunk/midcom/com.magnettechnologies.contactgrabber/lib/gmail/libgmailer.php (modified) (1 diff)
- trunk/midcom/com.magnettechnologies.contactgrabber/lib/hotmail/msn_contact_grab.class.php (modified) (1 diff)
- trunk/midcom/com.magnettechnologies.contactgrabber/lib/myspace/grabMyspace.class.php (modified) (1 diff)
- trunk/midcom/com.magnettechnologies.contactgrabber/lib/orkut/grabOrkut.class.php (modified) (1 diff)
- trunk/midcom/com.magnettechnologies.contactgrabber/lib/rediff/grabRediff.class.php (modified) (1 diff)
- trunk/midcom/com.magnettechnologies.contactgrabber/lib/yahoo/class.GrabYahoo.php (modified) (1 diff)
- trunk/midcom/com.magnettechnologies.contactgrabber/lib/yahoo/config.php (modified) (1 diff)
- trunk/midcom/de.bitfolge.feedcreator/feedcreator.php (modified) (2 diffs)
- trunk/midcom/midcom.admin.styleeditor/admin.php (modified) (2 diffs)
- trunk/midcom/midcom.core/midcom/application.php (modified) (21 diffs)
- trunk/midcom/midcom.core/midcom/baseclasses/components/request.php (modified) (2 diffs)
- trunk/midcom/midcom.core/midcom/exec/about.php (modified) (1 diff)
- trunk/midcom/midcom.core/midcom/exec/config-test.php (modified) (3 diffs)
- trunk/midcom/midcom.core/midcom/exec/convert_legacy_metadata.php (modified) (4 diffs)
- trunk/midcom/midcom.core/midcom/exec/convert_legacy_topics.php (modified) (1 diff)
- trunk/midcom/midcom.core/midcom/exec/cron.php (modified) (1 diff)
- trunk/midcom/midcom.core/midcom/exec/index-legacy-attachments.php (modified) (3 diffs)
- trunk/midcom/midcom.core/midcom/helper/metadata.php (modified) (1 diff)
- trunk/midcom/midcom.core/midcom/request.php (modified) (9 diffs)
- trunk/midcom/midcom.core/midcom/services/auth.php (modified) (2 diffs)
- trunk/midcom/midcom.core/support/importStyle.php (modified) (11 diffs)
- trunk/midcom/midcom.helper.datamanager/datatype.php (modified) (1 diff)
- trunk/midcom/midcom.helper.datamanager/lib_markdown.php (modified) (28 diffs)
- trunk/midcom/midcom.helper.datamanager/widget_account.php (modified) (1 diff)
- trunk/midcom/midcom.helper.datamanager2/type/select.php (modified) (1 diff)
- trunk/midcom/midgard.admin.sitegroup/bin/create-host.php (modified) (1 diff)
- trunk/midcom/midgard.admin.sitegroup/bin/create-sitegroup.php (modified) (1 diff)
- trunk/midcom/midgard.admin.sitegroup/creation/host.php (modified) (2 diffs)
- trunk/midcom/midgard.admin.sitewizard/sitetemplate.php (modified) (1 diff)
- trunk/midcom/net.nehmer.account/plugins/midgard_admin_sitewizard_plugin.php (modified) (1 diff)
- trunk/midcom/net.nehmer.markdown/lib/markdown.php (modified) (5 diffs)
- trunk/midcom/net.nemein.rss/feed.php (modified) (1 diff)
- trunk/midcom/net.nemein.teams/plugins/midgard_admin_sitewizard_plugin.php (modified) (1 diff)
- trunk/midcom/net.nemein.wiki/link.php (modified) (1 diff)
- trunk/midcom/no.bergfald.rcs/backends/aegir_rcs_functions.php (modified) (1 diff)
- trunk/midcom/no.bergfald.rcs/backends/nemein_rcs_functions.php (modified) (1 diff)
- trunk/midcom/no.odindata.quickform2/emailgenerator.php (modified) (1 diff)
- trunk/midcom/org.openpsa.directmarketing/support/link_detector.php (modified) (2 diffs)
- trunk/midcom/org.openpsa.documents/document_midcomdba.php (modified) (1 diff)
- trunk/midcom/org.openpsa.helpers/array2code.php (modified) (1 diff)
- trunk/midcom/org.openpsa.helpers/dm_savecancel.php (modified) (1 diff)
- trunk/midcom/org.openpsa.helpers/resources.php (modified) (1 diff)
- trunk/midcom/org.openpsa.helpers/schema_modifier.php (modified) (1 diff)
- trunk/midcom/org.openpsa.helpers/sprint_r.php (modified) (1 diff)
- trunk/midcom/org.openpsa.helpers/task_groups.php (modified) (1 diff)
- trunk/midcom/org.openpsa.helpers/tasks.php (modified) (1 diff)
- trunk/midcom/org.openpsa.helpers/workgroups.php (modified) (1 diff)
- trunk/midcom/org.openpsa.sales/sort_helper.php (modified) (1 diff)
- trunk/midcom/org.routamc.photostream/midcom/interfaces.php (modified) (1 diff)
- trunk/midcom/org.routamc.photostream/phpFlickr.php (modified) (1 diff)
- trunk/midcom/se.anykey.mmslib/mmslib.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/midcom/com.magnettechnologies.contactgrabber/lib/gmail/libgmailer.php
r14329 r14335 1 1 <?php 2 /** 3 * @package com.magnettechnologies.contactgrabber 4 */ 2 5 3 6 /** trunk/midcom/com.magnettechnologies.contactgrabber/lib/hotmail/msn_contact_grab.class.php
r11471 r14335 1 1 <?php 2 /** 3 * @package com.magnettechnologies.contactgrabber 4 */ 2 5 3 6 /* trunk/midcom/com.magnettechnologies.contactgrabber/lib/myspace/grabMyspace.class.php
r14328 r14335 1 1 <?php 2 /** 3 * @package com.magnettechnologies.contactgrabber 4 */ 2 5 3 6 /** trunk/midcom/com.magnettechnologies.contactgrabber/lib/orkut/grabOrkut.class.php
r14328 r14335 1 1 <?php 2 /** 3 * @package com.magnettechnologies.contactgrabber 4 */ 2 5 3 6 /** trunk/midcom/com.magnettechnologies.contactgrabber/lib/rediff/grabRediff.class.php
r14328 r14335 1 1 <?php 2 /** 3 * @package com.magnettechnologies.contactgrabber 4 */ 2 5 3 6 /** trunk/midcom/com.magnettechnologies.contactgrabber/lib/yahoo/class.GrabYahoo.php
r14328 r14335 1 1 <?php 2 /** 3 * @package com.magnettechnologies.contactgrabber 4 */ 2 5 3 6 /** trunk/midcom/com.magnettechnologies.contactgrabber/lib/yahoo/config.php
r14328 r14335 1 1 <?php 2 /** 3 * @package com.magnettechnologies.contactgrabber 4 */ 2 5 3 6 /** trunk/midcom/de.bitfolge.feedcreator/feedcreator.php
r14328 r14335 1 1 <?php 2 /** 3 * @package de.bitfolge.feedcreator 4 */ 2 5 /*************************************************************************** 3 6 … … 113 116 114 117 115 @package de.bitfolge.feedcreator 118 116 119 ***************************************************************************/ 117 120 trunk/midcom/midcom.admin.styleeditor/admin.php
r14329 r14335 16 16 /** 17 17 * the current topic we are in 18 * 18 * 19 19 * @var current_topic 20 20 * @access public 21 21 */ 22 22 var $_current_topic = 0; 23 23 24 24 /** 25 * pointer to midcom_session_object 25 * pointer to midcom_session_object 26 26 */ 27 27 var $_session = null; … … 312 312 * This overrides the basic show method of the class to include the ais style around the component. 313 313 * 314 * @see _on_show() ;314 * @see _on_show() 315 315 */ 316 316 function show() trunk/midcom/midcom.core/midcom/application.php
r14329 r14335 368 368 * @var string 369 369 * @access private 370 * @see midcom_application::get_host_prefix();370 * @see get_host_prefix() 371 371 */ 372 372 private $_cached_host_prefix = ''; … … 377 377 * @var string 378 378 * @access private 379 * @see midcom_application::get_page_prefix();379 * @see get_page_prefix() 380 380 */ 381 381 private $_cached_page_prefix = ''; … … 386 386 * @var string 387 387 * @access private 388 * @see midcom_application::get_host_name();388 * @see get_host_name() 389 389 */ 390 390 private $_cached_host_name = ''; … … 545 545 * This function must be called before any output starts. 546 546 * 547 * @see midcom_application::_process()547 * @see _process() 548 548 */ 549 549 public function codeinit() … … 1011 1011 if (!$path) 1012 1012 { 1013 $path = 'midcom.core.nullcomponent'; 1013 $path = 'midcom.core.nullcomponent'; 1014 1014 debug_add("No component defined for this node.", MIDCOM_LOG_ERROR); 1015 1015 debug_print_r("Root node:",$object,MIDCOM_LOG_DEBUG); … … 1569 1569 * @param int $param1 See get_context_data() 1570 1570 * @param int $param2 See get_context_data() 1571 * @see midcom_application::get_context_data()1571 * @see get_context_data() 1572 1572 * @access private 1573 1573 */ … … 1638 1638 * @param mixed $value The value to store. (This is stored by-reference!) 1639 1639 * @param int $contextid The context to associated this data with (defaults to the current context) 1640 * @see midcom_application::get_custom_context_data()1640 * @see get_custom_context_data() 1641 1641 */ 1642 1642 function set_custom_context_data ($key, &$value, $contextid = null) { … … 1665 1665 * @param int $param2 See get_context_data() 1666 1666 * @return mixed The requested value, which is returned by Reference! 1667 * @see midcom_application::get_context_data()1668 * @see midcom_application::set_custom_context_data()1667 * @see get_context_data() 1668 * @see set_custom_context_data() 1669 1669 */ 1670 1670 function & get_custom_context_data($param1, $param2 = null) … … 1733 1733 * 1734 1734 * @param string $newsub The substyle to append. 1735 * @see midcom_application::substyle_prepend()1735 * @see substyle_prepend() 1736 1736 */ 1737 1737 function substyle_append ($newsub) … … 1767 1767 * 1768 1768 * @param string $newsub The substyle to prepend. 1769 * @see midcom_application::substyle_append()1769 * @see substyle_append() 1770 1770 */ 1771 1771 function substyle_prepend($newsub) … … 2551 2551 * @param string $url The URL to the file to-be referenced. 2552 2552 * @param boolean $prepend Whether to add the JS include to beginning of includes 2553 * @see midcom_application::add_jscript();2554 * @see midcom_application::add_jsonload();2555 * @see midcom_application::print_jscripts();2556 * @see midcom_application::print_jsonload();2553 * @see add_jscript() 2554 * @see add_jsonload() 2555 * @see print_jscripts() 2556 * @see print_jsonload() 2557 2557 */ 2558 2558 function add_jsfile($url, $prepend = false) … … 2605 2605 * 2606 2606 * @param string $script The code to be included directly in the page. 2607 * @see midcom_application::add_jsfile();2608 * @see midcom_application::add_jsonload();2609 * @see midcom_application::print_jscripts();2610 * @see midcom_application::print_jsonload();2607 * @see add_jsfile() 2608 * @see add_jsonload() 2609 * @see print_jscripts() 2610 * @see print_jsonload() 2611 2611 */ 2612 2612 function add_jscript($script, $defer = '', $prepend = false) … … 2634 2634 * @param string $script The code to be included in the state. 2635 2635 * @param string $state The state where to include the code to. Defaults to document.ready 2636 * @see midcom_application::print_jquery_statuses();2636 * @see print_jquery_statuses() 2637 2637 */ 2638 2638 function add_jquery_state_script($script, $state = 'document.ready') … … 2658 2658 * @param string $script The input between the <object></object> tags. 2659 2659 * @param array $attributes Array of attribute=> value pairs to be placed in the tag. 2660 * @see midcom_application::print_head();2660 * @see print_head() 2661 2661 * 2662 2662 */ … … 2677 2677 * 2678 2678 * @param array $attributes Array of attribute=> value pairs to be placed in the tag. 2679 * @see midcom_application::print_head();2679 * @see print_head() 2680 2680 */ 2681 2681 function add_meta_head($attributes = null) … … 2696 2696 * @param string $script The input between the <style></style> tags. 2697 2697 * @param array $attributes Array of attribute=> value pairs to be placed in the tag. 2698 * @see midcom_application::print_head();2698 * @see print_head() 2699 2699 */ 2700 2700 function add_style_head($script, $attributes = null) … … 2720 2720 * 2721 2721 * @param array $attributes Array of attribute=> value pairs to be placed in the tag. 2722 * @see midcom_application::print_head();2722 * @see print_head() 2723 2723 */ 2724 2724 function add_link_head( $attributes = null ) … … 2791 2791 * 2792 2792 * @param string $method The name of the method to be called on page startup, including parameters but excluding the ';'. 2793 * @see midcom_application::add_jsfile();2794 * @see midcom_application::add_jscript();2795 * @see midcom_application::print_jscripts();2796 * @see midcom_application::print_jsonload();2793 * @see add_jsfile() 2794 * @see add_jscript() 2795 * @see print_jscripts() 2796 * @see print_jsonload() 2797 2797 */ 2798 2798 function add_jsonload($method) … … 2831 2831 * </code> 2832 2832 * 2833 * @see midcom_application::add_jsfile();2834 * @see midcom_application::add_jscript();2835 * @see midcom_application::add_jsonload();2836 * @see midcom_application::print_jscripts();2833 * @see add_jsfile() 2834 * @see add_jscript() 2835 * @see add_jsonload() 2836 * @see print_jscripts() 2837 2837 */ 2838 2838 function print_jsonload() … … 2859 2859 * cases. 2860 2860 * 2861 * @see midcom_application::add_link_head2862 * @see midcom_application::add_object_head2863 * @see midcom_application::add_style_head2864 * @see midcom_application::add_meta_head2865 * @see midcom_application::add_jsfile();2866 * @see midcom_application::add_jscript();2861 * @see add_link_head 2862 * @see add_object_head 2863 * @see add_style_head 2864 * @see add_meta_head 2865 * @see add_jsfile() 2866 * @see add_jscript() 2867 2867 */ 2868 2868 function print_head_elements() … … 2936 2936 * This method is called from print_head_elements method. 2937 2937 * 2938 * @see midcom_application::add_jquery_state_script2939 * @see midcom_application::print_head_elements2938 * @see add_jquery_state_script 2939 * @see print_head_elements 2940 2940 */ 2941 2941 function print_jquery_statuses() trunk/midcom/midcom.core/midcom/baseclasses/components/request.php
r14329 r14335 636 636 * @param Array $argv The argument list 637 637 * @return boolean Indicating whether the request was handled successfully. 638 * @see _on_handle() ;638 * @see _on_handle() 639 639 */ 640 640 public function handle($argc, $argv) … … 770 770 * handler will not be called. 771 771 * 772 * @see _on_show() ;772 * @see _on_show() 773 773 */ 774 774 public function show() trunk/midcom/midcom.core/midcom/exec/about.php
r6116 r14335 71 71 && class_exists('midgard_quota')) 72 72 { 73 $qb = new midgard_query_builder('midgard_quota');73 $qb = new MidgardQueryBuilder('midgard_quota'); 74 74 $qb->add_constraint('tablename', '=', 'wholesg'); 75 75 $qb->add_constraint('typename', '=', ''); trunk/midcom/midcom.core/midcom/exec/config-test.php
r14130 r14335 147 147 148 148 // Some helpers 149 $i18n =& $_MIDCOM->get_service('i18n'); 149 $i18n =& $GLOBALS['midcom']->get_service('i18n'); 150 151 // Check the PHP Version and PHP_Compat availability 150 152 151 153 $version = phpversion(); 152 if (version_compare($version, '5.1.0', '<')) 153 { 154 println('PHP Version', ERROR, 'PHP 5.1.0 or greater is required for MidCOM, 4.3.0 or greater is recommended.'); 154 if (version_compare($version, '4.1.0', '<')) 155 { 156 println('PHP Version', ERROR, 'PHP 4.1.0 or greater is required for MidCOM, 4.3.0 or greater is recommended.'); 157 } 158 else if (version_compare($version, '4.3.0', '<')) 159 { 160 println('PHP Version', WARNING, 'PHP 4.3.0 or greater is recommended for MidCOM.'); 161 println_check_for_include_file('PHP/Compat.php', 'PEAR Package: PHP_Compat', 162 ERROR, 'The PEAR Package PHP_Compat is required for pre-4.3.0 installations.'); 155 163 } 156 164 else … … 301 309 if ($overload != '7') 302 310 { 303 println('Multi-Byte String functions', WARNING, 'The Multi-Byte String functions are available, but this is a UTF-8 site and Function overloading is disabled, this is not recommended since string operations are erronous then.');311 println('Multi-Byte String functions', WARNING, 'The Multi-Byte String functions are available, but this is an UTF-8 site and Function overloading is disabled, this is not recommended since string operations are erronous then.'); 304 312 } 305 313 else … … 387 395 if ($result != 0) 388 396 { 389 println('External Utility: ImageMagick', ERROR, 'The exist ence ImageMagick toolkit could not be verified, it is required for all kinds of image processing in MidCOM.');397 println('External Utility: ImageMagick', ERROR, 'The existance ImageMagick toolkit could not be verified, it is required for all kinds of image processing in MidCOM.'); 390 398 } 391 399 else trunk/midcom/midcom.core/midcom/exec/convert_legacy_metadata.php
r14328 r14335 23 23 if (! $midgard->admin) 24 24 { 25 $ _MIDCOM->generate_error(MIDCOM_ERRAUTH, "This script requires admin privileges to run.");25 $GLOBALS['midcom']->generate_error(MIDCOM_ERRAUTH, "This script requires admin privileges to run."); 26 26 // This will exit. 27 27 } … … 79 79 if (! $person) 80 80 { 81 status ("<span style='color:red;'> Article {$article->id} had a broken approver id {$person->approver} (using current user as fallback): " . mgderrstr() . '</span>');81 status ("<span style='color:red;'> Article {$article->id} had an broken approver id {$person->approver} (using current user as fallback): " . mgderrstr() . '</span>'); 82 82 $person = mgd_get_person($midgard->user); 83 83 } … … 342 342 { 343 343 echo "</pre>\n"; 344 $ _MIDCOM->generate_error(MIDCOM_ERRCRIT, "Failed to list the child nodes of {$nodeid}. Aborting.");344 $GLOBALS['midcom']->generate_error(MIDCOM_ERRCRIT, "Failed to list the child nodes of {$nodeid}. Aborting."); 345 345 } 346 346 $nodes = array_merge($nodes, $childs); … … 352 352 echo "\n\nData Conversion complete.\n\n"; 353 353 echo "\n\nInvalidating the Content Cache...\n\n"; 354 $ _MIDCOM->cache->invalidate_all();354 $GLOBALS['midcom']->cache->invalidate_all(); 355 355 echo '</pre>'; 356 356 trunk/midcom/midcom.core/midcom/exec/convert_legacy_topics.php
r4908 r14335 14 14 */ 15 15 $_MIDCOM->auth->require_admin_user(); 16 17 @ini_set('max_execution_time', 0); 16 18 17 19 $qb = midcom_db_topic::new_query_builder(); trunk/midcom/midcom.core/midcom/exec/cron.php
r13403 r14335 19 19 } 20 20 21 $_MIDCOM->cache->content->enable_live_mode(); 22 21 23 header('Content-Type: text/plain'); 22 24 23 25 require(MIDCOM_ROOT . '/midcom/services/cron.php'); 24 25 $_MIDCOM->cache->content->enable_live_mode();26 26 27 27 // Ensure cron doesn't timeout trunk/midcom/midcom.core/midcom/exec/index-legacy-attachments.php
r14084 r14335 11 11 * varibales, recognized by their data_ name prefix. 12 12 * - Any blob/image type attachments, recognized by some of their parameters. 13 * - Any leaves a ssociated with net.siriux.photos topics are skipped completely.13 * - Any leaves accociated with net.siriux.photos topics are skipped completly. 14 14 * 15 15 * NAP will used to traverse the registered topic tree, indexing all attachments … … 20 20 * <i>Handle with care!</i> This handler unconditionally indexes all attachments 21 21 * found and not filtered along the above conditions. This might lead to attachments 22 * be ing indexed accidentially or, which is even worse, already indexed attachments23 * be ing overwritten, loosing additional information that might be present.22 * beeing indexed accidentially or, which is even worse, already indexed attachments 23 * beeing overwritten, loosing additional information that might be present. 24 24 * 25 25 * @package midcom … … 119 119 if (is_null($leaf[MIDCOM_NAV_OBJECT])) 120 120 { 121 debug_add("The leaf {$leafid} does not have an a ssociated MidgardObject, skipping it.", MIDCOM_LOG_INFO);121 debug_add("The leaf {$leafid} does not have an accociated MidgardObject, skipping it.", MIDCOM_LOG_INFO); 122 122 debug_print_r('Leaf strucuture dump:', $leaf); 123 123 continue; trunk/midcom/midcom.core/midcom/helper/metadata.php
r14329 r14335 153 153 * slightly post-processed metadata values. See _retrieve_value for post processing. 154 154 * 155 * @see midcom_helper_metdata::_retrieve_value() ;155 * @see midcom_helper_metdata::_retrieve_value() 156 156 * @param string $key The key to retrieve 157 157 * @return mixed The key's value. trunk/midcom/midcom.core/midcom/request.php
r14328 r14335 58 58 /** 59 59 * This one is thrown if the url does not map to anything 60 * 61 * @package midcom 60 62 */ 61 63 class midcom_url_notfound_exception extends Exception { } … … 66 68 * 67 69 * 70 * @package midcom 68 71 */ 69 72 class midcom_urlparserfactory { … … 101 104 /** 102 105 * Implements a simple representation of the url as a stack 106 * 107 * @package midcom 103 108 */ 104 109 class midcom_url_urlstack … … 128 133 * This class is used to collect information to be used when executing the 129 134 * request 135 * 136 * @package midcom 130 137 */ 131 138 class midcom_url_paramcollector { … … 214 221 * The parser will get in the url where its work starts and will work greedily on that 215 222 * until it gets nothing and returns. 223 * 224 * @package midcom 216 225 */ 217 226 abstract class midcom_url_parser { … … 241 250 * variable above. 242 251 * 252 * @package midcom 243 253 */ 244 254 class midcom_url_nullparser extends midcom_url_parser … … 247 257 } 248 258 259 /** 260 * @package midcom 261 */ 249 262 class midcom_url_topicgetter { 250 263 public function get_topic($topic_name, $up) { … … 255 268 /** 256 269 * This class parses any part of the url that is deemed to be related to topics 270 * 271 * @package midcom 257 272 */ 258 273 class midcom_url_topic extends midcom_url_parser … … 296 311 * /midcom-substyle 297 312 * etc 313 * 314 * @package midcom 298 315 */ 299 316 class midcom_url_midcom extends midcom_url_parser { trunk/midcom/midcom.core/midcom/services/auth.php
r14329 r14335 434 434 * @var int 435 435 * @access private 436 * @see request_sudo() ;437 * @see drop_sudo() ;436 * @see request_sudo() 437 * @see drop_sudo() 438 438 */ 439 439 var $_component_sudo = 0; … … 1401 1401 $sitegroup->name = 'SG0'; 1402 1402 } 1403 1403 1404 1404 if (!isset($_SERVER['PHP_AUTH_USER'])) 1405 1405 { trunk/midcom/midcom.core/support/importStyle.php
r4470 r14335 24 24 'default' => 'midgard', 25 25 ); 26 27 26 27 28 28 29 29 $args = Console_Getargs::factory($opts_config); … … 46 46 mgd_config_init($args->getValue('configuration')); 47 47 } 48 48 49 49 function run () { 50 50 $dir = $this->args->getValue(CONSOLE_GETARGS_PARAMS); … … 52 52 die("$dir is not a directory.Exiting...\n"); 53 53 } 54 54 55 55 $name = basename($dir); 56 56 $style_name = "template_{$name}"; … … 82 82 83 83 echo "Installing template: " . $style->name ; 84 84 85 85 $files = dir($dir); 86 86 $elements = array(); … … 89 89 $path = pathinfo($file); 90 90 if ($path['extension'] == 'php') { 91 91 92 92 $elements[] = str_replace('.php', '', $path['basename']); 93 93 } else { … … 101 101 102 102 echo "Remember that you have to clear the midgard pagecache to see effects!\n"; 103 103 104 104 } 105 105 … … 109 109 $file = $dir . "/" . $element_name . ".php"; 110 110 if (!is_file($file) || ! is_readable($file)) { 111 die("$file is not access able!\n");111 die("$file is not accessible!\n"); 112 112 } 113 113 … … 133 133 else 134 134 { 135 135 136 136 $element = $elements[0]; 137 137 // check if there is a newer version in the db. 138 138 $date = strtotime ( $element->metadata->revised ) ; 139 140 //YYYY-MM-DDThh:mm:ss 139 140 //YYYY-MM-DDThh:mm:ss 141 141 $file_date = filemtime($file); 142 142 if ($date > $file_date && !$this->pompt("Do you want to overwrite the current $element_name element?", false ) ) { … … 163 163 } 164 164 $fp = fopen('php://stdin', 'r'); 165 165 166 166 while (true) { 167 167 echo $question, " ", $defaultStr, ": "; 168 168 $response = trim(fgets($fp, 8192)); 169 169 170 170 if (!is_null($default) AND $response == '') { 171 171 return $default; 172 172 } 173 173 174 174 switch (strtolower($response)) { 175 175 case 'y': … … 178 178 case 'true': 179 179 return true; 180 180 181 181 case 'n': 182 182 case '0': … … 184 184 case 'false': 185 185 return false; 186 186 187 187 default: 188 188 continue; 189 189 } 190 } 190 } 191 191 } 192 192 trunk/midcom/midcom.helper.datamanager/datatype.php
r14329 r14335 345 345 * @return mixed The default ("empty") value for the widget. 346 346 * @access private 347 * @see midcom_helper_datamanager_datatype::_get_empty_value() ;347 * @see midcom_helper_datamanager_datatype::_get_empty_value() 348 348 */ 349 349 function _get_default_value() trunk/midcom/midcom.helper.datamanager/lib_markdown.php
r666 r14335 1 1 <?php 2 2 /** 3 * @package midcom.helper.datamanager 4 * @author The Midgard Project, http://www.midgard-project.org 5 * @copyright The Midgard Project, http://www.midgard-project.org 6 * @license http://www.gnu.org/licenses/lgpl.html GNU Lesser General Public License 7 */ 8 9 /** 10 * 11 */ 3 12 # 4 13 # Markdown - A text-to-HTML conversion tool for web writers 5 14 # 6 # Copyright (c) 2004 John Gruber 15 # Copyright (c) 2004 John Gruber 7 16 # <http://daringfireball.net/projects/markdown/> 8 17 # 9 # Copyright (c) 2004 Michel Fortin - PHP Port 18 # Copyright (c) 2004 Michel Fortin - PHP Port 10 19 # <http://www.michelf.com/projects/php-markdown/> 11 20 # … … 14 23 global $MarkdownPHPVersion, $MarkdownSyntaxVersion, 15 24 $md_empty_element_suffix, $md_tab_width, 16 $md_nested_brackets_depth, $md_nested_brackets, 17 $md_escape_table, $md_backslash_escape_table, 25 $md_nested_brackets_depth, $md_nested_brackets, 26 $md_escape_table, $md_backslash_escape_table, 18 27 $md_list_level; 19 28 … … 92 101 93 102 # Regex to match balanced [brackets]. 94 # Needed to insert a maximum bracke ddepth while converting to PHP.103 # Needed to insert a maximum bracket depth while converting to PHP. 95 104 $md_nested_brackets_depth = 6; 96 $md_nested_brackets = 105 $md_nested_brackets = 97 106 str_repeat('(?>[^\[\]]+|\[', $md_nested_brackets_depth). 98 107 str_repeat('\])*', $md_nested_brackets_depth); … … 279 288 <(hr) # start tag = $2 280 289 \b # word break 281 ([^<>])*? # 290 ([^<>])*? # 282 291 /?> # the matching end tag 283 292 [ \t]* … … 334 343 '{^[ ]{0,2}([ ]? -[ ]?){3,}[ \t]*$}mx', 335 344 '{^[ ]{0,2}([ ]? _[ ]?){3,}[ \t]*$}mx'), 336 "\n<hr$md_empty_element_suffix\n", 345 "\n<hr$md_empty_element_suffix\n", 337 346 $text); 338 347 … … 486 495 $title = $md_titles[$link_id]; 487 496 $title = str_replace(array('*', '_'), 488 array($md_escape_table['*'], 497 array($md_escape_table['*'], 489 498 $md_escape_table['_']), $title); 490 499 $result .= " title=\"$title\""; … … 506 515 # We've got to encode these to avoid conflicting with italics/bold. 507 516 $url = str_replace(array('*', '_'), 508 array($md_escape_table['*'], $md_escape_table['_']), 517 array($md_escape_table['*'], $md_escape_table['_']), 509 518 $url); 510 519 $result = "<a href=\"$url\""; … … 516 525 $result .= " title=\"$title\""; 517 526 } 518 527 519 528 $result .= ">$link_text</a>"; 520 529 … … 544 553 545 554 ) 546 }xs', 555 }xs', 547 556 '_DoImages_reference_callback', $text); 548 557 … … 594 603 $title = $md_titles[$link_id]; 595 604 $title = str_replace(array('*', '_'), 596 array($md_escape_table['*'], 605 array($md_escape_table['*'], 597 606 $md_escape_table['_']), $title); 598 607 $result .= " title=\"$title\"";
