Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
project
drupal
Commits
8207690a
Commit
8207690a
authored
Apr 21, 2006
by
Steven Wittens
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
-
#56617
: Search ranking criteria depended on eachother.
- XHTML validation of node search form
parent
0d0a939a
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
modules/node.module
modules/node.module
+2
-2
modules/node/node.module
modules/node/node.module
+2
-2
No files found.
modules/node.module
View file @
8207690a
...
...
@@ -692,7 +692,7 @@ function node_search($op = 'search', $keys = null) {
$ranking
[]
=
'%d * (2.0 - 2.0 / (1.0 + nc.totalcount * %f))'
;
$arguments2
[]
=
$weight
;
$arguments2
[]
=
$scale
;
$join2
.
=
' LEFT JOIN {node_counter} nc ON n.nid =
nc.n
id'
;
$join2
.
=
' LEFT JOIN {node_counter} nc ON n
c
.nid =
i.s
id'
;
}
$select2
=
(
count
(
$ranking
)
?
implode
(
' + '
,
$ranking
)
:
'i.relevance'
)
.
' AS score'
;
...
...
@@ -2156,7 +2156,7 @@ function node_form_alter($form_id, &$form) {
'#type'
=>
'submit'
,
'#value'
=>
t
(
'Advanced search'
),
'#prefix'
=>
'<div class="action">'
,
'#suffix'
=>
'</div><br cl
ear="all
" />'
,
'#suffix'
=>
'</div><br cl
ass="clear
" />'
,
);
$form
[
'#validate'
][
'node_search_validate'
]
=
array
();
...
...
modules/node/node.module
View file @
8207690a
...
...
@@ -692,7 +692,7 @@ function node_search($op = 'search', $keys = null) {
$ranking
[]
=
'%d * (2.0 - 2.0 / (1.0 + nc.totalcount * %f))'
;
$arguments2
[]
=
$weight
;
$arguments2
[]
=
$scale
;
$join2
.
=
' LEFT JOIN {node_counter} nc ON n.nid =
nc.n
id'
;
$join2
.
=
' LEFT JOIN {node_counter} nc ON n
c
.nid =
i.s
id'
;
}
$select2
=
(
count
(
$ranking
)
?
implode
(
' + '
,
$ranking
)
:
'i.relevance'
)
.
' AS score'
;
...
...
@@ -2156,7 +2156,7 @@ function node_form_alter($form_id, &$form) {
'#type'
=>
'submit'
,
'#value'
=>
t
(
'Advanced search'
),
'#prefix'
=>
'<div class="action">'
,
'#suffix'
=>
'</div><br cl
ear="all
" />'
,
'#suffix'
=>
'</div><br cl
ass="clear
" />'
,
);
$form
[
'#validate'
][
'node_search_validate'
]
=
array
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment