@@ -54,7 +54,7 @@ discard block |
||
| 54 | 54 | // show list of BUDA apps and variants, |
| 55 | 55 | // w/ buttons for adding and deleting |
| 56 | 56 | // |
| 57 | -function app_list($notice=null) { |
|
| 57 | +function app_list($notice = null) { |
|
| 58 | 58 | global $buda_root; |
| 59 | 59 | if (!is_dir($buda_root)) { |
| 60 | 60 | mkdir($buda_root); |
@@ -256,7 +256,7 @@ discard block |
||
| 256 | 256 | // |
| 257 | 257 | $x = "<input_template>\n"; |
| 258 | 258 | $ninfiles = 1 + count($variant_desc->input_file_names) + count($variant_desc->app_files); |
| 259 | - for ($i=0; $i<$ninfiles; $i++) { |
|
| 259 | + for ($i = 0; $i < $ninfiles; $i++) { |
|
| 260 | 260 | $x .= " <file_info>\n <sticky/>\n <no_delete/>\n <executable/>\n </file_info>\n"; |
| 261 | 261 | } |
| 262 | 262 | $x .= " <workunit>\n"; |
@@ -286,7 +286,7 @@ discard block |
||
| 286 | 286 | ); |
| 287 | 287 | |
| 288 | 288 | $x .= sprintf(" <max_delay>%f</max_delay>\n", |
| 289 | - $variant_desc->max_delay_days * 86400. |
|
| 289 | + $variant_desc->max_delay_days*86400. |
|
| 290 | 290 | ); |
| 291 | 291 | |
| 292 | 292 | $x .= " </workunit>\n<input_template>\n"; |
@@ -476,8 +476,8 @@ discard block |
||
| 476 | 476 | } |
| 477 | 477 | } |
| 478 | 478 | |
| 479 | -function app_form($desc=null) { |
|
| 480 | - page_head_select2($desc?"Edit BUDA app $desc->name":'Create BUDA app'); |
|
| 479 | +function app_form($desc = null) { |
|
| 480 | + page_head_select2($desc ? "Edit BUDA app $desc->name" : 'Create BUDA app'); |
|
| 481 | 481 | form_start('buda.php'); |
| 482 | 482 | form_input_hidden('action', 'app_action'); |
| 483 | 483 | if ($desc) { |
@@ -488,22 +488,22 @@ discard block |
||
| 488 | 488 | form_input_text('Internal name<br><small>No spaces</small>', 'name'); |
| 489 | 489 | } |
| 490 | 490 | form_input_text('User-visible name', 'long_name', |
| 491 | - $desc?$desc->long_name:null |
|
| 491 | + $desc ? $desc->long_name : null |
|
| 492 | 492 | ); |
| 493 | 493 | form_input_textarea( |
| 494 | 494 | 'Description<br><small>... of what the app does and of the research goals</small>', |
| 495 | 495 | 'description', |
| 496 | - $desc?$desc->description:null |
|
| 496 | + $desc ? $desc->description : null |
|
| 497 | 497 | ); |
| 498 | 498 | form_select2_multi('Science keywords', |
| 499 | 499 | 'sci_kw', |
| 500 | 500 | keyword_select_options(KW_CATEGORY_SCIENCE), |
| 501 | - $desc?$desc->sci_kw:null |
|
| 501 | + $desc ? $desc->sci_kw : null |
|
| 502 | 502 | ); |
| 503 | 503 | form_input_text( |
| 504 | 504 | 'URL of web page describing app', |
| 505 | 505 | 'url', |
| 506 | - !empty($desc->url)?$desc->url:'' |
|
| 506 | + !empty($desc->url) ? $desc->url : '' |
|
| 507 | 507 | ); |
| 508 | 508 | // don't include location keywords; |
| 509 | 509 | // various people may submit jobs to this app |