Created At: 2026-06-14T15:34:30Z
Completed At: 2026-06-14T15:34:30Z
File Path: `file:///c:/Users/HP/Downloads/climate-system/climate-system/index.php`
Total Lines: 4742
Total Bytes: 201499
Showing lines 685 to 735
The following code has been modified to include a line number before every line, in the format: <line_number>: <original_line>. Please note that any changes targeting the original code should remove the line number, colon, and leading space.
685:                 // Graph fields
686:                 if (isset($input['graphBaseValue'])) { $updates[] = "graph_base_value = :base_val"; $params[':base_val'] = ($input['graphBaseValue'] !== '') ? floatval($input['graphBaseValue']) : null; }
687:                 if (isset($input['graphUncertainty'])) { $updates[] = "graph_uncertainty = :uncertainty"; $params[':uncertainty'] = ($input['graphUncertainty'] !== '') ? floatval($input['graphUncertainty']) : null; }
688:                 if (isset($input['graphSSP1Slope'])) { $updates[] = "graph_ssp1_slope = :ssp1"; $params[':ssp1'] = ($input['graphSSP1Slope'] !== '') ? floatval($input['graphSSP1Slope']) : null; }
689:                 if (isset($input['graphSSP2Slope'])) { $updates[] = "graph_ssp2_slope = :ssp2"; $params[':ssp2'] = ($input['graphSSP2Slope'] !== '') ? floatval($input['graphSSP2Slope']) : null; }
690:                 if (isset($input['graphSSP3Slope'])) { $updates[] = "graph_ssp3_slope = :ssp3"; $params[':ssp3'] = ($input['graphSSP3Slope'] !== '') ? floatval($input['graphSSP3Slope']) : null; }
691:                 if (isset($input['graphSSP5Slope'])) { $updates[] = "graph_ssp5_slope = :ssp5"; $params[':ssp5'] = ($input['graphSSP5Slope'] !== '') ? floatval($input['graphSSP5Slope']) : null; }
692:                 if (isset($input['csvData'])) { $updates[] = "csv_data = :csv_data"; $params[':csv_data'] = $input['csvData']; }
693:                 
694:                 if (count($updates) > 0) {
695:                     $updates[] = "updated_at = CURRENT_TIMESTAMP";
696:                     $sql = "UPDATE futu
<truncated 1154 bytes>
put['graphSSP1Slope']) && $input['graphSSP1Slope'] !== '') ? floatval($input['graphSSP1Slope']) : null;
711:                 $ssp2 = (isset($input['graphSSP2Slope']) && $input['graphSSP2Slope'] !== '') ? floatval($input['graphSSP2Slope']) : null;
712:                 $ssp3 = (isset($input['graphSSP3Slope']) && $input['graphSSP3Slope'] !== '') ? floatval($input['graphSSP3Slope']) : null;
713:                 $ssp5 = (isset($input['graphSSP5Slope']) && $input['graphSSP5Slope'] !== '') ? floatval($input['graphSSP5Slope']) : null;
714:                 $csv = isset($input['csvData']) ? $input['csvData'] : null;
715: 
716:                 $stmtInsert = $db->prepare("
717:                     INSERT INTO future_climate (
718:                         location_id, variable_id, period_id, description, 
719:                         image_climate_map_url, image_climate_map_url_2, image_time_series_url, image_climate_stripe_url,
720:                         graph_base_value, graph_uncertainty, graph_ssp1_slope, graph_ssp2_slope, graph_ssp3_slope, graph_ssp5_slope,
721:                         csv_data, updated_at
722:                     ) VALUES (
723:                         :location_id, :variable_id, :period_id, :description,
724:                         :img_map, :img_map_2, :img_ts, :img_stripe,
725:                         :base_val, :uncertainty, :ssp1, :ssp2, :ssp3, :ssp5,
726:                         :csv_data, CURRENT_TIMESTAMP
727:                     )
728:                 ");
729:                 $stmtInsert->execute([
730:                     ':location_id' => $location_id,
731:                     ':variable_id' => $variable_id,
732:                     ':period_id' => $period_id,
733:                     ':description' => $desc,
734:                     ':img_map' => $imgMap,
735:                     ':img_map_2' => $imgMap2,
The above content does NOT show the entire file contents. If you need to view any lines of the file which were not shown to complete your task, call this tool again to view those lines.
