Changes in / [2902:2904]


Ignore:
Location:
/after-the-deadline/trunk
Files:
14 edited

Legend:

Unmodified
Added
Removed
  • /after-the-deadline/trunk/after-the-deadline.php

    r2902 r2904  
    44Plugin URI: http://gaut.am/bbpress/plugins/after-the-deadline/ 
    55Description: After the Deadline plugin checks spelling, style, and grammar in your bbPress forum posts. 
    6 Version: 1.6.1 
     6Version: 1.7 
    77Author: Gautam Gupta 
    8 Author URI: http://gaut.am/ 
     8Author URI: http://www.cyberfundu.com/ 
    99*/ 
    1010 
     
    2424 * Defines 
    2525 */ 
    26 define( 'ATD_VER'               , '1.6.1'                                               ); /** Version */ 
     26define( 'ATD_VER'               , '1.7'                                                 ); /** Version */ 
    2727define( 'ATD_OPTIONS'           , 'AftertheDeadline'                                    ); /** Option Name */ 
    2828define( 'ATD_USER_OPTIONS'      , 'AtDuserOptions'                                      ); /** User Option Name */ 
     
    3434$atd_supported_langs = array( 
    3535        'en' => __( 'English'   , 'after-the-deadline' ), 
    36         'pt' => __( 'Portuguese', 'after-the-deadline' ), 
    3736        'fr' => __( 'French'    , 'after-the-deadline' ), 
    3837        'de' => __( 'German'    , 'after-the-deadline' ), 
     38        'pt' => __( 'Portuguese', 'after-the-deadline' ), 
    3939        'es' => __( 'Spanish'   , 'after-the-deadline' ) 
    4040); 
     
    4545} 
    4646if ( !is_array( $atd_plugopts ) ) { /* Set the Options if they are not set */ 
    47         if ( defined( 'BB_LANG' ) && BB_LANG ) { /* Language check */ 
     47        if ( defined( 'BB_LANG' ) && BB_LANG != '' ) { /* Language check */ 
    4848                foreach( array_keys( $atd_supported_langs ) as $lang ) { 
    4949                        if ( strpos( BB_LANG, $lang ) !== false ) { 
  • /after-the-deadline/trunk/css/atd.css

    r2902 r2904  
    1 .atd_container{width:100%;clear:both}.checkLink{ cursor:pointer}.atd_container a{ background:url('../images/atdbuttontr.gif') no-repeat;padding-left:20px; }.hiddenSpellError{ border-bottom:2px solid red; cursor:default}.hiddenGrammarError{ border-bottom:2px solid green; cursor:default}.hiddenSuggestion{ border-bottom:2px solid blue; cursor:default}#suggestmenu { background:#fff; position:absolute; display:none; z-index:9999; overflow:hidden; margin-top:1px; text-align:left; font-size:12px; font-family:Tahoma,Verdana,Arial,Helvetica; cursor:default}#suggestmenu strong { background:#ddd; font-weight:bold; padding:3px 6px 3px 6px;  display:block;  border:1px solid #ccc; color:black; cursor:default}#suggestmenu em { text-align:center;  padding:3px 6px 3px 6px;  display:block;  border-top:1px solid #ccc; border-left:1px solid #ccc; cursor:default}#suggestmenu a,#suggestmenu a:visited { background:#fff; border-left:1px solid #bbb; border-right:1px solid #bbb; padding:3px 6px 3px 6px; display:block; margin:0px; text-decoration:none; color:#333; outline:none; cursor:default}#suggestmenu a.first,#suggestmenu a.first:visited { border-top:1px solid #ccc; cursor:default}.spell_sep_bottom { border-bottom:1px solid #ccc; cursor:default}.spell_sep_top { border-top:1px solid #ccc; cursor:default}#suggestmenu a:hover { color:#000; background:#dbecf3; cursor:default}#suggestmenu .foot { border-top:1px solid #ddd; background:#fff; cursor:default}#suggestmenu .foot a,#suggestmenu .foot a:visited { outline:none; cursor:default}#popup_container{font-family:Arial,sans-serif;font-size:12px;min-width:300px;max-width:600px;background:#FFF;border:solid 5px #999;color:#000;-moz-border-radius:5px;-webkit-border-radius:5px}#popup_title{font-size:14px;font-weight:bold;text-align:center;line-height:1.75em;color:#666;background:#CCC url(../images/title.gif) top repeat-x;border:solid 1px #FFF;border-bottom:solid 1px #999;cursor:default;padding:0em;margin:0em}#popup_content{background:16px 16px no-repeat url(../images/info.gif);padding:1em 1.75em;margin:0em}#popup_content.alert{background-image:url(../images/info.gif)}#popup_content.confirm{background-image:url(../images/important.gif)}#popup_content.prompt{background-image:url(../images/help.gif)}#popup_message{padding-left:48px}#popup_panel{text-align:center;margin:1em 0em 0em 1em}#popup_prompt{margin:.5em 0em}.atd-ajax-load{clear:both;background:url('../images/ajax-loader.gif') no-repeat;float:right;height:0;width:16px;} 
     1.atd_container{width:100%;clear:both}.atd_container a{cursor:pointer}.checkLink{background:url('../images/atdbuttontr.gif') no-repeat;padding-left:20px; }.hiddenSpellError{ border-bottom:2px solid red; cursor:default}.hiddenGrammarError{ border-bottom:2px solid green; cursor:default}.hiddenSuggestion{ border-bottom:2px solid blue; cursor:default}#suggestmenu { background:#fff; position:absolute; display:none; z-index:9999; overflow:hidden; margin-top:1px; text-align:left; font-size:12px; font-family:Tahoma,Verdana,Arial,Helvetica; cursor:default}#suggestmenu strong { background:#ddd; font-weight:bold; padding:3px 6px 3px 6px;  display:block;  border:1px solid #ccc; color:black; cursor:default}#suggestmenu em { text-align:center;  padding:3px 6px 3px 6px;  display:block;  border-top:1px solid #ccc; border-left:1px solid #ccc; cursor:default}#suggestmenu a,#suggestmenu a:visited { background:#fff; border-left:1px solid #bbb; border-right:1px solid #bbb; padding:3px 6px 3px 6px; display:block; margin:0px; text-decoration:none; color:#333; outline:none; cursor:default}#suggestmenu a.first,#suggestmenu a.first:visited { border-top:1px solid #ccc; cursor:default}.spell_sep_bottom { border-bottom:1px solid #ccc; cursor:default}.spell_sep_top { border-top:1px solid #ccc; cursor:default}#suggestmenu a:hover { color:#000; background:#dbecf3; cursor:default}#suggestmenu .foot { border-top:1px solid #ddd; background:#fff; cursor:default}#suggestmenu .foot a,#suggestmenu .foot a:visited { outline:none; cursor:default}#popup_container{font-family:Arial,sans-serif;font-size:12px;min-width:300px;max-width:600px;background:#FFF;border:solid 5px #999;color:#000;-moz-border-radius:5px;-webkit-border-radius:5px}#popup_title{font-size:14px;font-weight:bold;text-align:center;line-height:1.75em;color:#666;background:#CCC url(../images/title.gif) top repeat-x;border:solid 1px #FFF;border-bottom:solid 1px #999;cursor:default;padding:0em;margin:0em}#popup_content{background:16px 16px no-repeat url(../images/info.gif);padding:1em 1.75em;margin:0em}#popup_content.alert{background-image:url(../images/info.gif)}#popup_content.confirm{background-image:url(../images/important.gif)}#popup_content.prompt{background-image:url(../images/help.gif)}#popup_message{padding-left:48px}#popup_panel{text-align:center;margin:1em 0em 0em 1em}#popup_prompt{margin:.5em 0em}.atd-ajax-load{clear:both;background:url('../images/ajax-loader.gif') no-repeat;float:right;height:0;width:16px;} 
  • /after-the-deadline/trunk/includes/admin.php

    r2902 r2904  
    1717 * @return string|bool Returns version if update is available, else false 
    1818 */ 
    19 function atd_update_check(){ 
     19function atd_update_check() { 
    2020        $latest_ver = trim( wp_remote_retrieve_body( wp_remote_get( 'http://gaut.am/uploads/plugins/updater.php?pid=5&chk=ver&soft=bb&current=' . ATD_VER, array( 'user-agent' => 'AtD/bbPress v' . ATD_VER ) ) ) ); 
    2121        if ( !$latest_ver || version_compare( $latest_ver, ATD_VER, '<=' ) ) /* If call fails or plugin is upto date, then return */ 
     
    4949                $atd_plugopts['lang']           = ( in_array( $_POST['lang'], array_keys( $atd_supported_langs ) ) ) ? $_POST['lang'] : 'en'; 
    5050                $atd_plugopts['enableuser']     = array(); 
    51                 foreach ( (array) $_POST['enableuser'] as $option ) { 
     51                foreach ( (array) $_POST['enableuser'] as $option ) 
    5252                        if ( in_array( $option, array( 'autoproofread', 'ignorealways', 'ignoretypes' ) ) ) 
    5353                                $atd_plugopts['enableuser'][] = $option; 
    54                 } 
    5554                 
    5655                /* Save the options and notify user */ 
    5756                bb_update_option( ATD_OPTIONS, $atd_plugopts ); 
    58                 bb_admin_notice( __( 'The options have been successfully saved!', 'after-the-deadline' ) ); 
     57                bb_admin_notice( sprintf( __( 'The options have been successfully saved! Maybe you would consider <a href="%s">donating</a>.', 'after-the-deadline' ), 'http://gaut.am/donate/bb/atd/' ) ); 
    5958        } 
    6059         
     
    105104                        <?php bb_nonce_field( 'atd-save-chk' ); ?> 
    106105                        <input type="hidden" name="atd_opts_submit" value="1"></input> 
    107                         <input class="submit" type="submit" name="submit" value="Save Changes" /> 
     106                        <p><?php printf( __( 'Happy with the plugin? Why not <a href="%1$s">buy the author a cup of coffee or two</a> or <a href="%2$s">follow him on twitter</a> (or even visit his <a href="%3$s">website</a>).', 'after-the-deadline' ), 'http://gaut.am/donate/bb/atd/', 'http://twitter.com/Gaut_am', 'http://www.cyberfundu.com/' ); ?></p> 
     107                        <input class="submit" type="submit" name="submit" value="<?php _e( 'Save Changes', 'ajaxed-chat' ); ?>" /> 
    108108                </fieldset> 
    109                 <p><?php printf( __( 'Happy with the plugin? Why not <a href="%1$s">buy the author a cup of coffee or two</a> or get him something from his <a href="%2$s">wishlist</a>?', 'after-the-deadline' ), 'http://gaut.am/donate/AtD/', 'http://gaut.am/wishlist/' ); ?></p> 
    110109        </form> 
    111110<?php 
  • /after-the-deadline/trunk/includes/ajax-ignore.php

    r2902 r2904  
    99 
    1010/*  
    11  *  Called when Ignore Always is clicked (setup as an action through admin-ajax.php) 
     11 * Called when Ignore Always is clicked (setup as an action through admin-ajax.php) 
    1212 */ 
    1313function atd_ignore_call() { 
  • /after-the-deadline/trunk/includes/check.php

    r2902 r2904  
    33 * @package After the Deadline 
    44 * @subpackage Public Section 
    5  * @category Proxy Script 
     5 * @category Proxy Script (AJAX) 
    66 * @author Gautam Gupta (www.gaut.am) 
    77 * @link http://gaut.am/bbpress/plugins/after-the-deadline/ 
    88 */ 
    99 
    10 /** 
    11  * We dont do this via AJAX because AJAX requires a user ID to be set, and bbPress 1.1 also gives the ability for the non-members to post (and thus, do the spell check too). 
    12  */ 
     10define( 'DOING_AJAX', true ); /* Fake like it is an AJAX call as admin-ajax.php does some more checks which we don't need */ 
    1311 
    14 /** 
    15  * Browsing Function 
    16  *  
    17  * @uses WP_Http 
    18  * @uses cURL 
    19  * @uses file_get_contents 
    20  *  
    21  * @param string $url The URL needed to be visited 
    22  * @param string $method POST or GET (default POST) 
    23  * @param array $data The data needed to be sent (if POST) 
    24  * 
    25  * @return string|bool The source received otherwise false 
    26  */ 
    27 function atd_http( $url, $method = 'POST', $data = array() ) { 
    28         if ( class_exists( 'WP_Http' ) ) { /* Not necessarily as we avoid loading bb-load.php here */ 
    29                 return wp_remote_retrieve_body( wp_remote_request( $url, array( 'method' => $method, 'body' => $data, 'user-agent' => 'AtD/bbPress v' . ATD_VER ) ) ); 
    30         } elseif ( function_exists( 'curl_init' ) ) { /* Use cURL */ 
    31                 $ch = curl_init(); 
    32                 curl_setopt( $ch, CURLOPT_URL, $url ); 
    33                 curl_setopt( $ch, CURLOPT_RETURNTRANSFER, true ); 
    34                 curl_setopt( $ch, CURLOPT_USERAGENT, 'AtD/bbPress' ); 
    35                 if( strtoupper( $method ) == 'POST' ){ 
    36                         curl_setopt( $ch, CURLOPT_POST, true ); 
    37                         curl_setopt( $ch, CURLOPT_POSTFIELDS, http_build_query( $data ) ); 
    38                 } 
    39                 curl_setopt( $ch, CURLOPT_HEADER, false ); 
    40                 $source = curl_exec( $ch ); 
    41                 curl_close( $ch ); 
    42                 return $source; 
    43         } elseif ( function_exists( 'file_get_contents' ) ) { /* Use file_get_contents() */ 
    44                 if( strtoupper( $method ) == 'POST' && function_exists( 'stream_context_create' ) ){ 
    45                 $opts = array('http' => 
    46                         array( 
    47                                 'method' => 'POST', 
    48                                 'user_agent' => 'AtD/bbPress', 
    49                                 'content' => http_build_query( $data ) 
    50                         ) 
    51                 ); 
    52                 $context = stream_context_create($opts); 
    53                 return file_get_contents( $url, false, $context ); 
    54                 } else { 
    55                         return file_get_contents( $url ); 
    56                 } 
    57         } 
    58          
    59         return false; 
    60 } 
     12require_once( '../../../bb-load.php' ); 
     13 
     14if ( !class_exists( 'WP_Http' ) ) /* Should never happen, but still (for future) */ 
     15        require_once( BACKPRESS_PATH . 'class.wp-http.php' ); 
    6116 
    6217/* Collect the data to be sent */ 
    63 $url            = $_GET['url'] ? trim( $_GET['url'] ) : '/checkDocument'; 
    64 $api_key        = $_POST['key'] ? trim( $_POST['key'] ) : 'bbPress'; 
    65 $lang           = $_GET['lang'] ? trim( $_GET['lang'] ) : 'en'; 
    66 $service        = ( in_array( $lang, array( 'pt', 'fr', 'de', 'es' ) ) ) ? $lang . '.service.afterthedeadline.com' : 'service.afterthedeadline.com'; 
    67 if( !$postdata = trim( $_POST['data'] ) ) 
     18$user           = bb_get_current_user(); 
     19$api_key        = 'BB-' . md5( bb_get_uri() ) . '-'; /* Forum's starting key */ 
     20$api_key        .= $user->ID ? $user->ID : mt_rand(); /* User specific */ 
     21$lang           = in_array( $atd_plugopts['lang'], array( 'pt', 'fr', 'de', 'es' ) ) ? $atd_plugopts['lang'] . '.' : ''; 
     22$go             = 'http://' . $lang . 'service.afterthedeadline.com/checkDocument'; 
     23if( !$postdata = trim( $_POST['data'] ) ) /* Should never happen */ 
    6824        die(); 
    6925 
    7026/* Get the Data & echo */ 
    71 $data = trim( atd_http( 'http://' . $service . $url, 'POST', array( 'data' => $postdata, 'key' => $api_key ) ) ); 
     27$data = wp_remote_retrieve_body( wp_remote_request( $go, array( 'method' => 'POST', 'body' => array( 'data' => $postdata, 'key' => $api_key ), 'user-agent' => 'AtD/bbPress v' . ATD_VER ) ) ); 
    7228header( 'Content-Type: text/xml' ); 
    7329echo $data; 
  • /after-the-deadline/trunk/includes/profile-options.php

    r2902 r2904  
    3737                return; 
    3838         
    39         if ( in_array( 'ignoretypes', (array) $atd_plugopts['enableuser'] ) ) { 
     39        if ( in_array( 'ignoretypes', (array) $atd_plugopts['enableuser'] ) ) 
    4040                if ( is_array( $_POST['atd_ignoretypes'] ) ) 
    4141                        $options['ignoretypes'] = esc_attr( implode( ',', array_keys( $_POST['atd_ignoretypes'] ) ) ); 
    4242                else 
    4343                        unset( $options['ignoretypes'] ); 
    44         } 
    4544         
    4645        if ( in_array( 'ignorealways', (array) $atd_plugopts['enableuser'] ) ) 
  • /after-the-deadline/trunk/includes/public.php

    r2902 r2904  
    1818        if ( bb_is_user_logged_in() || ( function_exists( 'bb_is_login_required' ) && !bb_is_login_required() ) ) { 
    1919                global $atd_plugopts, $atd_supported_langs; 
    20                 $i18n = array( 
     20                 
     21                $i18n           = array( 
    2122                                'rpc'                           => ATD_PLUGPATH . 'includes/check.php'                          , 
    22                                 'api_key'                       => 'BB-' . md5( bb_get_uri() )                                  , 
    23                                 'lang'                          => $atd_plugopts['lang'] ? $atd_plugopts['lang'] : 'en'         , 
    2423                                'button_proofread'              => __( 'Proofread'                      , 'after-the-deadline' ), 
    2524                                'button_edit_text'              => __( 'Edit Text'                      , 'after-the-deadline' ), 
     25                                'button_accept_all'             => __( 'Accept All'                     , 'after-the-deadline' ), 
    2626                                'button_ok'                     => __( 'OK'                             , 'after-the-deadline' ), 
    2727                                'button_cancel'                 => __( 'Cancel'                         , 'after-the-deadline' ), 
     
    6464                        } 
    6565                } 
    66                 //wp_enqueue_script(    'after-the-deadline-po', ATD_PLUGPATH . 'scripts/profile.dev.js', array( 'jquery' ), ATD_VER, true ); 
    67                 //wp_enqueue_script(    'after-the-deadline', ATD_PLUGPATH . 'scripts/atd.dev.js', array( 'jquery' )    , ATD_VER, true ); 
     66                //wp_enqueue_script(    'after-the-deadline-po', ATD_PLUGPATH . 'scripts/profile.dev.js', array( 'jquery' ), ATD_VER    ); //Compressed js is echoed on the profile edit page itself 
     67                //wp_enqueue_script(    'after-the-deadline', ATD_PLUGPATH . 'scripts/atd.dev.js', array( 'jquery' )    , ATD_VER       ); 
    6868                wp_enqueue_script(      'after-the-deadline', ATD_PLUGPATH . 'scripts/atd.js'   , array( 'jquery' )     , ATD_VER       ); 
    6969                wp_localize_script(     'after-the-deadline', 'AtD'                             , $i18n                                 ); 
  • /after-the-deadline/trunk/readme.txt

    r2902 r2904  
    11=== After the Deadline === 
    22Contributors: Gautam Gupta 
    3 Donate link: http://gaut.am/donate/AtD/ 
     3Donate link: http://gaut.am/donate/bb/atd/ 
    44Tags: after the deadline, atd, writing, spell, spelling, spellchecker, grammar, style, edit, proofread, Gautam 
    55Requires at least: 1.0 
    66Tested up to: 1.1 
    7 Stable tag: 1.6.1 
     7Stable tag: 1.7 
    88 
    99After the Deadline plugin checks for spelling, style, and grammatical errors in your bbPress forum posts. 
     
    2828You can contribute by translating this plugin. Please refer to [this post](http://gaut.am/translating-wordpress-or-bbpress-plugins/) to know how to translate. 
    2929 
     30= Donate = 
     31You may donate by going [here](http://gaut.am/donate/bb/atd/). 
     32 
    3033= Todo = 
    3134Nothing for now 
     
    3639= Not on bbPress? = 
    3740You can get AtD elsewhere too! Please check [here](http://www.afterthedeadline.com/download.slp) for the list. 
    38  
    39 = Donate = 
    40 You may donate by going [here](http://gaut.am/donate/AtD/). 
    4141 
    4242== Installation == 
     
    6363 
    6464== Changelog == 
     65 
     66= 1.7 (13-06-10) = 
     67* Fixed a bug in which the API key sent to the server should be different for each user - [Check here](http://www.afterthedeadline.com/api.slp) 
     68* The proxy script now makes use of `WP_Http` which is much more reliable 
     69* Added an option for Accepting All Suggestions 
    6570 
    6671= 1.6.1 (26-03-10) = 
     
    104109 
    105110= 1.2.1 (19-11-09) = 
    106 Upgraded AtD/jQuery - [Changelog](http://www.polishmywriting.com/atd_jquery/changelog.html): 
    107  
    108 * Updated edit selection ability to keep phrase highlighted if no change was made 
    109 * Fixed a character escaping issue 
    110 * AtD now restores missing accents to English words borrowed from other languages 
     111Upgraded AtD/jQuery - [Changelog](http://www.polishmywriting.com/atd_jquery/changelog.html) 
    111112 
    112113= 1.2 (5-11-09) = 
     
    128129== Upgrade Notice == 
    129130 
     131= 1.7 = 
     132Added some new features and fixed bugs. 
     133 
    130134= 1.6.1 = 
    131135Upgraded AtD/jQuery 
  • /after-the-deadline/trunk/scripts/atd.dev.js

    r2902 r2904  
    575575        proofread_click_count : 0, 
    576576        i18n : {}, 
    577         rpc_css : 'http://www.polishmywriting.com/atd_jquery/server/proxycss.php?data=', // you may use this, but be nice! 
    578577        listener : {} 
    579 }, AtD || { api_key: '', rpc: '', lang: 'en' } ); 
     578}, AtD || { rpc: '' } ); 
    580579 
    581580/*AtD.getLang = function(key, defaultk) { 
     
    623622        jQuery.ajax({ 
    624623                type : "POST", 
    625                 url : AtD.rpc + '?url=/checkDocument&lang='+AtD.lang, 
    626                 data : 'key=' + AtD.api_key + '&data=' + text, 
     624                url : AtD.rpc, 
     625                data : 'data=' + text, 
    627626                format : 'raw',  
    628627                dataType : (jQuery.browser.msie) ? "text" : "xml", 
     
    11851184                /* set the spell check link to a link that lets the user edit the text */ 
    11861185                options['link'].html( options['after'] ); 
    1187            
     1186                 
    11881187                /* disable the spell check link while an asynchronous call is in progress. if a user tries to make a request while one is in progress 
    11891188                   they will lose their text. Not cool! */ 
     
    13361335 
    13371336/** 
     1337 * Accept All Suggestions 
     1338 */ 
     1339function AtD_acceptAllChanges() { 
     1340        var parent = AtD.core; 
     1341         
     1342        AtD.core.map( AtD.core.findSpans( jQuery('#' + AtD.current_id) ).reverse(),  
     1343        function(n) { 
     1344                if (parent.isMarkedNode(n)) { 
     1345                        var suggestions = parent.findSuggestion(n); 
     1346                        if (suggestions != undefined && suggestions.suggestions != undefined && suggestions.suggestions.length > 0) 
     1347                                parent.applySuggestion(n, suggestions.suggestions[0]); 
     1348                } 
     1349        }); 
     1350} 
     1351 
     1352/** 
    13381353 * Autoproofread 
    13391354 */ 
     
    13441359        jQuery.ajax({ 
    13451360                type : "POST", 
    1346                 url : AtD.rpc + '?url=/checkDocument&lang=' + AtD.lang, 
    1347                 data : 'key=' + AtD.api_key + '&data=' + jQuery('#'+id).val(), 
     1361                url : AtD.rpc, 
     1362                data : 'data=' + jQuery('#'+id).val(), 
    13481363                format : 'raw',  
    13491364                dataType : (jQuery.browser.msie) ? "text" : "xml",               
     
    13721387                                                AtD_update_post(id); 
    13731388                                        } else { /* Do the real checking */ 
    1374                                                 AtD.checkTextArea(id, node.attr('id'), jQuery.fn.addProofreader.defaults.edit_text_content); 
     1389                                                node.click(); 
    13751390                                        } 
    13761391                                }); 
     
    14491464 
    14501465jQuery.fn.addProofreader.defaults = { 
    1451         edit_text_content: '<span class="atd_container"><a class="checkLink">'+AtD.getLang('button_edit_text', 'Edit Text')+'</a></span>', 
     1466        edit_text_content: '<span class="atd_container"><a class="checkLink">'+AtD.getLang('button_edit_text', 'Edit Text')+'</a> | <a class="acceptAllLink" onclick="AtD_acceptAllChanges();">'+AtD.getLang('button_accept_all', 'Accept All')+'</a></span>', 
    14521467        proofread_content: '<span class="atd_container"><a class="checkLink">'+AtD.getLang('button_proofread', 'Proofread')+'</a></span>' 
    14531468}; 
  • /after-the-deadline/trunk/scripts/atd.js

    r2902 r2904  
    1 var a,EXPORTED_SYMBOLS=["AtDCore"];function AtDCore(){this.ignore_types=["Bias Language","Cliches","Complex Expression","Diacritical Marks","Double Negatives","Hidden Verbs","Jargon Language","Passive voice","Phrases to Avoid","Redundant Expression"];this.ignore_strings={};this.i18n=AtD}a=AtDCore.prototype;a.getLang=function(b,c){if(AtD[b]==undefined)return c;return AtD[b]};a.addI18n=function(b){this.i18n=b}; a.setIgnoreStrings=function(b){var c=this;this.map(b.split(/,\s*/g),function(d){c.ignore_strings[d]=1})}; a.showTypes=function(b){b=b.split(/,\s*/g);var c={};c["Double Negatives"]=1;c["Hidden Verbs"]=1;c["Passive voice"]=1;c["Bias Language"]=1;c.Cliches=1;c["Complex Expression"]=1;c["Diacritical Marks"]=1;c["Jargon Language"]=1;c["Phrases to Avoid"]=1;c["Redundant Expression"]=1;var d=[];this.map(b,function(e){c[e]=undefined});this.map(this.ignore_types,function(e){c[e]!=undefined&&d.push(e)});this.ignore_types=d}; a.makeError=function(b,c,d,e){var f={};f.type=d;f.string=b;f.tokens=c;f.regexp=(new RegExp("\\b"+b+"\\b")).test(b)?new RegExp("(?!"+b+"<)\\b"+b.replace(/\s+/g,e)+"\\b"):(new RegExp(b+"\\b")).test(b)?new RegExp("(?!"+b+"<)"+b.replace(/\s+/g,e)+"\\b"):(new RegExp("\\b"+b)).test(b)?new RegExp("(?!"+b+"<)\\b"+b.replace(/\s+/g,e)):new RegExp("(?!"+b+"<)"+b.replace(/\s+/g,e));f.used=false;return f}; a.addToErrorStructure=function(b,c,d,e){var f=this;this.map(c,function(g){var n=g.word.split(/\s+/),k=g.pre,h=n[0];if(b["__"+h]==undefined){b["__"+h]={};b["__"+h].pretoks={};b["__"+h].defaults=[]}if(k=="")b["__"+h].defaults.push(f.makeError(g.word,n,d,e,k));else{if(b["__"+h].pretoks["__"+k]==undefined)b["__"+h].pretoks["__"+k]=[];b["__"+h].pretoks["__"+k].push(f.makeError(g.word,n,d,e,k))}})}; a.buildErrorStructure=function(b,c,d){var e=this._getSeparators(),f={};this.addToErrorStructure(f,b,"hiddenSpellError",e);this.addToErrorStructure(f,d,"hiddenGrammarError",e);this.addToErrorStructure(f,c,"hiddenSuggestion",e);return f};a._getSeparators=function(){var b="",c;for(c=0;c<28;c++)b+="\\"+'"s!#$%&()*+,./:;<=>?@[]^_{|}'.charAt(c);return"(?:(?:[\u00a0"+b+"])|(?:\\-\\-))+"}; a.processXML=function(b){var c={};this.map(this.ignore_types,function(t){c[t]=1});this.suggestions=[];var d=b.getElementsByTagName("error");b=[];for(var e=[],f=[],g=0;g<d.length;g++)if(d[g].getElementsByTagName("string").item(0).firstChild!=null){var n=d[g].getElementsByTagName("string").item(0).firstChild.data,k=d[g].getElementsByTagName("type").item(0).firstChild.data,h=d[g].getElementsByTagName("description").item(0).firstChild.data,j;j=d[g].getElementsByTagName("precontext").item(0).firstChild!= null?d[g].getElementsByTagName("precontext").item(0).firstChild.data:"";if(this.ignore_strings[n]==undefined){var m={};m.description=h;m.suggestions=[];m.matcher=new RegExp("^"+n.replace(/\s+/,this._getSeparators())+"$");m.context=j;m.string=n;m.type=k;this.suggestions.push(m);if(d[g].getElementsByTagName("suggestions").item(0)!=undefined)for(var i=d[g].getElementsByTagName("suggestions").item(0).getElementsByTagName("option"),p=0;p<i.length;p++)m.suggestions.push(i[p].firstChild.data);if(d[g].getElementsByTagName("url").item(0)!= undefined){i=d[g].getElementsByTagName("url").item(0).firstChild.data;m.moreinfo=i+"&theme=tinymce"}if(c[h]==undefined){k=="suggestion"&&f.push({word:n,pre:j});k=="grammar"&&b.push({word:n,pre:j})}if(k=="spelling"||h=="Homophone")e.push({word:n,pre:j});if(h=="Cliches")m.description="Clich&eacute;s";if(h=="Spelling")m.description=this.getLang("menu_title_spelling","Spelling");if(h=="Repeated Word")m.description=this.getLang("menu_title_repeated_word","Repeated Word");if(h=="Did you mean...")m.description= this.getLang("menu_title_confused_word","Did you mean...")}}d=e.length+b.length+f.length;return{errors:d>0?this.buildErrorStructure(e,f,b):undefined,count:d,suggestions:this.suggestions}}; a.findSuggestion=function(b){var c=b.innerHTML,d=(this.getAttrib(b,"pre")+"").replace(/[\\,!\\?\\."\s]/g,"");this.getAttrib(b,"pre")==undefined&&alert(b.innerHTML);b=undefined;for(var e=this.suggestions.length,f=0;f<e;f++)if((d==""||d==this.suggestions[f].context)&&this.suggestions[f].matcher.test(c)){b=this.suggestions[f];break}return b};function TokenIterator(b){this.tokens=b;this.last=this.count=this.index=0}a=TokenIterator.prototype; a.next=function(){var b=this.tokens[this.index];this.count=this.last;this.last+=b.length+1;this.index++;if(b!=""){if(b[0]=="'")b=b.substring(1,b.length);if(b[b.length-1]=="'")b=b.substring(0,b.length-1)}return b};a.hasNext=function(){return this.index<this.tokens.length};a.hasNextN=function(b){return this.index+b<this.tokens.length};a.skip=function(b,c){this.index+=b;this.last+=c;if(this.index<this.tokens.length)this.count=this.last-this.tokens[this.index].length};a.getCount=function(){return this.count}; a.peek=function(b){var c=[];b=this.index+b;for(var d=this.index;d<b;d++)c.push(this.tokens[d]);return c};a=AtDCore.prototype; a.markMyWords=function(b,c){var d=new RegExp(this._getSeparators()),e=[],f=0,g=this;this._walk(b,function(k){k.nodeType==3&&!g.isMarkedNode(k)&&e.push(k)});var n;this.map(e,function(k){var h;if(k.nodeType==3){h=k.nodeValue;var j=k.nodeValue.split(d),m="",i=[];for(n=new TokenIterator(j);n.hasNext();){j=n.next();var p=c["__"+j],t;if(p!=undefined&&p.pretoks!=undefined){t=p.defaults;p=p.pretoks["__"+m];var l=false,q,u;q=h.substr(0,n.getCount());u=h.substr(q.length,h.length);q=function(o){if(o!=undefined&& !o.used&&w["__"+o.string]==undefined&&o.regexp.test(u)){w["__"+o.string]=1;i.push([o.regexp,'<span class="'+o.type+'" pre="'+m+'">$&</span>']);l=o.used=true}};var w={};if(p!=undefined){m+=" ";g.map(p,q)}if(!l){m="";g.map(t,q)}}m=j}if(i.length>0){newNode=k;for(h=0;h<i.length;h++){var v=i[h][0],x=i[h][1];newNode=function(o){if(o.nodeType==3){f++;return g.isIE()&&o.nodeValue.length>0&&o.nodeValue.substr(0,1)==" "?g.create('<span class="mceItemHidden">&nbsp;</span>'+o.nodeValue.substr(1,o.nodeValue.length- 1).replace(v,x),false):g.create(o.nodeValue.replace(v,x),false)}else{for(var s=g.contents(o),r=0;r<s.length;r++)if(s[r].nodeType==3&&v.test(s[r].nodeValue)){var y;y=g.isIE()&&s[r].nodeValue.length>0&&s[r].nodeValue.substr(0,1)==" "?g.create('<span class="mceItemHidden">&nbsp;</span>'+s[r].nodeValue.substr(1,s[r].nodeValue.length-1).replace(v,x),true):g.create(s[r].nodeValue.replace(v,x),true);g.replaceWith(s[r],y);g.removeParent(y);f++;return o}return o}}(newNode)}g.replaceWith(k,newNode)}}});return f}; a._walk=function(b,c){var d;for(d=0;d<b.length;d++){c.call(c,b[d]);this._walk(this.contents(b[d]),c)}};a.removeWords=function(b,c){var d=0,e=this;this.map(this.findSpans(b).reverse(),function(f){if(f&&(e.isMarkedNode(f)||e.hasClass(f,"mceItemHidden")||e.isEmptySpan(f)))if(f.innerHTML=="&nbsp;"){var g=document.createTextNode(" ");e.replaceWith(f,g)}else if(!c||f.innerHTML==c){e.removeParent(f);d++}});return d}; a.isEmptySpan=function(b){return this.getAttrib(b,"class")==""&&this.getAttrib(b,"style")==""&&this.getAttrib(b,"id")==""&&!this.hasClass(b,"Apple-style-span")&&this.getAttrib(b,"mce_name")==""};a.isMarkedNode=function(b){return this.hasClass(b,"hiddenGrammarError")||this.hasClass(b,"hiddenSpellError")||this.hasClass(b,"hiddenSuggestion")};a.applySuggestion=function(b,c){if(c=="(omit)")this.remove(b);else{c=this.create(c);this.replaceWith(b,c);this.removeParent(c)}}; a.hasErrorMessage=function(b){return b!=undefined&&b.getElementsByTagName("message").item(0)!=null};a.getErrorMessage=function(b){return b.getElementsByTagName("message").item(0)};a.isIE=function(){return navigator.appName=="Microsoft Internet Explorer"};var AtD=jQuery.extend({proofread_click_count:0,i18n:{},rpc_css:"http://www.polishmywriting.com/atd_jquery/server/proxycss.php?data=",listener:{}},AtD||{api_key:"",rpc:"",lang:"en"});AtD.getLang=function(b,c){if(AtD[b]==undefined)return c;return AtD[b]}; AtD.addI18n=function(b){AtD.i18n=b;AtD.core.addI18n(b)};AtD.setIgnoreStrings=function(b){AtD.core.setIgnoreStrings(b)};AtD.showTypes=function(b){AtD.core.showTypes(b)}; AtD.check=function(b,c){typeof AtD.proofread_click_count!="undefined"&&AtD.proofread_click_count++;AtD.callback_f=c;AtD.remove(b);c=jQuery("#"+b);c.html();text=jQuery.trim(c.html());text=encodeURIComponent(text);jQuery.ajax({type:"POST",url:AtD.rpc+"?url=/checkDocument&lang="+AtD.lang,data:"key="+AtD.api_key+"&data="+text,format:"raw",dataType:jQuery.browser.msie?"text":"xml",error:function(d,e,f){AtD.callback_f!=undefined&&AtD.callback_f.error!=undefined&&AtD.callback_f.error(e+": "+f)},success:function(d){var e; if(typeof d=="string"){e=new ActiveXObject("Microsoft.XMLDOM");e.async=false;e.loadXML(d)}else e=d;if(AtD.core.hasErrorMessage(e))AtD.callback_f!=undefined&&AtD.callback_f.error!=undefined&&AtD.callback_f.error(AtD.core.getErrorMessage(e));else{AtD.container=b;d=AtD.processXML(b,e);AtD.callback_f!=undefined&&AtD.callback_f.ready!=undefined&&AtD.callback_f.ready(d);d==0&&AtD.callback_f!=undefined&&AtD.callback_f.success!=undefined&&AtD.callback_f.success(d);AtD.counter=d;AtD.count=d}}})}; AtD.remove=function(b){AtD._removeWords(b,null)};AtD.clickListener=function(b){AtD.core.isMarkedNode(b.target)&&AtD.suggest(b.target)};AtD.processXML=function(b,c){c=AtD.core.processXML(c);if(c.count>0)c.count=AtD.core.markMyWords(jQuery("#"+b).contents(),c.errors);jQuery("#"+b).unbind("click",AtD.clickListener);jQuery("#"+b).click(AtD.clickListener);return c.count}; AtD.useSuggestion=function(b){this.core.applySuggestion(AtD.errorElement,b);AtD.counter--;AtD.counter==0&&AtD.callback_f!=undefined&&AtD.callback_f.success!=undefined&&AtD.callback_f.success(AtD.count)};AtD.editSelection=function(){AtD.errorElement.parent();AtD.callback_f!=undefined&&AtD.callback_f.editSelection!=undefined&&AtD.callback_f.editSelection(AtD.errorElement)}; AtD.ignoreSuggestion=function(){AtD.core.removeParent(AtD.errorElement);AtD.counter--;AtD.counter==0&&AtD.callback_f!=undefined&&AtD.callback_f.success!=undefined&&AtD.callback_f.success(AtD.count)}; AtD.ignoreAll=function(b){var c=AtD.errorElement.text();b=AtD._removeWords(b,c);AtD.counter-=b;AtD.counter==0&&AtD.callback_f!=undefined&&AtD.callback_f.success!=undefined&&AtD.callback_f.success(AtD.count);if(AtD.callback_f!=undefined&&AtD.callback_f.ignore!=undefined&&AtD.rpc_ignore!=undefined){AtD.callback_f.ignore(c);AtD.core.setIgnoreStrings(c)}};AtD.explainError=function(){AtD.callback_f!=undefined&&AtD.callback_f.explain!=undefined&&AtD.callback_f.explain(AtD.explainURL)}; AtD.suggest=function(b){if(jQuery("#suggestmenu").length==0){var c=jQuery('<div id="suggestmenu"></div>');c.prependTo("body")}else{c=jQuery("#suggestmenu");c.hide()}errorDescription=AtD.core.findSuggestion(b);AtD.errorElement=jQuery(b);c.empty();if(errorDescription==undefined)c.append("<strong>"+AtD.getLang("menu_title_no_suggestions","No suggestions")+"</strong>");else if(errorDescription.suggestions.length==0)c.append("<strong>"+errorDescription.description+"</strong>");else{c.append("<strong>"+ errorDescription.description+"</strong>");for(var d=0;d<errorDescription.suggestions.length;d++)(function(e){c.append("<a onclick=\"AtD.useSuggestion('"+e.replace(/'/,"\\'")+"');\">"+e+"</a>")})(errorDescription.suggestions[d])}if(AtD.callback_f!=undefined&&AtD.callback_f.explain!=undefined&&errorDescription.moreinfo!=undefined){c.append('<a onclick="AtD.explainError();" class="spell_sep_top">'+AtD.getLang("menu_option_explain","Explain...")+"</a>");AtD.explainURL=errorDescription.moreinfo}c.append('<a onclick="AtD.ignoreSuggestion();" class="spell_sep_top">'+ AtD.getLang("menu_option_ignore_once","Ignore suggestion")+"</a>");if(AtD.callback_f!=undefined&&AtD.callback_f.editSelection!=undefined){AtD.callback_f!=undefined&&AtD.callback_f.ignore!=undefined&&AtD.rpc_ignore!=undefined?c.append("<a onclick=\"AtD.ignoreAll('"+AtD.container+"');\">"+AtD.getLang("menu_option_ignore_always","Ignore always")+"</a>"):c.append("<a onclick=\"AtD.ignoreAll('"+AtD.container+"');\">"+AtD.getLang("menu_option_ignore_all","Ignore all")+"</a>");c.append("<a onclick=\"AtD.editSelection('"+ AtD.container+'\');" class="spell_sep_bottom spell_sep_top">'+AtD.getLang("menu_option_edit_selection","Edit Selection...")+"</a>")}else AtD.callback_f!=undefined&&AtD.callback_f.ignore!=undefined&&AtD.rpc_ignore!=undefined?c.append("<a onclick=\"AtD.ignoreAll('"+AtD.container+'\');" class="spell_sep_bottom">'+AtD.getLang("menu_option_ignore_always","Ignore always")+"</a>"):c.append("<a onclick=\"AtD.ignoreAll('"+AtD.container+'\');" class="spell_sep_bottom">'+AtD.getLang("menu_option_ignore_all", "Ignore all")+"</a>");d=jQuery(b).offset();b=jQuery(b).width();jQuery(c).css({left:d.left+b+"px",top:d.top+"px"});jQuery(c).fadeIn(200);AtD.suggestShow=true;setTimeout(function(){jQuery("body").bind("click",function(){AtD.suggestShow||jQuery("#suggestmenu").fadeOut(200)})},1);setTimeout(function(){AtD.suggestShow=false},2)};AtD._removeWords=function(b,c){return this.core.removeWords(jQuery("#"+b),c)}; AtD.initCoreModule=function(){var b=new AtDCore;b.hasClass=function(c,d){return jQuery(c).hasClass(d)};b.map=jQuery.map;b.contents=function(c){return jQuery(c).contents()};b.replaceWith=function(c,d){return jQuery(c).replaceWith(d)};b.findSpans=function(c){return jQuery.makeArray(c.find("span"))};b.create=function(c){return jQuery('<span class="mceItemHidden">'+c+"</span>")};b.remove=function(c){return jQuery(c).remove()};b.removeParent=function(c){return jQuery(c).unwrap?jQuery(c).contents().unwrap(): jQuery(c).replaceWith(jQuery(c).html())};b.getAttrib=function(c,d){return jQuery(c).attr(d)};return b};AtD.core=AtD.initCoreModule(); (function(b){b.alerts={verticalOffset:-75,horizontalOffset:0,repositionOnResize:true,overlayOpacity:0.01,overlayColor:"#FFF",draggable:false,okButton:"&nbsp;"+AtD.getLang("button_ok","OK")+"&nbsp;",cancelButton:"&nbsp;"+AtD.getLang("button_cancel","Cancel")+"&nbsp;",dialogClass:null,alert:function(c,d,e){if(d==null)d="Alert";b.alerts._show(d,c,null,"alert",function(f){e&&e(f)})},confirm:function(c,d,e){if(d==null)d="Confirm";b.alerts._show(d,c,null,"confirm",function(f){e&&e(f)})},prompt:function(c, d,e,f){if(e==null)e="Prompt";b.alerts._show(e,c,d,"prompt",function(g){f&&f(g)})},_show:function(c,d,e,f,g){b.alerts._hide();b.alerts._overlay("show");b("BODY").append('<div id="popup_container"><h1 id="popup_title"></h1><div id="popup_content"><div id="popup_message"></div></div></div>');b.alerts.dialogClass&&b("#popup_container").addClass(b.alerts.dialogClass);var n=b.browser.msie&&parseInt(b.browser.version)<=6?"absolute":"fixed";b("#popup_container").css({position:n,zIndex:99999,padding:0,margin:0}); b("#popup_title").text(c);b("#popup_content").addClass(f);b("#popup_message").text(d);b("#popup_message").html(b("#popup_message").text().replace(/\n/g,"<br />"));b("#popup_container").css({minWidth:b("#popup_container").outerWidth(),maxWidth:b("#popup_container").outerWidth()});b.alerts._reposition();b.alerts._maintainPosition(true);switch(f){case "alert":b("#popup_message").after('<div id="popup_panel"><input type="button" value="'+b.alerts.okButton+'" id="popup_ok" /></div>');b("#popup_ok").click(function(){b.alerts._hide(); g(true)});b("#popup_ok").focus().keypress(function(h){if(h.keyCode==13||h.keyCode==27)b("#popup_ok").trigger("click")});break;case "confirm":b("#popup_message").after('<div id="popup_panel"><input type="button" value="'+b.alerts.okButton+'" id="popup_ok" /> <input type="button" value="'+b.alerts.cancelButton+'" id="popup_cancel" /></div>');b("#popup_ok").click(function(){b.alerts._hide();g&&g(true)});b("#popup_cancel").click(function(){b.alerts._hide();g&&g(false)});b("#popup_ok").focus();b("#popup_ok, #popup_cancel").keypress(function(h){h.keyCode== 13&&b("#popup_ok").trigger("click");h.keyCode==27&&b("#popup_cancel").trigger("click")});break;case "prompt":b("#popup_message").append('<br /><input type="text" size="30" id="popup_prompt" />').after('<div id="popup_panel"><input type="button" value="'+b.alerts.okButton+'" id="popup_ok" /> <input type="button" value="'+b.alerts.cancelButton+'" id="popup_cancel" /></div>');b("#popup_prompt").width(b("#popup_message").width());b("#popup_ok").click(function(){var h=b("#popup_prompt").val();b.alerts._hide(); g&&g(h)});b("#popup_cancel").click(function(){b.alerts._hide();g&&g(null)});b("#popup_prompt, #popup_ok, #popup_cancel").keypress(function(h){h.keyCode==13&&b("#popup_ok").trigger("click");h.keyCode==27&&b("#popup_cancel").trigger("click")});e&&b("#popup_prompt").val(e);b("#popup_prompt").focus().select();break}if(b.alerts.draggable)try{b("#popup_container").draggable({handle:b("#popup_title")});b("#popup_title").css({cursor:"move"})}catch(k){}},_hide:function(){b("#popup_container").remove();b.alerts._overlay("hide"); b.alerts._maintainPosition(false)},_overlay:function(c){switch(c){case "show":b.alerts._overlay("hide");b("BODY").append('<div id="popup_overlay"></div>');b("#popup_overlay").css({position:"absolute",zIndex:99998,top:"0px",left:"0px",width:"100%",height:b(document).height(),background:b.alerts.overlayColor,opacity:b.alerts.overlayOpacity});break;case "hide":b("#popup_overlay").remove();break}},_reposition:function(){var c=b(window).height()/2-b("#popup_container").outerHeight()/2+b.alerts.verticalOffset, d=b(window).width()/2-b("#popup_container").outerWidth()/2+b.alerts.horizontalOffset;if(c<0)c=0;if(d<0)d=0;if(b.browser.msie&&parseInt(b.browser.version)<=6)c+=b(window).scrollTop();b("#popup_container").css({top:c+"px",left:d+"px"});b("#popup_overlay").height(b(document).height())},_maintainPosition:function(c){if(b.alerts.repositionOnResize)switch(c){case true:b(window).bind("resize",b.alerts._reposition);break;case false:b(window).unbind("resize",b.alerts._reposition);break}}};jAlert=function(c, d,e){b.alerts.alert(c,d,e)};jConfirm=function(c,d,e){b.alerts.confirm(c,d,e)};jPrompt=function(c,d,e,f){b.alerts.prompt(c,d,e,f)}})(jQuery);AtD.textareas={}; AtD.restoreTextArea=function(b){AtD_ajax_load("hide");var c=AtD.textareas[b];if(!(c==undefined||c.before==c.link.html())){AtD.remove(b);jQuery("#AtD_sync_").remove();var d;d=navigator.appName=="Microsoft Internet Explorer"?jQuery("#"+b).html().replace(/<BR.*?class.*?atd_remove_me.*?>/gi,"\n"):jQuery("#"+b).html();jQuery("#"+b).replaceWith(c.node);jQuery("#"+b).val(d.replace(/\&lt\;/g,"<").replace(/\&gt\;/,">").replace(/\&amp;/g,"&"));jQuery("#"+b).height(c.height);c.link.html(c.before)}}; AtD.checkTextArea=function(b,c,d){AtD._checkTextArea(b,AtD.check,c,d)}; AtD._checkTextArea=function(b,c,d,e){var f=jQuery("#"+b);if(AtD.textareas[b]==undefined){for(var g={},n=function(l,q){if(q.css(l)!="")g[l]=q.css(l)},k=["background-color","color","font-size","font-family","border-top-width","border-bottom-width","border-left-width","border-right-width","border-top-style","border-bottom-style","border-left-style","border-right-style","border-top-color","border-bottom-color","border-left-color","border-right-color","text-align","margin-top","margin-bottom","margin-left", "margin-right","width","line-height","letter-spacing","left","right","top","bottom","position","padding-left","padding-right","padding-top","padding-bottom"],h=0;h<k.length;h++)n(k[h],f);AtD.textareas[b]={node:f,height:f.height(),link:jQuery("#"+d),before:jQuery("#"+d).html(),after:e,style:g}}var j=AtD.textareas[b];if(j.link.html()!=j.before)AtD.restoreTextArea(b);else{j.link.html(j.after);var m=function(){return false};j.link.click(m);var i,p=jQuery('<input type="hidden" />');p.attr("id","AtD_sync_"); p.val(f.val());d=f.attr("name");if(navigator.appName=="Microsoft Internet Explorer"){f.replaceWith('<div id="'+b+'">'+f.val().replace(/\&/g,"&amp;").replace(/[\n\r\f]/gm,'<BR class="atd_remove_me">')+"</div>");i=jQuery("#"+b);i.attr("style",j.node.attr("style"));i.attr("class",j.node.attr("class"));i.css({overflow:"auto"});j.style["font-size"]=undefined;j.style["font-family"]=undefined}else{f.replaceWith('<div id="'+b+'">'+f.val().replace(/\&/g,"&amp;")+"</div>");i=jQuery("#"+b);i.attr("style",j.node.attr("style")); i.attr("class",j.node.attr("class"));i.css({overflow:"auto","white-space":"pre-wrap"});i.attr("contenteditable","true");i.attr("spellcheck",false);i.css({outline:"none"})}i.keypress(function(l){return l.keyCode!=13});p.attr("name",d);i.after(p);var t=false;f=function(){if(!t){t=true;setTimeout(function(){var l;l=navigator.appName=="Microsoft Internet Explorer"?i.html().replace(/<BR.*?class.*?atd_remove_me.*?>/gi,"\n"):i.html();var q=jQuery("<div></div>");q.html(l);AtD.core.removeWords(q);p.val(q.html().replace(/\&lt\;/g, "<").replace(/\&gt\;/,">").replace(/\&amp;/g,"&"));t=false},1500)}};i.keypress(f);i.mousemove(f);i.mouseout(f);i.css(j.style);i.height(j.height);AtD_ajax_load("show");c(b,{ready:function(){j.link.unbind("click",m);AtD_ajax_load("hide")},explain:function(l){window.open(l,"","width=480,height=380,toolbar=0,status=0,resizable=0,location=0,menuBar=0,left="+(screen.width/2-240)+",top="+(screen.height/2-190)).focus()},success:function(l){l==0&&jAlert(AtD.getLang("message_no_errors_found","No writing errors were found!"), AtD.getLang("message_no_errors","No errors!"));AtD.restoreTextArea(b)},error:function(l){j.link.unbind("click",m);l==undefined?jAlert(AtD.getLang("message_server_error_short","There was an error communicating with the spell checking service."),AtD.getLang("message_error","Error!")):jAlert(AtD.getLang("message_server_error_short","There was an error communicating with the spell checking service.")+"\n\n"+l,AtD.getLang("message_error","Error!"));AtD.restoreTextArea(b)},editSelection:function(l){var q= l.text();jPrompt(AtD.getLang("dialog_replace_selection","Replace selection with:"),l.text(),AtD.getLang("dialog_replace","Replace"),function(u){if(u!=null&&q!=u){jQuery(l).html(u);AtD.core.removeParent(l);AtD.counter--;AtD.counter==0&&AtD.restoreTextArea(b)}})},ignore:function(l){AtD_ajax_load("show");jQuery.ajax({type:"POST",url:AtD.rpc_ignore+encodeURI(l).replace(/&/g,"%26"),data:"action=atd_ignore",format:"raw",timeout:5E3,error:function(q,u,w){AtD.callback_f!=undefined&&AtD.callback_f.error!= undefined&&AtD.callback_f.error(u+": "+w)},success:function(){AtD_ajax_load("hide")}})}})}}; function AtD_check(b,c){AtD_ajax_load("show");jQuery.ajax({type:"POST",url:AtD.rpc+"?url=/checkDocument&lang="+AtD.lang,data:"key="+AtD.api_key+"&data="+jQuery("#"+b).val(),format:"raw",dataType:jQuery.browser.msie?"text":"xml",error:function(){AtD_update_post(b)},success:function(d){var e;if(typeof d=="string"){e=new ActiveXObject("Microsoft.XMLDOM");e.async=false;e.loadXML(d)}else e=d;AtD_ajax_load("hide");AtD.core.hasErrorMessage(e)&&AtD_update_post(b);if(AtD.core.processXML(e).count>0){d=AtD.getLang("dialog_confirm_post", "The proofreader has suggestions for your reply. Are you sure you want to post it?")+"\n\n"+AtD.getLang("dialog_confirm_post2","Press OK to post your reply, or Cancel to view the suggestions and edit your reply.");jConfirm(d,"",function(f){f==true?AtD_update_post(b):AtD.checkTextArea(b,c.attr("id"),jQuery.fn.addProofreader.defaults.edit_text_content)})}else AtD_update_post(b)}})}function AtD_update_post(b){AtD.proofread_click_count=2;jQuery("#"+b).parents("form").submit()} function AtD_ajax_load(b){if(b==undefined)jQuery(".atd-ajax-load").css("height")=="16px"?jQuery(".atd-ajax-load").css("height","0"):jQuery(".atd-ajax-load").css("height","16px");else b=="show"?jQuery(".atd-ajax-load").css("height","16px"):jQuery(".atd-ajax-load").css("height","0")} jQuery.fn.addProofreader=function(b){this.id=0;var c=this,d=jQuery.extend({},jQuery.fn.addProofreader.defaults,b);return this.each(function(){$this=jQuery(this);if($this.css("display")!="none"){$this.attr("id").length==0&&$this.attr("id","AtD_"+c.id++);var e=$this.attr("id"),f=jQuery("<span></span>");f.attr("id","AtD_"+c.id++);f.html(d.proofread_content);f.click(function(){AtD.current_id!=undefined&&AtD.current_id!=e&&AtD.restoreTextArea(AtD.current_id);if($this.val()!=""){AtD.checkTextArea(e,f.attr("id"), d.edit_text_content);AtD.current_id=e}else jAlert(AtD.getLang("message_error_no_text","Please enter some text in the post textbox to be checked!"),AtD.getLang("message_error","Error!"))});$this.wrap("<div></div>");$this.before('<span class="atd-ajax-load"></span>');$this.parents("form").submit(function(g){AtD.restoreTextArea(e);if(AtD.autoproofread!=undefined&&AtD.autoproofread==1&&AtD.proofread_click_count<=0&&$this.val()!=""){g.preventDefault();AtD_check(e,f)}});$this.before(f)}})}; jQuery.fn.addProofreader.defaults={edit_text_content:'<span class="atd_container"><a class="checkLink">'+AtD.getLang("button_edit_text","Edit Text")+"</a></span>",proofread_content:'<span class="atd_container"><a class="checkLink">'+AtD.getLang("button_proofread","Proofread")+"</a></span>"};jQuery(function(){jQuery("textarea").addProofreader();AtD.ignoreStrings!=undefined&&AtD.setIgnoreStrings(AtD.ignoreStrings);AtD.ignoreTypes!=undefined&&AtD.showTypes(AtD.ignoreTypes)}); 
     1var EXPORTED_SYMBOLS=["AtDCore"];function AtDCore(){this.ignore_types=["Bias Language","Cliches","Complex Expression","Diacritical Marks","Double Negatives","Hidden Verbs","Jargon Language","Passive voice","Phrases to Avoid","Redundant Expression"];this.ignore_strings={};this.i18n=AtD}AtDCore.prototype.getLang=function(a,b){if(AtD[a]==undefined)return b;return AtD[a]};AtDCore.prototype.addI18n=function(a){this.i18n=a}; AtDCore.prototype.setIgnoreStrings=function(a){var b=this;this.map(a.split(/,\s*/g),function(c){b.ignore_strings[c]=1})}; AtDCore.prototype.showTypes=function(a){a=a.split(/,\s*/g);var b={};b["Double Negatives"]=1;b["Hidden Verbs"]=1;b["Passive voice"]=1;b["Bias Language"]=1;b.Cliches=1;b["Complex Expression"]=1;b["Diacritical Marks"]=1;b["Jargon Language"]=1;b["Phrases to Avoid"]=1;b["Redundant Expression"]=1;var c=[];this.map(a,function(e){b[e]=undefined});this.map(this.ignore_types,function(e){b[e]!=undefined&&c.push(e)});this.ignore_types=c}; AtDCore.prototype.makeError=function(a,b,c,e){var d={};d.type=c;d.string=a;d.tokens=b;d.regexp=(new RegExp("\\b"+a+"\\b")).test(a)?new RegExp("(?!"+a+"<)\\b"+a.replace(/\s+/g,e)+"\\b"):(new RegExp(a+"\\b")).test(a)?new RegExp("(?!"+a+"<)"+a.replace(/\s+/g,e)+"\\b"):(new RegExp("\\b"+a)).test(a)?new RegExp("(?!"+a+"<)\\b"+a.replace(/\s+/g,e)):new RegExp("(?!"+a+"<)"+a.replace(/\s+/g,e));d.used=false;return d}; AtDCore.prototype.addToErrorStructure=function(a,b,c,e){var d=this;this.map(b,function(f){var m=f.word.split(/\s+/),j=f.pre,g=m[0];if(a["__"+g]==undefined){a["__"+g]={};a["__"+g].pretoks={};a["__"+g].defaults=[]}if(j=="")a["__"+g].defaults.push(d.makeError(f.word,m,c,e,j));else{if(a["__"+g].pretoks["__"+j]==undefined)a["__"+g].pretoks["__"+j]=[];a["__"+g].pretoks["__"+j].push(d.makeError(f.word,m,c,e,j))}})}; AtDCore.prototype.buildErrorStructure=function(a,b,c){var e=this._getSeparators(),d={};this.addToErrorStructure(d,a,"hiddenSpellError",e);this.addToErrorStructure(d,c,"hiddenGrammarError",e);this.addToErrorStructure(d,b,"hiddenSuggestion",e);return d};AtDCore.prototype._getSeparators=function(){var a="",b;for(b=0;b<28;b++)a+="\\"+'"s!#$%&()*+,./:;<=>?@[]^_{|}'.charAt(b);return"(?:(?:[\u00a0"+a+"])|(?:\\-\\-))+"}; AtDCore.prototype.processXML=function(a){var b={};this.map(this.ignore_types,function(s){b[s]=1});this.suggestions=[];var c=a.getElementsByTagName("error");a=[];for(var e=[],d=[],f=0;f<c.length;f++)if(c[f].getElementsByTagName("string").item(0).firstChild!=null){var m=c[f].getElementsByTagName("string").item(0).firstChild.data,j=c[f].getElementsByTagName("type").item(0).firstChild.data,g=c[f].getElementsByTagName("description").item(0).firstChild.data,i;i=c[f].getElementsByTagName("precontext").item(0).firstChild!= null?c[f].getElementsByTagName("precontext").item(0).firstChild.data:"";if(this.ignore_strings[m]==undefined){var l={};l.description=g;l.suggestions=[];l.matcher=new RegExp("^"+m.replace(/\s+/,this._getSeparators())+"$");l.context=i;l.string=m;l.type=j;this.suggestions.push(l);if(c[f].getElementsByTagName("suggestions").item(0)!=undefined)for(var h=c[f].getElementsByTagName("suggestions").item(0).getElementsByTagName("option"),o=0;o<h.length;o++)l.suggestions.push(h[o].firstChild.data);if(c[f].getElementsByTagName("url").item(0)!= undefined){h=c[f].getElementsByTagName("url").item(0).firstChild.data;l.moreinfo=h+"&theme=tinymce"}if(b[g]==undefined){j=="suggestion"&&d.push({word:m,pre:i});j=="grammar"&&a.push({word:m,pre:i})}if(j=="spelling"||g=="Homophone")e.push({word:m,pre:i});if(g=="Cliches")l.description="Clich&eacute;s";if(g=="Spelling")l.description=this.getLang("menu_title_spelling","Spelling");if(g=="Repeated Word")l.description=this.getLang("menu_title_repeated_word","Repeated Word");if(g=="Did you mean...")l.description= this.getLang("menu_title_confused_word","Did you mean...")}}c=e.length+a.length+d.length;return{errors:c>0?this.buildErrorStructure(e,d,a):undefined,count:c,suggestions:this.suggestions}}; AtDCore.prototype.findSuggestion=function(a){var b=a.innerHTML,c=(this.getAttrib(a,"pre")+"").replace(/[\\,!\\?\\."\s]/g,"");this.getAttrib(a,"pre")==undefined&&alert(a.innerHTML);a=undefined;for(var e=this.suggestions.length,d=0;d<e;d++)if((c==""||c==this.suggestions[d].context)&&this.suggestions[d].matcher.test(b)){a=this.suggestions[d];break}return a};function TokenIterator(a){this.tokens=a;this.last=this.count=this.index=0} TokenIterator.prototype.next=function(){var a=this.tokens[this.index];this.count=this.last;this.last+=a.length+1;this.index++;if(a!=""){if(a[0]=="'")a=a.substring(1,a.length);if(a[a.length-1]=="'")a=a.substring(0,a.length-1)}return a};TokenIterator.prototype.hasNext=function(){return this.index<this.tokens.length};TokenIterator.prototype.hasNextN=function(a){return this.index+a<this.tokens.length}; TokenIterator.prototype.skip=function(a,b){this.index+=a;this.last+=b;if(this.index<this.tokens.length)this.count=this.last-this.tokens[this.index].length};TokenIterator.prototype.getCount=function(){return this.count};TokenIterator.prototype.peek=function(a){var b=[];a=this.index+a;for(var c=this.index;c<a;c++)b.push(this.tokens[c]);return b}; AtDCore.prototype.markMyWords=function(a,b){var c=new RegExp(this._getSeparators()),e=[],d=0,f=this;this._walk(a,function(j){j.nodeType==3&&!f.isMarkedNode(j)&&e.push(j)});var m;this.map(e,function(j){var g;if(j.nodeType==3){g=j.nodeValue;var i=j.nodeValue.split(c),l="",h=[];for(m=new TokenIterator(i);m.hasNext();){i=m.next();var o=b["__"+i],s;if(o!=undefined&&o.pretoks!=undefined){s=o.defaults;o=o.pretoks["__"+l];var k=false,p,t;p=g.substr(0,m.getCount());t=g.substr(p.length,g.length);p=function(n){if(n!= undefined&&!n.used&&v["__"+n.string]==undefined&&n.regexp.test(t)){v["__"+n.string]=1;h.push([n.regexp,'<span class="'+n.type+'" pre="'+l+'">$&</span>']);k=n.used=true}};var v={};if(o!=undefined){l+=" ";f.map(o,p)}if(!k){l="";f.map(s,p)}}l=i}if(h.length>0){newNode=j;for(g=0;g<h.length;g++){var u=h[g][0],w=h[g][1];newNode=function(n){if(n.nodeType==3){d++;return f.isIE()&&n.nodeValue.length>0&&n.nodeValue.substr(0,1)==" "?f.create('<span class="mceItemHidden">&nbsp;</span>'+n.nodeValue.substr(1,n.nodeValue.length- 1).replace(u,w),false):f.create(n.nodeValue.replace(u,w),false)}else{for(var r=f.contents(n),q=0;q<r.length;q++)if(r[q].nodeType==3&&u.test(r[q].nodeValue)){var x;x=f.isIE()&&r[q].nodeValue.length>0&&r[q].nodeValue.substr(0,1)==" "?f.create('<span class="mceItemHidden">&nbsp;</span>'+r[q].nodeValue.substr(1,r[q].nodeValue.length-1).replace(u,w),true):f.create(r[q].nodeValue.replace(u,w),true);f.replaceWith(r[q],x);f.removeParent(x);d++;return n}return n}}(newNode)}f.replaceWith(j,newNode)}}});return d}; AtDCore.prototype._walk=function(a,b){var c;for(c=0;c<a.length;c++){b.call(b,a[c]);this._walk(this.contents(a[c]),b)}};AtDCore.prototype.removeWords=function(a,b){var c=0,e=this;this.map(this.findSpans(a).reverse(),function(d){if(d&&(e.isMarkedNode(d)||e.hasClass(d,"mceItemHidden")||e.isEmptySpan(d)))if(d.innerHTML=="&nbsp;"){var f=document.createTextNode(" ");e.replaceWith(d,f)}else if(!b||d.innerHTML==b){e.removeParent(d);c++}});return c}; AtDCore.prototype.isEmptySpan=function(a){return this.getAttrib(a,"class")==""&&this.getAttrib(a,"style")==""&&this.getAttrib(a,"id")==""&&!this.hasClass(a,"Apple-style-span")&&this.getAttrib(a,"mce_name")==""};AtDCore.prototype.isMarkedNode=function(a){return this.hasClass(a,"hiddenGrammarError")||this.hasClass(a,"hiddenSpellError")||this.hasClass(a,"hiddenSuggestion")};AtDCore.prototype.applySuggestion=function(a,b){if(b=="(omit)")this.remove(a);else{var c=this.create(b);this.replaceWith(a,c);this.removeParent(c)}}; AtDCore.prototype.hasErrorMessage=function(a){return a!=undefined&&a.getElementsByTagName("message").item(0)!=null};AtDCore.prototype.getErrorMessage=function(a){return a.getElementsByTagName("message").item(0)};AtDCore.prototype.isIE=function(){return navigator.appName=="Microsoft Internet Explorer"};var AtD=jQuery.extend({proofread_click_count:0,i18n:{},listener:{}},AtD||{rpc:""});AtD.getLang=function(a,b){if(AtD[a]==undefined)return b;return AtD[a]};AtD.addI18n=function(a){AtD.i18n=a;AtD.core.addI18n(a)}; AtD.setIgnoreStrings=function(a){AtD.core.setIgnoreStrings(a)};AtD.showTypes=function(a){AtD.core.showTypes(a)}; AtD.check=function(a,b){typeof AtD.proofread_click_count!="undefined"&&AtD.proofread_click_count++;AtD.callback_f=b;AtD.remove(a);var c=jQuery("#"+a);c.html();text=jQuery.trim(c.html());text=encodeURIComponent(text);jQuery.ajax({type:"POST",url:AtD.rpc,data:"data="+text,format:"raw",dataType:jQuery.browser.msie?"text":"xml",error:function(e,d,f){AtD.callback_f!=undefined&&AtD.callback_f.error!=undefined&&AtD.callback_f.error(d+": "+f)},success:function(e){var d;if(typeof e=="string"){d=new ActiveXObject("Microsoft.XMLDOM"); d.async=false;d.loadXML(e)}else d=e;if(AtD.core.hasErrorMessage(d))AtD.callback_f!=undefined&&AtD.callback_f.error!=undefined&&AtD.callback_f.error(AtD.core.getErrorMessage(d));else{AtD.container=a;e=AtD.processXML(a,d);AtD.callback_f!=undefined&&AtD.callback_f.ready!=undefined&&AtD.callback_f.ready(e);e==0&&AtD.callback_f!=undefined&&AtD.callback_f.success!=undefined&&AtD.callback_f.success(e);AtD.counter=e;AtD.count=e}}})};AtD.remove=function(a){AtD._removeWords(a,null)}; AtD.clickListener=function(a){AtD.core.isMarkedNode(a.target)&&AtD.suggest(a.target)};AtD.processXML=function(a,b){var c=AtD.core.processXML(b);if(c.count>0)c.count=AtD.core.markMyWords(jQuery("#"+a).contents(),c.errors);jQuery("#"+a).unbind("click",AtD.clickListener);jQuery("#"+a).click(AtD.clickListener);return c.count};AtD.useSuggestion=function(a){this.core.applySuggestion(AtD.errorElement,a);AtD.counter--;AtD.counter==0&&AtD.callback_f!=undefined&&AtD.callback_f.success!=undefined&&AtD.callback_f.success(AtD.count)}; AtD.editSelection=function(){AtD.errorElement.parent();AtD.callback_f!=undefined&&AtD.callback_f.editSelection!=undefined&&AtD.callback_f.editSelection(AtD.errorElement)};AtD.ignoreSuggestion=function(){AtD.core.removeParent(AtD.errorElement);AtD.counter--;AtD.counter==0&&AtD.callback_f!=undefined&&AtD.callback_f.success!=undefined&&AtD.callback_f.success(AtD.count)}; AtD.ignoreAll=function(a){var b=AtD.errorElement.text();a=AtD._removeWords(a,b);AtD.counter-=a;AtD.counter==0&&AtD.callback_f!=undefined&&AtD.callback_f.success!=undefined&&AtD.callback_f.success(AtD.count);if(AtD.callback_f!=undefined&&AtD.callback_f.ignore!=undefined&&AtD.rpc_ignore!=undefined){AtD.callback_f.ignore(b);AtD.core.setIgnoreStrings(b)}};AtD.explainError=function(){AtD.callback_f!=undefined&&AtD.callback_f.explain!=undefined&&AtD.callback_f.explain(AtD.explainURL)}; AtD.suggest=function(a){if(jQuery("#suggestmenu").length==0){var b=jQuery('<div id="suggestmenu"></div>');b.prependTo("body")}else{b=jQuery("#suggestmenu");b.hide()}errorDescription=AtD.core.findSuggestion(a);AtD.errorElement=jQuery(a);b.empty();if(errorDescription==undefined)b.append("<strong>"+AtD.getLang("menu_title_no_suggestions","No suggestions")+"</strong>");else if(errorDescription.suggestions.length==0)b.append("<strong>"+errorDescription.description+"</strong>");else{b.append("<strong>"+ errorDescription.description+"</strong>");for(var c=0;c<errorDescription.suggestions.length;c++)(function(e){b.append("<a onclick=\"AtD.useSuggestion('"+e.replace(/'/,"\\'")+"');\">"+e+"</a>")})(errorDescription.suggestions[c])}if(AtD.callback_f!=undefined&&AtD.callback_f.explain!=undefined&&errorDescription.moreinfo!=undefined){b.append('<a onclick="AtD.explainError();" class="spell_sep_top">'+AtD.getLang("menu_option_explain","Explain...")+"</a>");AtD.explainURL=errorDescription.moreinfo}b.append('<a onclick="AtD.ignoreSuggestion();" class="spell_sep_top">'+ AtD.getLang("menu_option_ignore_once","Ignore suggestion")+"</a>");if(AtD.callback_f!=undefined&&AtD.callback_f.editSelection!=undefined){AtD.callback_f!=undefined&&AtD.callback_f.ignore!=undefined&&AtD.rpc_ignore!=undefined?b.append("<a onclick=\"AtD.ignoreAll('"+AtD.container+"');\">"+AtD.getLang("menu_option_ignore_always","Ignore always")+"</a>"):b.append("<a onclick=\"AtD.ignoreAll('"+AtD.container+"');\">"+AtD.getLang("menu_option_ignore_all","Ignore all")+"</a>");b.append("<a onclick=\"AtD.editSelection('"+ AtD.container+'\');" class="spell_sep_bottom spell_sep_top">'+AtD.getLang("menu_option_edit_selection","Edit Selection...")+"</a>")}else AtD.callback_f!=undefined&&AtD.callback_f.ignore!=undefined&&AtD.rpc_ignore!=undefined?b.append("<a onclick=\"AtD.ignoreAll('"+AtD.container+'\');" class="spell_sep_bottom">'+AtD.getLang("menu_option_ignore_always","Ignore always")+"</a>"):b.append("<a onclick=\"AtD.ignoreAll('"+AtD.container+'\');" class="spell_sep_bottom">'+AtD.getLang("menu_option_ignore_all", "Ignore all")+"</a>");c=jQuery(a).offset();a=jQuery(a).width();jQuery(b).css({left:c.left+a+"px",top:c.top+"px"});jQuery(b).fadeIn(200);AtD.suggestShow=true;setTimeout(function(){jQuery("body").bind("click",function(){AtD.suggestShow||jQuery("#suggestmenu").fadeOut(200)})},1);setTimeout(function(){AtD.suggestShow=false},2)};AtD._removeWords=function(a,b){return this.core.removeWords(jQuery("#"+a),b)}; AtD.initCoreModule=function(){var a=new AtDCore;a.hasClass=function(b,c){return jQuery(b).hasClass(c)};a.map=jQuery.map;a.contents=function(b){return jQuery(b).contents()};a.replaceWith=function(b,c){return jQuery(b).replaceWith(c)};a.findSpans=function(b){return jQuery.makeArray(b.find("span"))};a.create=function(b){return jQuery('<span class="mceItemHidden">'+b+"</span>")};a.remove=function(b){return jQuery(b).remove()};a.removeParent=function(b){return jQuery(b).unwrap?jQuery(b).contents().unwrap(): jQuery(b).replaceWith(jQuery(b).html())};a.getAttrib=function(b,c){return jQuery(b).attr(c)};return a};AtD.core=AtD.initCoreModule(); (function(a){a.alerts={verticalOffset:-75,horizontalOffset:0,repositionOnResize:true,overlayOpacity:0.01,overlayColor:"#FFF",draggable:false,okButton:"&nbsp;"+AtD.getLang("button_ok","OK")+"&nbsp;",cancelButton:"&nbsp;"+AtD.getLang("button_cancel","Cancel")+"&nbsp;",dialogClass:null,alert:function(b,c,e){if(c==null)c="Alert";a.alerts._show(c,b,null,"alert",function(d){e&&e(d)})},confirm:function(b,c,e){if(c==null)c="Confirm";a.alerts._show(c,b,null,"confirm",function(d){e&&e(d)})},prompt:function(b, c,e,d){if(e==null)e="Prompt";a.alerts._show(e,b,c,"prompt",function(f){d&&d(f)})},_show:function(b,c,e,d,f){a.alerts._hide();a.alerts._overlay("show");a("BODY").append('<div id="popup_container"><h1 id="popup_title"></h1><div id="popup_content"><div id="popup_message"></div></div></div>');a.alerts.dialogClass&&a("#popup_container").addClass(a.alerts.dialogClass);var m=a.browser.msie&&parseInt(a.browser.version)<=6?"absolute":"fixed";a("#popup_container").css({position:m,zIndex:99999,padding:0,margin:0}); a("#popup_title").text(b);a("#popup_content").addClass(d);a("#popup_message").text(c);a("#popup_message").html(a("#popup_message").text().replace(/\n/g,"<br />"));a("#popup_container").css({minWidth:a("#popup_container").outerWidth(),maxWidth:a("#popup_container").outerWidth()});a.alerts._reposition();a.alerts._maintainPosition(true);switch(d){case "alert":a("#popup_message").after('<div id="popup_panel"><input type="button" value="'+a.alerts.okButton+'" id="popup_ok" /></div>');a("#popup_ok").click(function(){a.alerts._hide(); f(true)});a("#popup_ok").focus().keypress(function(g){if(g.keyCode==13||g.keyCode==27)a("#popup_ok").trigger("click")});break;case "confirm":a("#popup_message").after('<div id="popup_panel"><input type="button" value="'+a.alerts.okButton+'" id="popup_ok" /> <input type="button" value="'+a.alerts.cancelButton+'" id="popup_cancel" /></div>');a("#popup_ok").click(function(){a.alerts._hide();f&&f(true)});a("#popup_cancel").click(function(){a.alerts._hide();f&&f(false)});a("#popup_ok").focus();a("#popup_ok, #popup_cancel").keypress(function(g){g.keyCode== 13&&a("#popup_ok").trigger("click");g.keyCode==27&&a("#popup_cancel").trigger("click")});break;case "prompt":a("#popup_message").append('<br /><input type="text" size="30" id="popup_prompt" />').after('<div id="popup_panel"><input type="button" value="'+a.alerts.okButton+'" id="popup_ok" /> <input type="button" value="'+a.alerts.cancelButton+'" id="popup_cancel" /></div>');a("#popup_prompt").width(a("#popup_message").width());a("#popup_ok").click(function(){var g=a("#popup_prompt").val();a.alerts._hide(); f&&f(g)});a("#popup_cancel").click(function(){a.alerts._hide();f&&f(null)});a("#popup_prompt, #popup_ok, #popup_cancel").keypress(function(g){g.keyCode==13&&a("#popup_ok").trigger("click");g.keyCode==27&&a("#popup_cancel").trigger("click")});e&&a("#popup_prompt").val(e);a("#popup_prompt").focus().select();break}if(a.alerts.draggable)try{a("#popup_container").draggable({handle:a("#popup_title")});a("#popup_title").css({cursor:"move"})}catch(j){}},_hide:function(){a("#popup_container").remove();a.alerts._overlay("hide"); a.alerts._maintainPosition(false)},_overlay:function(b){switch(b){case "show":a.alerts._overlay("hide");a("BODY").append('<div id="popup_overlay"></div>');a("#popup_overlay").css({position:"absolute",zIndex:99998,top:"0px",left:"0px",width:"100%",height:a(document).height(),background:a.alerts.overlayColor,opacity:a.alerts.overlayOpacity});break;case "hide":a("#popup_overlay").remove();break}},_reposition:function(){var b=a(window).height()/2-a("#popup_container").outerHeight()/2+a.alerts.verticalOffset, c=a(window).width()/2-a("#popup_container").outerWidth()/2+a.alerts.horizontalOffset;if(b<0)b=0;if(c<0)c=0;if(a.browser.msie&&parseInt(a.browser.version)<=6)b+=a(window).scrollTop();a("#popup_container").css({top:b+"px",left:c+"px"});a("#popup_overlay").height(a(document).height())},_maintainPosition:function(b){if(a.alerts.repositionOnResize)switch(b){case true:a(window).bind("resize",a.alerts._reposition);break;case false:a(window).unbind("resize",a.alerts._reposition);break}}};jAlert=function(b, c,e){a.alerts.alert(b,c,e)};jConfirm=function(b,c,e){a.alerts.confirm(b,c,e)};jPrompt=function(b,c,e,d){a.alerts.prompt(b,c,e,d)}})(jQuery);AtD.textareas={}; AtD.restoreTextArea=function(a){AtD_ajax_load("hide");var b=AtD.textareas[a];if(!(b==undefined||b.before==b.link.html())){AtD.remove(a);jQuery("#AtD_sync_").remove();var c;c=navigator.appName=="Microsoft Internet Explorer"?jQuery("#"+a).html().replace(/<BR.*?class.*?atd_remove_me.*?>/gi,"\n"):jQuery("#"+a).html();jQuery("#"+a).replaceWith(b.node);jQuery("#"+a).val(c.replace(/\&lt\;/g,"<").replace(/\&gt\;/,">").replace(/\&amp;/g,"&"));jQuery("#"+a).height(b.height);b.link.html(b.before)}}; AtD.checkTextArea=function(a,b,c){AtD._checkTextArea(a,AtD.check,b,c)}; AtD._checkTextArea=function(a,b,c,e){var d=jQuery("#"+a);if(AtD.textareas[a]==undefined){for(var f={},m=function(k,p){if(p.css(k)!="")f[k]=p.css(k)},j=["background-color","color","font-size","font-family","border-top-width","border-bottom-width","border-left-width","border-right-width","border-top-style","border-bottom-style","border-left-style","border-right-style","border-top-color","border-bottom-color","border-left-color","border-right-color","text-align","margin-top","margin-bottom","margin-left", "margin-right","width","line-height","letter-spacing","left","right","top","bottom","position","padding-left","padding-right","padding-top","padding-bottom"],g=0;g<j.length;g++)m(j[g],d);AtD.textareas[a]={node:d,height:d.height(),link:jQuery("#"+c),before:jQuery("#"+c).html(),after:e,style:f}}var i=AtD.textareas[a];if(i.link.html()!=i.before)AtD.restoreTextArea(a);else{i.link.html(i.after);var l=function(){return false};i.link.click(l);var h,o=jQuery('<input type="hidden" />');o.attr("id","AtD_sync_"); o.val(d.val());c=d.attr("name");if(navigator.appName=="Microsoft Internet Explorer"){d.replaceWith('<div id="'+a+'">'+d.val().replace(/\&/g,"&amp;").replace(/[\n\r\f]/gm,'<BR class="atd_remove_me">')+"</div>");h=jQuery("#"+a);h.attr("style",i.node.attr("style"));h.attr("class",i.node.attr("class"));h.css({overflow:"auto"});i.style["font-size"]=undefined;i.style["font-family"]=undefined}else{d.replaceWith('<div id="'+a+'">'+d.val().replace(/\&/g,"&amp;")+"</div>");h=jQuery("#"+a);h.attr("style",i.node.attr("style")); h.attr("class",i.node.attr("class"));h.css({overflow:"auto","white-space":"pre-wrap"});h.attr("contenteditable","true");h.attr("spellcheck",false);h.css({outline:"none"})}h.keypress(function(k){return k.keyCode!=13});o.attr("name",c);h.after(o);var s=false;d=function(){if(!s){s=true;setTimeout(function(){var k;k=navigator.appName=="Microsoft Internet Explorer"?h.html().replace(/<BR.*?class.*?atd_remove_me.*?>/gi,"\n"):h.html();var p=jQuery("<div></div>");p.html(k);AtD.core.removeWords(p);o.val(p.html().replace(/\&lt\;/g, "<").replace(/\&gt\;/,">").replace(/\&amp;/g,"&"));s=false},1500)}};h.keypress(d);h.mousemove(d);h.mouseout(d);h.css(i.style);h.height(i.height);AtD_ajax_load("show");b(a,{ready:function(){i.link.unbind("click",l);AtD_ajax_load("hide")},explain:function(k){window.open(k,"","width=480,height=380,toolbar=0,status=0,resizable=0,location=0,menuBar=0,left="+(screen.width/2-240)+",top="+(screen.height/2-190)).focus()},success:function(k){k==0&&jAlert(AtD.getLang("message_no_errors_found","No writing errors were found!"), AtD.getLang("message_no_errors","No errors!"));AtD.restoreTextArea(a)},error:function(k){i.link.unbind("click",l);k==undefined?jAlert(AtD.getLang("message_server_error_short","There was an error communicating with the spell checking service."),AtD.getLang("message_error","Error!")):jAlert(AtD.getLang("message_server_error_short","There was an error communicating with the spell checking service.")+"\n\n"+k,AtD.getLang("message_error","Error!"));AtD.restoreTextArea(a)},editSelection:function(k){var p= k.text();jPrompt(AtD.getLang("dialog_replace_selection","Replace selection with:"),k.text(),AtD.getLang("dialog_replace","Replace"),function(t){if(t!=null&&p!=t){jQuery(k).html(t);AtD.core.removeParent(k);AtD.counter--;AtD.counter==0&&AtD.restoreTextArea(a)}})},ignore:function(k){AtD_ajax_load("show");jQuery.ajax({type:"POST",url:AtD.rpc_ignore+encodeURI(k).replace(/&/g,"%26"),data:"action=atd_ignore",format:"raw",timeout:5E3,error:function(p,t,v){AtD.callback_f!=undefined&&AtD.callback_f.error!= undefined&&AtD.callback_f.error(t+": "+v)},success:function(){AtD_ajax_load("hide")}})}})}};function AtD_acceptAllChanges(){var a=AtD.core;AtD.core.map(AtD.core.findSpans(jQuery("#"+AtD.current_id)).reverse(),function(b){if(a.isMarkedNode(b)){var c=a.findSuggestion(b);c!=undefined&&c.suggestions!=undefined&&c.suggestions.length>0&&a.applySuggestion(b,c.suggestions[0])}})} function AtD_check(a,b){AtD_ajax_load("show");jQuery.ajax({type:"POST",url:AtD.rpc,data:"data="+jQuery("#"+a).val(),format:"raw",dataType:jQuery.browser.msie?"text":"xml",error:function(){AtD_update_post(a)},success:function(c){var e;if(typeof c=="string"){e=new ActiveXObject("Microsoft.XMLDOM");e.async=false;e.loadXML(c)}else e=c;AtD_ajax_load("hide");AtD.core.hasErrorMessage(e)&&AtD_update_post(a);if(AtD.core.processXML(e).count>0){c=AtD.getLang("dialog_confirm_post","The proofreader has suggestions for your reply. Are you sure you want to post it?")+ "\n\n"+AtD.getLang("dialog_confirm_post2","Press OK to post your reply, or Cancel to view the suggestions and edit your reply.");jConfirm(c,"",function(d){d==true?AtD_update_post(a):b.click()})}else AtD_update_post(a)}})}function AtD_update_post(a){AtD.proofread_click_count=2;jQuery("#"+a).parents("form").submit()} function AtD_ajax_load(a){if(a==undefined)jQuery(".atd-ajax-load").css("height")=="16px"?jQuery(".atd-ajax-load").css("height","0"):jQuery(".atd-ajax-load").css("height","16px");else a=="show"?jQuery(".atd-ajax-load").css("height","16px"):jQuery(".atd-ajax-load").css("height","0")} jQuery.fn.addProofreader=function(a){this.id=0;var b=this,c=jQuery.extend({},jQuery.fn.addProofreader.defaults,a);return this.each(function(){$this=jQuery(this);if($this.css("display")!="none"){$this.attr("id").length==0&&$this.attr("id","AtD_"+b.id++);var e=$this.attr("id"),d=jQuery("<span></span>");d.attr("id","AtD_"+b.id++);d.html(c.proofread_content);d.click(function(){AtD.current_id!=undefined&&AtD.current_id!=e&&AtD.restoreTextArea(AtD.current_id);if($this.val()!=""){AtD.checkTextArea(e,d.attr("id"), c.edit_text_content);AtD.current_id=e}else jAlert(AtD.getLang("message_error_no_text","Please enter some text in the post textbox to be checked!"),AtD.getLang("message_error","Error!"))});$this.wrap("<div></div>");$this.before('<span class="atd-ajax-load"></span>');$this.parents("form").submit(function(f){AtD.restoreTextArea(e);if(AtD.autoproofread!=undefined&&AtD.autoproofread==1&&AtD.proofread_click_count<=0&&$this.val()!=""){f.preventDefault();AtD_check(e,d)}});$this.before(d)}})}; jQuery.fn.addProofreader.defaults={edit_text_content:'<span class="atd_container"><a class="checkLink">'+AtD.getLang("button_edit_text","Edit Text")+'</a> | <a class="acceptAllLink" onclick="AtD_acceptAllChanges();">'+AtD.getLang("button_accept_all","Accept All")+"</a></span>",proofread_content:'<span class="atd_container"><a class="checkLink">'+AtD.getLang("button_proofread","Proofread")+"</a></span>"}; jQuery(function(){jQuery("textarea").addProofreader();AtD.ignoreStrings!=undefined&&AtD.setIgnoreStrings(AtD.ignoreStrings);AtD.ignoreTypes!=undefined&&AtD.showTypes(AtD.ignoreTypes)}); 
  • /after-the-deadline/trunk/scripts/profile.dev.js

    r2902 r2904  
    4848function atd_ignore_init() { 
    4949        jQuery( '#atd_message' ).hide(); 
    50         atd_show_phrases( jQuery( '#atd_ignored_phrases' ).val().split( /,/g ) ); 
     50        if(jQuery( '#atd_ignored_phrases' ).val()) 
     51                atd_show_phrases( jQuery( '#atd_ignored_phrases' ).val().split( /,/g ) ); 
    5152} 
    5253 
  • /after-the-deadline/trunk/translations/after-the-deadline-hi_IN.po

    r2902 r2904  
    55"Project-Id-Version: After the Deadline\n" 
    66"Report-Msgid-Bugs-To: http://wordpress.org/tag/after-the-deadline\n" 
    7 "POT-Creation-Date: 2010-03-24 08:03+0000\n" 
    8 "PO-Revision-Date: 2010-03-24 13:36+0530\n" 
     7"POT-Creation-Date: 2010-06-13 11:10+0000\n" 
     8"PO-Revision-Date: 2010-06-13 16:50+0530\n" 
    99"Last-Translator: Gautam <gautam.2011@gmail.com>\n" 
    1010"Language-Team: \n" 
     
    4646msgstr "à€†à€«à¥à€Ÿà€° à€Šà¥€ à€¡à¥‡à€¡à€²à€Ÿà€‡à€š à€•à€Ÿ à€šà€¯à€Ÿ à€žà€‚à€žà¥à€•à€°à€£ (%1$s) à€‰à€ªà€²à€¬à¥à€§ à€¹à¥ˆ! à€•à¥ƒà€ªà¥à€¯à€Ÿ à€‰à€žà¥‡ <a href=\"%2$s\">à€¯à€¹à€Ÿà€</a> à€žà¥‡ à€¡à€Ÿà€‰à€šà€²à¥‹à€¡ à€•à€°à¥‡à€‚|" 
    4747 
    48 #: includes/admin.php:58 
    49 msgid "The options have been successfully saved!" 
    50 msgstr "à€µà€¿à€•à€²à¥à€ª à€žà€«à€²à€€à€Ÿà€ªà¥‚à€°à¥à€µà€• à€Šà€°à¥à€œ à€•à€°à€²à€¿à€ à€—à€ à€¹à¥ˆà€‚|" 
    51  
    52 #: includes/admin.php:67 
     48#: includes/admin.php:57 
     49#, php-format 
     50msgid "The options have been successfully saved! Maybe you would consider <a href=\"%s\">donating</a>." 
     51msgstr "à€µà€¿à€•à€²à¥à€ª à€žà€«à€²à€€à€Ÿà€ªà¥‚à€°à¥à€µà€• à€Šà€°à¥à€œ à€•à€°à€²à€¿à€ à€—à€ à€¹à¥ˆà€‚| à€¶à€Ÿà€¯à€Š à€†à€ª <a href=\"%s\">à€•à¥à€› à€Šà€Ÿà€š</a> à€•à€°à€šà€Ÿ à€šà€Ÿà€¹à¥‡à€‚à€—à¥‡|" 
     52 
     53#: includes/admin.php:66 
    5354msgid "Language" 
    5455msgstr "à€­à€Ÿà€·à€Ÿ" 
    5556 
    56 #: includes/admin.php:71 
     57#: includes/admin.php:70 
    5758#, php-format 
    5859msgid "Proofreading should be done for which language? The plugin currently supports the following languages - %s." 
     
    6061à€­à¥€ à€šà€¿à€®à¥à€šà€²à€¿à€–à€¿à€€ à€­à€Ÿà€·à€Ÿà€“à€‚ à€•à€Ÿ à€žà€®à€°à¥à€¥à€š à€•à€°à€€à€Ÿ à€¹à¥ˆ - %s|" 
    6162 
    62 #: includes/admin.php:74 
     63#: includes/admin.php:73 
    6364msgid "Enable the user to select the option for:" 
    6465msgstr "à€‰à€ªà€¯à¥‹à€—à€•à€°à¥à€€à€Ÿ à€•à¥‹ à€¯à€¹ à€µà€¿à€•à€²à¥à€ª à€šà¥à€šà€šà¥‡ à€•à¥€ à€ 
    6566à€šà¥à€®à€€à€¿ à€¹à¥ˆ:" 
    6667 
    67 #: includes/admin.php:76 
     68#: includes/admin.php:75 
    6869msgid "These options will be shown on the user's profile page. All of these options are disabled by default." 
    6970msgstr "à€¯à€¹ à€µà€¿à€•à€²à¥à€ª à€‰à€ªà€¯à¥‹à€—à€•à€°à¥à€€à€Ÿ à€•à¥‡ à€ªà¥à€°à¥‹à€«à€Œà€Ÿà€‡à€² à€ªà¥ƒà€·à¥à€  à€ªà€° à€Šà€¿à€–à€Ÿà€ à€œà€Ÿà€à€—à¥‡à€‚| à€žà€Ÿà€°à¥‡ à€µà€¿à€•à€²à¥à€ª à€¡à€¿à€«à€Œà¥‰à€²à¥à€Ÿ à€°à¥‚à€ª à€žà¥‡ à€ 
    7071à€•à¥à€·à€® à€¹à¥ˆà€‚|" 
    7172 
    72 #: includes/admin.php:79 
     73#: includes/admin.php:78 
    7374msgid "Autoproofreading the content if it is not proofread once before posting" 
    7475msgstr "à€ªà¥‹à€žà¥à€Ÿ à€•à¥‹ à€œà€®à€Ÿ à€•à€°à€šà¥‡ à€žà¥‡ à€ªà€¹à€²à¥‡ à€œà€Ÿà€à€šà€šà€Ÿ à€¯à€Šà€¿ à€µà¥‡à€¹ à€œà€Ÿà€à€šà¥€ à€šà€¹à¥€à€‚ à€—à€¯à¥€ à€¹à¥ˆ" 
    7576 
    76 #: includes/admin.php:83 
     77#: includes/admin.php:82 
    7778msgid "Ignoring a term forever (ignored terms can be removed from the profile page)" 
    7879msgstr "à€¹à€®à¥‡à€¶à€Ÿ à€µà€°à¥à€€à€šà¥€ à€•à¥€ à€‰à€ªà¥‡à€•à¥à€·à€Ÿ à€•à€°à€šà€Ÿ (à€‡à€šà¥à€¹à¥‡à€‚ à€ªà¥à€°à¥‹à€«à€Œà€Ÿà€‡à€² à€ªà¥ƒà€·à¥à€  à€žà¥‡ à€­à¥€ à€¹à€Ÿà€Ÿà€¯à€Ÿ à€œà€Ÿ à€žà€•à€€à€Ÿ à€¹à¥ˆ)" 
    7980 
    80 #: includes/admin.php:87 
     81#: includes/admin.php:86 
    8182msgid "Setting ignore types" 
    8283msgstr "à€šà€¿à€¶à¥à€šà€¿à€€ à€ªà¥à€°à€•à€Ÿà€°à¥‹à€‚ à€ªà€° à€§à¥à€¯à€Ÿà€š à€š à€Šà¥‡à€šà¥‡ à€•à€Ÿ à€µà€¿à€•à€²à¥à€ª" 
    8384 
    84 #: includes/admin.php:95 
     85#: includes/admin.php:94 
    8586msgid "After the Deadline Options" 
    8687msgstr "à€†à€«à¥à€Ÿà€° à€Šà¥€ à€¡à¥‡à€¡à€²à€Ÿà€‡à€š à€•à¥‡ à€µà€¿à€•à€²à¥à€ª" 
    8788 
    88 #: includes/admin.php:109 
    89 #, php-format 
    90 msgid "Happy with the plugin? Why not <a href=\"%1$s\">buy the author a cup of coffee or two</a> or get him something from his <a href=\"%2$s\">wishlist</a>?" 
    91 msgstr "à€ªà¥à€²à€—à€¿à€š à€žà¥‡ à€–à¥à€¶? à€²à€¿à€–à€šà¥‡ à€µà€Ÿà€²à¥‡ à€•à¥‹ à€•à¥à€› <a href=\"%1$s\">à€Šà€Ÿà€š</a> à€Šà¥€à€œà€¿à€¯à¥‡ à€¯à€Ÿ à€«à€¿à€° à€‰à€žà€•à¥€ <a href=\"%2$s\">à€‡à€šà¥à€›à€Ÿ à€žà¥‚à€šà¥€</a> à€Šà¥‡à€–à€¿à€¯à¥‡|" 
    92  
    93 #. #-#-#-#-#  plugin.pot (After the Deadline 1.6)  #-#-#-#-# 
    94 #. Plugin Name of an extension 
    95 #: includes/admin.php:120 
     89#: includes/admin.php:106 
     90#, php-format 
     91msgid "Happy with the plugin? Why not <a href=\"%1$s\">buy the author a cup of coffee or two</a> or <a href=\"%2$s\">follow him on twitter</a> (or even visit his <a href=\"%3$s\">website</a>)." 
     92msgstr "à€ªà¥à€²à€—à€¿à€š à€žà¥‡ à€–à¥à€¶? à€²à€¿à€–à€šà¥‡ à€µà€Ÿà€²à¥‡ à€•à¥‹ à€•à¥à€› <a href=\"%1$s\">à€Šà€Ÿà€š</a> à€Šà¥€à€œà€¿à€¯à¥‡ à€¯à€Ÿ à€«à€¿à€° à€‰à€žà€•à¥‹ <a href=\"%2$s\">à€Ÿà¥à€µà€¿à€Ÿà¥à€Ÿà€° à€ªà€° à€«à¥‹à€²à¥‹</a> à€•à€°à¥‡à€‚ (à€¯à€Ÿ à€‰à€žà€•à¥€ <a href=\"%3$s\">à€µà¥‡à€¬à€žà€Ÿà€‡à€Ÿ</a> à€Šà¥‡à€–à¥‡à€‚)|" 
     93 
     94#: includes/admin.php:107 
     95msgid "Save Changes" 
     96msgstr "à€µà€¿à€•à€²à¥à€ª à€œà€®à€Ÿ à€•à€°à¥‡à€‚" 
     97 
     98#. #-#-#-#-#  plugin.pot (After the Deadline 1.7)  #-#-#-#-# 
     99#. Plugin Name of the plugin/theme 
     100#: includes/admin.php:119 
    96101msgid "After the Deadline" 
    97102msgstr "à€†à€«à¥à€Ÿà€° à€Šà¥€ à€¡à¥‡à€¡à€²à€Ÿà€‡à€š" 
    98103 
    99 #: includes/profile-options.php:70 
     104#: includes/profile-options.php:69 
    100105msgid "Proofreading Options" 
    101106msgstr "à€µà€°à¥à€€à€šà¥€ à€œà€Ÿà€à€šà€šà¥‡ à€•à¥‡ à€µà€¿à€•à€²à¥à€ª" 
    102107 
    103 #: includes/profile-options.php:74 
     108#: includes/profile-options.php:73 
    104109msgid "Auto Proofread" 
    105110msgstr "à€žà¥à€µà€€: à€µà€°à¥à€€à€šà¥€ à€ à¥€à€• à€•à€°à€šà€Ÿ" 
    106111 
    107 #: includes/profile-options.php:76 
     112#: includes/profile-options.php:75 
    108113msgid "Automatically proofread content when I forget to do a spellcheck" 
    109114msgstr "à€ªà¥‹à€žà¥à€Ÿ à€•à¥‹ à€œà€®à€Ÿ à€•à€°à€šà¥‡ à€žà¥‡ à€ªà€¹à€²à¥‡ à€œà€Ÿà€à€šà€¿à€ à€¯à€Šà€¿ à€®à¥ˆà€‚ à€µà€°à¥à€€à€šà¥€ à€œà€Ÿà€à€šà€šà€Ÿ à€­à¥‚à€² à€œà€Ÿà€€à€Ÿ à€¹à¥‚à€|" 
    110115 
    111 #: includes/profile-options.php:84 
     116#: includes/profile-options.php:83 
    112117msgid "Grammar and Styles" 
    113118msgstr "à€µà¥à€¯à€Ÿà€•à€°à€£ à€”à€° à€¶à¥ˆà€²à€¿à€¯à€Ÿà€" 
    114119 
    115 #: includes/profile-options.php:86 
     120#: includes/profile-options.php:85 
    116121msgid "Enable proofreading for the following grammar and style rules when writing posts and pages:" 
    117122msgstr "à€šà€¿à€®à¥à€šà€²à€¿à€–à€¿à€€ à€µà¥à€¯à€Ÿà€•à€°à€£ à€”à€° à€¶à¥ˆà€²à¥€ à€•à¥‹ à€ªà¥‹à€žà¥à€Ÿ à€”à€° à€ªà¥ƒà€·à¥à€  à€²à€¿à€–à€šà¥‡ à€•à¥‡ à€žà€®à€¯ à€žà€•à¥à€·à€® à€•à€°à¥‡à€‚:" 
    118123 
    119 #: includes/profile-options.php:93 
     124#: includes/profile-options.php:92 
    120125msgid "Bias Language" 
    121126msgstr "à€ªà¥‚à€°à¥à€µà€Ÿà€—à¥à€°à€¹ à€­à€Ÿà€·à€Ÿ" 
    122127 
    123 #: includes/profile-options.php:94 
     128#: includes/profile-options.php:93 
    124129msgid "Clich&eacute;s" 
    125130msgstr "à€•à¥à€²à¥€à€¶à¥‡" 
    126131 
    127 #: includes/profile-options.php:95 
     132#: includes/profile-options.php:94 
    128133msgid "Complex Phrases" 
    129134msgstr "à€œà€Ÿà€¿à€² à€µà€Ÿà€•à¥à€¯à€Ÿà€‚à€¶" 
    130135 
    131 #: includes/profile-options.php:96 
     136#: includes/profile-options.php:95 
    132137msgid "Diacritical Marks" 
    133138msgstr "à€µà€¿à€¶à¥‡à€·à€• à€®à€Ÿà€°à¥à€•à¥à€ž" 
    134139 
    135 #: includes/profile-options.php:97 
     140#: includes/profile-options.php:96 
    136141msgid "Double Negatives" 
    137142msgstr "à€Šà¥‹ à€šà€•à€Ÿà€°à€Ÿà€€à¥à€®à€•" 
    138143 
    139 #: includes/profile-options.php:102 
     144#: includes/profile-options.php:101 
    140145msgid "Hidden Verbs" 
    141146msgstr "à€›à€¿à€ªà¥€ à€•à¥à€°à€¿à€¯à€Ÿ" 
    142147 
    143 #: includes/profile-options.php:103 
     148#: includes/profile-options.php:102 
    144149msgid "Jargon" 
    145150msgstr "à€µà€°à¥à€—-à€¬à¥‹à€²à¥€" 
    146151 
    147 #: includes/profile-options.php:104 
     152#: includes/profile-options.php:103 
    148153msgid "Passive Voice" 
    149154msgstr "à€•à€°à¥à€®à€µà€Ÿà€šà¥à€¯" 
    150155 
    151 #: includes/profile-options.php:105 
     156#: includes/profile-options.php:104 
    152157msgid "Phrases to Avoid" 
    153158msgstr "à€œà€¿à€š à€µà€Ÿà€•à¥à€¯à€Ÿà€‚à€¶à¥‹à€‚ à€•à¥‹ à€ 
    154159à€šà€Šà¥‡à€–à€Ÿ à€•à€°à€šà€Ÿ à€¹à¥ˆ" 
    155160 
    156 #: includes/profile-options.php:106 
     161#: includes/profile-options.php:105 
    157162msgid "Redundant Phrases" 
    158163msgstr "à€šà€¿à€°à€°à¥à€¥à€• à€µà€Ÿà€•à¥à€¯à€Ÿà€‚à€¶" 
    159164 
    160 #: includes/profile-options.php:113 
     165#: includes/profile-options.php:112 
    161166#, php-format 
    162167msgid "<a href=\"%s\">Learn more</a> about these options." 
    163168msgstr "à€‡à€š à€µà€¿à€•à€²à¥‹à€‚ à€•à¥‡ à€¬à€Ÿà€°à¥‡ à€®à¥ˆà€‚ <a href=\"%s\">à€œà¥à€¯à€Ÿà€Šà€Ÿ à€œà€Ÿà€šà¥‡à€‚</a>|" 
    164169 
    165 #: includes/profile-options.php:124 
     170#: includes/profile-options.php:123 
    166171msgid "Ignored Phrases" 
    167172msgstr "à€‰à€ªà¥‡à€•à¥à€·à€¿à€€ à€µà€Ÿà€•à¥à€¯à€Ÿà€‚à€¶" 
    168173 
    169 #: includes/profile-options.php:127 
     174#: includes/profile-options.php:126 
    170175msgid "Identify words and phrases to ignore while proofreading your posts and pages:" 
    171176msgstr "à€µà€°à¥à€€à€šà¥€ à€œà€Ÿà€‚à€šà€€à¥‡ à€žà€®à¥‡, à€‡à€š à€¶à€¬à¥à€Šà¥‹à€‚ à€”à€° à€µà€Ÿà€•à¥à€¯à€Ÿà€‚à€¶à¥‹à€‚ à€•à¥‹ à€šà€œà€°à€ 
    172177à€‚à€Šà€Ÿà€œ à€•à€°à¥‡à€‚:" 
    173178 
    174 #: includes/profile-options.php:128 
     179#: includes/profile-options.php:127 
    175180msgid "Add" 
    176181msgstr "à€œà€®à€Ÿ à€•à€°à¥‡à€‚" 
    177182 
    178 #: includes/profile-options.php:131 
     183#: includes/profile-options.php:130 
    179184msgid "Be sure to click \"Update Profile\" at the bottom of the screen to save your changes." 
    180185msgstr "\"à€ 
    181186à€ªà€¡à¥‡à€Ÿ à€ªà¥à€°à¥‹à€«à€Ÿà€‡à€²\" à€¬à€Ÿà€š à€•à¥‹ à€•à€® à€¹à¥‹à€šà¥‡ à€•à¥‡ à€¬à€Ÿà€Š à€Šà€¬à€Ÿà€šà€Ÿ à€š à€­à¥‚à€²à¥‡à€‚|" 
    182187 
    183 #: includes/public.php:24 
     188#: includes/public.php:23 
    184189msgid "Proofread" 
    185190msgstr "à€µà€°à¥à€€à€šà¥€ à€œà€Ÿà€à€šà¥‡à€‚" 
    186191 
    187 #: includes/public.php:25 
     192#: includes/public.php:24 
    188193msgid "Edit Text" 
    189194msgstr "à€ªà€Ÿà€  à€žà€‚à€ªà€Ÿà€Šà€¿à€€ à€•à€°à¥‡à€‚" 
     195 
     196#: includes/public.php:25 
     197msgid "Accept All" 
     198msgstr "à€žà€­à¥€ à€žà¥à€µà¥€à€•à€Ÿà€°à¥‡à€‚" 
    190199 
    191200#: includes/public.php:26 
     
    281290à€ªà€šà¥€ à€ªà¥‹à€žà¥à€Ÿ à€•à¥‹ à€žà€‚à€ªà€Ÿà€Šà€¿à€€ à€•à€°à€šà¥‡ à€•à¥‡ à€²à€¿à€ \"à€°à€Šà¥à€Š\" à€Šà€¬à€Ÿà€à€|" 
    282291 
    283 #. Plugin URI of an extension 
     292#. Plugin URI of the plugin/theme 
    284293msgid "http://gaut.am/bbpress/plugins/after-the-deadline/" 
    285294msgstr "http://gaut.am/bbpress/plugins/after-the-deadline/" 
    286295 
    287 #. Description of an extension 
     296#. Description of the plugin/theme 
    288297msgid "After the Deadline plugin checks spelling, style, and grammar in your bbPress forum posts." 
    289298msgstr "à€†à€«à¥à€Ÿà€° à€Šà¥€ à€¡à¥‡à€¡à€²à€Ÿà€‡à€š à€ªà¥à€²à€—à€¿à€š à€†à€ªà€•à¥‡ à€¬à¥à€¬à¥€à€ªà¥à€°à¥‡à€ž à€«à¥‹à€°à€® à€®à¥ˆà€‚ à€µà€°à¥à€€à€šà¥€ à€”à€° à€µà¥à€¯à€Ÿà€•à€°à€£ à€œà€Ÿà€‚à€šà€€à€Ÿ à€¹à¥ˆ|" 
    290299 
    291 #. Author of an extension 
     300#. Author of the plugin/theme 
    292301msgid "Gautam Gupta" 
    293302msgstr "à€—à¥Œà€€à€® à€—à¥à€ªà¥à€€à€Ÿ " 
    294303 
    295 #. Author URI of an extension 
    296 msgid "http://gaut.am/" 
    297 msgstr "http://gaut.am/" 
    298  
     304#. Author URI of the plugin/theme 
     305msgid "http://www.cyberfundu.com/" 
     306msgstr "http://www.cyberfundu.com/" 
     307 
     308#~ msgid "http://gaut.am/" 
     309#~ msgstr "http://gaut.am/" 
     310 
  • /after-the-deadline/trunk/translations/after-the-deadline.pot

    r2902 r2904  
    1 # Translation of the WordPress plugin After the Deadline 1.6 by Gautam Gupta. 
     1# Translation of the WordPress plugin After the Deadline 1.7 by Gautam Gupta. 
    22# Copyright (C) 2010 Gautam Gupta 
    33# This file is distributed under the same license as the After the Deadline package. 
     
    77msgid "" 
    88msgstr "" 
    9 "Project-Id-Version: After the Deadline 1.6\n" 
     9"Project-Id-Version: After the Deadline 1.7\n" 
    1010"Report-Msgid-Bugs-To: http://wordpress.org/tag/after-the-deadline\n" 
    11 "POT-Creation-Date: 2010-03-24 08:03+0000\n" 
     11"POT-Creation-Date: 2010-06-13 11:10+0000\n" 
    1212"PO-Revision-Date: 2010-MO-DA HO:MI+ZONE\n" 
    1313"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" 
     
    5252msgstr "" 
    5353 
    54 #: includes/admin.php:58 
    55 msgid "The options have been successfully saved!" 
    56 msgstr "" 
    57  
    58 #: includes/admin.php:67 
     54#: includes/admin.php:57 
     55#, php-format 
     56msgid "" 
     57"The options have been successfully saved! Maybe you would consider <a href=" 
     58"\"%s\">donating</a>." 
     59msgstr "" 
     60 
     61#: includes/admin.php:66 
    5962msgid "Language" 
    6063msgstr "" 
    6164 
    62 #: includes/admin.php:71 
     65#: includes/admin.php:70 
    6366#, php-format 
    6467msgid "" 
     
    6770msgstr "" 
    6871 
    69 #: includes/admin.php:74 
     72#: includes/admin.php:73 
    7073msgid "Enable the user to select the option for:" 
    7174msgstr "" 
    7275 
    73 #: includes/admin.php:76 
     76#: includes/admin.php:75 
    7477msgid "" 
    7578"These options will be shown on the user's profile page. All of these options " 
     
    7780msgstr "" 
    7881 
    79 #: includes/admin.php:79 
     82#: includes/admin.php:78 
    8083msgid "Autoproofreading the content if it is not proofread once before posting" 
    8184msgstr "" 
    8285 
    83 #: includes/admin.php:83 
     86#: includes/admin.php:82 
    8487msgid "" 
    8588"Ignoring a term forever (ignored terms can be removed from the profile page)" 
    8689msgstr "" 
    8790 
    88 #: includes/admin.php:87 
     91#: includes/admin.php:86 
    8992msgid "Setting ignore types" 
    9093msgstr "" 
    9194 
    92 #: includes/admin.php:95 
     95#: includes/admin.php:94 
    9396msgid "After the Deadline Options" 
    9497msgstr "" 
    9598 
    96 #: includes/admin.php:109 
     99#: includes/admin.php:106 
    97100#, php-format 
    98101msgid "" 
    99102"Happy with the plugin? Why not <a href=\"%1$s\">buy the author a cup of " 
    100 "coffee or two</a> or get him something from his <a href=\"%2$s\">wishlist</" 
    101 "a>?" 
    102 msgstr "" 
    103  
    104 #. #-#-#-#-#  plugin.pot (After the Deadline 1.6)  #-#-#-#-# 
    105 #. Plugin Name of an extension 
    106 #: includes/admin.php:120 
     103"coffee or two</a> or <a href=\"%2$s\">follow him on twitter</a> (or even " 
     104"visit his <a href=\"%3$s\">website</a>)." 
     105msgstr "" 
     106 
     107#: includes/admin.php:107 
     108msgid "Save Changes" 
     109msgstr "" 
     110 
     111#. #-#-#-#-#  plugin.pot (After the Deadline 1.7)  #-#-#-#-# 
     112#. Plugin Name of the plugin/theme 
     113#: includes/admin.php:119 
    107114msgid "After the Deadline" 
    108115msgstr "" 
    109116 
    110 #: includes/profile-options.php:70 
     117#: includes/profile-options.php:69 
    111118msgid "Proofreading Options" 
    112119msgstr "" 
    113120 
    114 #: includes/profile-options.php:74 
     121#: includes/profile-options.php:73 
    115122msgid "Auto Proofread" 
    116123msgstr "" 
    117124 
    118 #: includes/profile-options.php:76 
     125#: includes/profile-options.php:75 
    119126msgid "Automatically proofread content when I forget to do a spellcheck" 
    120127msgstr "" 
    121128 
    122 #: includes/profile-options.php:84 
     129#: includes/profile-options.php:83 
    123130msgid "Grammar and Styles" 
    124131msgstr "" 
    125132 
    126 #: includes/profile-options.php:86 
     133#: includes/profile-options.php:85 
    127134msgid "" 
    128135"Enable proofreading for the following grammar and style rules when writing " 
     
    130137msgstr "" 
    131138 
     139#: includes/profile-options.php:92 
     140msgid "Bias Language" 
     141msgstr "" 
     142 
    132143#: includes/profile-options.php:93 
    133 msgid "Bias Language" 
     144msgid "Clich&eacute;s" 
    134145msgstr "" 
    135146 
    136147#: includes/profile-options.php:94 
    137 msgid "Clich&eacute;s" 
     148msgid "Complex Phrases" 
    138149msgstr "" 
    139150 
    140151#: includes/profile-options.php:95 
    141 msgid "Complex Phrases" 
     152msgid "Diacritical Marks" 
    142153msgstr "" 
    143154 
    144155#: includes/profile-options.php:96 
    145 msgid "Diacritical Marks" 
    146 msgstr "" 
    147  
    148 #: includes/profile-options.php:97 
    149156msgid "Double Negatives" 
    150157msgstr "" 
    151158 
     159#: includes/profile-options.php:101 
     160msgid "Hidden Verbs" 
     161msgstr "" 
     162 
    152163#: includes/profile-options.php:102 
    153 msgid "Hidden Verbs" 
     164msgid "Jargon" 
    154165msgstr "" 
    155166 
    156167#: includes/profile-options.php:103 
    157 msgid "Jargon" 
     168msgid "Passive Voice" 
    158169msgstr "" 
    159170 
    160171#: includes/profile-options.php:104 
    161 msgid "Passive Voice" 
     172msgid "Phrases to Avoid" 
    162173msgstr "" 
    163174 
    164175#: includes/profile-options.php:105 
    165 msgid "Phrases to Avoid" 
    166 msgstr "" 
    167  
    168 #: includes/profile-options.php:106 
    169176msgid "Redundant Phrases" 
    170177msgstr "" 
    171178 
    172 #: includes/profile-options.php:113 
     179#: includes/profile-options.php:112 
    173180#, php-format 
    174181msgid "<a href=\"%s\">Learn more</a> about these options." 
    175182msgstr "" 
    176183 
    177 #: includes/profile-options.php:124 
     184#: includes/profile-options.php:123 
    178185msgid "Ignored Phrases" 
    179186msgstr "" 
    180187 
     188#: includes/profile-options.php:126 
     189msgid "" 
     190"Identify words and phrases to ignore while proofreading your posts and pages:" 
     191msgstr "" 
     192 
    181193#: includes/profile-options.php:127 
    182 msgid "" 
    183 "Identify words and phrases to ignore while proofreading your posts and pages:" 
    184 msgstr "" 
    185  
    186 #: includes/profile-options.php:128 
    187194msgid "Add" 
    188195msgstr "" 
    189196 
    190 #: includes/profile-options.php:131 
     197#: includes/profile-options.php:130 
    191198msgid "" 
    192199"Be sure to click \"Update Profile\" at the bottom of the screen to save your " 
     
    194201msgstr "" 
    195202 
     203#: includes/public.php:23 
     204msgid "Proofread" 
     205msgstr "" 
     206 
    196207#: includes/public.php:24 
    197 msgid "Proofread" 
     208msgid "Edit Text" 
    198209msgstr "" 
    199210 
    200211#: includes/public.php:25 
    201 msgid "Edit Text" 
     212msgid "Accept All" 
    202213msgstr "" 
    203214 
     
    298309msgstr "" 
    299310 
    300 #. Plugin URI of an extension 
     311#. Plugin URI of the plugin/theme 
    301312msgid "http://gaut.am/bbpress/plugins/after-the-deadline/" 
    302313msgstr "" 
    303314 
    304 #. Description of an extension 
     315#. Description of the plugin/theme 
    305316msgid "" 
    306317"After the Deadline plugin checks spelling, style, and grammar in your " 
     
    308319msgstr "" 
    309320 
    310 #. Author of an extension 
     321#. Author of the plugin/theme 
    311322msgid "Gautam Gupta" 
    312323msgstr "" 
    313324 
    314 #. Author URI of an extension 
    315 msgid "http://gaut.am/" 
    316 msgstr "" 
     325#. Author URI of the plugin/theme 
     326msgid "http://www.cyberfundu.com/" 
     327msgstr "" 
Note: See TracChangeset for help on using the changeset viewer.