diff -r dac5fad7ad6a -r 4264ace0855f includes/namespaces/file.php
--- a/includes/namespaces/file.php Fri Jul 30 15:01:06 2010 -0400
+++ b/includes/namespaces/file.php Fri Jul 30 15:49:11 2010 -0400
@@ -188,6 +188,34 @@
$html .= '
';
}
$db->free_result();
+ $html .= '' . $lang->get('onpage_filebox_lbl_pagesusing') . '
';
+ $q = $db->sql_query('SELECT t.page_id, t.namespace, p.name FROM ' . table_prefix . "page_text AS t\n"
+ . " LEFT JOIN enano_pages AS p\n"
+ . " ON ( t.page_id = p.urlname AND t.namespace = p.namespace )\n"
+ . " WHERE t.page_text REGEXP '\\\\[\\\\[:" .
+ addslashes(preg_quote($paths->nslist[$this->namespace])) .
+ addslashes(preg_quote($this->page_id)) .
+ "(\\\\||\\\\])';");
+ if ( !$q )
+ $db->_die();
+
+ if ( $db->numrows() < 1 )
+ {
+ $html .= '' . $lang->get('onpage_filebox_msg_no_inlinks') . '
';
+ }
+ else
+ {
+ $html .= '' . $lang->get('onpage_filebox_msg_pagesusing') . '
';
+ $html .= '';
+ }
+ $db->free_result();
$html .= '
';
return $html;
}