inc/xml_http_request_server.php
File xml_http_request_server.php
has 272 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
<?php
// File inc/xml_http_request_server.php / FirebirdWebAdmin
// Purpose answers to the XMLHttpRequests
// Author Lutz Brueckner <irie@gmx.de>
// Copyright (c) 2000-2006 by Lutz Brueckner,
Method detail_view
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function detail_view($type, $name, $title)
{
$url = fold_detail_url($type, 'open', $name, $title);
$comment_url = "javascript:requestCommentArea('".$type."', '".$name."');";
$comment_div = detail_div_prefix($type).'c_'.$name;
Method column_config_form
has 28 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function column_config_form($fk_table, $table, $column)
{
global $button_strings, $dt_strings;
$fk_columns = array();
Function table_columns_selectlist
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
Open
function table_columns_selectlist($table, $ename, $restriction)
{
$columns = array();
if (is_array($GLOBALS['s_fields'][$table])) {
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function detail_view
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
Open
function detail_view($type, $name, $title)
{
$url = fold_detail_url($type, 'open', $name, $title);
$comment_url = "javascript:requestCommentArea('".$type."', '".$name."');";
$comment_div = detail_div_prefix($type).'c_'.$name;
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"