Changeset 6324
- Timestamp:
- 06/20/08 21:06:57 (2 years ago)
- Location:
- branches/1.7
- Files:
-
- 3 modified
-
interface/owner/communication/comment/index.php (modified) (1 diff)
-
interface/owner/communication/notify/index.php (modified) (2 diffs)
-
lib/model/blog.comment.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/1.7/interface/owner/communication/comment/index.php
r6240 r6324 442 442 <input type="text" id="search" class="input-text" name="search" value="<?php echo htmlspecialchars($search);?>" onkeydown="if (event.keyCode == '13') { document.getElementById('search-form').withSearch.value = 'on'; document.getElementById('search-form').submit(); }" /> 443 443 <input type="hidden" name="withSearch" value="" /> 444 <input type="hidden" name="status" value="<?php echo $_POST['status'];?>" /> 444 445 <input type="submit" class="search-button input-button" value="<?php echo _t('검색');?>" onclick="document.getElementById('search-form').withSearch.value = 'on'; document.getElementById('search-form').submit();" /> 445 446 </div> -
branches/1.7/interface/owner/communication/notify/index.php
r5926 r6324 5 5 if (isset($_POST['page'])) 6 6 $_GET['page'] = $_POST['page']; 7 if (isset($_GET['category'])) $_POST['category'] = $_GET['category']; 8 if (isset($_GET['ip'])) $_POST['ip'] = $_GET['ip']; 9 if (isset($_GET['name'])) $_POST['name'] = $_GET['name']; 10 if (isset($_GET['perPage'])) $_POST['perPage'] = $_GET['perPage']; 11 if (isset($_GET['search'])) $_POST['search'] = $_GET['search']; 12 if (isset($_GET['withSearch'])) $_POST['withSearch'] = $_GET['withSearch']; 13 7 14 if(count($_POST) > 0) { 8 15 $IV = array( … … 173 180 174 181 <form id="list-form" method="post" action="<?php echo $blogURL;?>/owner/communication/notify"> 182 <?php 183 if(isset($_POST['search'])) echo ' <input type="hidden" name="search" value="'.$_POST['search'].'" />'.CRLF; 184 if(isset($_POST['withSearch'])) echo ' <input type="hidden" name="withSearch" value="'.$_POST['withSearch'].'" />'.CRLF; 185 ?> 175 186 <table class="data-inbox" cellspacing="0" cellpadding="0"> 176 187 <thead> -
branches/1.7/lib/model/blog.comment.php
r6298 r6324 125 125 function getCommentsNotifiedWithPagingForOwner($blogid, $category, $name, $ip, $search, $page, $count) { 126 126 global $database; 127 $postfix = ''; 128 127 129 if (empty($name) && empty($ip) && empty($search)) { 128 130 $sql = "SELECT … … 166 168 {$database['prefix']}CommentsNotifiedSiteInfo csiteinfo ON c.siteId = csiteinfo.id 167 169 WHERE c.blogid = $blogid AND (c.parent is null) "; 168 if (!empty($name)) 170 if (!empty($name)) { 169 171 $sql .= ' AND ( c.name = \'' . POD::escapeString($name) . '\') ' ; 170 if (!empty($ip)) 172 $postfix .= '&name=' . rawurlencode($name); 173 } 174 if (!empty($ip)) { 171 175 $sql .= ' AND ( c.ip = \'' . POD::escapeString($ip) . '\') '; 176 $postfix .= '&ip=' . rawurlencode($ip); 177 } 172 178 if (!empty($search)) { 173 179 $sql .= " AND ((c.name LIKE '%$search%') OR (c.homepage LIKE '%$search%') OR (c.comment LIKE '%$search%')) "; 180 $postfix .= '&search=' . rawurlencode($search); 174 181 } 175 182 $sql .= $childListStr . ' ORDER BY c.modified DESC'; 176 183 } 177 return fetchWithPaging($sql, $page, $count); 184 185 list($comments, $paging) = fetchWithPaging($sql, $page, $count); 186 if (strlen($postfix) > 0) { 187 $postfix .= '&withSearch=on'; 188 $paging['postfix'] .= $postfix; 189 } 190 191 return array($comments, $paging); 178 192 } 179 193
