Index: trunk/extensions/SemanticMediaWiki/specials/AskSpecial/SMW_SpecialQueryCreator.php |
— | — | @@ -65,12 +65,12 @@ |
66 | 66 | $result .= '<br>'; |
67 | 67 | $result .= wfMsg( 'smw_qc_query_help' ); |
68 | 68 | // Main query and format options |
69 | | - $result .= '<table style="width: 100%; ">'. |
70 | | - '<tr><th>' . wfMsg( 'smw_ask_queryhead' ) . "</th>\n<th>" . wfMsg( 'smw_ask_format_as' ) . "</th></tr>". |
71 | | - '<tr>'. |
72 | | - '<td style="padding-right: 7px;">'.$this->getQueryFormBox()."</td>\n" . |
73 | | - '<td style="padding-right: 7px; text-align:center;">'. $formatBox[0] .'</td>'. |
74 | | - '</tr>'. |
| 69 | + $result .= '<table style="width: 100%; ">' . |
| 70 | + '<tr><th>' . wfMsg( 'smw_ask_queryhead' ) . "</th>\n<th>" . wfMsg( 'smw_ask_format_as' ) . "</th></tr>" . |
| 71 | + '<tr>' . |
| 72 | + '<td style="width: 70%; padding-right: 7px;">' . $this->getQueryFormBox() . "</td>\n" . |
| 73 | + '<td style="padding-right: 7px; text-align:center;">' . $formatBox[0] . '</td>' . |
| 74 | + '</tr>' . |
75 | 75 | "</table>\n"; |
76 | 76 | // sorting and prinouts |
77 | 77 | $result .= $this->getPoSortFormBox(); |
— | — | @@ -89,7 +89,7 @@ |
90 | 90 | // additional options |
91 | 91 | $result .= '<div id="additional_options" style="display:none">'; |
92 | 92 | |
93 | | - $result .= $formatBox[1]; //display the format options |
| 93 | + $result .= $formatBox[1]; // display the format options |
94 | 94 | |
95 | 95 | if ( $this->uiCore->getQueryString() != '' ) // hide #ask if there isnt any query defined |
96 | 96 | $result .= $this->getAskEmbedBox(); |
— | — | @@ -188,26 +188,26 @@ |
189 | 189 | $result .= Html::openElement( 'select', array( 'name' => "order[$i]" ) ); |
190 | 190 | |
191 | 191 | $if1 = ( !is_array( $order_values ) or !array_key_exists( $i, $order_values ) or $order_values[$i] == 'NONE' ); |
192 | | - $result .= Xml::option(wfMsg( 'smw_qui_nosort' ), "NONE", $if1); |
| 192 | + $result .= Xml::option( wfMsg( 'smw_qui_nosort' ), "NONE", $if1 ); |
193 | 193 | |
194 | 194 | $if2 = ( is_array( $order_values ) and array_key_exists( $i, $order_values ) and $order_values[$i] == 'ASC' ); |
195 | | - $result .= Xml::option(wfMsg( 'smw_qui_ascorder' ), "ASC", $if2); |
| 195 | + $result .= Xml::option( wfMsg( 'smw_qui_ascorder' ), "ASC", $if2 ); |
196 | 196 | |
197 | 197 | $if3 = ( is_array( $order_values ) and array_key_exists( $i, $order_values ) and $order_values[$i] == 'DESC' ); |
198 | | - $result .= Xml::option(wfMsg( 'smw_qui_descorder' ), "DESC", $if3); |
| 198 | + $result .= Xml::option( wfMsg( 'smw_qui_descorder' ), "DESC", $if3 ); |
199 | 199 | |
200 | | - $result .= Xml::closeElement('select'); |
| 200 | + $result .= Xml::closeElement( 'select' ); |
201 | 201 | |
202 | 202 | $if4 = ( is_array( $display_values ) and array_key_exists( $i, $display_values ) ); |
203 | | - $result .=Xml::checkLabel(wfMsg( 'smw_qui_shownresults' ), "display[$i]", "display$i", $if4 ); |
| 203 | + $result .= Xml::checkLabel( wfMsg( 'smw_qui_shownresults' ), "display[$i]", "display$i", $if4 ); |
204 | 204 | |
205 | | - $result .= Xml::closeElement('div'); |
| 205 | + $result .= Xml::closeElement( 'div' ); |
206 | 206 | } |
207 | 207 | // END: create form elements already submitted earlier via form |
208 | 208 | |
209 | 209 | // create hidden form elements to be cloned later |
210 | 210 | $hidden = Html::openElement( 'div', array( 'id' => 'sorting_starter', 'style' => 'display:none' ) ) . |
211 | | - '<span class="smw-remove"><a> </a></span>'. |
| 211 | + '<span class="smw-remove"><a> </a></span>' . |
212 | 212 | wfMsg( 'smw_qui_property' ) . |
213 | 213 | Xml::input( "property_num", '35' ) . " "; |
214 | 214 | |
— | — | @@ -222,30 +222,34 @@ |
223 | 223 | |
224 | 224 | $hidden = json_encode( $hidden ); |
225 | 225 | |
226 | | - $dialogbox = Xml::openElement('div', array('id'=>'dialog')) . |
227 | | - Xml::checkLabel(wfMsg( 'smw_qui_shownresults' ), '', 'dialog-show-results', true). |
228 | | - '<div id="tab-box">'. |
229 | | - '<ul>'. |
230 | | - '<li><a href="#property-tab">Property</a></li>'. //todo i18n |
231 | | - '<li><a href="#category-tab">Category</a></li>'. //todo i18n |
232 | | - '</ul>'. |
233 | | - '<div id="property-tab">'. |
234 | | - Xml::inputLabel('Property', '','tab-property', 'tab-property'). '<br/>'. //todo i18n |
235 | | - Xml::inputLabel('Label (optional):', '','tab-property-label', 'tab-property-label'). '<br/>'. //todo i18n |
236 | | - 'Format: '. Html::openElement('select', array('name'=>'tab-format')) . //todo i18n |
237 | | - Xml::option('None (default)', 'NONE'). //todo i18n |
238 | | - Xml::option('Simple', '-'). //todo i18n |
239 | | - Xml::option('Numeric', 'n'). //todo i18n |
240 | | - Xml::option('Unit', 'u'). //todo i18n |
241 | | - Xml::option('Custom', 'CUSTOM'). //todo i18n |
242 | | - Xml::closeElement('select'). |
243 | | - Xml::input('format-custom'). |
244 | | - '</div>'. |
245 | | - '<div id="category-tab">'. |
246 | | - 'category options go here'. |
247 | | - '</div>'. |
248 | | - '</div>'. |
249 | | - '<br>Sort by: <select id ="dialog-order">' . //todo i18n |
| 226 | + $dialogbox = Xml::openElement( 'div', array( 'id' => 'dialog', 'title' => 'Advanced Print-Out Options' ) ) . // todo i18n |
| 227 | + Xml::checkLabel( wfMsg( 'smw_qui_shownresults' ), '', 'dialog-show-results', true ) . |
| 228 | + '<div id="tab-box">' . |
| 229 | + '<ul>' . |
| 230 | + '<li><a href="#property-tab">Property</a></li>' . // todo i18n |
| 231 | + '<li><a href="#category-tab">Category</a></li>' . // todo i18n |
| 232 | + '</ul>' . |
| 233 | + '<div id="property-tab">' . |
| 234 | + Xml::inputLabel( 'Property', '', 'tab-property', 'tab-property' ) . '<br/>' . // todo i18n |
| 235 | + Xml::inputLabel( 'Label (optional):', '', 'tab-property-label', 'tab-property-label' ) . '<br/>' . // todo i18n |
| 236 | + 'Format: ' . Html::openElement( 'select', array( 'name' => 'tab-format' ) ) . // todo i18n |
| 237 | + Xml::option( 'None (default)', 'NONE' ) . // todo i18n |
| 238 | + Xml::option( 'Simple', '-' ) . // todo i18n |
| 239 | + Xml::option( 'Numeric', 'n' ) . // todo i18n |
| 240 | + Xml::option( 'Unit', 'u' ) . // todo i18n |
| 241 | + Xml::option( 'Custom', 'CUSTOM' ) . // todo i18n |
| 242 | + Xml::closeElement( 'select' ) . |
| 243 | + Xml::input( 'format-custom' ) . '<br/>' . |
| 244 | + Xml::inputLabel( 'limit (optional):', '', 'tab-property-limit', 'tab-property-limit' ) . '<br/>' . // todo i18n |
| 245 | + '</div>' . |
| 246 | + '<div id="category-tab">' . |
| 247 | + Xml::inputLabel( 'Label (optional):', '', 'tab-category-label', 'tab-category-label' ) . '<br/>' . // todo i18n |
| 248 | + Xml::inputLabel( 'Specify a category (optional)', '', 'tab-category', 'tab-category' ) . '<br/>' . // todo i18n |
| 249 | + 'If result belongs to category, display' . Html::input( 'tab-yes', 'X' ) . '<br/>' . |
| 250 | + 'else display' . Html::input( 'tab-yes', ' ' ) . |
| 251 | + '</div>' . |
| 252 | + '</div>' . |
| 253 | + '<br>Sort by: <select id ="dialog-order">' . // todo i18n |
250 | 254 | '<option value="NONE">' . wfMsg( 'smw_qui_nosort' ) . '</option>' . |
251 | 255 | '<option value="ASC">' . wfMsg( 'smw_qui_ascorder' ) . '</option>' . |
252 | 256 | '<option value="DESC">' . wfMsg( 'smw_qui_descorder' ) . '</option>' . |
— | — | @@ -269,7 +273,7 @@ |
270 | 274 | autoOpen: false, |
271 | 275 | modal: true, |
272 | 276 | resizable: true, |
273 | | - minHeight: 500, |
| 277 | + minHeight: 300, |
274 | 278 | minWidth: 500 |
275 | 279 | }); |
276 | 280 | jQuery('#tab-box').tabs({ |