| 
									
										
										
										
											2024-08-13 19:46:56 +00:00
										 |  |  | <?php | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | // render config variables array
 | 
					
						
							| 
									
										
										
										
											2024-08-19 10:25:09 +00:00
										 |  |  | function renderConfig($config, $indent) { | 
					
						
							|  |  |  | ?>
 | 
					
						
							|  |  |  |                         <div style="padding-left: <?= $indent ?>px; padding-bottom: 20px;"> | 
					
						
							|  |  |  | <?php | 
					
						
							| 
									
										
										
										
											2024-08-13 19:46:56 +00:00
										 |  |  |     foreach ($config as $config_item => $config_value) { | 
					
						
							| 
									
										
										
										
											2024-08-19 10:25:09 +00:00
										 |  |  | ?>
 | 
					
						
							|  |  |  |                             <div class="row mb-1" style="padding-left: <?= $indent ?>px;"> | 
					
						
							|  |  |  |                                 <div class="col-md-4 text-end"> | 
					
						
							|  |  |  |                                     <?= htmlspecialchars($config_item) ?>:
 | 
					
						
							|  |  |  |                                 </div> | 
					
						
							|  |  |  | <?php | 
					
						
							| 
									
										
										
										
											2024-08-13 19:46:56 +00:00
										 |  |  |         if (is_array($config_value)) { | 
					
						
							| 
									
										
										
										
											2024-08-19 10:25:09 +00:00
										 |  |  | ?>
 | 
					
						
							|  |  |  | <?php | 
					
						
							| 
									
										
										
										
											2024-08-13 19:46:56 +00:00
										 |  |  |             // here we render recursively nested arrays
 | 
					
						
							| 
									
										
										
										
											2024-08-19 10:25:09 +00:00
										 |  |  |             $indent = $indent + 50; | 
					
						
							|  |  |  |             renderConfig($config_value, $indent); | 
					
						
							|  |  |  |             $indent = 0; | 
					
						
							| 
									
										
										
										
											2024-08-13 19:46:56 +00:00
										 |  |  |         } else { | 
					
						
							|  |  |  |             // if it's not array, just display it
 | 
					
						
							| 
									
										
										
										
											2024-08-19 10:25:09 +00:00
										 |  |  | ?>
 | 
					
						
							|  |  |  |                                 <div class="border col-md-8 text-start"> | 
					
						
							|  |  |  |                                     <?= htmlspecialchars($config_value ?? '')?>
 | 
					
						
							|  |  |  |                                 </div> | 
					
						
							|  |  |  | <?php | 
					
						
							| 
									
										
										
										
											2024-08-13 19:46:56 +00:00
										 |  |  |         } | 
					
						
							| 
									
										
										
										
											2024-08-19 10:25:09 +00:00
										 |  |  | ?>
 | 
					
						
							|  |  |  |                             </div> | 
					
						
							|  |  |  | <?php | 
					
						
							| 
									
										
										
										
											2024-08-13 19:46:56 +00:00
										 |  |  |     } | 
					
						
							| 
									
										
										
										
											2024-08-19 10:25:09 +00:00
										 |  |  | echo '</div>'; | 
					
						
							| 
									
										
										
										
											2024-08-13 19:46:56 +00:00
										 |  |  | } | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | ?>
 |