Index: trunk/extensions/SemanticMediaWiki/specials/SearchTriple/SMW_SpecialPageProperty.php |
— | — | @@ -53,7 +53,7 @@ |
54 | 54 | } |
55 | 55 | |
56 | 56 | $subject = SMWDataValueFactory::newTypeIDValue( '_wpg', $pagename ); |
57 | | - $pagename = $subject->isValid() ? $subject->getText() : ''; |
| 57 | + $pagename = $subject->isValid() ? $subject->getPrefixedText() : ''; |
58 | 58 | $property = SMWPropertyValue::makeUserProperty( $propname ); |
59 | 59 | $propname = $property->isValid() ? $property->getWikiValue() : ''; |
60 | 60 | |
— | — | @@ -62,6 +62,7 @@ |
63 | 63 | if ( ( $propname == '' ) ) { // no property given, show a message |
64 | 64 | $html .= wfMsg( 'smw_pp_docu' ) . "\n"; |
65 | 65 | } else { // property given, find and display results |
| 66 | + // FIXME: very ugly, needs i18n |
66 | 67 | $wgOut->setPagetitle( ( $pagename != '' ? $pagename . ' ':'' ) . $property->getWikiValue() ); |
67 | 68 | |
68 | 69 | // get results (get one more, to see if we have to add a link to more) |
— | — | @@ -77,7 +78,7 @@ |
78 | 79 | $navigation = Html::element( |
79 | 80 | 'a', |
80 | 81 | array( |
81 | | - 'href' => SpecialPage::getSafeTitleFor( 'PageProperty' )->getLocalURL( array( |
| 82 | + 'href' => $this->getTitle()->getLocalURL( array( |
82 | 83 | 'offset' => max( 0, $offset - $limit ), |
83 | 84 | 'limit' => $limit, |
84 | 85 | 'type' => $propname, |
— | — | @@ -100,7 +101,7 @@ |
101 | 102 | $navigation = Html::element( |
102 | 103 | 'a', |
103 | 104 | array( |
104 | | - 'href' => SpecialPage::getSafeTitleFor( 'PageProperty' )->getLocalURL( array( |
| 105 | + 'href' => $this->getTitle()->getLocalURL( array( |
105 | 106 | 'offset' => ( $offset + $limit ), |
106 | 107 | 'limit' => $limit, |
107 | 108 | 'type' => $propname, |
— | — | @@ -146,7 +147,7 @@ |
147 | 148 | } |
148 | 149 | |
149 | 150 | // Display query form |
150 | | - $spectitle = SpecialPage::getTitleFor( 'PageProperty' ); |
| 151 | + $spectitle = $this->getTitle(); |
151 | 152 | $html .= '<p> </p>'; |
152 | 153 | $html .= '<form name="pageproperty" action="' . $spectitle->escapeLocalURL() . '" method="get">' . "\n" . |
153 | 154 | '<input type="hidden" name="title" value="' . $spectitle->getPrefixedText() . '"/>' ; |