Changeset 41bece1 in github
- Timestamp:
- May 17, 2007 2:41:24 PM (6 years ago)
- Branches:
- master, HEAD, courier-fix, dev-browser-capabilities, pdo, release-0.6, release-0.7, release-0.8
- Children:
- 258f1e5
- Parents:
- 5870871
- Files:
-
- 8 edited
-
program/include/main.inc (modified) (2 diffs)
-
program/include/rcmail_template.inc (modified) (1 diff)
-
program/js/list.js (modified) (2 diffs)
-
program/steps/addressbook/func.inc (modified) (2 diffs)
-
program/steps/addressbook/mailto.inc (modified) (1 diff)
-
program/steps/mail/func.inc (modified) (7 diffs)
-
skins/default/common.css (modified) (2 diffs)
-
skins/default/mail.css (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
program/include/main.inc
rf115416 r41bece1 754 754 755 755 756 // compose a URL to the given action 757 function rcmail_self_url($action, $p=array(), $task=null) 756 /** 757 * Compose an URL for a specific action 758 * 759 * @param string Request action 760 * @param array More URL parameters 761 * @param string Request task (omit if the same) 762 * @return The application URL 763 */ 764 function rcmail_url($action, $p=array(), $task=null) 758 765 { 759 766 global $MAIN_TASKS, $COMM_PATH; … … 1121 1128 { 1122 1129 return preg_replace('/[\r\n]/', '', $str); 1123 }1124 1125 1126 /**1127 * Compose an URL for a specific action1128 *1129 * @param string Request action1130 * @param array More URL parameters1131 * @return The application URL1132 */1133 function rcmail_url($action, $param=NULL)1134 {1135 $url = $GLOBALS['COMM_PATH'] . '&'.$action;1136 1137 if (is_array($param))1138 foreach ($param as $p => $val)1139 $url .= sprintf('&%s=%s', urlencode($p), urlencode($val));1140 1141 return $url;1142 1130 } 1143 1131 -
program/include/rcmail_template.inc
r7198044 r41bece1 564 564 // make valid href to specific buttons 565 565 if (in_array($attrib['command'], $MAIN_TASKS)) 566 $attrib['href'] = Q(rcmail_ self_url(null, null, $attrib['command']));566 $attrib['href'] = Q(rcmail_url(null, null, $attrib['command'])); 567 567 else if (in_array($attrib['command'], $a_static_commands)) 568 $attrib['href'] = Q(rcmail_ self_url($attrib['command']));568 $attrib['href'] = Q(rcmail_url($attrib['command'])); 569 569 } 570 570 -
program/js/list.js
rf115416 r41bece1 585 585 // get subjects of selectedd messages 586 586 var names = ''; 587 var c, subject, obj;587 var c, node, subject, obj; 588 588 for(var n=0; n<this.selection.length; n++) 589 589 { … … 600 600 601 601 for(c=0; c<obj.childNodes.length; c++) 602 if ( !subject && obj.childNodes[c].nodeName=='TD' && obj.childNodes[c].firstChild && obj.childNodes[c].firstChild.nodeType==3)602 if (obj.childNodes[c].nodeName=='TD' && (node = obj.childNodes[c].firstChild) && (node.nodeType==3 || node.nodeName=='A')) 603 603 { 604 subject = obj.childNodes[c].firstChild.data;604 subject = node.nodeType==3 ? node.data : node.innerHTML; 605 605 names += (subject.length > 50 ? subject.substring(0, 50)+'...' : subject) + '<br />'; 606 break; 606 607 } 607 608 } -
program/steps/addressbook/func.inc
rf115416 r41bece1 72 72 'rcmli'.$local_id, 73 73 !$current ? 'selected' : '', 74 Q(rcmail_ self_url('list', array('_source' => 0))),74 Q(rcmail_url('list', array('_source' => 0))), 75 75 JS_OBJECT_NAME, 76 76 $local_id, … … 90 90 'rcmli'.$dom_id, 91 91 $current == $id ? 'selected' : '', 92 Q(rcmail_ self_url('list', array('_source' => $id))),92 Q(rcmail_url('list', array('_source' => $id))), 93 93 JS_OBJECT_NAME, 94 94 $js_id, -
program/steps/addressbook/mailto.inc
rf115416 r41bece1 37 37 $mailto_id = substr(md5($mailto_str), 0, 16); 38 38 $_SESSION['mailto'][$mailto_id] = $mailto_str; 39 $OUTPUT->command('redirect', rcmail_ self_url('compose', array('_mailto' => $mailto_id), 'mail'));39 $OUTPUT->command('redirect', rcmail_url('compose', array('_mailto' => $mailto_id), 'mail')); 40 40 } 41 41 else -
program/steps/mail/func.inc
r7198044 r41bece1 59 59 // define url for getting message parts 60 60 if (strlen($_GET['_uid'])) 61 $GET_URL = sprintf('%s&_action=get&_mbox=%s&_uid=%d', $COMM_PATH, $IMAP->get_mailbox_name(), get_input_value('_uid', RCUBE_INPUT_GET));61 $GET_URL = rcmail_url('get', array('_mbox'=>$IMAP->get_mailbox_name(), '_uid'=>get_input_value('_uid', RCUBE_INPUT_GET))); 62 62 63 63 … … 234 234 $unread_count ? ' unread' : '', 235 235 $folder['id']==$mbox_name ? ' selected' : '', 236 Q(rcmail_ self_url('', array('_mbox' => $folder['id']))),236 Q(rcmail_url('', array('_mbox' => $folder['id']))), 237 237 JS_OBJECT_NAME, 238 238 $js_name, … … 324 324 $a_show_cols = is_array($CONFIG['list_cols']) ? $CONFIG['list_cols'] : array('subject'); 325 325 $a_sort_cols = array('subject', 'date', 'from', 'to', 'size'); 326 327 $mbox = $IMAP->get_mailbox_name(); 326 328 327 329 // show 'to' instead of from in sent messages 328 if (($ IMAP->get_mailbox_name()==$CONFIG['sent_mbox'] || $IMAP->get_mailbox_name()==$CONFIG['drafts_mbox']) && ($f = array_search('from', $a_show_cols))330 if (($mbox==$CONFIG['sent_mbox'] || $mbox==$CONFIG['drafts_mbox']) && ($f = array_search('from', $a_show_cols)) 329 331 && !array_search('to', $a_show_cols)) 330 332 $a_show_cols[$f] = 'to'; … … 383 385 else 384 386 { 385 $col_name = sprintf('<a href="./#sort" onclick="return %s.command(\'sort\',\'%s\',this)" title="%s">%s</a>', 386 JS_OBJECT_NAME, 387 $col, 388 rcube_label('sortby'), 389 $col_name); 387 $col_name = sprintf( 388 '<a href="./#sort" onclick="return %s.command(\'sort\',\'%s\',this)" title="%s">%s</a>', 389 JS_OBJECT_NAME, 390 $col, 391 rcube_label('sortby'), 392 $col_name); 390 393 } 391 394 } … … 454 457 else if ($col=='subject') 455 458 { 459 $action = $mbox==$CONFIG['drafts_mbox'] ? 'compose' : 'show'; 460 $uid_param = $mbox==$CONFIG['drafts_mbox'] ? '_draf_uid' : '_uid'; 456 461 $cont = Q(rcube_imap::decode_mime_string($header->$col, $header->charset)); 457 462 if (empty($cont)) $cont = Q(rcube_label('nosubject')); 463 $cont = sprintf('<a href="%s" onclick="return false">%s</a>', Q(rcmail_url($action, array($uid_param=>$header->uid, '_mbox'=>$mbox))), $cont); 458 464 } 459 465 else if ($col=='size') … … 514 520 515 521 $a_show_cols = is_array($CONFIG['list_cols']) ? $CONFIG['list_cols'] : array('subject'); 522 $mbox = $IMAP->get_mailbox_name(); 516 523 517 524 // show 'to' instead of from in sent messages 518 if (($ IMAP->get_mailbox_name() == $CONFIG['sent_mbox'] || $IMAP->get_mailbox_name()== $CONFIG['drafts_mbox'])525 if (($mbox == $CONFIG['sent_mbox'] || $mbox == $CONFIG['drafts_mbox']) 519 526 && (($f = array_search('from', $a_show_cols)) !== false) && array_search('to', $a_show_cols) === false) 520 527 $a_show_cols[$f] = 'to'; … … 536 543 else if ($col=='subject') 537 544 { 545 $action = $mbox==$CONFIG['drafts_mbox'] ? 'compose' : 'show'; 546 $uid_param = $mbox==$CONFIG['drafts_mbox'] ? '_draf_uid' : '_uid'; 538 547 $cont = Q(rcube_imap::decode_mime_string($header->$col, $header->charset)); 539 548 if (!$cont) $cont = Q(rcube_label('nosubject')); 549 $cont = sprintf('<a href="%s" onclick="return false">%s</a>', Q(rcmail_url($action, array($uid_param=>$header->uid, '_mbox'=>$mbox))), $cont); 540 550 } 541 551 else if ($col=='size') -
skins/default/common.css
rf115416 r41bece1 290 290 table.records-table tr.selected td 291 291 { 292 font-weight: bold;293 292 color: #FFFFFF; 294 293 background-color: #CC3333; … … 301 300 table.records-table tr.unfocused td 302 301 { 303 font-weight: bold;304 302 color: #FFFFFF; 305 303 background-color: #929292; -
skins/default/mail.css
r281e3ed r41bece1 397 397 398 398 #messagelist thead tr td a, 399 #messagelist t head tr td a:hover399 #messagelist tbody tr td a 400 400 { 401 401 display: block; … … 419 419 } 420 420 421 #messagelist tbody tr td a 422 { 423 color: #000; 424 } 425 421 426 #messagelist col 422 427 { … … 478 483 #messagelist tr.selected td 479 484 { 480 font-weight: bold;481 485 color: #FFFFFF; 482 486 background-color: #CC3333; … … 485 489 #messagelist tr.unfocused td 486 490 { 487 font-weight: bold;488 491 color: #FFFFFF; 489 492 background-color: #929292; 490 493 } 491 494 492 #messagelist tr.selected td a .rcmContactAddress495 #messagelist tr.selected td a 493 496 { 494 497 color: #FFFFFF; 495 498 } 496 499 497 #messagelist tr.unfocused td a .rcmContactAddress500 #messagelist tr.unfocused td a 498 501 { 499 502 color: #FFFFFF; 500 503 } 501 504 502 #messagelist tr.deleted td a .rcmContactAddress505 #messagelist tr.deleted td a 503 506 { 504 507 color: #CCCCCC;
Note: See TracChangeset
for help on using the changeset viewer.
