Index: trunk/extensions/SemanticForms/includes/SF_FormLinker.php |
— | — | @@ -75,6 +75,8 @@ |
76 | 76 | $propertyName = $property->getWikiValue(); |
77 | 77 | $linkedPageName = $propertyValue->getWikiValue(); |
78 | 78 | } |
| 79 | + // Needed for SMW 1.7 (?) |
| 80 | + $linkedPageName = str_replace( '_', ' ', $linkedPageName ); |
79 | 81 | if ( !is_null( $linkedPageName ) ) { |
80 | 82 | if ( array_key_exists( $linkedPageName, self::$mLinkedPages ) ) { |
81 | 83 | self::$mLinkedPages[$linkedPageName][] = $propertyName; |
— | — | @@ -214,6 +216,10 @@ |
215 | 217 | $form_edit_url .= ( strpos( $form_edit_url, "?" ) ) ? "&" : "?"; |
216 | 218 | $form_edit_url .= "alt_form[$i]=$alt_form"; |
217 | 219 | } |
| 220 | + // Add "redlink=1" to the query string, so that the user will |
| 221 | + // go to the actual page if it now exists. |
| 222 | + $form_edit_url .= ( strpos( $form_edit_url, "?" ) ) ? "&" : "?"; |
| 223 | + $form_edit_url .= "redlink=1"; |
218 | 224 | return $form_edit_url; |
219 | 225 | } |
220 | 226 | |