Changeset 1652 in subversion
- Timestamp:
- Aug 15, 2008 6:00:33 PM (5 years ago)
- Location:
- trunk/roundcubemail
- Files:
-
- 3 edited
-
CHANGELOG (modified) (1 diff)
-
program/js/tiny_mce/plugins/spellchecker/classes/GoogleSpell.php (modified) (3 diffs)
-
program/js/tiny_mce/plugins/spellchecker/config.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/roundcubemail/CHANGELOG
r1651 r1652 8 8 - Added pspell support patch by Kris Steinhoff (#1483960) 9 9 - Enable spellchecker for HTML editor (#1485114) 10 - Respect spellcheck_uri in tinyMCE spellchecker (#1484196) 10 11 11 12 2008/08/09 (alec) -
trunk/roundcubemail/program/js/tiny_mce/plugins/spellchecker/classes/GoogleSpell.php
r1651 r1652 54 54 $port = 443; 55 55 $path = "/tbproxy/spell?lang=" . $lang . "&hl=en"; 56 $host = "www.google.com"; 57 $url = "https://" . $server; 56 $ssl = true; 57 58 // spell check uri is configured (added by RoundCube) 59 if (!empty($this->_config['rpc_uri'])) { 60 $a_uri = parse_url($this->_config['rpc_uri']); 61 $ssl = ($a_uri['scheme']=='https' || $a_uri['scheme']=='ssl'); 62 $port = $a_uri['port'] ? $a_uri['port'] : ($ssl ? 443 : 80); 63 $server = $a_uri['host']; 64 $path = $a_uri['path'] . ($a_uri['query'] ? '?'.$a_uri['query'] : '') . $lang; 65 } 58 66 59 67 // Setup XML request … … 75 83 // Use curl 76 84 $ch = curl_init(); 77 curl_setopt($ch, CURLOPT_URL, $url);85 curl_setopt($ch, CURLOPT_URL, ($ssl ? "https://" : "http://") . $server); 78 86 curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); 79 87 curl_setopt($ch, CURLOPT_CUSTOMREQUEST, $header); … … 83 91 } else { 84 92 // Use raw sockets 85 $fp = fsockopen( "ssl://". $server, $port, $errno, $errstr, 30);93 $fp = fsockopen(($ssl ? "ssl://" : "") . $server, $port, $errno, $errstr, 30); 86 94 if ($fp) { 87 95 // Send request -
trunk/roundcubemail/program/js/tiny_mce/plugins/spellchecker/config.php
r1651 r1652 8 8 $rcmail_config = new rcube_config(); 9 9 $config['general.engine'] = $rcmail_config->get('spellcheck_engine') == 'pspell' ? 'PSpell' : 'GoogleSpell'; 10 $config['GoogleSpell.rpc_uri'] = $rcmail_config->get('spellcheck_uri'); 10 11 11 12 /** end RoundCube specific code */
Note: See TracChangeset
for help on using the changeset viewer.
