From 546a74246dfde12cee41de90908efc6f23f9addb Mon Sep 17 00:00:00 2001 From: SAIF Date: Thu, 19 Sep 2013 21:54:48 +0100 Subject: [PATCH] Add The Scripts Files Add The Scripts Files --- .gitattributes | 22 + .gitignore | 215 + .svn/README.txt | 2 + .svn/dir-wcprops | 5 + .svn/empty-file | 0 .svn/entries | 59 + .svn/format | 1 + .svn/prop-base/Converter.php.svn-base | 0 .svn/prop-base/README.svn-base | 0 .svn/prop-base/cli.php.svn-base | 0 .svn/prop-base/index.php.svn-base | 0 .svn/props/Converter.php.svn-work | 0 .svn/props/README.svn-work | 0 .svn/props/cli.php.svn-work | 0 .svn/props/index.php.svn-work | 0 .svn/text-base/Converter.php.svn-base | 936 ++ .svn/text-base/README.svn-base | 18 + .svn/text-base/cli.php.svn-base | 445 + .svn/text-base/index.php.svn-base | 16 + .svn/wcprops/Converter.php.svn-work | 5 + .svn/wcprops/README.svn-work | 5 + .svn/wcprops/cli.php.svn-work | 5 + .svn/wcprops/index.php.svn-work | 5 + Converter.php | 936 ++ Function/.svn/README.txt | 2 + Function/.svn/dir-wcprops | 5 + Function/.svn/empty-file | 0 Function/.svn/entries | 257 + Function/.svn/format | 1 + .../.svn/prop-base/ChangeUser.php.svn-base | 0 .../.svn/prop-base/ConnParam.php.svn-base | 0 .../.svn/prop-base/ConnParamBool.php.svn-base | 0 Function/.svn/prop-base/Connect.php.svn-base | 0 Function/.svn/prop-base/CreateDB.php.svn-base | 0 Function/.svn/prop-base/DBQuery.php.svn-base | 0 Function/.svn/prop-base/DropDB.php.svn-base | 0 Function/.svn/prop-base/Error.php.svn-base | 0 .../.svn/prop-base/EscapeString.php.svn-base | 0 .../.svn/prop-base/FetchField.php.svn-base | 0 .../.svn/prop-base/FieldFlags.php.svn-base | 0 Function/.svn/prop-base/FieldLen.php.svn-base | 0 .../.svn/prop-base/FieldName.php.svn-base | 0 .../.svn/prop-base/FieldTable.php.svn-base | 0 .../.svn/prop-base/FieldType.php.svn-base | 0 .../.svn/prop-base/FreeResult.php.svn-base | 0 Function/.svn/prop-base/Generic.php.svn-base | 0 .../prop-base/GenericBoolean.php.svn-base | 0 Function/.svn/prop-base/ListDBs.php.svn-base | 0 .../.svn/prop-base/ListFields.php.svn-base | 0 .../.svn/prop-base/ListProcesses.php.svn-base | 0 .../.svn/prop-base/ListTables.php.svn-base | 0 .../.svn/prop-base/ParReversed.php.svn-base | 0 .../prop-base/RealEscapeString.php.svn-base | 0 Function/.svn/prop-base/SelectDB.php.svn-base | 0 .../.svn/prop-base/Tablename.php.svn-base | 0 .../prop-base/UnbufferedQuery.php.svn-base | 0 Function/.svn/props/ChangeUser.php.svn-work | 0 Function/.svn/props/ConnParam.php.svn-work | 0 .../.svn/props/ConnParamBool.php.svn-work | 0 Function/.svn/props/Connect.php.svn-work | 0 Function/.svn/props/CreateDB.php.svn-work | 0 Function/.svn/props/DBQuery.php.svn-work | 0 Function/.svn/props/DropDB.php.svn-work | 0 Function/.svn/props/Error.php.svn-work | 0 Function/.svn/props/EscapeString.php.svn-work | 0 Function/.svn/props/FetchField.php.svn-work | 0 Function/.svn/props/FieldFlags.php.svn-work | 0 Function/.svn/props/FieldLen.php.svn-work | 0 Function/.svn/props/FieldName.php.svn-work | 0 Function/.svn/props/FieldTable.php.svn-work | 0 Function/.svn/props/FieldType.php.svn-work | 0 Function/.svn/props/FreeResult.php.svn-work | 0 Function/.svn/props/Generic.php.svn-work | 0 .../.svn/props/GenericBoolean.php.svn-work | 0 Function/.svn/props/ListDBs.php.svn-work | 0 Function/.svn/props/ListFields.php.svn-work | 0 .../.svn/props/ListProcesses.php.svn-work | 0 Function/.svn/props/ListTables.php.svn-work | 0 Function/.svn/props/ParReversed.php.svn-work | 0 .../.svn/props/RealEscapeString.php.svn-work | 0 Function/.svn/props/SelectDB.php.svn-work | 0 Function/.svn/props/Tablename.php.svn-work | 0 .../.svn/props/UnbufferedQuery.php.svn-work | 0 .../.svn/text-base/ChangeUser.php.svn-base | 91 + .../.svn/text-base/ConnParam.php.svn-base | 36 + .../.svn/text-base/ConnParamBool.php.svn-base | 37 + Function/.svn/text-base/Connect.php.svn-base | 203 + Function/.svn/text-base/CreateDB.php.svn-base | 63 + Function/.svn/text-base/DBQuery.php.svn-base | 61 + Function/.svn/text-base/DropDB.php.svn-base | 62 + Function/.svn/text-base/Error.php.svn-base | 45 + .../.svn/text-base/EscapeString.php.svn-base | 47 + .../.svn/text-base/FetchField.php.svn-base | 147 + .../.svn/text-base/FieldFlags.php.svn-base | 92 + Function/.svn/text-base/FieldLen.php.svn-base | 48 + .../.svn/text-base/FieldName.php.svn-base | 46 + .../.svn/text-base/FieldTable.php.svn-base | 47 + .../.svn/text-base/FieldType.php.svn-base | 89 + .../.svn/text-base/FreeResult.php.svn-base | 42 + Function/.svn/text-base/Generic.php.svn-base | 152 + .../text-base/GenericBoolean.php.svn-base | 26 + Function/.svn/text-base/ListDBs.php.svn-base | 45 + .../.svn/text-base/ListFields.php.svn-base | 66 + .../.svn/text-base/ListProcesses.php.svn-base | 48 + .../.svn/text-base/ListTables.php.svn-base | 54 + .../.svn/text-base/ParReversed.php.svn-base | 41 + .../text-base/RealEscapeString.php.svn-base | 59 + Function/.svn/text-base/SelectDB.php.svn-base | 56 + .../.svn/text-base/Tablename.php.svn-base | 45 + .../text-base/UnbufferedQuery.php.svn-base | 48 + Function/.svn/wcprops/ChangeUser.php.svn-work | 5 + Function/.svn/wcprops/ConnParam.php.svn-work | 5 + .../.svn/wcprops/ConnParamBool.php.svn-work | 5 + Function/.svn/wcprops/Connect.php.svn-work | 5 + Function/.svn/wcprops/CreateDB.php.svn-work | 5 + Function/.svn/wcprops/DBQuery.php.svn-work | 5 + Function/.svn/wcprops/DropDB.php.svn-work | 5 + Function/.svn/wcprops/Error.php.svn-work | 5 + .../.svn/wcprops/EscapeString.php.svn-work | 5 + Function/.svn/wcprops/FetchField.php.svn-work | 5 + Function/.svn/wcprops/FieldFlags.php.svn-work | 5 + Function/.svn/wcprops/FieldLen.php.svn-work | 5 + Function/.svn/wcprops/FieldName.php.svn-work | 5 + Function/.svn/wcprops/FieldTable.php.svn-work | 5 + Function/.svn/wcprops/FieldType.php.svn-work | 5 + Function/.svn/wcprops/FreeResult.php.svn-work | 5 + Function/.svn/wcprops/Generic.php.svn-work | 5 + .../.svn/wcprops/GenericBoolean.php.svn-work | 5 + Function/.svn/wcprops/ListDBs.php.svn-work | 5 + Function/.svn/wcprops/ListFields.php.svn-work | 5 + .../.svn/wcprops/ListProcesses.php.svn-work | 5 + Function/.svn/wcprops/ListTables.php.svn-work | 5 + .../.svn/wcprops/ParReversed.php.svn-work | 5 + .../wcprops/RealEscapeString.php.svn-work | 5 + Function/.svn/wcprops/SelectDB.php.svn-work | 5 + Function/.svn/wcprops/Tablename.php.svn-work | 5 + .../.svn/wcprops/UnbufferedQuery.php.svn-work | 5 + Function/ChangeUser.php | 91 + Function/ConnParam.php | 36 + Function/ConnParamBool.php | 37 + Function/Connect.php | 203 + Function/CreateDB.php | 63 + Function/DBQuery.php | 61 + Function/DropDB.php | 62 + Function/Error.php | 45 + Function/EscapeString.php | 47 + Function/FetchField.php | 147 + Function/FieldFlags.php | 92 + Function/FieldLen.php | 48 + Function/FieldName.php | 46 + Function/FieldTable.php | 47 + Function/FieldType.php | 89 + Function/FreeResult.php | 42 + Function/Generic.php | 152 + Function/GenericBoolean.php | 26 + Function/ListDBs.php | 45 + Function/ListFields.php | 66 + Function/ListProcesses.php | 48 + Function/ListTables.php | 54 + Function/ParReversed.php | 41 + Function/RealEscapeString.php | 59 + Function/SelectDB.php | 56 + Function/Tablename.php | 45 + Function/UnbufferedQuery.php | 48 + GUI/.svn/README.txt | 2 + GUI/.svn/dir-wcprops | 5 + GUI/.svn/empty-file | 0 GUI/.svn/entries | 65 + GUI/.svn/format | 1 + .../prop-base/convert_directory.php.svn-base | 0 GUI/.svn/prop-base/convert_file.php.svn-base | 0 .../prop-base/convert_snippet.php.svn-base | 0 GUI/.svn/prop-base/help.php.svn-base | 0 GUI/.svn/prop-base/index.php.svn-base | 0 GUI/.svn/props/convert_directory.php.svn-work | 0 GUI/.svn/props/convert_file.php.svn-work | 0 GUI/.svn/props/convert_snippet.php.svn-work | 0 GUI/.svn/props/help.php.svn-work | 0 GUI/.svn/props/index.php.svn-work | 0 .../text-base/convert_directory.php.svn-base | 109 + GUI/.svn/text-base/convert_file.php.svn-base | 84 + .../text-base/convert_snippet.php.svn-base | 57 + GUI/.svn/text-base/help.php.svn-base | 138 + GUI/.svn/text-base/index.php.svn-base | 46 + .../wcprops/convert_directory.php.svn-work | 5 + GUI/.svn/wcprops/convert_file.php.svn-work | 5 + GUI/.svn/wcprops/convert_snippet.php.svn-work | 5 + GUI/.svn/wcprops/help.php.svn-work | 5 + GUI/.svn/wcprops/index.php.svn-work | 5 + GUI/convert_directory.php | 109 + GUI/convert_file.php | 84 + GUI/convert_snippet.php | 57 + GUI/css/.svn/README.txt | 2 + GUI/css/.svn/dir-wcprops | 5 + GUI/css/.svn/empty-file | 0 GUI/css/.svn/entries | 23 + GUI/css/.svn/format | 1 + GUI/css/.svn/prop-base/main.css.svn-base | 0 GUI/css/.svn/props/main.css.svn-work | 0 GUI/css/.svn/text-base/main.css.svn-base | 274 + GUI/css/.svn/wcprops/main.css.svn-work | 5 + GUI/css/bootstrap-theme.css | 372 + GUI/css/bootstrap.css | 7686 +++++++++++++++++ GUI/css/main.css | 241 + GUI/file.php | 169 + GUI/help.php | 138 + GUI/index.php | 47 + GUI/js/application.js | 83 + GUI/js/bootstrap.js | 1999 +++++ GUI/js/bootstrap.min.js | 6 + GUI/js/collapse.js | 179 + GUI/js/dropdown.js | 154 + GUI/js/holder.js | 419 + GUI/js/html5shiv.js | 8 + GUI/js/jquery.js | 6 + GUI/js/respond.min.js | 6 + GUI/phpinfo.php | 4 + GUI/snippets/.svn/README.txt | 2 + GUI/snippets/.svn/dir-wcprops | 5 + GUI/snippets/.svn/empty-file | 0 GUI/snippets/.svn/entries | 95 + GUI/snippets/.svn/format | 1 + ...SQLConverterTool_GUI_Snippets.php.svn-base | 0 .../.svn/prop-base/footer.php.svn-base | 0 .../prop-base/form_directory.php.svn-base | 0 .../.svn/prop-base/form_file.php.svn-base | 0 .../.svn/prop-base/form_snippet.php.svn-base | 0 .../.svn/prop-base/header.php.svn-base | 0 .../show_converted_directory.php.svn-base | 0 .../show_converted_file.php.svn-base | 0 .../show_converted_snippet.php.svn-base | 0 ...SQLConverterTool_GUI_Snippets.php.svn-work | 0 GUI/snippets/.svn/props/footer.php.svn-work | 0 .../.svn/props/form_directory.php.svn-work | 0 .../.svn/props/form_file.php.svn-work | 0 .../.svn/props/form_snippet.php.svn-work | 0 GUI/snippets/.svn/props/header.php.svn-work | 0 .../show_converted_directory.php.svn-work | 0 .../props/show_converted_file.php.svn-work | 0 .../props/show_converted_snippet.php.svn-work | 0 ...SQLConverterTool_GUI_Snippets.php.svn-base | 34 + .../.svn/text-base/footer.php.svn-base | 20 + .../text-base/form_directory.php.svn-base | 107 + .../.svn/text-base/form_file.php.svn-base | 95 + .../.svn/text-base/form_snippet.php.svn-base | 90 + .../.svn/text-base/header.php.svn-base | 55 + .../show_converted_directory.php.svn-base | 37 + .../show_converted_file.php.svn-base | 91 + .../show_converted_snippet.php.svn-base | 87 + ...SQLConverterTool_GUI_Snippets.php.svn-work | 5 + GUI/snippets/.svn/wcprops/footer.php.svn-work | 5 + .../.svn/wcprops/form_directory.php.svn-work | 5 + .../.svn/wcprops/form_file.php.svn-work | 5 + .../.svn/wcprops/form_snippet.php.svn-work | 5 + GUI/snippets/.svn/wcprops/header.php.svn-work | 5 + .../show_converted_directory.php.svn-work | 5 + .../wcprops/show_converted_file.php.svn-work | 5 + .../show_converted_snippet.php.svn-work | 5 + .../MySQLConverterTool_GUI_Snippets.php | 34 + GUI/snippets/footer.php | 44 + GUI/snippets/form_directory.php | 115 + GUI/snippets/form_file.php | 103 + GUI/snippets/form_snippet.php | 88 + GUI/snippets/header.php | 91 + GUI/snippets/show_converted_directory.php | 37 + GUI/snippets/show_converted_file.php | 89 + GUI/snippets/show_converted_snippet.php | 85 + README | 18 + UnitTests/.svn/README.txt | 2 + UnitTests/.svn/dir-wcprops | 5 + UnitTests/.svn/empty-file | 0 UnitTests/.svn/entries | 38 + UnitTests/.svn/format | 1 + .../.svn/prop-base/AllTests.php.svn-base | 0 UnitTests/.svn/prop-base/README.svn-base | 0 UnitTests/.svn/props/AllTests.php.svn-work | 0 UnitTests/.svn/props/README.svn-work | 0 .../.svn/text-base/AllTests.php.svn-base | 45 + UnitTests/.svn/text-base/README.svn-base | 54 + UnitTests/.svn/wcprops/AllTests.php.svn-work | 5 + UnitTests/.svn/wcprops/README.svn-work | 5 + UnitTests/AllTests.php | 45 + UnitTests/Converter/.svn/README.txt | 2 + UnitTests/Converter/.svn/dir-wcprops | 5 + UnitTests/Converter/.svn/empty-file | 0 UnitTests/Converter/.svn/entries | 269 + UnitTests/Converter/.svn/format | 1 + .../.svn/prop-base/AllTests.php.svn-base | 0 .../prop-base/ChangeUserTest.php.svn-base | 0 .../prop-base/ConnParamBoolTest.php.svn-base | 0 .../.svn/prop-base/ConnParamTest.php.svn-base | 0 .../.svn/prop-base/ConnectTest.php.svn-base | 0 .../.svn/prop-base/ConverterTest.php.svn-base | 0 .../.svn/prop-base/CreateDBTest.php.svn-base | 0 .../.svn/prop-base/DBQueryTest.php.svn-base | 0 .../.svn/prop-base/DropDBTest.php.svn-base | 0 .../.svn/prop-base/ErrorTest.php.svn-base | 0 .../prop-base/EscapeStringTest.php.svn-base | 0 .../prop-base/FetchFieldTest.php.svn-base | 0 .../prop-base/FieldFlagsTest.php.svn-base | 0 .../.svn/prop-base/FieldLenTest.php.svn-base | 0 .../.svn/prop-base/FieldNameTest.php.svn-base | 0 .../prop-base/FieldTableTest.php.svn-base | 0 .../.svn/prop-base/FieldTypeTest.php.svn-base | 0 .../prop-base/FreeResultTest.php.svn-base | 0 .../prop-base/GenericBooleanTest.php.svn-base | 0 .../.svn/prop-base/GenericTest.php.svn-base | 0 .../.svn/prop-base/ListDBsTest.php.svn-base | 0 .../prop-base/ListFieldsTest.php.svn-base | 0 .../prop-base/ListProcessesTest.php.svn-base | 0 .../prop-base/ParReversedTest.php.svn-base | 0 .../RealEscapeStringTest.php.svn-base | 0 .../.svn/prop-base/SelectDBTest.php.svn-base | 0 .../.svn/prop-base/TablenameTest.php.svn-base | 0 .../UnbufferedQueryTest.php.svn-base | 0 .../.svn/props/AllTests.php.svn-work | 0 .../.svn/props/ChangeUserTest.php.svn-work | 0 .../.svn/props/ConnParamBoolTest.php.svn-work | 0 .../.svn/props/ConnParamTest.php.svn-work | 0 .../.svn/props/ConnectTest.php.svn-work | 0 .../.svn/props/ConverterTest.php.svn-work | 0 .../.svn/props/CreateDBTest.php.svn-work | 0 .../.svn/props/DBQueryTest.php.svn-work | 0 .../.svn/props/DropDBTest.php.svn-work | 0 .../.svn/props/ErrorTest.php.svn-work | 0 .../.svn/props/EscapeStringTest.php.svn-work | 0 .../.svn/props/FetchFieldTest.php.svn-work | 0 .../.svn/props/FieldFlagsTest.php.svn-work | 0 .../.svn/props/FieldLenTest.php.svn-work | 0 .../.svn/props/FieldNameTest.php.svn-work | 0 .../.svn/props/FieldTableTest.php.svn-work | 0 .../.svn/props/FieldTypeTest.php.svn-work | 0 .../.svn/props/FreeResultTest.php.svn-work | 0 .../props/GenericBooleanTest.php.svn-work | 0 .../.svn/props/GenericTest.php.svn-work | 0 .../.svn/props/ListDBsTest.php.svn-work | 0 .../.svn/props/ListFieldsTest.php.svn-work | 0 .../.svn/props/ListProcessesTest.php.svn-work | 0 .../.svn/props/ParReversedTest.php.svn-work | 0 .../props/RealEscapeStringTest.php.svn-work | 0 .../.svn/props/SelectDBTest.php.svn-work | 0 .../.svn/props/TablenameTest.php.svn-work | 0 .../props/UnbufferedQueryTest.php.svn-work | 0 .../.svn/text-base/AllTests.php.svn-base | 94 + .../text-base/ChangeUserTest.php.svn-base | 53 + .../text-base/ConnParamBoolTest.php.svn-base | 55 + .../.svn/text-base/ConnParamTest.php.svn-base | 57 + .../.svn/text-base/ConnectTest.php.svn-base | 57 + .../.svn/text-base/ConverterTest.php.svn-base | 697 ++ .../.svn/text-base/CreateDBTest.php.svn-base | 54 + .../.svn/text-base/DBQueryTest.php.svn-base | 54 + .../.svn/text-base/DropDBTest.php.svn-base | 54 + .../.svn/text-base/ErrorTest.php.svn-base | 54 + .../text-base/EscapeStringTest.php.svn-base | 54 + .../text-base/FetchFieldTest.php.svn-base | 54 + .../text-base/FieldFlagsTest.php.svn-base | 54 + .../.svn/text-base/FieldLenTest.php.svn-base | 54 + .../.svn/text-base/FieldNameTest.php.svn-base | 54 + .../text-base/FieldTableTest.php.svn-base | 54 + .../.svn/text-base/FieldTypeTest.php.svn-base | 54 + .../text-base/FreeResultTest.php.svn-base | 56 + .../text-base/GenericBooleanTest.php.svn-base | 55 + .../.svn/text-base/GenericTest.php.svn-base | 57 + .../.svn/text-base/ListDBsTest.php.svn-base | 55 + .../text-base/ListFieldsTest.php.svn-base | 54 + .../text-base/ListProcessesTest.php.svn-base | 54 + .../text-base/ParReversedTest.php.svn-base | 54 + .../RealEscapeStringTest.php.svn-base | 54 + .../.svn/text-base/SelectDBTest.php.svn-base | 54 + .../.svn/text-base/TablenameTest.php.svn-base | 54 + .../UnbufferedQueryTest.php.svn-base | 54 + .../.svn/wcprops/AllTests.php.svn-work | 5 + .../.svn/wcprops/ChangeUserTest.php.svn-work | 5 + .../wcprops/ConnParamBoolTest.php.svn-work | 5 + .../.svn/wcprops/ConnParamTest.php.svn-work | 5 + .../.svn/wcprops/ConnectTest.php.svn-work | 5 + .../.svn/wcprops/ConverterTest.php.svn-work | 5 + .../.svn/wcprops/CreateDBTest.php.svn-work | 5 + .../.svn/wcprops/DBQueryTest.php.svn-work | 5 + .../.svn/wcprops/DropDBTest.php.svn-work | 5 + .../.svn/wcprops/ErrorTest.php.svn-work | 5 + .../wcprops/EscapeStringTest.php.svn-work | 5 + .../.svn/wcprops/FetchFieldTest.php.svn-work | 5 + .../.svn/wcprops/FieldFlagsTest.php.svn-work | 5 + .../.svn/wcprops/FieldLenTest.php.svn-work | 5 + .../.svn/wcprops/FieldNameTest.php.svn-work | 5 + .../.svn/wcprops/FieldTableTest.php.svn-work | 5 + .../.svn/wcprops/FieldTypeTest.php.svn-work | 5 + .../.svn/wcprops/FreeResultTest.php.svn-work | 5 + .../wcprops/GenericBooleanTest.php.svn-work | 5 + .../.svn/wcprops/GenericTest.php.svn-work | 5 + .../.svn/wcprops/ListDBsTest.php.svn-work | 5 + .../.svn/wcprops/ListFieldsTest.php.svn-work | 5 + .../wcprops/ListProcessesTest.php.svn-work | 5 + .../.svn/wcprops/ParReversedTest.php.svn-work | 5 + .../wcprops/RealEscapeStringTest.php.svn-work | 5 + .../.svn/wcprops/SelectDBTest.php.svn-work | 5 + .../.svn/wcprops/TablenameTest.php.svn-work | 5 + .../wcprops/UnbufferedQueryTest.php.svn-work | 5 + UnitTests/Converter/AllTests.php | 94 + UnitTests/Converter/ChangeUserTest.php | 53 + UnitTests/Converter/ConnParamBoolTest.php | 55 + UnitTests/Converter/ConnParamTest.php | 57 + UnitTests/Converter/ConnectTest.php | 57 + UnitTests/Converter/ConverterTest.php | 697 ++ UnitTests/Converter/CreateDBTest.php | 54 + UnitTests/Converter/DBQueryTest.php | 54 + UnitTests/Converter/DropDBTest.php | 54 + UnitTests/Converter/ErrorTest.php | 54 + UnitTests/Converter/EscapeStringTest.php | 54 + UnitTests/Converter/FetchFieldTest.php | 54 + UnitTests/Converter/FieldFlagsTest.php | 54 + UnitTests/Converter/FieldLenTest.php | 54 + UnitTests/Converter/FieldNameTest.php | 54 + UnitTests/Converter/FieldTableTest.php | 54 + UnitTests/Converter/FieldTypeTest.php | 54 + UnitTests/Converter/FreeResultTest.php | 56 + UnitTests/Converter/GenericBooleanTest.php | 55 + UnitTests/Converter/GenericTest.php | 57 + UnitTests/Converter/ListDBsTest.php | 55 + UnitTests/Converter/ListFieldsTest.php | 54 + UnitTests/Converter/ListProcessesTest.php | 54 + UnitTests/Converter/ParReversedTest.php | 54 + UnitTests/Converter/RealEscapeStringTest.php | 54 + UnitTests/Converter/SelectDBTest.php | 54 + UnitTests/Converter/TablenameTest.php | 54 + UnitTests/Converter/TestCode/.svn/README.txt | 2 + UnitTests/Converter/TestCode/.svn/dir-wcprops | 5 + UnitTests/Converter/TestCode/.svn/empty-file | 0 UnitTests/Converter/TestCode/.svn/entries | 500 ++ UnitTests/Converter/TestCode/.svn/format | 1 + .../TestCode/.svn/prop-base/README.svn-base | 0 .../prop-base/change_user001.php.svn-base | 0 .../.svn/prop-base/config.php.svn-base | 0 .../.svn/prop-base/conn_param001.php.svn-base | 0 .../.svn/prop-base/conn_param002.php.svn-base | 0 .../.svn/prop-base/conn_param003.php.svn-base | 0 .../.svn/prop-base/conn_param004.php.svn-base | 0 .../.svn/prop-base/conn_param005.php.svn-base | 0 .../.svn/prop-base/conn_param006.php.svn-base | 0 .../.svn/prop-base/conn_param007.php.svn-base | 0 .../.svn/prop-base/conn_param008.php.svn-base | 0 .../prop-base/conn_param_bool001.php.svn-base | 0 .../prop-base/conn_param_bool002.php.svn-base | 0 .../prop-base/conn_param_bool003.php.svn-base | 0 .../prop-base/conn_param_bool004.php.svn-base | 0 .../prop-base/conn_param_bool005.php.svn-base | 0 .../.svn/prop-base/connect001.php.svn-base | 0 .../.svn/prop-base/connect002.php.svn-base | 0 .../.svn/prop-base/connect003.php.svn-base | 0 .../.svn/prop-base/connect004.php.svn-base | 0 .../.svn/prop-base/connect005.php.svn-base | 0 .../.svn/prop-base/connect006.php.svn-base | 0 .../.svn/prop-base/connect007.php.svn-base | 0 .../.svn/prop-base/create_db001.php.svn-base | 0 .../.svn/prop-base/db_query001.php.svn-base | 0 .../.svn/prop-base/drop_db001.php.svn-base | 0 .../.svn/prop-base/error001.php.svn-base | 0 .../.svn/prop-base/error002.php.svn-base | 0 .../prop-base/escape_string001.php.svn-base | 0 .../prop-base/fetch_field001.php.svn-base | 0 .../prop-base/field_flags001.php.svn-base | 0 .../.svn/prop-base/field_len001.php.svn-base | 0 .../.svn/prop-base/field_name001.php.svn-base | 0 .../prop-base/field_table001.php.svn-base | 0 .../.svn/prop-base/field_type001.php.svn-base | 0 .../prop-base/free_result001.php.svn-base | 0 .../.svn/prop-base/generic001.php.svn-base | 0 .../.svn/prop-base/generic002.php.svn-base | 0 .../.svn/prop-base/generic003.php.svn-base | 0 .../.svn/prop-base/generic004.php.svn-base | 0 .../.svn/prop-base/generic005.php.svn-base | 0 .../.svn/prop-base/generic006.php.svn-base | 0 .../.svn/prop-base/generic007.php.svn-base | 0 .../.svn/prop-base/generic008.php.svn-base | 0 .../prop-base/generic_boolean001.php.svn-base | 0 .../prop-base/generic_boolean002.php.svn-base | 0 .../.svn/prop-base/list_dbs001.php.svn-base | 0 .../prop-base/list_fields001.php.svn-base | 0 .../prop-base/list_processes001.php.svn-base | 0 .../prop-base/par_reversed001.php.svn-base | 0 .../real_escape_string001.php.svn-base | 0 .../.svn/prop-base/select_db001.php.svn-base | 0 .../.svn/prop-base/tablename001.php.svn-base | 0 .../unbuffered_query001.php.svn-base | 0 .../TestCode/.svn/props/README.svn-work | 0 .../.svn/props/change_user001.php.svn-work | 0 .../TestCode/.svn/props/config.php.svn-work | 0 .../.svn/props/conn_param001.php.svn-work | 0 .../.svn/props/conn_param002.php.svn-work | 0 .../.svn/props/conn_param003.php.svn-work | 0 .../.svn/props/conn_param004.php.svn-work | 0 .../.svn/props/conn_param005.php.svn-work | 0 .../.svn/props/conn_param006.php.svn-work | 0 .../.svn/props/conn_param007.php.svn-work | 0 .../.svn/props/conn_param008.php.svn-work | 0 .../props/conn_param_bool001.php.svn-work | 0 .../props/conn_param_bool002.php.svn-work | 0 .../props/conn_param_bool003.php.svn-work | 0 .../props/conn_param_bool004.php.svn-work | 0 .../props/conn_param_bool005.php.svn-work | 0 .../.svn/props/connect001.php.svn-work | 0 .../.svn/props/connect002.php.svn-work | 0 .../.svn/props/connect003.php.svn-work | 0 .../.svn/props/connect004.php.svn-work | 0 .../.svn/props/connect005.php.svn-work | 0 .../.svn/props/connect006.php.svn-work | 0 .../.svn/props/connect007.php.svn-work | 0 .../.svn/props/create_db001.php.svn-work | 0 .../.svn/props/db_query001.php.svn-work | 0 .../.svn/props/drop_db001.php.svn-work | 0 .../TestCode/.svn/props/error001.php.svn-work | 0 .../TestCode/.svn/props/error002.php.svn-work | 0 .../.svn/props/escape_string001.php.svn-work | 0 .../.svn/props/fetch_field001.php.svn-work | 0 .../.svn/props/field_flags001.php.svn-work | 0 .../.svn/props/field_len001.php.svn-work | 0 .../.svn/props/field_name001.php.svn-work | 0 .../.svn/props/field_table001.php.svn-work | 0 .../.svn/props/field_type001.php.svn-work | 0 .../.svn/props/free_result001.php.svn-work | 0 .../.svn/props/generic001.php.svn-work | 0 .../.svn/props/generic002.php.svn-work | 0 .../.svn/props/generic003.php.svn-work | 0 .../.svn/props/generic004.php.svn-work | 0 .../.svn/props/generic005.php.svn-work | 0 .../.svn/props/generic006.php.svn-work | 0 .../.svn/props/generic007.php.svn-work | 0 .../.svn/props/generic008.php.svn-work | 0 .../props/generic_boolean001.php.svn-work | 0 .../props/generic_boolean002.php.svn-work | 0 .../.svn/props/list_dbs001.php.svn-work | 0 .../.svn/props/list_fields001.php.svn-work | 0 .../.svn/props/list_processes001.php.svn-work | 0 .../.svn/props/par_reversed001.php.svn-work | 0 .../props/real_escape_string001.php.svn-work | 0 .../.svn/props/select_db001.php.svn-work | 0 .../.svn/props/tablename001.php.svn-work | 0 .../props/unbuffered_query001.php.svn-work | 0 .../TestCode/.svn/text-base/README.svn-base | 106 + .../text-base/change_user001.php.svn-base | 102 + .../.svn/text-base/config.php.svn-base | 27 + .../.svn/text-base/conn_param001.php.svn-base | 66 + .../.svn/text-base/conn_param002.php.svn-base | 66 + .../.svn/text-base/conn_param003.php.svn-base | 59 + .../.svn/text-base/conn_param004.php.svn-base | 63 + .../.svn/text-base/conn_param005.php.svn-base | 70 + .../.svn/text-base/conn_param006.php.svn-base | 69 + .../.svn/text-base/conn_param007.php.svn-base | 69 + .../.svn/text-base/conn_param008.php.svn-base | 77 + .../text-base/conn_param_bool001.php.svn-base | 72 + .../text-base/conn_param_bool002.php.svn-base | 63 + .../text-base/conn_param_bool003.php.svn-base | 63 + .../text-base/conn_param_bool004.php.svn-base | 63 + .../text-base/conn_param_bool005.php.svn-base | 88 + .../.svn/text-base/connect001.php.svn-base | 25 + .../.svn/text-base/connect002.php.svn-base | 26 + .../.svn/text-base/connect003.php.svn-base | 27 + .../.svn/text-base/connect004.php.svn-base | 30 + .../.svn/text-base/connect005.php.svn-base | 22 + .../.svn/text-base/connect006.php.svn-base | 21 + .../.svn/text-base/connect007.php.svn-base | 25 + .../.svn/text-base/create_db001.php.svn-base | 92 + .../.svn/text-base/db_query001.php.svn-base | 103 + .../.svn/text-base/drop_db001.php.svn-base | 92 + .../.svn/text-base/error001.php.svn-base | 64 + .../.svn/text-base/error002.php.svn-base | 62 + .../text-base/escape_string001.php.svn-base | 65 + .../text-base/fetch_field001.php.svn-base | 182 + .../text-base/field_flags001.php.svn-base | 125 + .../.svn/text-base/field_len001.php.svn-base | 79 + .../.svn/text-base/field_name001.php.svn-base | 81 + .../text-base/field_table001.php.svn-base | 81 + .../.svn/text-base/field_type001.php.svn-base | 180 + .../text-base/free_result001.php.svn-base | 80 + .../.svn/text-base/generic001.php.svn-base | 94 + .../.svn/text-base/generic002.php.svn-base | 130 + .../.svn/text-base/generic003.php.svn-base | 99 + .../.svn/text-base/generic004.php.svn-base | 118 + .../.svn/text-base/generic005.php.svn-base | 90 + .../.svn/text-base/generic006.php.svn-base | 93 + .../.svn/text-base/generic007.php.svn-base | 35 + .../.svn/text-base/generic008.php.svn-base | 84 + .../text-base/generic_boolean001.php.svn-base | 81 + .../text-base/generic_boolean002.php.svn-base | 77 + .../.svn/text-base/list_dbs001.php.svn-base | 78 + .../text-base/list_fields001.php.svn-base | 119 + .../text-base/list_processes001.php.svn-base | 83 + .../text-base/par_reversed001.php.svn-base | 154 + .../real_escape_string001.php.svn-base | 65 + .../.svn/text-base/select_db001.php.svn-base | 110 + .../.svn/text-base/tablename001.php.svn-base | 93 + .../unbuffered_query001.php.svn-base | 146 + .../TestCode/.svn/wcprops/README.svn-work | 5 + .../.svn/wcprops/change_user001.php.svn-work | 5 + .../TestCode/.svn/wcprops/config.php.svn-work | 5 + .../.svn/wcprops/conn_param001.php.svn-work | 5 + .../.svn/wcprops/conn_param002.php.svn-work | 5 + .../.svn/wcprops/conn_param003.php.svn-work | 5 + .../.svn/wcprops/conn_param004.php.svn-work | 5 + .../.svn/wcprops/conn_param005.php.svn-work | 5 + .../.svn/wcprops/conn_param006.php.svn-work | 5 + .../.svn/wcprops/conn_param007.php.svn-work | 5 + .../.svn/wcprops/conn_param008.php.svn-work | 5 + .../wcprops/conn_param_bool001.php.svn-work | 5 + .../wcprops/conn_param_bool002.php.svn-work | 5 + .../wcprops/conn_param_bool003.php.svn-work | 5 + .../wcprops/conn_param_bool004.php.svn-work | 5 + .../wcprops/conn_param_bool005.php.svn-work | 5 + .../.svn/wcprops/connect001.php.svn-work | 5 + .../.svn/wcprops/connect002.php.svn-work | 5 + .../.svn/wcprops/connect003.php.svn-work | 5 + .../.svn/wcprops/connect004.php.svn-work | 5 + .../.svn/wcprops/connect005.php.svn-work | 5 + .../.svn/wcprops/connect006.php.svn-work | 5 + .../.svn/wcprops/connect007.php.svn-work | 5 + .../.svn/wcprops/create_db001.php.svn-work | 5 + .../.svn/wcprops/db_query001.php.svn-work | 5 + .../.svn/wcprops/drop_db001.php.svn-work | 5 + .../.svn/wcprops/error001.php.svn-work | 5 + .../.svn/wcprops/error002.php.svn-work | 5 + .../wcprops/escape_string001.php.svn-work | 5 + .../.svn/wcprops/fetch_field001.php.svn-work | 5 + .../.svn/wcprops/field_flags001.php.svn-work | 5 + .../.svn/wcprops/field_len001.php.svn-work | 5 + .../.svn/wcprops/field_name001.php.svn-work | 5 + .../.svn/wcprops/field_table001.php.svn-work | 5 + .../.svn/wcprops/field_type001.php.svn-work | 5 + .../.svn/wcprops/free_result001.php.svn-work | 5 + .../.svn/wcprops/generic001.php.svn-work | 5 + .../.svn/wcprops/generic002.php.svn-work | 5 + .../.svn/wcprops/generic003.php.svn-work | 5 + .../.svn/wcprops/generic004.php.svn-work | 5 + .../.svn/wcprops/generic005.php.svn-work | 5 + .../.svn/wcprops/generic006.php.svn-work | 5 + .../.svn/wcprops/generic007.php.svn-work | 5 + .../.svn/wcprops/generic008.php.svn-work | 5 + .../wcprops/generic_boolean001.php.svn-work | 5 + .../wcprops/generic_boolean002.php.svn-work | 5 + .../.svn/wcprops/list_dbs001.php.svn-work | 5 + .../.svn/wcprops/list_fields001.php.svn-work | 5 + .../wcprops/list_processes001.php.svn-work | 5 + .../.svn/wcprops/par_reversed001.php.svn-work | 5 + .../real_escape_string001.php.svn-work | 5 + .../.svn/wcprops/select_db001.php.svn-work | 5 + .../.svn/wcprops/tablename001.php.svn-work | 5 + .../wcprops/unbuffered_query001.php.svn-work | 5 + UnitTests/Converter/TestCode/README | 106 + .../Converter/TestCode/change_user001.php | 102 + UnitTests/Converter/TestCode/config.php | 27 + .../Converter/TestCode/conn_param001.php | 66 + .../Converter/TestCode/conn_param002.php | 66 + .../Converter/TestCode/conn_param003.php | 59 + .../Converter/TestCode/conn_param004.php | 63 + .../Converter/TestCode/conn_param005.php | 70 + .../Converter/TestCode/conn_param006.php | 69 + .../Converter/TestCode/conn_param007.php | 69 + .../Converter/TestCode/conn_param008.php | 77 + .../Converter/TestCode/conn_param_bool001.php | 72 + .../Converter/TestCode/conn_param_bool002.php | 63 + .../Converter/TestCode/conn_param_bool003.php | 63 + .../Converter/TestCode/conn_param_bool004.php | 63 + .../Converter/TestCode/conn_param_bool005.php | 88 + UnitTests/Converter/TestCode/connect001.php | 25 + UnitTests/Converter/TestCode/connect002.php | 26 + UnitTests/Converter/TestCode/connect003.php | 27 + UnitTests/Converter/TestCode/connect004.php | 30 + UnitTests/Converter/TestCode/connect005.php | 22 + UnitTests/Converter/TestCode/connect006.php | 21 + UnitTests/Converter/TestCode/connect007.php | 25 + UnitTests/Converter/TestCode/create_db001.php | 92 + UnitTests/Converter/TestCode/db_query001.php | 103 + UnitTests/Converter/TestCode/drop_db001.php | 92 + UnitTests/Converter/TestCode/error001.php | 64 + UnitTests/Converter/TestCode/error002.php | 62 + .../Converter/TestCode/escape_string001.php | 65 + .../Converter/TestCode/fetch_field001.php | 182 + .../Converter/TestCode/field_flags001.php | 125 + UnitTests/Converter/TestCode/field_len001.php | 79 + .../Converter/TestCode/field_name001.php | 81 + .../Converter/TestCode/field_table001.php | 81 + .../Converter/TestCode/field_type001.php | 180 + .../Converter/TestCode/free_result001.php | 80 + UnitTests/Converter/TestCode/generic001.php | 94 + UnitTests/Converter/TestCode/generic002.php | 130 + UnitTests/Converter/TestCode/generic003.php | 99 + UnitTests/Converter/TestCode/generic004.php | 118 + UnitTests/Converter/TestCode/generic005.php | 90 + UnitTests/Converter/TestCode/generic006.php | 93 + UnitTests/Converter/TestCode/generic007.php | 35 + UnitTests/Converter/TestCode/generic008.php | 84 + .../Converter/TestCode/generic_boolean001.php | 81 + .../Converter/TestCode/generic_boolean002.php | 77 + UnitTests/Converter/TestCode/list_dbs001.php | 78 + .../Converter/TestCode/list_fields001.php | 119 + .../Converter/TestCode/list_processes001.php | 83 + .../Converter/TestCode/par_reversed001.php | 154 + .../TestCode/real_escape_string001.php | 65 + UnitTests/Converter/TestCode/select_db001.php | 110 + UnitTests/Converter/TestCode/tablename001.php | 93 + .../TestCode/unbuffered_query001.php | 146 + UnitTests/Converter/UnbufferedQueryTest.php | 54 + UnitTests/Function/.svn/README.txt | 2 + UnitTests/Function/.svn/dir-wcprops | 5 + UnitTests/Function/.svn/empty-file | 0 UnitTests/Function/.svn/entries | 266 + UnitTests/Function/.svn/format | 1 + .../.svn/prop-base/AllTests.php.svn-base | 0 .../prop-base/ChangeUserTest.php.svn-base | 0 .../prop-base/ConnParamBoolTest.php.svn-base | 0 .../.svn/prop-base/ConnParamTest.php.svn-base | 0 .../.svn/prop-base/ConnectTest.php.svn-base | 0 .../.svn/prop-base/CreateDBTest.php.svn-base | 0 .../.svn/prop-base/DBQueryTest.php.svn-base | 0 .../.svn/prop-base/DropDBTest.php.svn-base | 0 .../.svn/prop-base/ErrorTest.php.svn-base | 0 .../prop-base/EscapeStringTest.php.svn-base | 0 .../prop-base/FetchFieldTest.php.svn-base | 0 .../prop-base/FieldFlagsTest.php.svn-base | 0 .../.svn/prop-base/FieldLenTest.php.svn-base | 0 .../.svn/prop-base/FieldNameTest.php.svn-base | 0 .../prop-base/FieldTableTest.php.svn-base | 0 .../.svn/prop-base/FieldTypeTest.php.svn-base | 0 .../prop-base/FreeResultTest.php.svn-base | 0 .../prop-base/GenericBooleanTest.php.svn-base | 0 .../.svn/prop-base/GenericTest.php.svn-base | 0 .../.svn/prop-base/ListDBsTest.php.svn-base | 0 .../prop-base/ListFieldsTest.php.svn-base | 0 .../prop-base/ListProcessesTest.php.svn-base | 0 .../prop-base/ListTablesTest.php.svn-base | 0 .../prop-base/ParReversedTest.php.svn-base | 0 .../RealEscapeStringTest.php.svn-base | 0 .../.svn/prop-base/SelectDBTest.php.svn-base | 0 .../.svn/prop-base/TablenameTest.php.svn-base | 0 .../UnbufferedQueryTest.php.svn-base | 0 .../Function/.svn/props/AllTests.php.svn-work | 0 .../.svn/props/ChangeUserTest.php.svn-work | 0 .../.svn/props/ConnParamBoolTest.php.svn-work | 0 .../.svn/props/ConnParamTest.php.svn-work | 0 .../.svn/props/ConnectTest.php.svn-work | 0 .../.svn/props/CreateDBTest.php.svn-work | 0 .../.svn/props/DBQueryTest.php.svn-work | 0 .../.svn/props/DropDBTest.php.svn-work | 0 .../.svn/props/ErrorTest.php.svn-work | 0 .../.svn/props/EscapeStringTest.php.svn-work | 0 .../.svn/props/FetchFieldTest.php.svn-work | 0 .../.svn/props/FieldFlagsTest.php.svn-work | 0 .../.svn/props/FieldLenTest.php.svn-work | 0 .../.svn/props/FieldNameTest.php.svn-work | 0 .../.svn/props/FieldTableTest.php.svn-work | 0 .../.svn/props/FieldTypeTest.php.svn-work | 0 .../.svn/props/FreeResultTest.php.svn-work | 0 .../props/GenericBooleanTest.php.svn-work | 0 .../.svn/props/GenericTest.php.svn-work | 0 .../.svn/props/ListDBsTest.php.svn-work | 0 .../.svn/props/ListFieldsTest.php.svn-work | 0 .../.svn/props/ListProcessesTest.php.svn-work | 0 .../.svn/props/ListTablesTest.php.svn-work | 0 .../.svn/props/ParReversedTest.php.svn-work | 0 .../props/RealEscapeStringTest.php.svn-work | 0 .../.svn/props/SelectDBTest.php.svn-work | 0 .../.svn/props/TablenameTest.php.svn-work | 0 .../props/UnbufferedQueryTest.php.svn-work | 0 .../.svn/text-base/AllTests.php.svn-base | 95 + .../text-base/ChangeUserTest.php.svn-base | 86 + .../text-base/ConnParamBoolTest.php.svn-base | 95 + .../.svn/text-base/ConnParamTest.php.svn-base | 97 + .../.svn/text-base/ConnectTest.php.svn-base | 143 + .../.svn/text-base/CreateDBTest.php.svn-base | 94 + .../.svn/text-base/DBQueryTest.php.svn-base | 111 + .../.svn/text-base/DropDBTest.php.svn-base | 97 + .../.svn/text-base/ErrorTest.php.svn-base | 92 + .../text-base/EscapeStringTest.php.svn-base | 65 + .../text-base/FetchFieldTest.php.svn-base | 64 + .../text-base/FieldFlagsTest.php.svn-base | 90 + .../.svn/text-base/FieldLenTest.php.svn-base | 75 + .../.svn/text-base/FieldNameTest.php.svn-base | 77 + .../text-base/FieldTableTest.php.svn-base | 76 + .../.svn/text-base/FieldTypeTest.php.svn-base | 76 + .../text-base/FreeResultTest.php.svn-base | 72 + .../text-base/GenericBooleanTest.php.svn-base | 52 + .../.svn/text-base/GenericTest.php.svn-base | 108 + .../.svn/text-base/ListDBsTest.php.svn-base | 74 + .../text-base/ListFieldsTest.php.svn-base | 100 + .../text-base/ListProcessesTest.php.svn-base | 74 + .../text-base/ListTablesTest.php.svn-base | 86 + .../text-base/ParReversedTest.php.svn-base | 81 + .../RealEscapeStringTest.php.svn-base | 77 + .../.svn/text-base/SelectDBTest.php.svn-base | 86 + .../.svn/text-base/TablenameTest.php.svn-base | 73 + .../UnbufferedQueryTest.php.svn-base | 75 + .../.svn/wcprops/AllTests.php.svn-work | 5 + .../.svn/wcprops/ChangeUserTest.php.svn-work | 5 + .../wcprops/ConnParamBoolTest.php.svn-work | 5 + .../.svn/wcprops/ConnParamTest.php.svn-work | 5 + .../.svn/wcprops/ConnectTest.php.svn-work | 5 + .../.svn/wcprops/CreateDBTest.php.svn-work | 5 + .../.svn/wcprops/DBQueryTest.php.svn-work | 5 + .../.svn/wcprops/DropDBTest.php.svn-work | 5 + .../.svn/wcprops/ErrorTest.php.svn-work | 5 + .../wcprops/EscapeStringTest.php.svn-work | 5 + .../.svn/wcprops/FetchFieldTest.php.svn-work | 5 + .../.svn/wcprops/FieldFlagsTest.php.svn-work | 5 + .../.svn/wcprops/FieldLenTest.php.svn-work | 5 + .../.svn/wcprops/FieldNameTest.php.svn-work | 5 + .../.svn/wcprops/FieldTableTest.php.svn-work | 5 + .../.svn/wcprops/FieldTypeTest.php.svn-work | 5 + .../.svn/wcprops/FreeResultTest.php.svn-work | 5 + .../wcprops/GenericBooleanTest.php.svn-work | 5 + .../.svn/wcprops/GenericTest.php.svn-work | 5 + .../.svn/wcprops/ListDBsTest.php.svn-work | 5 + .../.svn/wcprops/ListFieldsTest.php.svn-work | 5 + .../wcprops/ListProcessesTest.php.svn-work | 5 + .../.svn/wcprops/ListTablesTest.php.svn-work | 5 + .../.svn/wcprops/ParReversedTest.php.svn-work | 5 + .../wcprops/RealEscapeStringTest.php.svn-work | 5 + .../.svn/wcprops/SelectDBTest.php.svn-work | 5 + .../.svn/wcprops/TablenameTest.php.svn-work | 5 + .../wcprops/UnbufferedQueryTest.php.svn-work | 5 + UnitTests/Function/AllTests.php | 95 + UnitTests/Function/ChangeUserTest.php | 86 + UnitTests/Function/ConnParamBoolTest.php | 95 + UnitTests/Function/ConnParamTest.php | 97 + UnitTests/Function/ConnectTest.php | 143 + UnitTests/Function/CreateDBTest.php | 94 + UnitTests/Function/DBQueryTest.php | 111 + UnitTests/Function/DropDBTest.php | 97 + UnitTests/Function/ErrorTest.php | 92 + UnitTests/Function/EscapeStringTest.php | 65 + UnitTests/Function/FetchFieldTest.php | 64 + UnitTests/Function/FieldFlagsTest.php | 90 + UnitTests/Function/FieldLenTest.php | 75 + UnitTests/Function/FieldNameTest.php | 77 + UnitTests/Function/FieldTableTest.php | 76 + UnitTests/Function/FieldTypeTest.php | 76 + UnitTests/Function/FreeResultTest.php | 72 + UnitTests/Function/GenericBooleanTest.php | 52 + UnitTests/Function/GenericTest.php | 108 + UnitTests/Function/ListDBsTest.php | 74 + UnitTests/Function/ListFieldsTest.php | 100 + UnitTests/Function/ListProcessesTest.php | 74 + UnitTests/Function/ListTablesTest.php | 86 + UnitTests/Function/ParReversedTest.php | 81 + UnitTests/Function/RealEscapeStringTest.php | 77 + UnitTests/Function/SelectDBTest.php | 86 + UnitTests/Function/TablenameTest.php | 73 + UnitTests/Function/UnbufferedQueryTest.php | 75 + UnitTests/README | 54 + cli.php | 445 + index.php | 16 + 850 files changed, 40934 insertions(+) create mode 100644 .gitattributes create mode 100644 .gitignore create mode 100644 .svn/README.txt create mode 100644 .svn/dir-wcprops create mode 100644 .svn/empty-file create mode 100644 .svn/entries create mode 100644 .svn/format create mode 100644 .svn/prop-base/Converter.php.svn-base create mode 100644 .svn/prop-base/README.svn-base create mode 100644 .svn/prop-base/cli.php.svn-base create mode 100644 .svn/prop-base/index.php.svn-base create mode 100644 .svn/props/Converter.php.svn-work create mode 100644 .svn/props/README.svn-work create mode 100644 .svn/props/cli.php.svn-work create mode 100644 .svn/props/index.php.svn-work create mode 100644 .svn/text-base/Converter.php.svn-base create mode 100644 .svn/text-base/README.svn-base create mode 100644 .svn/text-base/cli.php.svn-base create mode 100644 .svn/text-base/index.php.svn-base create mode 100644 .svn/wcprops/Converter.php.svn-work create mode 100644 .svn/wcprops/README.svn-work create mode 100644 .svn/wcprops/cli.php.svn-work create mode 100644 .svn/wcprops/index.php.svn-work create mode 100644 Converter.php create mode 100644 Function/.svn/README.txt create mode 100644 Function/.svn/dir-wcprops create mode 100644 Function/.svn/empty-file create mode 100644 Function/.svn/entries create mode 100644 Function/.svn/format create mode 100644 Function/.svn/prop-base/ChangeUser.php.svn-base create mode 100644 Function/.svn/prop-base/ConnParam.php.svn-base create mode 100644 Function/.svn/prop-base/ConnParamBool.php.svn-base create mode 100644 Function/.svn/prop-base/Connect.php.svn-base create mode 100644 Function/.svn/prop-base/CreateDB.php.svn-base create mode 100644 Function/.svn/prop-base/DBQuery.php.svn-base create mode 100644 Function/.svn/prop-base/DropDB.php.svn-base create mode 100644 Function/.svn/prop-base/Error.php.svn-base create mode 100644 Function/.svn/prop-base/EscapeString.php.svn-base create mode 100644 Function/.svn/prop-base/FetchField.php.svn-base create mode 100644 Function/.svn/prop-base/FieldFlags.php.svn-base create mode 100644 Function/.svn/prop-base/FieldLen.php.svn-base create mode 100644 Function/.svn/prop-base/FieldName.php.svn-base create mode 100644 Function/.svn/prop-base/FieldTable.php.svn-base create mode 100644 Function/.svn/prop-base/FieldType.php.svn-base create mode 100644 Function/.svn/prop-base/FreeResult.php.svn-base create mode 100644 Function/.svn/prop-base/Generic.php.svn-base create mode 100644 Function/.svn/prop-base/GenericBoolean.php.svn-base create mode 100644 Function/.svn/prop-base/ListDBs.php.svn-base create mode 100644 Function/.svn/prop-base/ListFields.php.svn-base create mode 100644 Function/.svn/prop-base/ListProcesses.php.svn-base create mode 100644 Function/.svn/prop-base/ListTables.php.svn-base create mode 100644 Function/.svn/prop-base/ParReversed.php.svn-base create mode 100644 Function/.svn/prop-base/RealEscapeString.php.svn-base create mode 100644 Function/.svn/prop-base/SelectDB.php.svn-base create mode 100644 Function/.svn/prop-base/Tablename.php.svn-base create mode 100644 Function/.svn/prop-base/UnbufferedQuery.php.svn-base create mode 100644 Function/.svn/props/ChangeUser.php.svn-work create mode 100644 Function/.svn/props/ConnParam.php.svn-work create mode 100644 Function/.svn/props/ConnParamBool.php.svn-work create mode 100644 Function/.svn/props/Connect.php.svn-work create mode 100644 Function/.svn/props/CreateDB.php.svn-work create mode 100644 Function/.svn/props/DBQuery.php.svn-work create mode 100644 Function/.svn/props/DropDB.php.svn-work create mode 100644 Function/.svn/props/Error.php.svn-work create mode 100644 Function/.svn/props/EscapeString.php.svn-work create mode 100644 Function/.svn/props/FetchField.php.svn-work create mode 100644 Function/.svn/props/FieldFlags.php.svn-work create mode 100644 Function/.svn/props/FieldLen.php.svn-work create mode 100644 Function/.svn/props/FieldName.php.svn-work create mode 100644 Function/.svn/props/FieldTable.php.svn-work create mode 100644 Function/.svn/props/FieldType.php.svn-work create mode 100644 Function/.svn/props/FreeResult.php.svn-work create mode 100644 Function/.svn/props/Generic.php.svn-work create mode 100644 Function/.svn/props/GenericBoolean.php.svn-work create mode 100644 Function/.svn/props/ListDBs.php.svn-work create mode 100644 Function/.svn/props/ListFields.php.svn-work create mode 100644 Function/.svn/props/ListProcesses.php.svn-work create mode 100644 Function/.svn/props/ListTables.php.svn-work create mode 100644 Function/.svn/props/ParReversed.php.svn-work create mode 100644 Function/.svn/props/RealEscapeString.php.svn-work create mode 100644 Function/.svn/props/SelectDB.php.svn-work create mode 100644 Function/.svn/props/Tablename.php.svn-work create mode 100644 Function/.svn/props/UnbufferedQuery.php.svn-work create mode 100644 Function/.svn/text-base/ChangeUser.php.svn-base create mode 100644 Function/.svn/text-base/ConnParam.php.svn-base create mode 100644 Function/.svn/text-base/ConnParamBool.php.svn-base create mode 100644 Function/.svn/text-base/Connect.php.svn-base create mode 100644 Function/.svn/text-base/CreateDB.php.svn-base create mode 100644 Function/.svn/text-base/DBQuery.php.svn-base create mode 100644 Function/.svn/text-base/DropDB.php.svn-base create mode 100644 Function/.svn/text-base/Error.php.svn-base create mode 100644 Function/.svn/text-base/EscapeString.php.svn-base create mode 100644 Function/.svn/text-base/FetchField.php.svn-base create mode 100644 Function/.svn/text-base/FieldFlags.php.svn-base create mode 100644 Function/.svn/text-base/FieldLen.php.svn-base create mode 100644 Function/.svn/text-base/FieldName.php.svn-base create mode 100644 Function/.svn/text-base/FieldTable.php.svn-base create mode 100644 Function/.svn/text-base/FieldType.php.svn-base create mode 100644 Function/.svn/text-base/FreeResult.php.svn-base create mode 100644 Function/.svn/text-base/Generic.php.svn-base create mode 100644 Function/.svn/text-base/GenericBoolean.php.svn-base create mode 100644 Function/.svn/text-base/ListDBs.php.svn-base create mode 100644 Function/.svn/text-base/ListFields.php.svn-base create mode 100644 Function/.svn/text-base/ListProcesses.php.svn-base create mode 100644 Function/.svn/text-base/ListTables.php.svn-base create mode 100644 Function/.svn/text-base/ParReversed.php.svn-base create mode 100644 Function/.svn/text-base/RealEscapeString.php.svn-base create mode 100644 Function/.svn/text-base/SelectDB.php.svn-base create mode 100644 Function/.svn/text-base/Tablename.php.svn-base create mode 100644 Function/.svn/text-base/UnbufferedQuery.php.svn-base create mode 100644 Function/.svn/wcprops/ChangeUser.php.svn-work create mode 100644 Function/.svn/wcprops/ConnParam.php.svn-work create mode 100644 Function/.svn/wcprops/ConnParamBool.php.svn-work create mode 100644 Function/.svn/wcprops/Connect.php.svn-work create mode 100644 Function/.svn/wcprops/CreateDB.php.svn-work create mode 100644 Function/.svn/wcprops/DBQuery.php.svn-work create mode 100644 Function/.svn/wcprops/DropDB.php.svn-work create mode 100644 Function/.svn/wcprops/Error.php.svn-work create mode 100644 Function/.svn/wcprops/EscapeString.php.svn-work create mode 100644 Function/.svn/wcprops/FetchField.php.svn-work create mode 100644 Function/.svn/wcprops/FieldFlags.php.svn-work create mode 100644 Function/.svn/wcprops/FieldLen.php.svn-work create mode 100644 Function/.svn/wcprops/FieldName.php.svn-work create mode 100644 Function/.svn/wcprops/FieldTable.php.svn-work create mode 100644 Function/.svn/wcprops/FieldType.php.svn-work create mode 100644 Function/.svn/wcprops/FreeResult.php.svn-work create mode 100644 Function/.svn/wcprops/Generic.php.svn-work create mode 100644 Function/.svn/wcprops/GenericBoolean.php.svn-work create mode 100644 Function/.svn/wcprops/ListDBs.php.svn-work create mode 100644 Function/.svn/wcprops/ListFields.php.svn-work create mode 100644 Function/.svn/wcprops/ListProcesses.php.svn-work create mode 100644 Function/.svn/wcprops/ListTables.php.svn-work create mode 100644 Function/.svn/wcprops/ParReversed.php.svn-work create mode 100644 Function/.svn/wcprops/RealEscapeString.php.svn-work create mode 100644 Function/.svn/wcprops/SelectDB.php.svn-work create mode 100644 Function/.svn/wcprops/Tablename.php.svn-work create mode 100644 Function/.svn/wcprops/UnbufferedQuery.php.svn-work create mode 100644 Function/ChangeUser.php create mode 100644 Function/ConnParam.php create mode 100644 Function/ConnParamBool.php create mode 100644 Function/Connect.php create mode 100644 Function/CreateDB.php create mode 100644 Function/DBQuery.php create mode 100644 Function/DropDB.php create mode 100644 Function/Error.php create mode 100644 Function/EscapeString.php create mode 100644 Function/FetchField.php create mode 100644 Function/FieldFlags.php create mode 100644 Function/FieldLen.php create mode 100644 Function/FieldName.php create mode 100644 Function/FieldTable.php create mode 100644 Function/FieldType.php create mode 100644 Function/FreeResult.php create mode 100644 Function/Generic.php create mode 100644 Function/GenericBoolean.php create mode 100644 Function/ListDBs.php create mode 100644 Function/ListFields.php create mode 100644 Function/ListProcesses.php create mode 100644 Function/ListTables.php create mode 100644 Function/ParReversed.php create mode 100644 Function/RealEscapeString.php create mode 100644 Function/SelectDB.php create mode 100644 Function/Tablename.php create mode 100644 Function/UnbufferedQuery.php create mode 100644 GUI/.svn/README.txt create mode 100644 GUI/.svn/dir-wcprops create mode 100644 GUI/.svn/empty-file create mode 100644 GUI/.svn/entries create mode 100644 GUI/.svn/format create mode 100644 GUI/.svn/prop-base/convert_directory.php.svn-base create mode 100644 GUI/.svn/prop-base/convert_file.php.svn-base create mode 100644 GUI/.svn/prop-base/convert_snippet.php.svn-base create mode 100644 GUI/.svn/prop-base/help.php.svn-base create mode 100644 GUI/.svn/prop-base/index.php.svn-base create mode 100644 GUI/.svn/props/convert_directory.php.svn-work create mode 100644 GUI/.svn/props/convert_file.php.svn-work create mode 100644 GUI/.svn/props/convert_snippet.php.svn-work create mode 100644 GUI/.svn/props/help.php.svn-work create mode 100644 GUI/.svn/props/index.php.svn-work create mode 100644 GUI/.svn/text-base/convert_directory.php.svn-base create mode 100644 GUI/.svn/text-base/convert_file.php.svn-base create mode 100644 GUI/.svn/text-base/convert_snippet.php.svn-base create mode 100644 GUI/.svn/text-base/help.php.svn-base create mode 100644 GUI/.svn/text-base/index.php.svn-base create mode 100644 GUI/.svn/wcprops/convert_directory.php.svn-work create mode 100644 GUI/.svn/wcprops/convert_file.php.svn-work create mode 100644 GUI/.svn/wcprops/convert_snippet.php.svn-work create mode 100644 GUI/.svn/wcprops/help.php.svn-work create mode 100644 GUI/.svn/wcprops/index.php.svn-work create mode 100644 GUI/convert_directory.php create mode 100644 GUI/convert_file.php create mode 100644 GUI/convert_snippet.php create mode 100644 GUI/css/.svn/README.txt create mode 100644 GUI/css/.svn/dir-wcprops create mode 100644 GUI/css/.svn/empty-file create mode 100644 GUI/css/.svn/entries create mode 100644 GUI/css/.svn/format create mode 100644 GUI/css/.svn/prop-base/main.css.svn-base create mode 100644 GUI/css/.svn/props/main.css.svn-work create mode 100644 GUI/css/.svn/text-base/main.css.svn-base create mode 100644 GUI/css/.svn/wcprops/main.css.svn-work create mode 100644 GUI/css/bootstrap-theme.css create mode 100644 GUI/css/bootstrap.css create mode 100644 GUI/css/main.css create mode 100644 GUI/file.php create mode 100644 GUI/help.php create mode 100644 GUI/index.php create mode 100644 GUI/js/application.js create mode 100644 GUI/js/bootstrap.js create mode 100644 GUI/js/bootstrap.min.js create mode 100644 GUI/js/collapse.js create mode 100644 GUI/js/dropdown.js create mode 100644 GUI/js/holder.js create mode 100644 GUI/js/html5shiv.js create mode 100644 GUI/js/jquery.js create mode 100644 GUI/js/respond.min.js create mode 100644 GUI/phpinfo.php create mode 100644 GUI/snippets/.svn/README.txt create mode 100644 GUI/snippets/.svn/dir-wcprops create mode 100644 GUI/snippets/.svn/empty-file create mode 100644 GUI/snippets/.svn/entries create mode 100644 GUI/snippets/.svn/format create mode 100644 GUI/snippets/.svn/prop-base/MySQLConverterTool_GUI_Snippets.php.svn-base create mode 100644 GUI/snippets/.svn/prop-base/footer.php.svn-base create mode 100644 GUI/snippets/.svn/prop-base/form_directory.php.svn-base create mode 100644 GUI/snippets/.svn/prop-base/form_file.php.svn-base create mode 100644 GUI/snippets/.svn/prop-base/form_snippet.php.svn-base create mode 100644 GUI/snippets/.svn/prop-base/header.php.svn-base create mode 100644 GUI/snippets/.svn/prop-base/show_converted_directory.php.svn-base create mode 100644 GUI/snippets/.svn/prop-base/show_converted_file.php.svn-base create mode 100644 GUI/snippets/.svn/prop-base/show_converted_snippet.php.svn-base create mode 100644 GUI/snippets/.svn/props/MySQLConverterTool_GUI_Snippets.php.svn-work create mode 100644 GUI/snippets/.svn/props/footer.php.svn-work create mode 100644 GUI/snippets/.svn/props/form_directory.php.svn-work create mode 100644 GUI/snippets/.svn/props/form_file.php.svn-work create mode 100644 GUI/snippets/.svn/props/form_snippet.php.svn-work create mode 100644 GUI/snippets/.svn/props/header.php.svn-work create mode 100644 GUI/snippets/.svn/props/show_converted_directory.php.svn-work create mode 100644 GUI/snippets/.svn/props/show_converted_file.php.svn-work create mode 100644 GUI/snippets/.svn/props/show_converted_snippet.php.svn-work create mode 100644 GUI/snippets/.svn/text-base/MySQLConverterTool_GUI_Snippets.php.svn-base create mode 100644 GUI/snippets/.svn/text-base/footer.php.svn-base create mode 100644 GUI/snippets/.svn/text-base/form_directory.php.svn-base create mode 100644 GUI/snippets/.svn/text-base/form_file.php.svn-base create mode 100644 GUI/snippets/.svn/text-base/form_snippet.php.svn-base create mode 100644 GUI/snippets/.svn/text-base/header.php.svn-base create mode 100644 GUI/snippets/.svn/text-base/show_converted_directory.php.svn-base create mode 100644 GUI/snippets/.svn/text-base/show_converted_file.php.svn-base create mode 100644 GUI/snippets/.svn/text-base/show_converted_snippet.php.svn-base create mode 100644 GUI/snippets/.svn/wcprops/MySQLConverterTool_GUI_Snippets.php.svn-work create mode 100644 GUI/snippets/.svn/wcprops/footer.php.svn-work create mode 100644 GUI/snippets/.svn/wcprops/form_directory.php.svn-work create mode 100644 GUI/snippets/.svn/wcprops/form_file.php.svn-work create mode 100644 GUI/snippets/.svn/wcprops/form_snippet.php.svn-work create mode 100644 GUI/snippets/.svn/wcprops/header.php.svn-work create mode 100644 GUI/snippets/.svn/wcprops/show_converted_directory.php.svn-work create mode 100644 GUI/snippets/.svn/wcprops/show_converted_file.php.svn-work create mode 100644 GUI/snippets/.svn/wcprops/show_converted_snippet.php.svn-work create mode 100644 GUI/snippets/MySQLConverterTool_GUI_Snippets.php create mode 100644 GUI/snippets/footer.php create mode 100644 GUI/snippets/form_directory.php create mode 100644 GUI/snippets/form_file.php create mode 100644 GUI/snippets/form_snippet.php create mode 100644 GUI/snippets/header.php create mode 100644 GUI/snippets/show_converted_directory.php create mode 100644 GUI/snippets/show_converted_file.php create mode 100644 GUI/snippets/show_converted_snippet.php create mode 100644 README create mode 100644 UnitTests/.svn/README.txt create mode 100644 UnitTests/.svn/dir-wcprops create mode 100644 UnitTests/.svn/empty-file create mode 100644 UnitTests/.svn/entries create mode 100644 UnitTests/.svn/format create mode 100644 UnitTests/.svn/prop-base/AllTests.php.svn-base create mode 100644 UnitTests/.svn/prop-base/README.svn-base create mode 100644 UnitTests/.svn/props/AllTests.php.svn-work create mode 100644 UnitTests/.svn/props/README.svn-work create mode 100644 UnitTests/.svn/text-base/AllTests.php.svn-base create mode 100644 UnitTests/.svn/text-base/README.svn-base create mode 100644 UnitTests/.svn/wcprops/AllTests.php.svn-work create mode 100644 UnitTests/.svn/wcprops/README.svn-work create mode 100644 UnitTests/AllTests.php create mode 100644 UnitTests/Converter/.svn/README.txt create mode 100644 UnitTests/Converter/.svn/dir-wcprops create mode 100644 UnitTests/Converter/.svn/empty-file create mode 100644 UnitTests/Converter/.svn/entries create mode 100644 UnitTests/Converter/.svn/format create mode 100644 UnitTests/Converter/.svn/prop-base/AllTests.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/ChangeUserTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/ConnParamBoolTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/ConnParamTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/ConnectTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/ConverterTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/CreateDBTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/DBQueryTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/DropDBTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/ErrorTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/EscapeStringTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/FetchFieldTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/FieldFlagsTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/FieldLenTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/FieldNameTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/FieldTableTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/FieldTypeTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/FreeResultTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/GenericBooleanTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/GenericTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/ListDBsTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/ListFieldsTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/ListProcessesTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/ParReversedTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/RealEscapeStringTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/SelectDBTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/TablenameTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/prop-base/UnbufferedQueryTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/props/AllTests.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/ChangeUserTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/ConnParamBoolTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/ConnParamTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/ConnectTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/ConverterTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/CreateDBTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/DBQueryTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/DropDBTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/ErrorTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/EscapeStringTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/FetchFieldTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/FieldFlagsTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/FieldLenTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/FieldNameTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/FieldTableTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/FieldTypeTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/FreeResultTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/GenericBooleanTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/GenericTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/ListDBsTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/ListFieldsTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/ListProcessesTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/ParReversedTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/RealEscapeStringTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/SelectDBTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/TablenameTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/props/UnbufferedQueryTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/text-base/AllTests.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/ChangeUserTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/ConnParamBoolTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/ConnParamTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/ConnectTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/ConverterTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/CreateDBTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/DBQueryTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/DropDBTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/ErrorTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/EscapeStringTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/FetchFieldTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/FieldFlagsTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/FieldLenTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/FieldNameTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/FieldTableTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/FieldTypeTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/FreeResultTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/GenericBooleanTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/GenericTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/ListDBsTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/ListFieldsTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/ListProcessesTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/ParReversedTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/RealEscapeStringTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/SelectDBTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/TablenameTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/text-base/UnbufferedQueryTest.php.svn-base create mode 100644 UnitTests/Converter/.svn/wcprops/AllTests.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/ChangeUserTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/ConnParamBoolTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/ConnParamTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/ConnectTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/ConverterTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/CreateDBTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/DBQueryTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/DropDBTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/ErrorTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/EscapeStringTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/FetchFieldTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/FieldFlagsTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/FieldLenTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/FieldNameTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/FieldTableTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/FieldTypeTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/FreeResultTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/GenericBooleanTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/GenericTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/ListDBsTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/ListFieldsTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/ListProcessesTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/ParReversedTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/RealEscapeStringTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/SelectDBTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/TablenameTest.php.svn-work create mode 100644 UnitTests/Converter/.svn/wcprops/UnbufferedQueryTest.php.svn-work create mode 100644 UnitTests/Converter/AllTests.php create mode 100644 UnitTests/Converter/ChangeUserTest.php create mode 100644 UnitTests/Converter/ConnParamBoolTest.php create mode 100644 UnitTests/Converter/ConnParamTest.php create mode 100644 UnitTests/Converter/ConnectTest.php create mode 100644 UnitTests/Converter/ConverterTest.php create mode 100644 UnitTests/Converter/CreateDBTest.php create mode 100644 UnitTests/Converter/DBQueryTest.php create mode 100644 UnitTests/Converter/DropDBTest.php create mode 100644 UnitTests/Converter/ErrorTest.php create mode 100644 UnitTests/Converter/EscapeStringTest.php create mode 100644 UnitTests/Converter/FetchFieldTest.php create mode 100644 UnitTests/Converter/FieldFlagsTest.php create mode 100644 UnitTests/Converter/FieldLenTest.php create mode 100644 UnitTests/Converter/FieldNameTest.php create mode 100644 UnitTests/Converter/FieldTableTest.php create mode 100644 UnitTests/Converter/FieldTypeTest.php create mode 100644 UnitTests/Converter/FreeResultTest.php create mode 100644 UnitTests/Converter/GenericBooleanTest.php create mode 100644 UnitTests/Converter/GenericTest.php create mode 100644 UnitTests/Converter/ListDBsTest.php create mode 100644 UnitTests/Converter/ListFieldsTest.php create mode 100644 UnitTests/Converter/ListProcessesTest.php create mode 100644 UnitTests/Converter/ParReversedTest.php create mode 100644 UnitTests/Converter/RealEscapeStringTest.php create mode 100644 UnitTests/Converter/SelectDBTest.php create mode 100644 UnitTests/Converter/TablenameTest.php create mode 100644 UnitTests/Converter/TestCode/.svn/README.txt create mode 100644 UnitTests/Converter/TestCode/.svn/dir-wcprops create mode 100644 UnitTests/Converter/TestCode/.svn/empty-file create mode 100644 UnitTests/Converter/TestCode/.svn/entries create mode 100644 UnitTests/Converter/TestCode/.svn/format create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/README.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/change_user001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/config.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param003.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param004.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param005.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param006.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param007.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param008.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param_bool001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param_bool002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param_bool003.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param_bool004.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/conn_param_bool005.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/connect001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/connect002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/connect003.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/connect004.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/connect005.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/connect006.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/connect007.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/create_db001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/db_query001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/drop_db001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/error001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/error002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/escape_string001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/fetch_field001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/field_flags001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/field_len001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/field_name001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/field_table001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/field_type001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/free_result001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/generic001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/generic002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/generic003.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/generic004.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/generic005.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/generic006.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/generic007.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/generic008.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/generic_boolean001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/generic_boolean002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/list_dbs001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/list_fields001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/list_processes001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/par_reversed001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/real_escape_string001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/select_db001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/tablename001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/prop-base/unbuffered_query001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/props/README.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/change_user001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/config.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param003.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param004.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param005.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param006.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param007.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param008.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param_bool001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param_bool002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param_bool003.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param_bool004.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/conn_param_bool005.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/connect001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/connect002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/connect003.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/connect004.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/connect005.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/connect006.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/connect007.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/create_db001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/db_query001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/drop_db001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/error001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/error002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/escape_string001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/fetch_field001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/field_flags001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/field_len001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/field_name001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/field_table001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/field_type001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/free_result001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/generic001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/generic002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/generic003.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/generic004.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/generic005.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/generic006.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/generic007.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/generic008.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/generic_boolean001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/generic_boolean002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/list_dbs001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/list_fields001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/list_processes001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/par_reversed001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/real_escape_string001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/select_db001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/tablename001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/props/unbuffered_query001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/README.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/change_user001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/config.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param003.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param004.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param005.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param006.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param007.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param008.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param_bool001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param_bool002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param_bool003.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param_bool004.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/conn_param_bool005.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/connect001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/connect002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/connect003.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/connect004.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/connect005.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/connect006.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/connect007.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/create_db001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/db_query001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/drop_db001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/error001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/error002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/escape_string001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/fetch_field001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/field_flags001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/field_len001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/field_name001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/field_table001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/field_type001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/free_result001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/generic001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/generic002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/generic003.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/generic004.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/generic005.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/generic006.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/generic007.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/generic008.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/generic_boolean001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/generic_boolean002.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/list_dbs001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/list_fields001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/list_processes001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/par_reversed001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/real_escape_string001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/select_db001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/tablename001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/text-base/unbuffered_query001.php.svn-base create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/README.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/change_user001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/config.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param003.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param004.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param005.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param006.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param007.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param008.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param_bool001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param_bool002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param_bool003.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param_bool004.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/conn_param_bool005.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/connect001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/connect002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/connect003.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/connect004.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/connect005.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/connect006.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/connect007.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/create_db001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/db_query001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/drop_db001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/error001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/error002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/escape_string001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/fetch_field001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/field_flags001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/field_len001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/field_name001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/field_table001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/field_type001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/free_result001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/generic001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/generic002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/generic003.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/generic004.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/generic005.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/generic006.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/generic007.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/generic008.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/generic_boolean001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/generic_boolean002.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/list_dbs001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/list_fields001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/list_processes001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/par_reversed001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/real_escape_string001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/select_db001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/tablename001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/.svn/wcprops/unbuffered_query001.php.svn-work create mode 100644 UnitTests/Converter/TestCode/README create mode 100644 UnitTests/Converter/TestCode/change_user001.php create mode 100644 UnitTests/Converter/TestCode/config.php create mode 100644 UnitTests/Converter/TestCode/conn_param001.php create mode 100644 UnitTests/Converter/TestCode/conn_param002.php create mode 100644 UnitTests/Converter/TestCode/conn_param003.php create mode 100644 UnitTests/Converter/TestCode/conn_param004.php create mode 100644 UnitTests/Converter/TestCode/conn_param005.php create mode 100644 UnitTests/Converter/TestCode/conn_param006.php create mode 100644 UnitTests/Converter/TestCode/conn_param007.php create mode 100644 UnitTests/Converter/TestCode/conn_param008.php create mode 100644 UnitTests/Converter/TestCode/conn_param_bool001.php create mode 100644 UnitTests/Converter/TestCode/conn_param_bool002.php create mode 100644 UnitTests/Converter/TestCode/conn_param_bool003.php create mode 100644 UnitTests/Converter/TestCode/conn_param_bool004.php create mode 100644 UnitTests/Converter/TestCode/conn_param_bool005.php create mode 100644 UnitTests/Converter/TestCode/connect001.php create mode 100644 UnitTests/Converter/TestCode/connect002.php create mode 100644 UnitTests/Converter/TestCode/connect003.php create mode 100644 UnitTests/Converter/TestCode/connect004.php create mode 100644 UnitTests/Converter/TestCode/connect005.php create mode 100644 UnitTests/Converter/TestCode/connect006.php create mode 100644 UnitTests/Converter/TestCode/connect007.php create mode 100644 UnitTests/Converter/TestCode/create_db001.php create mode 100644 UnitTests/Converter/TestCode/db_query001.php create mode 100644 UnitTests/Converter/TestCode/drop_db001.php create mode 100644 UnitTests/Converter/TestCode/error001.php create mode 100644 UnitTests/Converter/TestCode/error002.php create mode 100644 UnitTests/Converter/TestCode/escape_string001.php create mode 100644 UnitTests/Converter/TestCode/fetch_field001.php create mode 100644 UnitTests/Converter/TestCode/field_flags001.php create mode 100644 UnitTests/Converter/TestCode/field_len001.php create mode 100644 UnitTests/Converter/TestCode/field_name001.php create mode 100644 UnitTests/Converter/TestCode/field_table001.php create mode 100644 UnitTests/Converter/TestCode/field_type001.php create mode 100644 UnitTests/Converter/TestCode/free_result001.php create mode 100644 UnitTests/Converter/TestCode/generic001.php create mode 100644 UnitTests/Converter/TestCode/generic002.php create mode 100644 UnitTests/Converter/TestCode/generic003.php create mode 100644 UnitTests/Converter/TestCode/generic004.php create mode 100644 UnitTests/Converter/TestCode/generic005.php create mode 100644 UnitTests/Converter/TestCode/generic006.php create mode 100644 UnitTests/Converter/TestCode/generic007.php create mode 100644 UnitTests/Converter/TestCode/generic008.php create mode 100644 UnitTests/Converter/TestCode/generic_boolean001.php create mode 100644 UnitTests/Converter/TestCode/generic_boolean002.php create mode 100644 UnitTests/Converter/TestCode/list_dbs001.php create mode 100644 UnitTests/Converter/TestCode/list_fields001.php create mode 100644 UnitTests/Converter/TestCode/list_processes001.php create mode 100644 UnitTests/Converter/TestCode/par_reversed001.php create mode 100644 UnitTests/Converter/TestCode/real_escape_string001.php create mode 100644 UnitTests/Converter/TestCode/select_db001.php create mode 100644 UnitTests/Converter/TestCode/tablename001.php create mode 100644 UnitTests/Converter/TestCode/unbuffered_query001.php create mode 100644 UnitTests/Converter/UnbufferedQueryTest.php create mode 100644 UnitTests/Function/.svn/README.txt create mode 100644 UnitTests/Function/.svn/dir-wcprops create mode 100644 UnitTests/Function/.svn/empty-file create mode 100644 UnitTests/Function/.svn/entries create mode 100644 UnitTests/Function/.svn/format create mode 100644 UnitTests/Function/.svn/prop-base/AllTests.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/ChangeUserTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/ConnParamBoolTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/ConnParamTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/ConnectTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/CreateDBTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/DBQueryTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/DropDBTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/ErrorTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/EscapeStringTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/FetchFieldTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/FieldFlagsTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/FieldLenTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/FieldNameTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/FieldTableTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/FieldTypeTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/FreeResultTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/GenericBooleanTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/GenericTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/ListDBsTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/ListFieldsTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/ListProcessesTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/ListTablesTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/ParReversedTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/RealEscapeStringTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/SelectDBTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/TablenameTest.php.svn-base create mode 100644 UnitTests/Function/.svn/prop-base/UnbufferedQueryTest.php.svn-base create mode 100644 UnitTests/Function/.svn/props/AllTests.php.svn-work create mode 100644 UnitTests/Function/.svn/props/ChangeUserTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/ConnParamBoolTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/ConnParamTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/ConnectTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/CreateDBTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/DBQueryTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/DropDBTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/ErrorTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/EscapeStringTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/FetchFieldTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/FieldFlagsTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/FieldLenTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/FieldNameTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/FieldTableTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/FieldTypeTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/FreeResultTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/GenericBooleanTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/GenericTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/ListDBsTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/ListFieldsTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/ListProcessesTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/ListTablesTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/ParReversedTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/RealEscapeStringTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/SelectDBTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/TablenameTest.php.svn-work create mode 100644 UnitTests/Function/.svn/props/UnbufferedQueryTest.php.svn-work create mode 100644 UnitTests/Function/.svn/text-base/AllTests.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/ChangeUserTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/ConnParamBoolTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/ConnParamTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/ConnectTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/CreateDBTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/DBQueryTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/DropDBTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/ErrorTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/EscapeStringTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/FetchFieldTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/FieldFlagsTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/FieldLenTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/FieldNameTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/FieldTableTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/FieldTypeTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/FreeResultTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/GenericBooleanTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/GenericTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/ListDBsTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/ListFieldsTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/ListProcessesTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/ListTablesTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/ParReversedTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/RealEscapeStringTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/SelectDBTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/TablenameTest.php.svn-base create mode 100644 UnitTests/Function/.svn/text-base/UnbufferedQueryTest.php.svn-base create mode 100644 UnitTests/Function/.svn/wcprops/AllTests.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/ChangeUserTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/ConnParamBoolTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/ConnParamTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/ConnectTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/CreateDBTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/DBQueryTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/DropDBTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/ErrorTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/EscapeStringTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/FetchFieldTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/FieldFlagsTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/FieldLenTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/FieldNameTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/FieldTableTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/FieldTypeTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/FreeResultTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/GenericBooleanTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/GenericTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/ListDBsTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/ListFieldsTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/ListProcessesTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/ListTablesTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/ParReversedTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/RealEscapeStringTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/SelectDBTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/TablenameTest.php.svn-work create mode 100644 UnitTests/Function/.svn/wcprops/UnbufferedQueryTest.php.svn-work create mode 100644 UnitTests/Function/AllTests.php create mode 100644 UnitTests/Function/ChangeUserTest.php create mode 100644 UnitTests/Function/ConnParamBoolTest.php create mode 100644 UnitTests/Function/ConnParamTest.php create mode 100644 UnitTests/Function/ConnectTest.php create mode 100644 UnitTests/Function/CreateDBTest.php create mode 100644 UnitTests/Function/DBQueryTest.php create mode 100644 UnitTests/Function/DropDBTest.php create mode 100644 UnitTests/Function/ErrorTest.php create mode 100644 UnitTests/Function/EscapeStringTest.php create mode 100644 UnitTests/Function/FetchFieldTest.php create mode 100644 UnitTests/Function/FieldFlagsTest.php create mode 100644 UnitTests/Function/FieldLenTest.php create mode 100644 UnitTests/Function/FieldNameTest.php create mode 100644 UnitTests/Function/FieldTableTest.php create mode 100644 UnitTests/Function/FieldTypeTest.php create mode 100644 UnitTests/Function/FreeResultTest.php create mode 100644 UnitTests/Function/GenericBooleanTest.php create mode 100644 UnitTests/Function/GenericTest.php create mode 100644 UnitTests/Function/ListDBsTest.php create mode 100644 UnitTests/Function/ListFieldsTest.php create mode 100644 UnitTests/Function/ListProcessesTest.php create mode 100644 UnitTests/Function/ListTablesTest.php create mode 100644 UnitTests/Function/ParReversedTest.php create mode 100644 UnitTests/Function/RealEscapeStringTest.php create mode 100644 UnitTests/Function/SelectDBTest.php create mode 100644 UnitTests/Function/TablenameTest.php create mode 100644 UnitTests/Function/UnbufferedQueryTest.php create mode 100644 UnitTests/README create mode 100644 cli.php create mode 100644 index.php diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..412eeda --- /dev/null +++ b/.gitattributes @@ -0,0 +1,22 @@ +# Auto detect text files and perform LF normalization +* text=auto + +# Custom for Visual Studio +*.cs diff=csharp +*.sln merge=union +*.csproj merge=union +*.vbproj merge=union +*.fsproj merge=union +*.dbproj merge=union + +# Standard to msysgit +*.doc diff=astextplain +*.DOC diff=astextplain +*.docx diff=astextplain +*.DOCX diff=astextplain +*.dot diff=astextplain +*.DOT diff=astextplain +*.pdf diff=astextplain +*.PDF diff=astextplain +*.rtf diff=astextplain +*.RTF diff=astextplain diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..b9d6bd9 --- /dev/null +++ b/.gitignore @@ -0,0 +1,215 @@ +################# +## Eclipse +################# + +*.pydevproject +.project +.metadata +bin/ +tmp/ +*.tmp +*.bak +*.swp +*~.nib +local.properties +.classpath +.settings/ +.loadpath + +# External tool builders +.externalToolBuilders/ + +# Locally stored "Eclipse launch configurations" +*.launch + +# CDT-specific +.cproject + +# PDT-specific +.buildpath + + +################# +## Visual Studio +################# + +## Ignore Visual Studio temporary files, build results, and +## files generated by popular Visual Studio add-ons. + +# User-specific files +*.suo +*.user +*.sln.docstates + +# Build results + +[Dd]ebug/ +[Rr]elease/ +x64/ +build/ +[Bb]in/ +[Oo]bj/ + +# MSTest test Results +[Tt]est[Rr]esult*/ +[Bb]uild[Ll]og.* + +*_i.c +*_p.c +*.ilk +*.meta +*.obj +*.pch +*.pdb +*.pgc +*.pgd +*.rsp +*.sbr +*.tlb +*.tli +*.tlh +*.tmp +*.tmp_proj +*.log +*.vspscc +*.vssscc +.builds +*.pidb +*.log +*.scc + +# Visual C++ cache files +ipch/ +*.aps +*.ncb +*.opensdf +*.sdf +*.cachefile + +# Visual Studio profiler +*.psess +*.vsp +*.vspx + +# Guidance Automation Toolkit +*.gpState + +# ReSharper is a .NET coding add-in +_ReSharper*/ +*.[Rr]e[Ss]harper + +# TeamCity is a build add-in +_TeamCity* + +# DotCover is a Code Coverage Tool +*.dotCover + +# NCrunch +*.ncrunch* +.*crunch*.local.xml + +# Installshield output folder +[Ee]xpress/ + +# DocProject is a documentation generator add-in +DocProject/buildhelp/ +DocProject/Help/*.HxT +DocProject/Help/*.HxC +DocProject/Help/*.hhc +DocProject/Help/*.hhk +DocProject/Help/*.hhp +DocProject/Help/Html2 +DocProject/Help/html + +# Click-Once directory +publish/ + +# Publish Web Output +*.Publish.xml +*.pubxml + +# NuGet Packages Directory +## TODO: If you have NuGet Package Restore enabled, uncomment the next line +#packages/ + +# Windows Azure Build Output +csx +*.build.csdef + +# Windows Store app package directory +AppPackages/ + +# Others +sql/ +*.Cache +ClientBin/ +[Ss]tyle[Cc]op.* +~$* +*~ +*.dbmdl +*.[Pp]ublish.xml +*.pfx +*.publishsettings + +# RIA/Silverlight projects +Generated_Code/ + +# Backup & report files from converting an old project file to a newer +# Visual Studio version. Backup files are not needed, because we have git ;-) +_UpgradeReport_Files/ +Backup*/ +UpgradeLog*.XML +UpgradeLog*.htm + +# SQL Server files +App_Data/*.mdf +App_Data/*.ldf + +############# +## Windows detritus +############# + +# Windows image file caches +Thumbs.db +ehthumbs.db + +# Folder config file +Desktop.ini + +# Recycle Bin used on file shares +$RECYCLE.BIN/ + +# Mac crap +.DS_Store + + +############# +## Python +############# + +*.py[co] + +# Packages +*.egg +*.egg-info +dist/ +build/ +eggs/ +parts/ +var/ +sdist/ +develop-eggs/ +.installed.cfg + +# Installer logs +pip-log.txt + +# Unit test / coverage reports +.coverage +.tox + +#Translations +*.mo + +#Mr Developer +.mr.developer.cfg diff --git a/.svn/README.txt b/.svn/README.txt new file mode 100644 index 0000000..271a8ce --- /dev/null +++ b/.svn/README.txt @@ -0,0 +1,2 @@ +This is a Subversion working copy administrative directory. +Visit http://subversion.tigris.org/ for more information. diff --git a/.svn/dir-wcprops b/.svn/dir-wcprops new file mode 100644 index 0000000..4629956 --- /dev/null +++ b/.svn/dir-wcprops @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 58 +/svnpublic/mysqli_converter/!svn/ver/11/MySQLConverterTool +END diff --git a/.svn/empty-file b/.svn/empty-file new file mode 100644 index 0000000..e69de29 diff --git a/.svn/entries b/.svn/entries new file mode 100644 index 0000000..3fabce3 --- /dev/null +++ b/.svn/entries @@ -0,0 +1,59 @@ + + + + + + + + + + + diff --git a/.svn/format b/.svn/format new file mode 100644 index 0000000..b8626c4 --- /dev/null +++ b/.svn/format @@ -0,0 +1 @@ +4 diff --git a/.svn/prop-base/Converter.php.svn-base b/.svn/prop-base/Converter.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/.svn/prop-base/README.svn-base b/.svn/prop-base/README.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/.svn/prop-base/cli.php.svn-base b/.svn/prop-base/cli.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/.svn/prop-base/index.php.svn-base b/.svn/prop-base/index.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/.svn/props/Converter.php.svn-work b/.svn/props/Converter.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/.svn/props/README.svn-work b/.svn/props/README.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/.svn/props/cli.php.svn-work b/.svn/props/cli.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/.svn/props/index.php.svn-work b/.svn/props/index.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/.svn/text-base/Converter.php.svn-base b/.svn/text-base/Converter.php.svn-base new file mode 100644 index 0000000..1b5a6b5 --- /dev/null +++ b/.svn/text-base/Converter.php.svn-base @@ -0,0 +1,936 @@ +ext/mysqli Converter +* +* @category Converter +* @package MySQLConverterTool +* @author Andrey Hristov , Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Converter { + + // + // protected + // + + /** + * Scanner state constant + * + * @const + * @access protected + */ + const STATE_NORMAL = 'normal_state'; + + + /** + * Scanner state constant + * + * @const + * @access protectd + */ + const STATE_FUNC_FOUND = 'func_found'; + + + /** + * Scanner state constant + * + * @const + * @access protected + */ + const STATE_PARAM_LIST = 'parameter_list'; + + + /** + * Converted (= resulting) source code + * + * @var string + */ + protected $output = ''; + + + /** + * List of errors which occured during the conversion + * + * @var array + */ + protected $errors = array(); + + + /** + * List of PHP token + * + * @var string + */ + protected $tokens = array(); + + + /** + * Mapping of ext/mysql -> ext/mysqli constants + * + */ + protected $mysql_ext_consts = array( + 'MYSQL_CLIENT_COMPRESS' => 'MYSQLI_CLIENT_COMPRESS', + 'MYSQL_CLIENT_IGNORE_SPACE' => 'MYSQLI_CLIENT_IGNORE_SPACE', + 'MYSQL_CLIENT_INTERACTIVE' => 'MYSQLI_CLIENT_INTERACTIVE', + 'MYSQL_CLIENT_SSL' => 'MYSQLI_CLIENT_SSL', + 'MYSQL_ASSOC' => 'MYSQLI_ASSOC', + 'MYSQL_BOTH' => 'MYSQLI_BOTH', + 'MYSQL_NUM' => 'MYSQLI_NUM', + ); + + + /** + * Number of functions found in the given source + * + * @var int + */ + protected $funcs_found = 0; + + + /** + * Number of functions converted in the given source + * + * @var int + */ + protected $funcs_converted = 0; + + + /** + * List of functions that are not supported + * + * @var array + */ + protected $mysql_funcs_not_supported = array( + // rewrite the ugly mysql_result calls manually! + 'mysql_result' => true, + // whatever that function is... + 'mysql_fetch_field2' => true, + ); + + + /** + * List of functions that can be converted + * + * Acts as kind of a function pointer list, but with objects + * + * @var array + */ + protected $mysql_funcs = array(); + + + /** + * Flag: enable token debug output? + * + * @var bool + */ + protected $debug_dump_tokens = false; + + + /** + * Flag: enable parameter parsing debug output? + * + * @var bool + */ + protected $debug_dump_params = false; + + + /** + * Current line number during the parsing process + * + * @var int + */ + protected $lineno = 0; + + + // + // public + // + + + /** + * + * + * @param bool Turn on debug output of scanner token? + * @param bool Turn on debug output of function parameters? + */ + public function __construct($debug_token = false, $debug_params = false) { + + if (!function_exists('token_name')) { + // HACK FIXME + die('ext/tokenizer is needed!\n'); + } + + if (!defined('T_ML_COMMENT')) + define('T_ML_COMMENT', T_COMMENT); + + if (!defined('T_DOC_COMMENT')) + define('T_DOC_COMMENT', T_ML_COMMENT); + + if (!defined('T_SIMPLE_TOKEN')) + define('T_SIMPLE_TOKEN', 32567); + + $this->debug_dump_tokens = $debug_token; + $this->debug_dump_params = $debug_params; + + $this->mysql_funcs = + array( + // PHP_FALIAS(mysql, mysql_db_query, NULL) + 'mysql' => new MySQLConverterTool_Function_DBQuery(), + // in OO this is a property + 'mysql_affected_rows' => new MySQLConverterTool_Function_ConnParam('mysqli_affected_rows'), + 'mysql_change_user' => new MySQLConverterTool_Function_ChangeUser(), + 'mysql_client_encoding' => new MySQLConverterTool_Function_ConnParam('mysqli_character_set_name'), + 'mysql_close' => new MySQLConverterTool_Function_ConnParamBool('mysqli_close'), + // pconnect has less params but they are not significant for mysqli_connect + 'mysql_connect' => new MySQLConverterTool_Function_Connect(), + // PHP_FALIAS(mysql_createdb, mysql_create_db, NULL) + 'mysql_createdb' => new MySQLConverterTool_Function_CreateDB(), + 'mysql_create_db' => new MySQLConverterTool_Function_CreateDB(), + 'mysql_data_seek' => new MySQLConverterTool_Function_Generic('mysqli_data_seek'), + 'mysql_dbname' => new MySQLConverterTool_Function_Tablename(), + 'mysql_db_name' => new MySQLConverterTool_Function_Tablename(), + 'mysql_db_query' => new MySQLConverterTool_Function_DBQuery(), + // PHP_FALIAS(mysql_dropdb, mysql_drop_db, NULL) + 'mysql_dropdb' => new MySQLConverterTool_Function_DropDB(), + 'mysql_drop_db' => new MySQLConverterTool_Function_DropDB(), + // in OO this is a property + 'mysql_error' => new MySQLConverterTool_Function_Error('mysqli_error'), + // in OO this is a property + 'mysql_errno' => new MySQLConverterTool_Function_Error('mysqli_errno'), + 'mysql_escape_string' => new MySQLConverterTool_Function_EscapeString('mysqli_real_escape_string'), + 'mysql_fetch_array' => new MySQLConverterTool_Function_Generic('mysqli_fetch_array'), + 'mysql_fetch_assoc' => new MySQLConverterTool_Function_Generic('mysqli_fetch_assoc'), + 'mysql_fetch_field' => new MySQLConverterTool_Function_FetchField(), + 'mysql_fetch_lengths' => new MySQLConverterTool_Function_GenericBoolean('mysqli_fetch_lengths'), + 'mysql_fetch_object' => new MySQLConverterTool_Function_Generic('mysqli_fetch_object'), + 'mysql_fetch_row' => new MySQLConverterTool_Function_Generic('mysqli_fetch_row'), + // PHP_FALIAS(mysql_fieldflags, mysql_field_flags, NULL) + 'mysql_fieldflags' => new MySQLConverterTool_Function_FieldFlags(), + 'mysql_field_flags' => new MySQLConverterTool_Function_FieldFlags(), + // PHP_FALIAS(mysql_fieldlen, mysql_field_len, NULL) + 'mysql_fieldlen' => new MySQLConverterTool_Function_FieldLen(), + 'mysql_field_len' => new MySQLConverterTool_Function_FieldLen(), + // PHP_FALIAS(mysql_fieldname, mysql_field_name, NULL) + 'mysql_fieldname' => new MySQLConverterTool_Function_FieldName(), + 'mysql_field_name' => new MySQLConverterTool_Function_FieldName(), + 'mysql_field_seek' => new MySQLConverterTool_Function_GenericBoolean('mysqli_field_seek'), + // PHP_FALIAS(mysql_fieldtable, mysql_field_table, NULL) + 'mysql_fieldtable' => new MySQLConverterTool_Function_FieldTable(), + 'mysql_field_table' => new MySQLConverterTool_Function_FieldTable(), + // PHP_FALIAS(mysql_fieldtype, mysql_field_type, NULL) + 'mysql_fieldtype' => new MySQLConverterTool_Function_FieldType(), + 'mysql_field_type' => new MySQLConverterTool_Function_FieldType(), + // PHP_FALIAS(mysql_freeresult, mysql_free_result, NULL) + 'mysql_freeresult' => new MySQLConverterTool_Function_FreeResult(), + 'mysql_free_result' => new MySQLConverterTool_Function_FreeResult(), + 'mysql_get_client_info' => new MySQLConverterTool_Function_Generic('mysqli_get_client_info'), + // in OO this is a property + 'mysql_get_host_info' => new MySQLConverterTool_Function_ConnParamBool('mysqli_get_host_info'), + // in OO this is a property + 'mysql_get_proto_info' => new MySQLConverterTool_Function_ConnParamBool('mysqli_get_proto_info'), + // in OO this is a property + 'mysql_get_server_info' => new MySQLConverterTool_Function_ConnParamBool('mysqli_get_server_info'), + 'mysql_info' => new MySQLConverterTool_Function_ConnParam('mysqli_info'), + 'mysql_insert_id' => new MySQLConverterTool_Function_ConnParamBool('mysqli_insert_id'), + // PHP_FALIAS(mysql_listdbs, mysql_list_dbs, NULL) + 'mysql_listdbs' => new MySQLConverterTool_Function_ListDBs(), + 'mysql_list_dbs' => new MySQLConverterTool_Function_ListDBs(), + // PHP_FALIAS(mysql_listfields, mysql_list_fields, NULL) + 'mysql_listfields' => new MySQLConverterTool_Function_ListFields(), + 'mysql_list_fields' => new MySQLConverterTool_Function_ListFields(), + 'mysql_list_processes' => new MySQLConverterTool_Function_ListProcesses(), + // PHP_FALIAS(mysql_listtables, mysql_list_tables, NULL) + 'mysql_listtables' => new MySQLConverterTool_Function_ListTables(), + 'mysql_list_tables' => new MySQLConverterTool_Function_ListTables(), + // PHP_FALIAS(mysql_numfields, mysql_num_fields, NULL) + 'mysql_numfields' => new MySQLConverterTool_Function_Generic('mysqli_num_fields'), + // in OO this is a property + 'mysql_num_fields' => new MySQLConverterTool_Function_GenericBoolean('mysqli_num_fields'), + // PHP_FALIAS(mysql_numrows, mysql_num_rows, NULL) + 'mysql_numrows' => new MySQLConverterTool_Function_Generic('mysqli_num_rows'), + // in OO this is a property + 'mysql_num_rows' => new MySQLConverterTool_Function_Generic('mysqli_num_rows'), + // pconnect has less params but they are not significant for mysqli_connect + 'mysql_pconnect' => new MySQLConverterTool_Function_Connect(), + 'mysql_ping' => new MySQLConverterTool_Function_ConnParam('mysqli_ping'), + 'mysql_query' => new MySQLConverterTool_Function_ParReversed('mysqli_query'), + 'mysql_real_escape_string' => new MySQLConverterTool_Function_RealEscapeString('mysqli_real_escape_string'), + // mysql_result -- Get result data + // PHP_FALIAS(mysql_selectdb, mysql_select_db, NULL) + 'mysql_selectdb' => new MySQLConverterTool_Function_SelectDB(), + 'mysql_select_db' => new MySQLConverterTool_Function_SelectDB(), + 'mysql_stat' => new MySQLConverterTool_Function_ConnParam('mysqli_stat'), + 'mysql_tablename' => new MySQLConverterTool_Function_Tablename(), + 'mysql_table_name' => new MySQLConverterTool_Function_Tablename(), + 'mysql_thread_id' => new MySQLConverterTool_Function_ConnParam('mysqli_thread_id'), + 'mysql_unbuffered_query' => new MySQLConverterTool_Function_UnbufferedQuery(), + ); + + } // end func __construct + + + + /** + * Converts the given source code + * + * @param string Source code to be converted + * @return array Converted source code and status information + */ + public function convertString($source) { + + $this->lineno = 0; + $this->output = ''; + $this->tokens = token_get_all($source); + $this->errors = array(); + $this->lineno = 1; + + $this->funcs_found = 0; + $this->funcs_converted = 0; + + $this->scanner(0); + + return array( + 'output' => $this->output, + 'found' => $this->funcs_found, + 'converted' => $this->funcs_converted, + 'errors' => $this->errors, + ); + } // end func convertString + + + /** + * Reads a file and returns the converted source code + * + * @param strng filename + * @param array Converted source and status information + */ + public function convertFile($filename) { + + if (!file_exists($filename) || !is_readable($filename) || !is_file($filename)) { + $ret = $this->convertString(''); + $ret['errors'][] = array('line' => -1, 'msg' => 'Cannot open file "' . $filename . '".'); + return $ret; + } + + return $this->convertString(file_get_contents($filename)); + } + + + /** + * Returns all files of a directory that have a certain name + * + * + */ + public function getFilesOfDirectory($dir, $file_pattern = '*', Array $files = array()) { + + if (!is_dir($dir) || !is_readable($dir)) + return $files; + + $patterns = $this->buildRegularExpression($file_pattern); + if (empty($patterns)) + return $files; + + $dh = opendir($dir); + if (!$dh) + return $files; + + while ($file = readdir($dh)) { + if ('.' == $file || '..' == $file) + continue; + + $ffile = $dir . '/' . $file; + if (is_dir($ffile)) + $files = $this->getFilesOfDirectory($ffile, $file_pattern, $files); + + if (!is_file($ffile)) + continue; + + $accept = false; + foreach ($patterns as $k => $pattern) { + if (preg_match('@' . $pattern . '$@i', $file)) { + $accept = true; + break; + } + } + + if ($accept) + $files[] = $ffile; + } + closedir($dh); + + return $files; + } + + + /** + * Unsets the variable which stores the global (default) connection of ext/mysql + * + * This is a hack required by the test framework. + * + */ + public function unsetGlobalConnection() { + + $obj = new MySQLConverterTool_Function_Generic('mysqli_query'); + eval(sprintf('@mysqli_close(%s);', $obj->ston_name)); + eval(sprintf('if (isset(%s)) unset(%s);', $obj->ston_name, $obj->ston_name)); + + } + + + /** + * Returns a list of functions that can be converted automatically + * + * @return array + */ + public function getSupportedFunctions() { + + $ret = array_keys($this->mysql_funcs); + sort($ret); + + return $ret; + } + + + /** + * Returns a list of functions that cannot be converted automatically + * + * @return array + */ + public function getUnsupportedFunctions() { + + $ret = array_keys($this->mysql_funcs_not_supported); + sort($ret); + + return $ret; + } + + // + // protected + // + + + /** + * Scans the source and rebuilds a converted version of it + * + * @param int + */ + protected function scanner($level) { + + // current parser state + $state = self::STATE_NORMAL; + + // list of function parameters + $func_params = array(); + // current parameter value + $curr_param = ''; + // current bracket nesting level + $bracket_level = 0; + // name of the currently processed function + $func_name = ''; + // flag: does the currently parameter contain variables or constants? + $param_dynamic = false; + // flag for something that looks like a mysql_func call but is not followed by parameters + $expect_param_brace_open = false; + + + while (list( , $token) = each($this->tokens)) { + + if (is_string($token)) { + $id = T_SIMPLE_TOKEN; + $token_name = 'T_SIMPLE_TOKEN'; + $text = $token; + } else { + list($id, $text) = $token; + $token_name = token_name($id); + } + + // remember the current line number + $lineno = $this->lineno; + $this->lineno += $this->countLines($text); + + if ($this->debug_dump_tokens) { + + $this->debug_print('dump token', + sprintf("[%-05d - %10s - %d - %-10s - %03d - %05d] %s", + $lineno, + $token_name, + $expect_param_brace_open, + $state, + $bracket_level, + strlen($text), + htmlspecialchars($text)) + ); + + } + + switch ($id) { + + case T_COMMENT: + case T_ML_COMMENT: + case T_DOC_COMMENT: + + switch ($state) { + case self::STATE_NORMAL: + $this->output .= $text; + break; + + case self::STATE_FUNC_FOUND: + // comment between func_name and comma + break; + + case self::STATE_PARAM_LIST: + $curr_param .= $text; + break; + } + + break; + + case T_SIMPLE_TOKEN: + + switch ($state) { + + case self::STATE_NORMAL: + $this->output .= $text; + break; + + case self::STATE_FUNC_FOUND: + + switch ($text) { + case '(': + $state = self::STATE_PARAM_LIST; + $func_params = array(); + $curr_param = NULL; + $param_dynamic = false; + $expect_param_brace_open = false; + break; + + case ')': + default: + if ($expect_param_brace_open) { + // something that looks like is not followed by an opening brace for + $state = self::STATE_NORMAL; + $this->funcs_found--; + $expect_param_brace_open = 0; + $steps = 0; + $tmp = ''; + while (($token = prev($this->tokens)) && ($tmp != $func_name)) { + if (is_array($token)) { + $tmp = $token[1]; + } else { + $tmp = $token; + } + $steps++; + } + while ($steps-- > 1) { + $token = next($this->tokens); + if (is_array($token)) + $tmp = $token[1]; + else + $tmp = $token; + $this->output .= $tmp; + } + next($this->tokens); + break 3; + } + break; + } + break; + + case self::STATE_PARAM_LIST: + + switch ($text) { + case ',': + if ($bracket_level == 1) { + $func_params[] = array('value' => $curr_param, 'dynamic' => $param_dynamic); + $curr_param = ''; + $param_dynamic = false; + } else { + $curr_param .= $text; + } + // don't add to the curr_param + break(2); + + case '(': + $bracket_level++; + break; + + case ')': + $bracket_level--; + if ($bracket_level == 0) { + // end of the parameter specification + + if (!is_null($curr_param)) + $func_params[] = array('value' => $curr_param, 'dynamic' => $param_dynamic); + + $curr_param = NULL; + $param_dynamic = false; + $state = self::STATE_NORMAL; + + if ($this->debug_dump_params) { + $this->debug_print( + 'params', + array('name' => $func_name, 'params' => $func_params) + ); + } + + if (!$level) { + + list($handler_warning, $handler_code) = $this->mysql_funcs[$func_name]->handle($func_params); + if (!is_null($handler_warning)) + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] %s', $lineno, $handler_warning)); + + if (is_null($handler_code)) { + $this->output .= $this->rebuildFunctionCode($func_name, $func_params, $handler_warning); + } else { + $this->funcs_converted++; + $this->output .= $handler_code; + } + + } else { + // we are in recursive call - return + + list($handler_warning, $handler_code) = $this->mysql_funcs[$func_name]->handle($func_params); + if (!is_null($handler_warning)) + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] %s', $lineno, $handler_warning)); + + if (is_null($handler_code)) { + return $this->rebuildFunctionCode($func_name, $func_params, $handler_warning); + } else { + $this->funcs_converted++; + return $handler_code; + } + + } + + } + break; + + case '.': + case '&': + case '^': + case '|': + case '&&': + case '||': + case 'and': + case 'or': + case 'xor': + case '<<': + case '>>': + case '<': + case '<=': + case '>': + case '>=': + case '=': + case '*': + case '/': + case '%': + case '+': + case '-': + case '++': + case '--': + case '!': + case '~': + case '=': + case '+=': + case '-=': + case '*=': + case '/=': + case '.=': + case '%=': + case '&=': + case '|=': + case '^=': + case '<<=': + case '>>=': + case '?': + case '==': + case '!=': + case '===': + case '!==': + case '(': + case 'new': + // forget it - this parameter value is build dynamically + // we won't try to guess it's value using static code analysis + // this needs to be checked manually + $param_dynamic = true; + if ($this->debug_dump_params) { + $this->debug_print( + 'params', + 'Operator found in parameter. Assuming that the paramter value will be dynamic and cannot be foreseen.' + ); + } + break; + } + + $curr_param .= $text; + break; + } + break; + + case T_STRING: + + if (isset($this->mysql_ext_consts[$text])) { + + $text = $this->mysql_ext_consts[$text]; + + } else { + + switch ($state) { + case self::STATE_PARAM_LIST: + // maybe a function call or constant as part of a parameter value? + + if (isset($this->mysql_funcs_not_supported[$text])) { + + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] Function "%s" is not supported for conversion! You must rewrite the converted code. The conversion is not complete. Consider rewriting your code first and rerunning the conversion tool"', $lineno, $text)); + + } + + if (isset($this->mysql_funcs[$text])) { + // return the current token and reparse it + prev($this->tokens); + // in the default of the outter switch add this to $curr_param + $text = $this->scanner($level + 1); + $param_dynamic = true; + } + // fall to default + break; + + case self::STATE_FUNC_FOUND: + + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] We found a string between the function name "%s" and the parameter list. Looks like a syntax error in the source file. Please check!', $lineno, $func_name)); + + break; + + case self::STATE_NORMAL: + default: + + if (isset($this->mysql_funcs_not_supported[$text])) { + + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] Function "%s" is not supported for conversion! You must rewrite the converted code code. The conversion is not complete. Consider rewriting your code first and rerunning the conversion tool."', $lineno, $text)); + + } + + if (isset($this->mysql_funcs[$text])) { + $state = self::STATE_FUNC_FOUND; + $func_name = $text; + $bracket_level = 1; + $this->funcs_found++; + $expect_param_brace_open = true; + + break(2); + } + + if ($text == 'is_resource') { + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] You are using is_resource(). Make sure that you do not use it to test for the return value of mysql_query(). mysql_query() returns a resource or a boolean value. mysqli_query() returns an object or a boolean value. If you check the return value of mysql_query like < if (is_resource($res = mysql_query())) [...] > the converted code will fail, because $res will be an object in ext/mysqli."', $lineno, $text)); + } + // here we fall-through + } + } + + + default: + + if ($id === T_CONSTANT_ENCAPSED_STRING) { + /* try to detect function_exists('some_mysql_func'); */ + $prev_steps = 0; + + if (isset($this->mysql_funcs[substr($text, 1, -1)]) && + $this->mysql_funcs[substr($text, 1, -1)]->new_name) { + // strip quotes + // move back because now 'some_mysql_func' will be returned by prev() + $prev_steps = 1; + $tmp_token = prev($this->tokens); + + do { + $tmp_token = prev($this->tokens); + $prev_steps++; + } while ($tmp_token[0] === T_WHITESPACE); + + if ($tmp_token === '(') { + + $tmp_token = prev($this->tokens); + $prev_steps++; + + if ($tmp_token[0] === T_STRING && + $tmp_token[1] === 'function_exists') { + + $text = $text[0] . $this->mysql_funcs[substr($text, 1, -1)]->new_name . $text[0]; + } + + } + + while ($prev_steps--) + each($this->tokens); + } + } + + switch ($state) { + case self::STATE_PARAM_LIST: + + switch ($id) { + + case T_VARIABLE: + case T_FUNCTION: + case T_CONST: + // this is a variable, we cannot guess value of the parameter + // using this static conversion approach + if ($this->debug_dump_params) { + $this->debug_print( + 'params', + "Adding variable '$text' to current parameter." + ); + } + $param_dynamic = true; + $curr_param .= $text; + break; + + case T_WHITESPACE: + default: + if ($this->debug_dump_params) { + $this->debug_print( + 'params', + "Adding '$text' to current parameter." + ); + } + + $curr_param .= $text; + break; + } + break; + + case self::STATE_FUNC_FOUND: + + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] Please check your code for parse errors, we failed to parse "%s". Conversion will be incomplete!".', $lineno, $text)); + break; + + default: + case self::STATE_NORMAL: + $this->output .= $text; + break; + } + break; + } + + } + + } + + + /** + * Print a debug message + * + * @param string Message prefix + * @param mixed Array or literal to print + */ + protected function debug_print($prefix, $var) { + + if (is_scalar($var)) { + printf("[%s/%s] %s\n", + get_class($this), + $prefix, + $var); + } else { + printf("[%s/%s] ", get_class($this), $prefix); + var_dump($var); + printf("\n"); + } + + + } // end func debug_print + + + /** + * Returns the number of lines of a string + * + * @param string + * @return int + */ + protected function countLines($text) { + + $last_pos = 0; + $lines = 0; + while (($pos = strpos($text, "\n", $last_pos)) !== FALSE) { + $last_pos = $pos + 1; + $lines++; + } + + return $lines; + } + + + /** + * Rebuilds the original function code based on function name and parameters and adds a comment with a warning after the last parameter + * + * @param string + * @param array + * @param string + */ + protected function rebuildFunctionCode($name, $params, $warning) { + + $ret = $name . '('; + if (count($params) > 0) { + foreach ($params as $k => $param) + $ret .= $param['value'] . ', '; + $ret = substr($ret, 0, -2); + } + $ret .= ')'; + // $ret .= ' /* [MySQLConverterTool] ' . $warning . '*/)'; + + return $ret; + } + + + + /** + * Expands a user specified file pattern with * as the only pattern to a regular expression + * + * @param string + * @return array + */ + protected function buildRegularExpression($file_pattern) { + + $parts = explode(',', $file_pattern); + if (empty($parts)) + return array(); + + $ret = array(); + foreach ($parts as $k => $v) + $ret[] = str_replace('\*', '.*', preg_quote($v, '@')); + + return $ret; + } + +} +?> \ No newline at end of file diff --git a/.svn/text-base/README.svn-base b/.svn/text-base/README.svn-base new file mode 100644 index 0000000..23b599c --- /dev/null +++ b/.svn/text-base/README.svn-base @@ -0,0 +1,18 @@ + Welcome to the MySQL ext/mysql->ext/mysqli Converter Tool. + This tool helps you to migrate PHP files using the PHP + MySQL extension to use the MySQLi extension. + + Extract the archive into a directory on your web server. Open + http:////MySQLConverterTool/GUI/index.php + for a Web GUI. If you want to work on the command line, try + php -f cli.php. + + Note that absolutely no security checks are performed + by the tool which prevent users from trying to read and convert + files (e.g. /etc/passwd). Make sure to add security measures, + if needed. + + If you want to run any tests, check the hints given + in UnitTests/README. + + Have fun! \ No newline at end of file diff --git a/.svn/text-base/cli.php.svn-base b/.svn/text-base/cli.php.svn-base new file mode 100644 index 0000000..207aa6e --- /dev/null +++ b/.svn/text-base/cli.php.svn-base @@ -0,0 +1,445 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ + +/** +* Parse the command line options +* +* @param int +* @param array +* @return array +* @access public +*/ +function parseOptions($argc, $argv) { + + $options = array(); + $error = null; + + if ($argc < 2) { + $error = 'No options given'; + return array($options, $error); + } + + reset($argv); + + // skip $argv[0] - program name + next($argv); + + while (list($k, $arg) = each($argv)) { + $arg = trim($arg); + switch ($arg) { + case '-f': + if (list($k, $arg) = each($argv)) { + $arg = trim($arg); + if (substr($arg, 0, 1) == '-') { + $error = '-f needs a file name'; + break 2; + } else if (!file_exists($arg)) { + $error = sprintf('"%s" does not exist', $arg); + break 2; + } else if (!is_file($arg)) { + $error = sprintf('"%s" is not a file', $arg); + break 2; + } else if (!is_readable($arg)) { + $error = sprintf('"%s" is not reabale', $arg); + break 2; + } else { + $options['files'][$arg] = $arg; + } + } else { + $error = sprintf('-f needs a file name'); + break 2; + } + break; + + case '-d': + if (list($k, $arg) = each($argv)) { + $arg = trim($arg); + if (substr($arg, 0, 1) == '-') { + $error = '-d needs a directory name'; + break 2; + } else if (!file_exists($arg)) { + $error = sprintf('"%s" does not exist', $arg); + break 2; + } else if (!is_dir($arg)) { + $error = sprintf('"%s" is not a directory', $arg); + break 2; + } else if (!is_readable($arg)) { + $error = sprintf('"%s" is not readable', $arg); + break 2; + } else { + $options['directories'][$arg] = $arg; + } + } else { + $error = sprintf('-d needs a directory name'); + break 2; + } + break; + + case '-s': + if (list($k, $arg) = each($argv)) { + $arg = trim($arg); + if ('' == $arg) { + $error = '-s expects a code snippet to follow the option'; + break 2; + } + $options['snippet'] = $arg; + } else { + $error = '-s expects a code snippet to follow the option'; + break 2; + } + break; + + case '-h': + case '--help': + $options['help'] = true; + + case '-u': + $options['update'] = true; + break; + + case '-b': + $options['backup'] = true; + $options['update'] = true; + break; + + case '-v': + if (isset($options['quiet'])) { + $error = 'You cannot use -v with -q'; + break 2; + } + $options['verbose'] = true; + break; + + case '-q': + if (isset($options['verbose'])) { + $error = 'You cannot use -q with -v'; + break 2; + } + $options['quiet'] = true; + break; + + case '-w': + $options['warnings'] = true; + break; + + case '-p': + if (list($k, $arg) = each($argv)) { + $arg = trim($arg); + if ('' == $arg) { + $error = '-p needs a search pattern'; + break 2; + } else { + $options['pattern'] = $arg; + } + } else { + $error = '-p needs a search pattern'; + break 2; + } + break; + + default: + $error = sprintf('Invalid option "%s"', $arg); + break; + + } + + } + + return array($options, $error); +} // end func parseOptions + + +/** +* Prints the help message with usage instructions +* +* @param array +*/ +function printHelp($argv) { + + printf("\n"); + printf("Usage of %s :\n\n", $argv[0]); + printf("-f Convert file\n"); + printf("-d Convert directory\n"); + printf('-p File name pattern for -d, e.g. -p "*.php,*.php3". Default: *'); + printf("\n"); + printf("-s Convert code snippet\n"); + printf("\n"); + printf("-u Update (modify) input file during the conversion\n"); + printf("-b Backup files to [original_name].org before they get updated\n\n"); + printf("-v verbose - print conversion details\n"); + printf("-w warnings - print errors/warnings, if any\n"); + printf("-q quiet - don't print the generated code\n"); + printf("\n\n"); + +} // end func printHelp + + +/** +* Returns a status description (OK, Error, Warning) based on the conversion result +* +* @param array +* @return string +*/ +function getConversionStatus($conv_result) { + + $status = null; + if (($conv_result['found'] == $conv_result['converted']) && (count($conv_result['errors']) == 0)) { + $status = 'OK'; + } else if (($conv_result['found'] == $conv_result['converted']) && (count($conv_result['errors']) > 0)) { + $status = 'Warning'; + } else if (($conv_result['found'] != $conv_result['converted']) && (count($conv_result['errors']) > 0)) { + $status = 'Error'; + } + + return $status; +} // end func getConversionStatus + + +/** +* Prints the overview summary with conversion details +* +* @param array +* @param string +* @param mixed +*/ +function printConversionHeader($conv_result, $status, $file = null) { + + if (!is_null($file)) { + print "\n"; + printSeperator("File $file"); + print "\n"; + } + + print "\n"; + printSeperator("Summary", '-'); + print "\n"; + + printf("Status: %s\n", $status); + printf("Number of mysql_-functions found: %d\n", $conv_result['found']); + printf("Number of mysql_-functions converted: %d\n", $conv_result['converted']); + printf("Warnings/Errors: %d\n", count($conv_result['errors'])); + printf("Code length: %d Bytes\n", strlen($conv_result['output'])); + +} // end func printConversionHeader + + +/** +* Prints the conversion errors +* +* @param array +*/ +function printConversionErrors($conv_result) { + + print "\n"; + print "\n"; + printSeperator("Warnings/Errors", '-'); + print "\n"; + + foreach ($conv_result['errors'] as $k => $error) { + printSeperator(sprintf("Warning/Error on line %d", $error['line']), ' '); + print $error['msg']; + print "\n"; + } +} // end func printConversionErrors + + +/** +* Prints the generated source code +* +* @param array +*/ +function printConversionOutput($conv_result, $verbose, $quiet) { + + if ($verbose) { + print "\n"; + print "\n"; + printSeperator("Generated code", '-'); + print "\n"; + } + + if (!$quiet) + print $conv_result['output']; + + if ($verbose) { + print "\n"; + print "\n"; + printSeperator("End of code", "-"); + print "\n"; + } + +} // end func printConversionOutput + + +/** +* Converts a file +* +* @param string +* @param bool +*/ +function convertFile($file, $verbose, $quiet, $update, $backup, $warnings, $seperator = '#') { + + $conv = new MySQLConverterTool_Converter(); + $ret = $conv->convertFile($file); + $status = getConversionStatus($ret); + + if ($quiet) + printSeperator(sprintf('[ %-7s ] %s', $status, $file), $seperator); + + if ($verbose) + printConversionHeader($ret, $status, $file); + + if ($backup) { + $ffile = $file . '.org'; + if (file_exists($ffile) && !unlink($ffile)) { + printf("Error:\n"); + printf("Cannot unlink old backup file '%s'. Check the file permissions.\n\n", $ffile); + return; + } + + if (!rename($file, $ffile)) { + printf("Error:\n"); + printf("Cannot rename '%s' to %s'. Check the file permissions.\n\n", $file, $ffile); + return; + } + + if ($verbose) + printf("Backup created.\n", $ffile); + } + + if ($update) { + + if (!$fp = fopen($file, 'w')) { + printf("Error:\n"); + printf("Cannot modify file '%s'. Check the file permissions.\n\n", $file); + return; + } + fwrite($fp, $ret['output']); + fclose($fp); + + if ($verbose) + printf("File updated/modified.\n", $file); + + } + + if (($verbose || $warnings) && count($ret['errors']) > 0) + printConversionErrors($ret); + + printConversionOutput($ret, $verbose, $quiet); +} // end func convertFile + + +/** +* +*/ +function convertSnippet($code, $verbose, $quiet, $warnings, $seperator = '#') { + + $conv = new MySQLConverterTool_Converter(); + $ret = $conv->convertString($code); + $status = getConversionStatus($ret); + + if ($quiet) + printSeperator('Snippet', $seperator); + + if ($verbose) + printConversionHeader($ret, $status, NULL); + + if (($verbose || $warnings) && count($ret['errors']) > 0) + printConversionErrors($ret); + + printConversionOutput($ret, $verbose, $quiet); +} // end func convertSnippet + + +/** +* Helper: prints a line with a title +* +* @param string +* @param string +*/ +function printSeperator($title, $seperator = '#') { + + $len = strlen($title) + 2; + + $num = 1; + // $num = max(floor((80 - $len) / 2), 0); + for ($i = 0; $i < $num; $i++) + print $seperator; + + printf(' %s ', $title); + + if ($num > 0) { + $num = 80 - $num - $len; + for ($i = 0; $i < $num; $i++) + print $seperator; + } + + print "\n"; + +} // end func printSeperator + + +if (!isset($argc) || !isset($argv)) { + // redirect to the web gui + // or maybe die("This is the command line interface, use php -f cli.php to run it! Open index.php for the web interface."); ? + header('Location: GUI/index.php'); + exit(0); + +} + + +list($options, $error) = parseOptions($argc, $argv); +if (!is_null($error) || empty($options) || isset($options['help'])) { + // some sort of trouble or help output requested + + if (!is_null($error)) { + printf("\n"); + printf("Error: %s\n", $error); + } + printHelp($argv); + +} else { + + print "\n"; + + if (!empty($options['files'])) { + foreach ($options['files'] as $k => $file) + convertFile($file, isset($options['verbose']), isset($options['quiet']), isset($options['update']), isset($options['backup']), isset($options['warnings'])); + } + + if (!empty($options['directories'])) { + $conv = new MySQLConverterTool_Converter(); + foreach ($options['directories'] as $k => $directory) { + $files = $conv->getFilesOfDirectory($directory, (isset($options['pattern'])) ? $options['pattern'] : ''); + if (empty($files)) { + printSeperator(sprintf('No files found in "%s"', $directory), '*'); + print "\n"; + continue; + } + + printSeperator(sprintf('Directory "%s"', $directory), '*'); + print "\n"; + foreach ($files as $k => $file) { + convertFile($file, isset($options['verbose']), isset($options['quiet']), isset($options['update']), isset($options['backup']), isset($options['warnings']), ' '); + } + + } + } + + if (isset($options['snippet'])) + convertSnippet($options['snippet'], isset($options['verbose']), isset($options['quiet']), isset($options['warnings'])); + +} +?> \ No newline at end of file diff --git a/.svn/text-base/index.php.svn-base b/.svn/text-base/index.php.svn-base new file mode 100644 index 0000000..b70f9a1 --- /dev/null +++ b/.svn/text-base/index.php.svn-base @@ -0,0 +1,16 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ +header('Location: GUI/index.php'); +exit(0); +?> \ No newline at end of file diff --git a/.svn/wcprops/Converter.php.svn-work b/.svn/wcprops/Converter.php.svn-work new file mode 100644 index 0000000..3764228 --- /dev/null +++ b/.svn/wcprops/Converter.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 71 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Converter.php +END diff --git a/.svn/wcprops/README.svn-work b/.svn/wcprops/README.svn-work new file mode 100644 index 0000000..5cea925 --- /dev/null +++ b/.svn/wcprops/README.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 64 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/README +END diff --git a/.svn/wcprops/cli.php.svn-work b/.svn/wcprops/cli.php.svn-work new file mode 100644 index 0000000..50d52b9 --- /dev/null +++ b/.svn/wcprops/cli.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 65 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/cli.php +END diff --git a/.svn/wcprops/index.php.svn-work b/.svn/wcprops/index.php.svn-work new file mode 100644 index 0000000..bb2d002 --- /dev/null +++ b/.svn/wcprops/index.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 67 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/index.php +END diff --git a/Converter.php b/Converter.php new file mode 100644 index 0000000..2abb901 --- /dev/null +++ b/Converter.php @@ -0,0 +1,936 @@ +ext/mysqli Converter +* +* @category Converter +* @package MySQLConverterTool +* @author Andrey Hristov , Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Converter { + + // + // protected + // + + /** + * Scanner state constant + * + * @const + * @access protected + */ + const STATE_NORMAL = 'normal_state'; + + + /** + * Scanner state constant + * + * @const + * @access protectd + */ + const STATE_FUNC_FOUND = 'func_found'; + + + /** + * Scanner state constant + * + * @const + * @access protected + */ + const STATE_PARAM_LIST = 'parameter_list'; + + + /** + * Converted (= resulting) source code + * + * @var string + */ + protected $output = ''; + + + /** + * List of errors which occured during the conversion + * + * @var array + */ + protected $errors = array(); + + + /** + * List of PHP token + * + * @var string + */ + protected $tokens = array(); + + + /** + * Mapping of ext/mysql -> ext/mysqli constants + * + */ + protected $mysql_ext_consts = array( + 'MYSQL_CLIENT_COMPRESS' => 'MYSQLI_CLIENT_COMPRESS', + 'MYSQL_CLIENT_IGNORE_SPACE' => 'MYSQLI_CLIENT_IGNORE_SPACE', + 'MYSQL_CLIENT_INTERACTIVE' => 'MYSQLI_CLIENT_INTERACTIVE', + 'MYSQL_CLIENT_SSL' => 'MYSQLI_CLIENT_SSL', + 'MYSQL_ASSOC' => 'MYSQLI_ASSOC', + 'MYSQL_BOTH' => 'MYSQLI_BOTH', + 'MYSQL_NUM' => 'MYSQLI_NUM', + ); + + + /** + * Number of functions found in the given source + * + * @var int + */ + protected $funcs_found = 0; + + + /** + * Number of functions converted in the given source + * + * @var int + */ + protected $funcs_converted = 0; + + + /** + * List of functions that are not supported + * + * @var array + */ + protected $mysql_funcs_not_supported = array( + // rewrite the ugly mysql_result calls manually! + 'mysql_result' => true, + // whatever that function is... + 'mysql_fetch_field2' => true, + ); + + + /** + * List of functions that can be converted + * + * Acts as kind of a function pointer list, but with objects + * + * @var array + */ + protected $mysql_funcs = array(); + + + /** + * Flag: enable token debug output? + * + * @var bool + */ + protected $debug_dump_tokens = false; + + + /** + * Flag: enable parameter parsing debug output? + * + * @var bool + */ + protected $debug_dump_params = false; + + + /** + * Current line number during the parsing process + * + * @var int + */ + protected $lineno = 0; + + + // + // public + // + + + /** + * + * + * @param bool Turn on debug output of scanner token? + * @param bool Turn on debug output of function parameters? + */ + public function __construct($debug_token = false, $debug_params = false) { + + if (!function_exists('token_name')) { + // HACK FIXME + die('ext/tokenizer is needed!\n'); + } + + if (!defined('T_ML_COMMENT')) + define('T_ML_COMMENT', T_COMMENT); + + if (!defined('T_DOC_COMMENT')) + define('T_DOC_COMMENT', T_ML_COMMENT); + + if (!defined('T_SIMPLE_TOKEN')) + define('T_SIMPLE_TOKEN', 32567); + + $this->debug_dump_tokens = $debug_token; + $this->debug_dump_params = $debug_params; + + $this->mysql_funcs = + array( + // PHP_FALIAS(mysql, mysql_db_query, NULL) + 'mysql' => new MySQLConverterTool_Function_DBQuery(), + // in OO this is a property + 'mysql_affected_rows' => new MySQLConverterTool_Function_ConnParam('mysqli_affected_rows'), + 'mysql_change_user' => new MySQLConverterTool_Function_ChangeUser(), + 'mysql_client_encoding' => new MySQLConverterTool_Function_ConnParam('mysqli_character_set_name'), + 'mysql_close' => new MySQLConverterTool_Function_ConnParamBool('mysqli_close'), + // pconnect has less params but they are not significant for mysqli_connect + 'mysql_connect' => new MySQLConverterTool_Function_Connect(), + // PHP_FALIAS(mysql_createdb, mysql_create_db, NULL) + 'mysql_createdb' => new MySQLConverterTool_Function_CreateDB(), + 'mysql_create_db' => new MySQLConverterTool_Function_CreateDB(), + 'mysql_data_seek' => new MySQLConverterTool_Function_Generic('mysqli_data_seek'), + 'mysql_dbname' => new MySQLConverterTool_Function_Tablename(), + 'mysql_db_name' => new MySQLConverterTool_Function_Tablename(), + 'mysql_db_query' => new MySQLConverterTool_Function_DBQuery(), + // PHP_FALIAS(mysql_dropdb, mysql_drop_db, NULL) + 'mysql_dropdb' => new MySQLConverterTool_Function_DropDB(), + 'mysql_drop_db' => new MySQLConverterTool_Function_DropDB(), + // in OO this is a property + 'mysql_error' => new MySQLConverterTool_Function_Error('mysqli_error'), + // in OO this is a property + 'mysql_errno' => new MySQLConverterTool_Function_Error('mysqli_errno'), + 'mysql_escape_string' => new MySQLConverterTool_Function_EscapeString('mysqli_real_escape_string'), + 'mysql_fetch_array' => new MySQLConverterTool_Function_Generic('mysqli_fetch_array'), + 'mysql_fetch_assoc' => new MySQLConverterTool_Function_Generic('mysqli_fetch_assoc'), + 'mysql_fetch_field' => new MySQLConverterTool_Function_FetchField(), + 'mysql_fetch_lengths' => new MySQLConverterTool_Function_GenericBoolean('mysqli_fetch_lengths'), + 'mysql_fetch_object' => new MySQLConverterTool_Function_Generic('mysqli_fetch_object'), + 'mysql_fetch_row' => new MySQLConverterTool_Function_Generic('mysqli_fetch_row'), + // PHP_FALIAS(mysql_fieldflags, mysql_field_flags, NULL) + 'mysql_fieldflags' => new MySQLConverterTool_Function_FieldFlags(), + 'mysql_field_flags' => new MySQLConverterTool_Function_FieldFlags(), + // PHP_FALIAS(mysql_fieldlen, mysql_field_len, NULL) + 'mysql_fieldlen' => new MySQLConverterTool_Function_FieldLen(), + 'mysql_field_len' => new MySQLConverterTool_Function_FieldLen(), + // PHP_FALIAS(mysql_fieldname, mysql_field_name, NULL) + 'mysql_fieldname' => new MySQLConverterTool_Function_FieldName(), + 'mysql_field_name' => new MySQLConverterTool_Function_FieldName(), + 'mysql_field_seek' => new MySQLConverterTool_Function_GenericBoolean('mysqli_field_seek'), + // PHP_FALIAS(mysql_fieldtable, mysql_field_table, NULL) + 'mysql_fieldtable' => new MySQLConverterTool_Function_FieldTable(), + 'mysql_field_table' => new MySQLConverterTool_Function_FieldTable(), + // PHP_FALIAS(mysql_fieldtype, mysql_field_type, NULL) + 'mysql_fieldtype' => new MySQLConverterTool_Function_FieldType(), + 'mysql_field_type' => new MySQLConverterTool_Function_FieldType(), + // PHP_FALIAS(mysql_freeresult, mysql_free_result, NULL) + 'mysql_freeresult' => new MySQLConverterTool_Function_FreeResult(), + 'mysql_free_result' => new MySQLConverterTool_Function_FreeResult(), + 'mysql_get_client_info' => new MySQLConverterTool_Function_Generic('mysqli_get_client_info'), + // in OO this is a property + 'mysql_get_host_info' => new MySQLConverterTool_Function_ConnParamBool('mysqli_get_host_info'), + // in OO this is a property + 'mysql_get_proto_info' => new MySQLConverterTool_Function_ConnParamBool('mysqli_get_proto_info'), + // in OO this is a property + 'mysql_get_server_info' => new MySQLConverterTool_Function_ConnParamBool('mysqli_get_server_info'), + 'mysql_info' => new MySQLConverterTool_Function_ConnParam('mysqli_info'), + 'mysql_insert_id' => new MySQLConverterTool_Function_ConnParamBool('mysqli_insert_id'), + // PHP_FALIAS(mysql_listdbs, mysql_list_dbs, NULL) + 'mysql_listdbs' => new MySQLConverterTool_Function_ListDBs(), + 'mysql_list_dbs' => new MySQLConverterTool_Function_ListDBs(), + // PHP_FALIAS(mysql_listfields, mysql_list_fields, NULL) + 'mysql_listfields' => new MySQLConverterTool_Function_ListFields(), + 'mysql_list_fields' => new MySQLConverterTool_Function_ListFields(), + 'mysql_list_processes' => new MySQLConverterTool_Function_ListProcesses(), + // PHP_FALIAS(mysql_listtables, mysql_list_tables, NULL) + 'mysql_listtables' => new MySQLConverterTool_Function_ListTables(), + 'mysql_list_tables' => new MySQLConverterTool_Function_ListTables(), + // PHP_FALIAS(mysql_numfields, mysql_num_fields, NULL) + 'mysql_numfields' => new MySQLConverterTool_Function_Generic('mysqli_num_fields'), + // in OO this is a property + 'mysql_num_fields' => new MySQLConverterTool_Function_GenericBoolean('mysqli_num_fields'), + // PHP_FALIAS(mysql_numrows, mysql_num_rows, NULL) + 'mysql_numrows' => new MySQLConverterTool_Function_Generic('mysqli_num_rows'), + // in OO this is a property + 'mysql_num_rows' => new MySQLConverterTool_Function_Generic('mysqli_num_rows'), + // pconnect has less params but they are not significant for mysqli_connect + 'mysql_pconnect' => new MySQLConverterTool_Function_Connect(), + 'mysql_ping' => new MySQLConverterTool_Function_ConnParam('mysqli_ping'), + 'mysql_query' => new MySQLConverterTool_Function_ParReversed('mysqli_query'), + 'mysql_real_escape_string' => new MySQLConverterTool_Function_RealEscapeString('mysqli_real_escape_string'), + // mysql_result -- Get result data + // PHP_FALIAS(mysql_selectdb, mysql_select_db, NULL) + 'mysql_selectdb' => new MySQLConverterTool_Function_SelectDB(), + 'mysql_select_db' => new MySQLConverterTool_Function_SelectDB(), + 'mysql_stat' => new MySQLConverterTool_Function_ConnParam('mysqli_stat'), + 'mysql_tablename' => new MySQLConverterTool_Function_Tablename(), + 'mysql_table_name' => new MySQLConverterTool_Function_Tablename(), + 'mysql_thread_id' => new MySQLConverterTool_Function_ConnParam('mysqli_thread_id'), + 'mysql_unbuffered_query' => new MySQLConverterTool_Function_UnbufferedQuery(), + ); + + } // end func __construct + + + + /** + * Converts the given source code + * + * @param string Source code to be converted + * @return array Converted source code and status information + */ + public function convertString($source) { + + $this->lineno = 0; + $this->output = ''; + $this->tokens = token_get_all($source); + $this->errors = array(); + $this->lineno = 1; + + $this->funcs_found = 0; + $this->funcs_converted = 0; + + $this->scanner(0); + + return array( + 'output' => $this->output, + 'found' => $this->funcs_found, + 'converted' => $this->funcs_converted, + 'errors' => $this->errors, + ); + } // end func convertString + + + /** + * Reads a file and returns the converted source code + * + * @param strng filename + * @param array Converted source and status information + */ + public function convertFile($filename) { + + if (!file_exists($filename) || !is_readable($filename) || !is_file($filename)) { + $ret = $this->convertString(''); + $ret['errors'][] = array('line' => -1, 'msg' => 'Cannot open file "' . $filename . '".'); + return $ret; + } + + return $this->convertString(file_get_contents($filename)); + } + + + /** + * Returns all files of a directory that have a certain name + * + * + */ + public function getFilesOfDirectory($dir, $file_pattern = '*', Array $files = array()) { + + if (!is_dir($dir) || !is_readable($dir)) + return $files; + + $patterns = $this->buildRegularExpression($file_pattern); + if (empty($patterns)) + return $files; + + $dh = opendir($dir); + if (!$dh) + return $files; + + while ($file = readdir($dh)) { + if ('.' == $file || '..' == $file) + continue; + + $ffile = $dir . '/' . $file; + if (is_dir($ffile)) + $files = $this->getFilesOfDirectory($ffile, $file_pattern, $files); + + if (!is_file($ffile)) + continue; + + $accept = false; + foreach ($patterns as $k => $pattern) { + if (preg_match('@' . $pattern . '$@i', $file)) { + $accept = true; + break; + } + } + + if ($accept) + $files[] = $ffile; + } + closedir($dh); + + return $files; + } + + + /** + * Unsets the variable which stores the global (default) connection of ext/mysql + * + * This is a hack required by the test framework. + * + */ + public function unsetGlobalConnection() { + + $obj = new MySQLConverterTool_Function_Generic('mysqli_query'); + eval(sprintf('@mysqli_close(%s);', $obj->ston_name)); + eval(sprintf('if (isset(%s)) unset(%s);', $obj->ston_name, $obj->ston_name)); + + } + + + /** + * Returns a list of functions that can be converted automatically + * + * @return array + */ + public function getSupportedFunctions() { + + $ret = array_keys($this->mysql_funcs); + sort($ret); + + return $ret; + } + + + /** + * Returns a list of functions that cannot be converted automatically + * + * @return array + */ + public function getUnsupportedFunctions() { + + $ret = array_keys($this->mysql_funcs_not_supported); + sort($ret); + + return $ret; + } + + // + // protected + // + + + /** + * Scans the source and rebuilds a converted version of it + * + * @param int + */ + protected function scanner($level) { + + // current parser state + $state = self::STATE_NORMAL; + + // list of function parameters + $func_params = array(); + // current parameter value + $curr_param = ''; + // current bracket nesting level + $bracket_level = 0; + // name of the currently processed function + $func_name = ''; + // flag: does the currently parameter contain variables or constants? + $param_dynamic = false; + // flag for something that looks like a mysql_func call but is not followed by parameters + $expect_param_brace_open = false; + + + while (list( , $token) = each($this->tokens)) { + + if (is_string($token)) { + $id = T_SIMPLE_TOKEN; + $token_name = 'T_SIMPLE_TOKEN'; + $text = $token; + } else { + list($id, $text) = $token; + $token_name = token_name($id); + } + + // remember the current line number + $lineno = $this->lineno; + $this->lineno += $this->countLines($text); + + if ($this->debug_dump_tokens) { + + $this->debug_print('dump token', + sprintf("[%-05d - %10s - %d - %-10s - %03d - %05d] %s", + $lineno, + $token_name, + $expect_param_brace_open, + $state, + $bracket_level, + strlen($text), + htmlspecialchars($text)) + ); + + } + + switch ($id) { + + case T_COMMENT: + case T_ML_COMMENT: + case T_DOC_COMMENT: + + switch ($state) { + case self::STATE_NORMAL: + $this->output .= $text; + break; + + case self::STATE_FUNC_FOUND: + // comment between func_name and comma + break; + + case self::STATE_PARAM_LIST: + $curr_param .= $text; + break; + } + + break; + + case T_SIMPLE_TOKEN: + + switch ($state) { + + case self::STATE_NORMAL: + $this->output .= $text; + break; + + case self::STATE_FUNC_FOUND: + + switch ($text) { + case '(': + $state = self::STATE_PARAM_LIST; + $func_params = array(); + $curr_param = NULL; + $param_dynamic = false; + $expect_param_brace_open = false; + break; + + case ')': + default: + if ($expect_param_brace_open) { + // something that looks like is not followed by an opening brace for + $state = self::STATE_NORMAL; + $this->funcs_found--; + $expect_param_brace_open = 0; + $steps = 0; + $tmp = ''; + while (($token = prev($this->tokens)) && ($tmp != $func_name)) { + if (is_array($token)) { + $tmp = $token[1]; + } else { + $tmp = $token; + } + $steps++; + } + while ($steps-- > 1) { + $token = next($this->tokens); + if (is_array($token)) + $tmp = $token[1]; + else + $tmp = $token; + $this->output .= $tmp; + } + next($this->tokens); + break 3; + } + break; + } + break; + + case self::STATE_PARAM_LIST: + + switch ($text) { + case ',': + if ($bracket_level == 1) { + $func_params[] = array('value' => $curr_param, 'dynamic' => $param_dynamic); + $curr_param = ''; + $param_dynamic = false; + } else { + $curr_param .= $text; + } + // don't add to the curr_param + break(2); + + case '(': + $bracket_level++; + break; + + case ')': + $bracket_level--; + if ($bracket_level == 0) { + // end of the parameter specification + + if (!is_null($curr_param)) + $func_params[] = array('value' => $curr_param, 'dynamic' => $param_dynamic); + + $curr_param = NULL; + $param_dynamic = false; + $state = self::STATE_NORMAL; + + if ($this->debug_dump_params) { + $this->debug_print( + 'params', + array('name' => $func_name, 'params' => $func_params) + ); + } + + if (!$level) { + + list($handler_warning, $handler_code) = $this->mysql_funcs[$func_name]->handle($func_params); + if (!is_null($handler_warning)) + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] %s', $lineno, $handler_warning)); + + if (is_null($handler_code)) { + $this->output .= $this->rebuildFunctionCode($func_name, $func_params, $handler_warning); + } else { + $this->funcs_converted++; + $this->output .= $handler_code; + } + + } else { + // we are in recursive call - return + + list($handler_warning, $handler_code) = $this->mysql_funcs[$func_name]->handle($func_params); + if (!is_null($handler_warning)) + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] %s', $lineno, $handler_warning)); + + if (is_null($handler_code)) { + return $this->rebuildFunctionCode($func_name, $func_params, $handler_warning); + } else { + $this->funcs_converted++; + return $handler_code; + } + + } + + } + break; + + case '.': + case '&': + case '^': + case '|': + case '&&': + case '||': + case 'and': + case 'or': + case 'xor': + case '<<': + case '>>': + case '<': + case '<=': + case '>': + case '>=': + case '=': + case '*': + case '/': + case '%': + case '+': + case '-': + case '++': + case '--': + case '!': + case '~': + case '=': + case '+=': + case '-=': + case '*=': + case '/=': + case '.=': + case '%=': + case '&=': + case '|=': + case '^=': + case '<<=': + case '>>=': + case '?': + case '==': + case '!=': + case '===': + case '!==': + case '(': + case 'new': + // forget it - this parameter value is build dynamically + // we won't try to guess it's value using static code analysis + // this needs to be checked manually + $param_dynamic = true; + if ($this->debug_dump_params) { + $this->debug_print( + 'params', + 'Operator found in parameter. Assuming that the paramter value will be dynamic and cannot be foreseen.' + ); + } + break; + } + + $curr_param .= $text; + break; + } + break; + + case T_STRING: + + if (isset($this->mysql_ext_consts[$text])) { + + $text = $this->mysql_ext_consts[$text]; + + } else { + + switch ($state) { + case self::STATE_PARAM_LIST: + // maybe a function call or constant as part of a parameter value? + + if (isset($this->mysql_funcs_not_supported[$text])) { + + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] Function "%s" is not supported for conversion! You must rewrite the converted code. The conversion is not complete. Consider rewriting your code first and rerunning the conversion tool"', $lineno, $text)); + + } + + if (isset($this->mysql_funcs[$text])) { + // return the current token and reparse it + prev($this->tokens); + // in the default of the outter switch add this to $curr_param + $text = $this->scanner($level + 1); + $param_dynamic = true; + } + // fall to default + break; + + case self::STATE_FUNC_FOUND: + + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] We found a string between the function name "%s" and the parameter list. Looks like a syntax error in the source file. Please check!', $lineno, $func_name)); + + break; + + case self::STATE_NORMAL: + default: + + if (isset($this->mysql_funcs_not_supported[$text])) { + + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] Function "%s" is not supported for conversion! You must rewrite the converted code code. The conversion is not complete. Consider rewriting your code first and rerunning the conversion tool."', $lineno, $text)); + + } + + if (isset($this->mysql_funcs[$text])) { + $state = self::STATE_FUNC_FOUND; + $func_name = $text; + $bracket_level = 1; + $this->funcs_found++; + $expect_param_brace_open = true; + + break(2); + } + + if ($text == 'is_resource') { + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] You are using is_resource(). Make sure that you do not use it to test for the return value of mysql_query(). mysql_query() returns a resource or a boolean value. mysqli_query() returns an object or a boolean value. If you check the return value of mysql_query like < if (is_resource($res = mysql_query())) [...] > the converted code will fail, because $res will be an object in ext/mysqli."', $lineno, $text)); + } + // here we fall-through + } + } + + + default: + + if ($id === T_CONSTANT_ENCAPSED_STRING) { + /* try to detect function_exists('some_mysql_func'); */ + $prev_steps = 0; + + if (isset($this->mysql_funcs[substr($text, 1, -1)]) && + $this->mysql_funcs[substr($text, 1, -1)]->new_name) { + // strip quotes + // move back because now 'some_mysql_func' will be returned by prev() + $prev_steps = 1; + $tmp_token = prev($this->tokens); + + do { + $tmp_token = prev($this->tokens); + $prev_steps++; + } while ($tmp_token[0] === T_WHITESPACE); + + if ($tmp_token === '(') { + + $tmp_token = prev($this->tokens); + $prev_steps++; + + if ($tmp_token[0] === T_STRING && + $tmp_token[1] === 'function_exists') { + + $text = $text[0] . $this->mysql_funcs[substr($text, 1, -1)]->new_name . $text[0]; + } + + } + + while ($prev_steps--) + each($this->tokens); + } + } + + switch ($state) { + case self::STATE_PARAM_LIST: + + switch ($id) { + + case T_VARIABLE: + case T_FUNCTION: + case T_CONST: + // this is a variable, we cannot guess value of the parameter + // using this static conversion approach + if ($this->debug_dump_params) { + $this->debug_print( + 'params', + "Adding variable '$text' to current parameter." + ); + } + $param_dynamic = true; + $curr_param .= $text; + break; + + case T_WHITESPACE: + default: + if ($this->debug_dump_params) { + $this->debug_print( + 'params', + "Adding '$text' to current parameter." + ); + } + + $curr_param .= $text; + break; + } + break; + + case self::STATE_FUNC_FOUND: + + $this->errors[] = array('line' => $lineno, 'msg' => sprintf('[Line %d] Please check your code for parse errors, we failed to parse "%s". Conversion will be incomplete!".', $lineno, $text)); + break; + + default: + case self::STATE_NORMAL: + $this->output .= $text; + break; + } + break; + } + + } + + } + + + /** + * Print a debug message + * + * @param string Message prefix + * @param mixed Array or literal to print + */ + protected function debug_print($prefix, $var) { + + if (is_scalar($var)) { + printf("[%s/%s] %s\n", + get_class($this), + $prefix, + $var); + } else { + printf("[%s/%s] ", get_class($this), $prefix); + var_dump($var); + printf("\n"); + } + + + } // end func debug_print + + + /** + * Returns the number of lines of a string + * + * @param string + * @return int + */ + protected function countLines($text) { + + $last_pos = 0; + $lines = 0; + while (($pos = strpos($text, "\n", $last_pos)) !== FALSE) { + $last_pos = $pos + 1; + $lines++; + } + + return $lines; + } + + + /** + * Rebuilds the original function code based on function name and parameters and adds a comment with a warning after the last parameter + * + * @param string + * @param array + * @param string + */ + protected function rebuildFunctionCode($name, $params, $warning) { + + $ret = $name . '('; + if (count($params) > 0) { + foreach ($params as $k => $param) + $ret .= $param['value'] . ', '; + $ret = substr($ret, 0, -2); + } + $ret .= ')'; + // $ret .= ' /* [MySQLConverterTool] ' . $warning . '*/)'; + + return $ret; + } + + + + /** + * Expands a user specified file pattern with * as the only pattern to a regular expression + * + * @param string + * @return array + */ + protected function buildRegularExpression($file_pattern) { + + $parts = explode(',', $file_pattern); + if (empty($parts)) + return array(); + + $ret = array(); + foreach ($parts as $k => $v) + $ret[] = str_replace('\*', '.*', preg_quote($v, '@')); + + return $ret; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/README.txt b/Function/.svn/README.txt new file mode 100644 index 0000000..271a8ce --- /dev/null +++ b/Function/.svn/README.txt @@ -0,0 +1,2 @@ +This is a Subversion working copy administrative directory. +Visit http://subversion.tigris.org/ for more information. diff --git a/Function/.svn/dir-wcprops b/Function/.svn/dir-wcprops new file mode 100644 index 0000000..9ca8be1 --- /dev/null +++ b/Function/.svn/dir-wcprops @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 67 +/svnpublic/mysqli_converter/!svn/ver/11/MySQLConverterTool/Function +END diff --git a/Function/.svn/empty-file b/Function/.svn/empty-file new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/entries b/Function/.svn/entries new file mode 100644 index 0000000..e235a09 --- /dev/null +++ b/Function/.svn/entries @@ -0,0 +1,257 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Function/.svn/format b/Function/.svn/format new file mode 100644 index 0000000..b8626c4 --- /dev/null +++ b/Function/.svn/format @@ -0,0 +1 @@ +4 diff --git a/Function/.svn/prop-base/ChangeUser.php.svn-base b/Function/.svn/prop-base/ChangeUser.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/ConnParam.php.svn-base b/Function/.svn/prop-base/ConnParam.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/ConnParamBool.php.svn-base b/Function/.svn/prop-base/ConnParamBool.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/Connect.php.svn-base b/Function/.svn/prop-base/Connect.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/CreateDB.php.svn-base b/Function/.svn/prop-base/CreateDB.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/DBQuery.php.svn-base b/Function/.svn/prop-base/DBQuery.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/DropDB.php.svn-base b/Function/.svn/prop-base/DropDB.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/Error.php.svn-base b/Function/.svn/prop-base/Error.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/EscapeString.php.svn-base b/Function/.svn/prop-base/EscapeString.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/FetchField.php.svn-base b/Function/.svn/prop-base/FetchField.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/FieldFlags.php.svn-base b/Function/.svn/prop-base/FieldFlags.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/FieldLen.php.svn-base b/Function/.svn/prop-base/FieldLen.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/FieldName.php.svn-base b/Function/.svn/prop-base/FieldName.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/FieldTable.php.svn-base b/Function/.svn/prop-base/FieldTable.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/FieldType.php.svn-base b/Function/.svn/prop-base/FieldType.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/FreeResult.php.svn-base b/Function/.svn/prop-base/FreeResult.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/Generic.php.svn-base b/Function/.svn/prop-base/Generic.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/GenericBoolean.php.svn-base b/Function/.svn/prop-base/GenericBoolean.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/ListDBs.php.svn-base b/Function/.svn/prop-base/ListDBs.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/ListFields.php.svn-base b/Function/.svn/prop-base/ListFields.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/ListProcesses.php.svn-base b/Function/.svn/prop-base/ListProcesses.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/ListTables.php.svn-base b/Function/.svn/prop-base/ListTables.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/ParReversed.php.svn-base b/Function/.svn/prop-base/ParReversed.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/RealEscapeString.php.svn-base b/Function/.svn/prop-base/RealEscapeString.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/SelectDB.php.svn-base b/Function/.svn/prop-base/SelectDB.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/Tablename.php.svn-base b/Function/.svn/prop-base/Tablename.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/prop-base/UnbufferedQuery.php.svn-base b/Function/.svn/prop-base/UnbufferedQuery.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/ChangeUser.php.svn-work b/Function/.svn/props/ChangeUser.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/ConnParam.php.svn-work b/Function/.svn/props/ConnParam.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/ConnParamBool.php.svn-work b/Function/.svn/props/ConnParamBool.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/Connect.php.svn-work b/Function/.svn/props/Connect.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/CreateDB.php.svn-work b/Function/.svn/props/CreateDB.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/DBQuery.php.svn-work b/Function/.svn/props/DBQuery.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/DropDB.php.svn-work b/Function/.svn/props/DropDB.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/Error.php.svn-work b/Function/.svn/props/Error.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/EscapeString.php.svn-work b/Function/.svn/props/EscapeString.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/FetchField.php.svn-work b/Function/.svn/props/FetchField.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/FieldFlags.php.svn-work b/Function/.svn/props/FieldFlags.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/FieldLen.php.svn-work b/Function/.svn/props/FieldLen.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/FieldName.php.svn-work b/Function/.svn/props/FieldName.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/FieldTable.php.svn-work b/Function/.svn/props/FieldTable.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/FieldType.php.svn-work b/Function/.svn/props/FieldType.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/FreeResult.php.svn-work b/Function/.svn/props/FreeResult.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/Generic.php.svn-work b/Function/.svn/props/Generic.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/GenericBoolean.php.svn-work b/Function/.svn/props/GenericBoolean.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/ListDBs.php.svn-work b/Function/.svn/props/ListDBs.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/ListFields.php.svn-work b/Function/.svn/props/ListFields.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/ListProcesses.php.svn-work b/Function/.svn/props/ListProcesses.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/ListTables.php.svn-work b/Function/.svn/props/ListTables.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/ParReversed.php.svn-work b/Function/.svn/props/ParReversed.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/RealEscapeString.php.svn-work b/Function/.svn/props/RealEscapeString.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/SelectDB.php.svn-work b/Function/.svn/props/SelectDB.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/Tablename.php.svn-work b/Function/.svn/props/Tablename.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/props/UnbufferedQuery.php.svn-work b/Function/.svn/props/UnbufferedQuery.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/Function/.svn/text-base/ChangeUser.php.svn-base b/Function/.svn/text-base/ChangeUser.php.svn-base new file mode 100644 index 0000000..23def8e --- /dev/null +++ b/Function/.svn/text-base/ChangeUser.php.svn-base @@ -0,0 +1,91 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ChangeUser extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_change_user'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_change_user ( string user, string password [, string database [, resource link_identifier]] ) + // mysqli_change_user ( mysqli link, string user, string password, string database ) + + $warning = NULL; + + if (4 == count($params)) { + + list($user, $pass, $db, $conn) = $this->extractParamValues($params); + $ret = "mysqli_change_user($conn, $user, $pass, $db)"; + + } else if (3 == count($params)) { + + list($user, $pass, $db) = $this->extractParamValues($params); + $conn = $this->ston_name; + $ret = "mysqli_change_user($conn, $user, $pass, $db)"; + + } else if (2 == count($params)) { + + list($user, $pass) = $this->extractParamValues($params); + $conn = $this->ston_name; + + // [1] $res = mysqli_query(conn, 'SELECT DATABASE()') + // [2] $row = mysqli_fetch_row($res); + // [3] $row = array_shift($row); + // [4] unset($row); + // [5] mysqli_free_result($res); + // [6] unset($res); + // [7] mysqli_change_user(conn, user, pass, $db) + // + // [1] ( ($res = mysqli_query() ) ? $db : false + // [2] ( ($res = mysqli_query() && row = mysqli_fetch_row($res)) ? $db : false + // [3] ( ($res = mysqli_query() && row = mysqli_fetch_row($res) && ((row = array_shift(row)) !== false) ) ? true : false + // [5] ( ($res = mysqli_query() && row = mysqli_fetch_row($res) && ((row = array_shift(row)) !== false) ) && mysqli_free_result(res) ) ? true : false + // [7] ( ($res = mysqli_query() && row = mysqli_fetch_row($res) && ((row = array_shift(row)) !== false) ) && mysqli_free_result(res) ) ? mysqli_change_user(conn, user, pass, $row) : false + + + $ret = '( '; + $ret.= '( '; + $ret.= '($___mysqli_res = mysqli_query(' . $conn . ', "SELECT DATABASE()")) && '; + $ret.= '($___mysqli_tmp = mysqli_fetch_row($___mysqli_res)) && '; + $ret.= '(($___mysqli_tmp = array_shift($___mysqli_tmp)) !== false) && '; + $ret.= '(mysqli_free_result($___mysqli_res)) '; + $ret.= ') ? '; + $ret.= sprintf('mysqli_change_user(%s, %s, %s, $___mysqli_tmp) : ', $conn, $user, $pass); + $ret.= 'false '; + $ret.= ')'; + + } else { + + $warning = self::PARSE_ERROR_WRONG_PARAMS; + $ret = NULL; + + } + + return array($warning, $ret); + } + + + function getConversionHint() { + + return 'mysql_change_user() can be translated into mysqli_change_user if the database is given. If not, it must be emulated using mysqli_query() and SELECT DATABASE() - which looks a bit like a hack.'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/ConnParam.php.svn-base b/Function/.svn/text-base/ConnParam.php.svn-base new file mode 100644 index 0000000..643dfac --- /dev/null +++ b/Function/.svn/text-base/ConnParam.php.svn-base @@ -0,0 +1,36 @@ + mysqli_func(resource) +* +* @category Functions +* @package MySQLConverterTool +* @author Andrey Hristov , Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ConnParam extends MySQLConverterTool_Function_Generic { + + function handle(Array $params = array()) { + + if (count($params) > 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(NULL, "$this->new_name($conn)"); + } + + function getConversionHint() { + + return 'Generic class for all functions that look like mysql_foo([]) -> mysqli_bar()'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/ConnParamBool.php.svn-base b/Function/.svn/text-base/ConnParamBool.php.svn-base new file mode 100644 index 0000000..bd8e145 --- /dev/null +++ b/Function/.svn/text-base/ConnParamBool.php.svn-base @@ -0,0 +1,37 @@ + ((bool)mysqli_func(resource)) +* +* @category Functions +* @package MySQLConverterTool +* @author Andrey Hristov , Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ConnParamBool extends MySQLConverterTool_Function_Generic { + + + function handle(Array $params = array()) { + + if (count($params) > 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(NULL, '((is_null($___mysqli_res = ' . $this->new_name . '(' . $conn . '))) ? false : $___mysqli_res)'); + } + + function getConversionHint() { + + return 'Generic class for all functions that look like mysql_foo([]) -> ((bool)mysqli_bar())'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/Connect.php.svn-base b/Function/.svn/text-base/Connect.php.svn-base new file mode 100644 index 0000000..b841235 --- /dev/null +++ b/Function/.svn/text-base/Connect.php.svn-base @@ -0,0 +1,203 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_Connect extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_connect'; + + + public function __construct() { + } + + function handle(Array $params = array()) { + static $last_params = array(); + + /* + Known deficiencies: + - will try to handle unix_socket but not the best solution + */ + + // mysql_connect ( [string server [, string username [, string password [, bool new_link [, int client_flags]]]]] ) + // mysql_pconnect ( [string server [, string username [, string password [, int client_flags]]]] ) + // mysqli_connect ( [string host [, string username [, string passwd [, string dbname [, int port [, string socket]]]]]] ) + + $warning = NULL; + $socket = NULL; + $port = NULL; + + @list($server, $user, $password, $new_link, $client_flags) = $this->extractParamValues($params); + if (!is_null($server)) { + if ($params[0]['dynamic']) { + $warning = 'Cannot analyze server parameter to extract host, socket and port! Conversion cannot be performed automatically. You must manually check the result of the conversion.'; + } else { + list($server, $socket, $port) = $this->expandServerParam($server); + } + } + + $found = false; + if (is_null($new_link) || ($new_link == false)) { + // Maybe someone relies on: + // If a second call is made to mysql_connect() with the same arguments, + // no new link will be established, but instead, the link identifier of the already + // opened link will be returned. The new_link parameter modifies this behavior + // and makes mysql_connect() always open a new link, even if mysql_connect() + // was called before with the same parameters. + // The current converter version cannot catch this. All we can do is throw a warning + + foreach ($last_params as $k => $lparams) { + if ($params == $lparams) { + $warning .= " You're calling mysql_connect() twice with the same parameters. We don't know for sure if you want a new connection or reuse the old connection. You must check your code."; + $found = true; + break; + } + } + + } + if (!$found) + $last_params[] = $params; + + + $dbname = 'NULL'; + $ret = NULL; + $num_params = count($params); + + if ($num_params < 5) { + + if (!is_null($socket)) { + + $ret = sprintf('(%s = %s(%s, %s, %s, %s, %d, \'%s\'))', + $this->ston_name, + $this->new_name, + is_null($server) ? 'NULL' : $server, + is_null($user) ? 'NULL' : $user, + is_null($password) ? 'NULL' : $password, + is_null($dbname) ? 'NULL' : $dbname, + is_null($port) ? 'NULL' : $port, + $socket); + } else { + + if (is_null($server)) { + // mysql_connect() + $ret = sprintf('(%s = %s())', + $this->ston_name, + $this->new_name); + + } else if (!is_null($port)) { + // port used - no chance to generate pretty code + + $ret = sprintf('(%s = %s(%s, %s, %s, %s, %d))', + $this->ston_name, + $this->new_name, + is_null($server) ? 'NULL' : $server, + is_null($user) ? 'NULL' : $user, + is_null($password) ? 'NULL' : $password, + is_null($dbname) ? 'NULL' : $dbname, + $port + ); + + } else if (!is_null($password)) { + + // mysql_connect(, , ) + $ret = sprintf('(%s = %s(%s, %s, %s))', + $this->ston_name, + $this->new_name, + is_null($server) ? 'NULL' : $server, + is_null($user) ? 'NULL' : $user, + $password); + + } else if (!is_null($user)) { + // mysql_connect(, + $ret = sprintf('(%s = %s(%s, %s))', + $this->ston_name, + $this->new_name, + is_null($server) ? 'NULL' : $server, + $user); + + } else { + // mysql_connect() but not mysql_connect() + + $ret = sprintf('(%s = %s(%s))', + $this->ston_name, + $this->new_name, + $server); + + } + + } + + } else if ($num_params == 5) { + + $ret = sprintf('(((%s = mysqli_init()) && (mysqli_real_connect(%s, %s, %s, %s, %s, %d, %s, %s))) ? %s : FALSE)', + $this->ston_name, + $this->ston_name, + $server, + $user, + $password, + $dbname, + is_null($port) ? 3306 : $port, + is_null($socket) ? 'NULL' : $socket, + $client_flags, + $this->ston_name); + + } else { + // too many parameters + + $warning = self::PARSE_ERROR_WRONG_PARAMS; + $ret = NULL; + + } + + return array($warning, $ret); + } + + + protected function expandServerParam($server) { + + $socket = NULL; + $port = NULL; + + $pos = strpos($server, ':/'); + if (FALSE !== $pos) { + // Unix Socket + + $first_ch = $server[0]; + $last_ch = substr($server, -1, 1); + + if (($last_ch == '"' || $last_ch == "'") && $last_ch == $first_ch) { + $server = substr($server, 1, -1); + } + + $socket = substr($server, $pos + 1); + $server = '"localhost"'; + + } else if (preg_match('/(["\']*)([^:]+):(\d+)/iu', $server, $matches)) { + // host:port + + $server = $matches[1] . $matches[2] . $matches[1]; + $port = $matches[3]; + + } + + return array($server, $socket, $port); + } + + function getConversionHint() { + + return 'mysql_connect can be mapped to mysqli_connect with some parameter swapping if no client_flags are used. If client_flags are used, mysqli_init()/mysqli_real_connect() are needed.'; + + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/CreateDB.php.svn-base b/Function/.svn/text-base/CreateDB.php.svn-base new file mode 100644 index 0000000..c474a0b --- /dev/null +++ b/Function/.svn/text-base/CreateDB.php.svn-base @@ -0,0 +1,63 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_CreateDB extends MySQLConverterTool_Function_Generic { + + + // not used, but anyway + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_create_db ( string database_name [, resource link_identifier] ) + + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($db, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + list($db, $db_type) = $this->extractValueAndType(trim($db)); + + if ('const' == $db_type) { + $ret = sprintf('((is_null($___mysqli_res = %s(%s, "CREATE DATABASE " . constant(\'%s\')))) ? false : $___mysqli_res)', + $this->new_name, + $conn, + $db + ); + } else { + $ret = sprintf('((is_null($___mysqli_res = %s(%s, "CREATE DATABASE %s"))) ? false : $___mysqli_res)', + $this->new_name, + $conn, + $db + ); + } + + return array('mysql_create_db(string database_name [...]) is emulated using mysqli_query() and CREATE DATABASE database_name. This is a possible SQL injection security bug as no tests are performed what value database_name has. Check your script!', $ret); + } + + function getConversionHint() { + + return 'Emulated using mysqli_query and CREATE DATABASE.'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/DBQuery.php.svn-base b/Function/.svn/text-base/DBQuery.php.svn-base new file mode 100644 index 0000000..dd6eb86 --- /dev/null +++ b/Function/.svn/text-base/DBQuery.php.svn-base @@ -0,0 +1,61 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_DBQuery extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_db_query ( string database, string query [, resource link_identifier] ) + if (count($params) < 2 || count($params) > 3) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($new_db, $query, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + list($new_db, $new_db_type) = $this->extractValueAndType(trim($new_db)); + if ('const' == $new_db_type) { + $ret = sprintf('((mysqli_query(%s, "USE " . constant(\'%s\'))) ? mysqli_query(%s, %s) : false)', + $conn, + $new_db, + $conn, + $query); + } else { + $ret = sprintf('((mysqli_query(%s, "USE %s")) ? mysqli_query(%s, %s) : false)', + $conn, + $new_db, + $conn, + $query); + } + + return array('mysql_db_query(string database_name [...]) is emulated using mysqli_query() and USE database_name. This is a possible SQL injection security bug as no tests are performed what value database_name has. Check your script!', $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query and USE.'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/DropDB.php.svn-base b/Function/.svn/text-base/DropDB.php.svn-base new file mode 100644 index 0000000..3870d01 --- /dev/null +++ b/Function/.svn/text-base/DropDB.php.svn-base @@ -0,0 +1,62 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_DropDB extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_drop_db ( string database_name [, resource link_identifier] ) + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($db, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + list($db, $db_type) = $this->extractValueAndType(trim($db)); + + if ('const' == $db_type) { + $ret = sprintf('((is_null($___mysqli_res = %s(%s, "DROP DATABASE " . constant(\'%s\')))) ? false : $___mysqli_res)', + $this->new_name, + $conn, + $db + ); + } else { + $ret = sprintf('((is_null($___mysqli_res = %s(%s, "DROP DATABASE %s"))) ? false : $___mysqli_res)', + $this->new_name, + $conn, + $db + ); + } + + return array('mysql_drop_db(string database_name [...]) is emulated using mysqli_query() and DROP DATABASE database_name. This is a possible SQL injection security bug as no tests are performed what value database_name has. Check your script!', $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query and DROP DATABASE.'; + } + + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/Error.php.svn-base b/Function/.svn/text-base/Error.php.svn-base new file mode 100644 index 0000000..9d0d821 --- /dev/null +++ b/Function/.svn/text-base/Error.php.svn-base @@ -0,0 +1,45 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ + +class MySQLConverterTool_Function_Error extends MySQLConverterTool_Function_Generic { + + function handle(Array $params = array()) { + + if (count($params) > 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($conn) = $this->extractParamValues($params); + if (is_null($conn)) { + $warning = 'mysql_error()/mysql_errno() can be called without a connection handle, mysqli_error()/mysqli_errno() not. As we do not know if a default connection has been opened, we have wrapped the function call in (() ? mysqli_() : mysqli_connect_error()/mysqli_connect_errno()). This is not 100% the same as the original code in all cases. Check the generated code!'; + $conn = $this->ston_name; + } else { + $warning = null; + } + if ('mysqli_error' == $this->new_name) + $ret = sprintf('((is_object(%s)) ? %s(%s) : (($___mysqli_res = mysqli_connect_error()) ? $___mysqli_res : false))', $conn, $this->new_name, $conn); + else + $ret = sprintf('((is_object(%s)) ? %s(%s) : (($___mysqli_res = mysqli_connect_errno()) ? $___mysqli_res : false))', $conn, $this->new_name, $conn); + + return array($warning, $ret); + } + + function getConversionHint() { + + return 'mysql_error()/mysql_errno() do not require a connection handle. When using the default connection for mysqli_error()/mysqli_errno() we throw a warning. We do not know for sure if a connection exists and add some extra code for the case it does not exist.'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/EscapeString.php.svn-base b/Function/.svn/text-base/EscapeString.php.svn-base new file mode 100644 index 0000000..5b892ff --- /dev/null +++ b/Function/.svn/text-base/EscapeString.php.svn-base @@ -0,0 +1,47 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_EscapeString extends MySQLConverterTool_Function_Generic { + + + function handle(Array $params = array()) { + + // mysql_escape_string ( string unescaped_string ) + + if (count($params) != 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($par1) = $this->extractParamValues($params); + $conn = $this->ston_name; + + $warning = 'WARNING: mysql_escape_string() is deprecated. If no global connection has been opened already the converter cannot use mysqli_real_escape_string() to emulate the function. We add a runtime test if a connection exists, if not trigger_error() gets used to throw an E_USER_ERROR. It would be a security bug to do anything else. You must fix our code manually!'; + $ret = sprintf('((isset(%s) && is_object(%s)) ? %s(%s, %s) : ((trigger_error("[MySQLConverterToo] Fix the mysql_escape_string() call! This code does not work.", E_USER_ERROR)) ? "" : ""))', + $conn, + $conn, + $this->new_name, + $conn, + $par1 + ); + + return array($warning, $ret); + } + + function getConversionHint() { + + return 'Emulated using mysqli_real_escape_string and the default connection. If not default connection exists an E_USER_ERROR gets thrown.'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/FetchField.php.svn-base b/Function/.svn/text-base/FetchField.php.svn-base new file mode 100644 index 0000000..183ea78 --- /dev/null +++ b/Function/.svn/text-base/FetchField.php.svn-base @@ -0,0 +1,147 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FetchField extends MySQLConverterTool_Function_Generic { + + public $new_name = "mysqli_fetch_field_direct"; + + + public function __construct() { + } + + function handle(Array $params = array()) { + + // object mysql_fetch_field ( resource result [, int field_offset] ) + // object mysqli_fetch_field_direct ( mysqli_result result, int fieldnr ) + + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($res, $offset) = $this->extractParamValues($params); + + + /* + [01] $f = f() && is_object($f) + [02] $f->primary_key = ($f->flags & MYSQLI_PRI_KEY_FLAG) ? 1 : 0 + [03] $f->multiple_key = ($f->flags & MYSQLI_MULTIPLE_KEY_FLAG) ? 1 : 0 + [04] $f->unique_key = ($f->flags & MYSQLI_UNIQUE_KEY_FLAG) ? 1 : 0 + + MySQL source! #define IS_NUM(t) ((t) <= FIELD_TYPE_INT24 || (t) == FIELD_TYPE_YEAR || (t) == FIELD_TYPE_NEWDECIMAL) + [05] $f->numeric = ($f->type <= MYSQLI_TYPE_INT24 || $f->fype == MYSQLI_TYPE_YEAR || ((defined('MYSQLI_TYPE_NEWDECIMAL')) ? ($f->type == MYSQLI_TYPE_NEWDECIMAL) : false) + + [06] $f->blob = (int)in_array($f->type, array(MYSQLI_TYPE_TINY_BLOB, MYSQLI_TYPE_BLOB, MYSQLI_TYPE_MEDIUM_BLOB, MYSQLI_TYPE_LONG_BLOB)) + + [07] $f->unsinged = ($f->flags & MYSQLI_UNSIGNED_FLAG) ? 1 : 0 + [08] $f->zerofill = ($f->flags & MYSQLI_ZEROFILL_FLAG) ? 1 : 0 + + [09] $type = $f->type + [10] $f->type = (($type == MYSQLI_TYPE_STRING) || ($type == MYSQLI_TYPE_VAR_STRING)) ? 'type' : '' + [11] $f->type = ("" == $f-type && in_array($___mysqli_tmp, array(MYSQLI_TYPE_TINY, MYSQLI_TYPE_SHORT, MYSQLI_TYPE_LONG, MYSQLI_TYPE_LONGLONG, MYSQLI_TYPE_INT24))) ? "int " : "" + [12] $f->type = ("" == $f-type && in_array($___mysqli_tmp, array(MYSQLI_TYPE_FLOAT, MYSQLI_TYPE_DOUBLE, MYSQLI_TYPE_DECIMAL, ((defined("MYSQLI_TYPE_NEWDECIMAL")) ? constant("MYSQLI_TYPE_NEWDECIMAL") : -1)))) ? "real " : "" + [13] $f->type = ("" == $f-type && $___mysqli_tmp == MYSQLI_TYPE_TIMESTAMP) ? "timestamp " : "" + [14] $f->type = ("" == $f-type && $___mysqli_tmp == MYSQLI_TYPE_YEAR) ? "year " : "" + [15] $f->type = ("" == $f-type && ($___mysqli_tmp == MYSQLI_TYPE_DATE) || ($___mysqli_tmp == MYSQLI_TYPE_NEWDATE)) ? "date " : "" + [16] $f->type = ("" == $f-type && $___mysqli_tmp == MYSQLI_TYPE_TIME) ? "time " : "" + [17] $f->type = ("" == $f-type && $___mysqli_tmp == MYSQLI_TYPE_SET) ? "set " : "" + [18] $f->type = ("" == $f-type && ($___mysqli_tmp == MYSQLI_TYPE_ENUM) ? "enum " : "" + [19] $f->type = ("" == $f-type && ($___mysqli_tmp == MYSQLI_TYPE_GEOMETRY) ? "geometry " : "" + [20] $f->type = ("" == $f-type && ($___mysqli_tmp == MYSQLI_TYPE_DATETIME) ? "datetime " : "" + [21] $f->type = ("" == $f-type && (in_array($___mysqli_tmp, array(MYSQLI_TYPE_TINY_BLOB, MYSQLI_TYPE_BLOB, MYSQLI_TYPE_MEDIUM_BLOB, MYSQLI_TYPE_LONG_BLOB))) ? "blob " : "" + [22] $f->type = ("" == $f-type && ($___mysqli_tmp == MYSQLI_TYPE_NULL) ? "null " : "unknown"; + + [23] $f->not_null = ($f->flags & MYSQLI_NOT_NULL_FLAG) ? 1 : 0 + + ( + ([01] && is_object($f) ? ( + !is_null([02]) && !is_null([03]) && !is_null([04]) && + !is_null([05]) && !is_null([06]) && !is_null([07]) && + !is_null([08]) && !is_null([09]) ... + ) : false) ? $___mysqli_tmp : false) + */ + + $warning = 'You should rewrite all your mysql_fetch_field() calls. The generated code should be compatible. But have a look at the generated code, it is unmaintainable! FIX your code!'; + + + $ret = '('; + $ret.= '('; + // [01] + $ret.= sprintf('(($___mysqli_tmp = mysqli_fetch_field_direct(%s, %s)) && is_object($___mysqli_tmp))', $res, + (is_null($offset)) ? sprintf('mysqli_field_tell(%s)', $res) : (int)$offset); + $ret.= ' ? ( '; + // [02] + $ret.= '(!is_null($___mysqli_tmp->primary_key = ($___mysqli_tmp->flags & MYSQLI_PRI_KEY_FLAG) ? 1 : 0)) && '; + // [03] + $ret.= '(!is_null($___mysqli_tmp->multiple_key = ($___mysqli_tmp->flags & MYSQLI_MULTIPLE_KEY_FLAG) ? 1 : 0)) && '; + // [04] + $ret.= '(!is_null($___mysqli_tmp->unique_key = ($___mysqli_tmp->flags & MYSQLI_UNIQUE_KEY_FLAG) ? 1 : 0)) && '; + // [05] + $ret.= '(!is_null($___mysqli_tmp->numeric = (int)(($___mysqli_tmp->type <= MYSQLI_TYPE_INT24) || ($___mysqli_tmp->type == MYSQLI_TYPE_YEAR) || ((defined("MYSQLI_TYPE_NEWDECIMAL")) ? ($___mysqli_tmp->type == MYSQLI_TYPE_NEWDECIMAL) : 0)))) && '; + // [06] + $ret.= '(!is_null($___mysqli_tmp->blob = (int)in_array($___mysqli_tmp->type, array(MYSQLI_TYPE_TINY_BLOB, MYSQLI_TYPE_BLOB, MYSQLI_TYPE_MEDIUM_BLOB, MYSQLI_TYPE_LONG_BLOB)))) && '; + // [07] + $ret.= '(!is_null($___mysqli_tmp->unsigned = ($___mysqli_tmp->flags & MYSQLI_UNSIGNED_FLAG) ? 1 : 0)) && '; + // [08] + $ret.= '(!is_null($___mysqli_tmp->zerofill = ($___mysqli_tmp->flags & MYSQLI_ZEROFILL_FLAG) ? 1 : 0)) && '; + // [09] + $ret.= '(!is_null($___mysqli_type = $___mysqli_tmp->type)) && '; + // [10] + $ret.= '(!is_null($___mysqli_tmp->type = (($___mysqli_type == MYSQLI_TYPE_STRING) || ($___mysqli_type == MYSQLI_TYPE_VAR_STRING)) ? "type" : "")) &&'; + // [11] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && in_array($___mysqli_type, array(MYSQLI_TYPE_TINY, MYSQLI_TYPE_SHORT, MYSQLI_TYPE_LONG, MYSQLI_TYPE_LONGLONG, MYSQLI_TYPE_INT24))) ? "int" : $___mysqli_tmp->type)) &&'; + // [12] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && in_array($___mysqli_type, array(MYSQLI_TYPE_FLOAT, MYSQLI_TYPE_DOUBLE, MYSQLI_TYPE_DECIMAL, ((defined("MYSQLI_TYPE_NEWDECIMAL")) ? constant("MYSQLI_TYPE_NEWDECIMAL") : -1)))) ? "real" : $___mysqli_tmp->type)) && '; + // [13] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_TIMESTAMP) ? "timestamp" : $___mysqli_tmp->type)) && '; + // [14] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_YEAR) ? "year" : $___mysqli_tmp->type)) && '; + // [15] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && (($___mysqli_type == MYSQLI_TYPE_DATE) || ($___mysqli_type == MYSQLI_TYPE_NEWDATE))) ? "date " : $___mysqli_tmp->type)) && '; + // [16] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_TIME) ? "time" : $___mysqli_tmp->type)) && '; + // [17] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_SET) ? "set" : $___mysqli_tmp->type)) &&'; + // [18] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_ENUM) ? "enum" : $___mysqli_tmp->type)) && '; + // [19] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_GEOMETRY) ? "geometry" : $___mysqli_tmp->type)) && '; + // [20] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_DATETIME) ? "datetime" : $___mysqli_tmp->type)) && '; + // [21] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && (in_array($___mysqli_type, array(MYSQLI_TYPE_TINY_BLOB, MYSQLI_TYPE_BLOB, MYSQLI_TYPE_MEDIUM_BLOB, MYSQLI_TYPE_LONG_BLOB)))) ? "blob" : $___mysqli_tmp->type)) && '; + // [22] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_NULL) ? "null" : $___mysqli_tmp->type)) && '; + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type) ? "unknown" : $___mysqli_tmp->type)) && '; + // [23] + $ret.= '(!is_null($___mysqli_tmp->not_null = ($___mysqli_tmp->flags & MYSQLI_NOT_NULL_FLAG) ? 1 : 0))'; + + $ret.= ' ) : false'; + $ret.= ' )'; + $ret.= ' ? $___mysqli_tmp : false)'; + + + return array($warning, $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_field_direct() and a conditional expression.'; + } + + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/FieldFlags.php.svn-base b/Function/.svn/text-base/FieldFlags.php.svn-base new file mode 100644 index 0000000..a3ea757 --- /dev/null +++ b/Function/.svn/text-base/FieldFlags.php.svn-base @@ -0,0 +1,92 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FieldFlags extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_fetch_field_direct'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // string mysql_field_flags ( resource result, int field_offset ) + // "not_null" NOT_NULL_FLAG MYSQLI_NOT_NULL_FLAG + // "primary_key" PRI_KEY_FLAG MYSQLI_PRI_KEY_FLAG + // "unique_key" UNIQUE_KEY_FLAG MYSQLI_UNIQUE_KEY_FLAG + // "multiple_key" MULTIPLE_KEY_FLAG MYSQLI_MULTIPLE_KEY_FLAG + // "blob" BLOB_FLAG MYSQLI_BLOB_FLAG + // "unsigned" UNSIGNED_FLAG MYSQLI_UNSIGNED_FLAG + // "zerofill" ZEROFILL_FLAG MYSQLI_ZEROFILL_FLAG + // "binary" BINARY_FLAG !!! + // "enum" ENUM_FLAG !!! + // "auto_increment" AUTO_INCREMENT_FLAG MYSQLI_AUTO_INCREMENT_FLAG + // "timestamp" TIMESTAMP_FLAG MYSQLI_TIMESTAMP_FLAG + // "set" SET_FLAG MYSQLI_SET_FLAG + + // object mysqli_fetch_field_direct ( mysqli_result result, int fieldnr ) + + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res, $i) = $this->extractParamValues($params); + + // (($__f = ) ? (string)((substr((($__f & FLAG_CONSTANT) ? 'flag_string' : '')) [. ()], -1)) : false) + // ----------- 1 ---------- ------------------- n --------------------------------------------------- ------- 3 -- + + // ----------- 1 ---------- + $ret = sprintf('(($___mysqli_tmp = %s(%s, %s)->flags) ? ', + $this->new_name, + $res, + $i + ); + + // ------------------- n ------------------------ + $ret .= '(string)(substr('; + $ret .= '(($___mysqli_tmp & MYSQLI_NOT_NULL_FLAG) ? "not_null " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_PRI_KEY_FLAG) ? "primary_key " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_UNIQUE_KEY_FLAG) ? "unique_key " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_MULTIPLE_KEY_FLAG) ? "unique_key " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_BLOB_FLAG) ? "blob " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_UNSIGNED_FLAG) ? "unsigned " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_ZEROFILL_FLAG) ? "zerofill " : "") . ' ; + // FIXME - Constants are missing in ext/mysqli, added to CVS on 20.07.2006 + $ret .= '(($___mysqli_tmp & 128) ? "binary " : "") . ' ; + $ret .= '(($___mysqli_tmp & 256) ? "enum " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_AUTO_INCREMENT_FLAG) ? "auto_increment " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_TIMESTAMP_FLAG) ? "timestamp " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_SET_FLAG) ? "set " : "")'; + $ret .= ', 0, -1)'; + + // ------- 3 -------------- + $ret .= ')'; + $ret .= ' : false)'; + + return array(NULL, $ret); + } + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_field_direct and a conditional espression.'; + } + + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/FieldLen.php.svn-base b/Function/.svn/text-base/FieldLen.php.svn-base new file mode 100644 index 0000000..2d9b2d3 --- /dev/null +++ b/Function/.svn/text-base/FieldLen.php.svn-base @@ -0,0 +1,48 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FieldLen extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_fetch_fields'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // int mysql_field_len ( resource result, int field_offset ) + // array mysqli_fetch_fields ( mysqli_result result ) + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res, $i) = $this->extractParamValues($params); + + return array(NULL, sprintf('((($___mysqli_tmp = mysqli_fetch_fields(%s)) && (isset($___mysqli_tmp[%d]))) ? $___mysqli_tmp[%d]->length : false)', + $res, + $i, + $i)); + } + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_fields().'; + } + + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/FieldName.php.svn-base b/Function/.svn/text-base/FieldName.php.svn-base new file mode 100644 index 0000000..895d013 --- /dev/null +++ b/Function/.svn/text-base/FieldName.php.svn-base @@ -0,0 +1,46 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FieldName extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_fetch_field_direct'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // string mysql_field_name ( resource result, int field_offset ) + // mysqli_fetch_field_direct ( mysqli_result result, int fieldnr ) + + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res, $i) = $this->extractParamValues($params); + + return array(NULL, sprintf('((($___mysqli_tmp = mysqli_fetch_field_direct(%s, %d)->name) && (!is_null($___mysqli_tmp))) ? $___mysqli_tmp : false)', $res, $i)); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_field_direct().'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/FieldTable.php.svn-base b/Function/.svn/text-base/FieldTable.php.svn-base new file mode 100644 index 0000000..f64223c --- /dev/null +++ b/Function/.svn/text-base/FieldTable.php.svn-base @@ -0,0 +1,47 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FieldTable extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_fetch_field_direct'; + + + public function __construct() + { + } + + + function handle(Array $params = array()) + { + // string mysql_field_table ( resource result, int field_offset ) + // object mysqli_fetch_field_direct ( mysqli_result result, int fieldnr ) + + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res, $i) = $this->extractParamValues($params); + + return array(NULL, "(mysqli_fetch_field_direct($res, $i)->table)"); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_field_direct().'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/FieldType.php.svn-base b/Function/.svn/text-base/FieldType.php.svn-base new file mode 100644 index 0000000..c79fb7c --- /dev/null +++ b/Function/.svn/text-base/FieldType.php.svn-base @@ -0,0 +1,89 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FieldType extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_fetch_field_direct'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // string mysql_field_type ( resource result, int field_offset ) + // object mysqli_fetch_field_direct ( mysqli_result result, int fieldnr ) + + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + /* + + The following types reported by ext/mysqli are not reported by ext/mysql: + + REGISTER_LONG_CONSTANT("MYSQLI_TYPE_CHAR", FIELD_TYPE_CHAR, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("MYSQLI_TYPE_INTERVAL", FIELD_TYPE_INTERVAL, CONST_CS | CONST_PERSISTENT); + #if MYSQL_VERSION_ID > 50002 + REGISTER_LONG_CONSTANT("MYSQLI_TYPE_BIT", FIELD_TYPE_BIT, CONST_CS | CONST_PERSISTENT); + #endif + */ + list($res, $i) = $this->extractParamValues($params); + + // (($__f = ->type) ? (string)((substr((($__f == FLAG_CONSTANT) ? 'flag_string' : '')) [. ()], -1) : false) + // (($__f = ->type) ? (string)((substr((( ($__f == FLAG_CONSTANT) || (...) ) ? 'flag_string ' : '')) [. ()], -1) : false) + // ----------- 1 ---------- ------------------- n ------------------------ ------- 3 -------------- + // refinement of 1: + // ((is_object($__f = ) && !is_null($__f = $f__->type)) ? + // refinement of n: + // ((($__f == substr()) == "") ? "unknown" : $__f) + + // ----------- 1 ---------- + $ret = '('; + $ret.= sprintf('(is_object($___mysqli_tmp = mysqli_fetch_field_direct(%s, %d)) && !is_null($___mysqli_tmp = $___mysqli_tmp->type)) ? ', $res, $i); + + // ------------------- n ------------------------ + $ret.= '((($___mysqli_tmp = '; + $ret.= '(string)(substr('; + $ret.= '( (($___mysqli_tmp == MYSQLI_TYPE_STRING) || ($___mysqli_tmp == MYSQLI_TYPE_VAR_STRING) ) ? "string " : "" ) . '; + $ret.= '( (in_array($___mysqli_tmp, array(MYSQLI_TYPE_TINY, MYSQLI_TYPE_SHORT, MYSQLI_TYPE_LONG, MYSQLI_TYPE_LONGLONG, MYSQLI_TYPE_INT24))) ? "int " : "" ) . '; + $ret.= '( (in_array($___mysqli_tmp, array(MYSQLI_TYPE_FLOAT, MYSQLI_TYPE_DOUBLE, MYSQLI_TYPE_DECIMAL, ((defined("MYSQLI_TYPE_NEWDECIMAL")) ? constant("MYSQLI_TYPE_NEWDECIMAL") : -1)))) ? "real " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_TIMESTAMP) ? "timestamp " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_YEAR) ? "year " : "" ) . '; + $ret.= '( (($___mysqli_tmp == MYSQLI_TYPE_DATE) || ($___mysqli_tmp == MYSQLI_TYPE_NEWDATE) ) ? "date " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_TIME) ? "time " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_SET) ? "set " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_ENUM) ? "enum " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_GEOMETRY) ? "geometry " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_DATETIME) ? "datetime " : "" ) . '; + $ret.= '( (in_array($___mysqli_tmp, array(MYSQLI_TYPE_TINY_BLOB, MYSQLI_TYPE_BLOB, MYSQLI_TYPE_MEDIUM_BLOB, MYSQLI_TYPE_LONG_BLOB))) ? "blob " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_NULL) ? "null " : "" )'; + $ret.= ', 0, -1))'; + $ret.= ') == "") ? "unknown" : $___mysqli_tmp)'; + + // ------- 3 -------------- + $ret.= ' : false)'; + + return array(NULL, $ret); + } + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_field_direct() and a conditional expression. The following types reported by ext/mysqli are not reposted by ext/mysql: MYSQLI_TYPE_CHAR, MYSQLI_TYPE_INTERVAL, MYSQLI_TYPE_BIT'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/FreeResult.php.svn-base b/Function/.svn/text-base/FreeResult.php.svn-base new file mode 100644 index 0000000..9dbd180 --- /dev/null +++ b/Function/.svn/text-base/FreeResult.php.svn-base @@ -0,0 +1,42 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FreeResult extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_free_result'; + + + public function __construct() { + } + + public function handle(Array $params = array()) { + + if (count($params) != 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res) = $this->extractParamValues($params); + + return array(NULL, sprintf('((mysqli_free_result(%s) || (is_object(%s) && (get_class(%s) == "mysqli_result"))) ? true : false)', $res, $res, $res)); + } + + + function getConversionHint() { + + return 'Emulated using a conditional expression and mysqli_free_result().'; + } + + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/Generic.php.svn-base b/Function/.svn/text-base/Generic.php.svn-base new file mode 100644 index 0000000..60216c6 --- /dev/null +++ b/Function/.svn/text-base/Generic.php.svn-base @@ -0,0 +1,152 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_Generic { + + /** + * + * @const PARSE_ERROR_WRONG_PARAMS + */ + const PARSE_ERROR_WRONG_PARAMS = 'Wrong parameter count. Function call not converted, resulting code is incomplete -- original code used. You must check your source!'; + + + // + // public + // + + /** + * New name of the converted function + * + * Used only for functions that have MySQLi counterpart that takes the same + * parameters as the originial MySQL extension function. + * + * + * @var string + */ + public $new_name; + + + /** + * Name of a variable holding the connection identifier of all functions that rely on default connections + * + * @var string + */ + public $ston_name = '$GLOBALS["___mysqli_ston"]'; + + + // + // public + // + + public function __construct($new_name, $ston_name = NULL) { + + $this->new_name = $new_name; + if (!is_null($ston_name)) + $this->ston_name = $ston_name; + + } + + + /* + * Try to use less concats - dots - in the output string + * + * @param string + * @param string + */ + public function smart_concat($par1, $par2) { + + if ($par2[0] !== '"' && $par2[0] !== "'") + return '"' . $par1 . '" . ' . $par2; + + return $par2[0] . $par1 . substr($par2, 1); + } + + + /** + * Returns a string with the functions call + * + * @param array list of parameters of the returned function call + */ + public function handle(Array $params = array()) { + + $params = $this->extractParamValues($params); + return array(NULL, $this->new_name."(".implode(", ", $params).")"); + } + + + /** + * Returns a string which describes who the conversion is done + * + * @return string + */ + public function getConversionHint() { + + return 'Using 1:1 counterpart from the MySQLi extension'; + } + + + /** + * Returns a PHP comment which describes how the conversion is done + * + * @return string + */ + public function getConversionPHPComment() { + + $ret = wordwrap($this->getConversionHint(), 60); + $ret = explode("\n", $ret); + $ret = "\n// [MySQL->MySQLi] " . implode("\n// [MySQL->MySQLi] ", $ret); + $ret .= "\n"; + + return $ret; + } + + // + // protected + // + + /** + * Extracts the parameter values from the parameter scanner hash + * + * @param array + * @return array + */ + protected function extractParamValues($params) { + + $ret = array(); + foreach ($params as $k => $param) { + $ret[] = $param['value']; + } + + return $ret; + } + + + /** + * + */ + protected function extractValueAndType($var) { + + $var_type = 'const'; + if ("" != $var && ($var[0] == '"' || $var[0] == "'") && $var[0] == substr($var, -1)) { + $var = substr($var, 1, -1); + $var_type = 'string_or_var'; + } + if ("" != ($tmp = trim($var)) && $tmp[0] == '$') { + $var_type = 'string_or_var'; + } + + return array($var, $var_type); + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/GenericBoolean.php.svn-base b/Function/.svn/text-base/GenericBoolean.php.svn-base new file mode 100644 index 0000000..d641e8f --- /dev/null +++ b/Function/.svn/text-base/GenericBoolean.php.svn-base @@ -0,0 +1,26 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_GenericBoolean extends MySQLConverterTool_Function_Generic { + + + public function handle(Array $params = array()) { + + $params = $this->extractParamValues($params); + return array(NULL, sprintf('(($___mysqli_tmp = %s(%s)) ? $___mysqli_tmp : false)', $this->new_name, implode(", ", $params))); + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/ListDBs.php.svn-base b/Function/.svn/text-base/ListDBs.php.svn-base new file mode 100644 index 0000000..30d2f1c --- /dev/null +++ b/Function/.svn/text-base/ListDBs.php.svn-base @@ -0,0 +1,45 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ListDBs extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_list_dbs ( [resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + if (count($params) > 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(NULL, sprintf('(($___mysqli_tmp = mysqli_query(%s, "SHOW DATABASES")) ? $___mysqli_tmp : false)', $conn)); + } + + function getConversionHint() { + + return 'Emulated using mysqli_query() and SHOW DATABASES. Returns NULL instead of false in case of an error'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/ListFields.php.svn-base b/Function/.svn/text-base/ListFields.php.svn-base new file mode 100644 index 0000000..004cef6 --- /dev/null +++ b/Function/.svn/text-base/ListFields.php.svn-base @@ -0,0 +1,66 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ListFields extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_list_fields ( string database_name, string table_name [, resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + + if (count($params) < 2 || count($params) > 3) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($db, $table, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + + list($db, $db_type) = $this->extractValueAndType(trim($db)); + list($table, $table_type) = $this->extractValueAndType(trim($table)); + + $sql = '"SHOW COLUMNS FROM '; + if ($db_type == 'const') + $sql .= '" . constant(\'' . $db . '\') . ".'; + else + $sql .= $db . '.'; + + if ($table_type == 'const') + $sql .= '" . constant(\'' . $table . '\')'; + else + $sql .= $table . '"'; + + $ret = sprintf('(($___mysqli_tmp = mysqli_query(%s, %s)) ? $___mysqli_tmp : false)', $conn, $sql); + + return array( + 'mysql_list_fields(string database_name, string table_name [...]) is emulated using mysqli_query() and SHOW COLUMNS FROM database_name.table_name . This is a possible SQL injection security bug as no tests are performed what value database_name and/or table_name have. Check your script! Additionally, this is not fully compatible to the original expression, check the mysql_list_fields() documentation on php.net!', $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query() and SHOW COLUMNS FROM table'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/ListProcesses.php.svn-base b/Function/.svn/text-base/ListProcesses.php.svn-base new file mode 100644 index 0000000..a771a93 --- /dev/null +++ b/Function/.svn/text-base/ListProcesses.php.svn-base @@ -0,0 +1,48 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ListProcesses extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // resource mysql_list_processes ( [resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + + if (count($params) > 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(NULL, sprintf('mysqli_query(%s, "SHOW PROCESSLIST")', $conn)); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query() and SHOW PROCESSLIST.'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/ListTables.php.svn-base b/Function/.svn/text-base/ListTables.php.svn-base new file mode 100644 index 0000000..03d7e3d --- /dev/null +++ b/Function/.svn/text-base/ListTables.php.svn-base @@ -0,0 +1,54 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ListTables extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_list_tables ( string database [, resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($db, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + list($db, $db_type) = $this->extractValueAndType(trim($db)); + if ('const' == $db_type) { + $ret = sprintf('mysqli_query(%s, "SHOW TABLES FROM " . constant(\'%s\'))', $conn, $db); + } else { + $ret = sprintf('mysqli_query(%s, "SHOW TABLES FROM %s")', $conn, $db); + } + + return array('mysql_list_tables(string database_name [...]) is emulated using mysqli_query() and SHOW TABLES FROM database_name. This is a possible SQL injection security bug as no tests are performed what value database_name has. Check your script!', $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query() and SHOW TABLES FROM.'; + } +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/ParReversed.php.svn-base b/Function/.svn/text-base/ParReversed.php.svn-base new file mode 100644 index 0000000..4ed81c9 --- /dev/null +++ b/Function/.svn/text-base/ParReversed.php.svn-base @@ -0,0 +1,41 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ParReversed extends MySQLConverterTool_Function_Generic { + + + function handle(Array $params = array()) { + + // mysql_query ( string query [, resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($par1, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(NULL, "$this->new_name($conn, $par1)"); + } + + + function getConversionHint() { + + return 'Generic function for: mysql_func(param1, param2) => mysqli_func(param2, param1). Currently used for mysql_query(), mysql_real_escape_string()'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/RealEscapeString.php.svn-base b/Function/.svn/text-base/RealEscapeString.php.svn-base new file mode 100644 index 0000000..ba4085f --- /dev/null +++ b/Function/.svn/text-base/RealEscapeString.php.svn-base @@ -0,0 +1,59 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_RealEscapeString extends MySQLConverterTool_Function_Generic { + + + function handle(Array $params = array()) { + + // string mysql_real_escape_string ( string unescaped_string [, resource link_identifier] ) + // string mysqli_real_escape_string ( mysqli link, string escapestr ) + + if (count($params) == 1) { + + list($string) = $this->extractParamValues($params); + $conn = $this->ston_name; + $warning = 'If no global connection has been opened already the converter cannot use mysqli_real_escape_string() to emulate the function. We add a runtime test if a connection exists, if not trigger_error() gets used to throw an E_USER_ERROR. It would be a security bug to do anything else. You must fix our code manually!'; + $ret = sprintf('((isset(%s) && is_object(%s)) ? %s(%s, %s) : ((trigger_error("[MySQLConverterToo] Fix the mysql_escape_string() call! This code does not work.", E_USER_ERROR)) ? "" : ""))', + $conn, + $conn, + $this->new_name, + $conn, + $string + ); + + } else if (count($params) == 2) { + + list($string, $conn) = @$this->extractParamValues($params); + $warning = null; + $ret = sprintf('%s(%s, %s)', $this->new_name, $conn, $string); + + } else { + + $warning = self::PARSE_ERROR_WRONG_PARAMS; + $ret = null; + + } + + return array($warning, $ret); + } + + function getConversionHint() { + + return 'Emulated using mysqli_real_escape_string and the default connection if no connection is given. If no default connection exists an E_USER_ERROR gets thrown.'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/SelectDB.php.svn-base b/Function/.svn/text-base/SelectDB.php.svn-base new file mode 100644 index 0000000..7bf4446 --- /dev/null +++ b/Function/.svn/text-base/SelectDB.php.svn-base @@ -0,0 +1,56 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_SelectDB extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // bool mysql_select_db ( string database_name [, resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($db, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + list($db, $db_type) = $this->extractValueAndType(trim($db)); + if ('const' == $db_type) { + $ret = sprintf('((bool)mysqli_query(%s, "USE " . constant(\'%s\')))', $conn, $db); + } else { + $ret = sprintf('((bool)mysqli_query(%s, "USE %s"))', $conn, $db); + } + + return array('mysql_select_db(string database_name [...]) is emulated using mysqli_query() and USE database_name. This is a possible SQL injection security bug as no tests are performed what value database_name has. Check your script!', $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query() and USE.'; + } + + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/Tablename.php.svn-base b/Function/.svn/text-base/Tablename.php.svn-base new file mode 100644 index 0000000..50c313a --- /dev/null +++ b/Function/.svn/text-base/Tablename.php.svn-base @@ -0,0 +1,45 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_Tablename extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_fetch_row'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_db_name ( resource result, int row [, mixed field] ) + // string mysql_tablename ( resource result, int i ) + + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res, $i) = $this->extractParamValues($params); + + return array(NULL, sprintf('((mysqli_data_seek(%s, %s) && (($___mysqli_tmp = mysqli_fetch_row(%s)) !== NULL)) ? array_shift($___mysqli_tmp) : false)', $res, $i, $res)); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_data_seek(), mysqli_fetch_row() and a conditional expression.'; + } + +} +?> \ No newline at end of file diff --git a/Function/.svn/text-base/UnbufferedQuery.php.svn-base b/Function/.svn/text-base/UnbufferedQuery.php.svn-base new file mode 100644 index 0000000..d94e509 --- /dev/null +++ b/Function/.svn/text-base/UnbufferedQuery.php.svn-base @@ -0,0 +1,48 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_UnbufferedQuery extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_unbuffered_query ( string query [, resource link_identifier] ) + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($q, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(null, "mysqli_query($conn, $q, MYSQLI_USE_RESULT)"); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query and MYSQLI_USE_RESULT.'; + } + + +} +?> \ No newline at end of file diff --git a/Function/.svn/wcprops/ChangeUser.php.svn-work b/Function/.svn/wcprops/ChangeUser.php.svn-work new file mode 100644 index 0000000..6e7f11b --- /dev/null +++ b/Function/.svn/wcprops/ChangeUser.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 81 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/ChangeUser.php +END diff --git a/Function/.svn/wcprops/ConnParam.php.svn-work b/Function/.svn/wcprops/ConnParam.php.svn-work new file mode 100644 index 0000000..5a1b71d --- /dev/null +++ b/Function/.svn/wcprops/ConnParam.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 80 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/ConnParam.php +END diff --git a/Function/.svn/wcprops/ConnParamBool.php.svn-work b/Function/.svn/wcprops/ConnParamBool.php.svn-work new file mode 100644 index 0000000..067adc5 --- /dev/null +++ b/Function/.svn/wcprops/ConnParamBool.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 84 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/ConnParamBool.php +END diff --git a/Function/.svn/wcprops/Connect.php.svn-work b/Function/.svn/wcprops/Connect.php.svn-work new file mode 100644 index 0000000..c23cb0c --- /dev/null +++ b/Function/.svn/wcprops/Connect.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 78 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/Connect.php +END diff --git a/Function/.svn/wcprops/CreateDB.php.svn-work b/Function/.svn/wcprops/CreateDB.php.svn-work new file mode 100644 index 0000000..f325c32 --- /dev/null +++ b/Function/.svn/wcprops/CreateDB.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 79 +/svnpublic/mysqli_converter/!svn/ver/8/MySQLConverterTool/Function/CreateDB.php +END diff --git a/Function/.svn/wcprops/DBQuery.php.svn-work b/Function/.svn/wcprops/DBQuery.php.svn-work new file mode 100644 index 0000000..c221413 --- /dev/null +++ b/Function/.svn/wcprops/DBQuery.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 79 +/svnpublic/mysqli_converter/!svn/ver/10/MySQLConverterTool/Function/DBQuery.php +END diff --git a/Function/.svn/wcprops/DropDB.php.svn-work b/Function/.svn/wcprops/DropDB.php.svn-work new file mode 100644 index 0000000..0a53e7a --- /dev/null +++ b/Function/.svn/wcprops/DropDB.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 77 +/svnpublic/mysqli_converter/!svn/ver/8/MySQLConverterTool/Function/DropDB.php +END diff --git a/Function/.svn/wcprops/Error.php.svn-work b/Function/.svn/wcprops/Error.php.svn-work new file mode 100644 index 0000000..ef26932 --- /dev/null +++ b/Function/.svn/wcprops/Error.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 77 +/svnpublic/mysqli_converter/!svn/ver/11/MySQLConverterTool/Function/Error.php +END diff --git a/Function/.svn/wcprops/EscapeString.php.svn-work b/Function/.svn/wcprops/EscapeString.php.svn-work new file mode 100644 index 0000000..b17ebb1 --- /dev/null +++ b/Function/.svn/wcprops/EscapeString.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 83 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/EscapeString.php +END diff --git a/Function/.svn/wcprops/FetchField.php.svn-work b/Function/.svn/wcprops/FetchField.php.svn-work new file mode 100644 index 0000000..2843073 --- /dev/null +++ b/Function/.svn/wcprops/FetchField.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 81 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/FetchField.php +END diff --git a/Function/.svn/wcprops/FieldFlags.php.svn-work b/Function/.svn/wcprops/FieldFlags.php.svn-work new file mode 100644 index 0000000..6e40307 --- /dev/null +++ b/Function/.svn/wcprops/FieldFlags.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 81 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/FieldFlags.php +END diff --git a/Function/.svn/wcprops/FieldLen.php.svn-work b/Function/.svn/wcprops/FieldLen.php.svn-work new file mode 100644 index 0000000..20b3be0 --- /dev/null +++ b/Function/.svn/wcprops/FieldLen.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 79 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/FieldLen.php +END diff --git a/Function/.svn/wcprops/FieldName.php.svn-work b/Function/.svn/wcprops/FieldName.php.svn-work new file mode 100644 index 0000000..1f85da0 --- /dev/null +++ b/Function/.svn/wcprops/FieldName.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 80 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/FieldName.php +END diff --git a/Function/.svn/wcprops/FieldTable.php.svn-work b/Function/.svn/wcprops/FieldTable.php.svn-work new file mode 100644 index 0000000..d8a5c1f --- /dev/null +++ b/Function/.svn/wcprops/FieldTable.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 81 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/FieldTable.php +END diff --git a/Function/.svn/wcprops/FieldType.php.svn-work b/Function/.svn/wcprops/FieldType.php.svn-work new file mode 100644 index 0000000..d8ce28e --- /dev/null +++ b/Function/.svn/wcprops/FieldType.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 80 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/FieldType.php +END diff --git a/Function/.svn/wcprops/FreeResult.php.svn-work b/Function/.svn/wcprops/FreeResult.php.svn-work new file mode 100644 index 0000000..77e44c9 --- /dev/null +++ b/Function/.svn/wcprops/FreeResult.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 81 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/FreeResult.php +END diff --git a/Function/.svn/wcprops/Generic.php.svn-work b/Function/.svn/wcprops/Generic.php.svn-work new file mode 100644 index 0000000..82dcbb6 --- /dev/null +++ b/Function/.svn/wcprops/Generic.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 78 +/svnpublic/mysqli_converter/!svn/ver/8/MySQLConverterTool/Function/Generic.php +END diff --git a/Function/.svn/wcprops/GenericBoolean.php.svn-work b/Function/.svn/wcprops/GenericBoolean.php.svn-work new file mode 100644 index 0000000..ecef9ed --- /dev/null +++ b/Function/.svn/wcprops/GenericBoolean.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 85 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/GenericBoolean.php +END diff --git a/Function/.svn/wcprops/ListDBs.php.svn-work b/Function/.svn/wcprops/ListDBs.php.svn-work new file mode 100644 index 0000000..8c9bdf1 --- /dev/null +++ b/Function/.svn/wcprops/ListDBs.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 78 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/ListDBs.php +END diff --git a/Function/.svn/wcprops/ListFields.php.svn-work b/Function/.svn/wcprops/ListFields.php.svn-work new file mode 100644 index 0000000..17b6a45 --- /dev/null +++ b/Function/.svn/wcprops/ListFields.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 81 +/svnpublic/mysqli_converter/!svn/ver/8/MySQLConverterTool/Function/ListFields.php +END diff --git a/Function/.svn/wcprops/ListProcesses.php.svn-work b/Function/.svn/wcprops/ListProcesses.php.svn-work new file mode 100644 index 0000000..8cb3eda --- /dev/null +++ b/Function/.svn/wcprops/ListProcesses.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 84 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/ListProcesses.php +END diff --git a/Function/.svn/wcprops/ListTables.php.svn-work b/Function/.svn/wcprops/ListTables.php.svn-work new file mode 100644 index 0000000..e78a3d2 --- /dev/null +++ b/Function/.svn/wcprops/ListTables.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 81 +/svnpublic/mysqli_converter/!svn/ver/8/MySQLConverterTool/Function/ListTables.php +END diff --git a/Function/.svn/wcprops/ParReversed.php.svn-work b/Function/.svn/wcprops/ParReversed.php.svn-work new file mode 100644 index 0000000..d57282e --- /dev/null +++ b/Function/.svn/wcprops/ParReversed.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 82 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/ParReversed.php +END diff --git a/Function/.svn/wcprops/RealEscapeString.php.svn-work b/Function/.svn/wcprops/RealEscapeString.php.svn-work new file mode 100644 index 0000000..6f74010 --- /dev/null +++ b/Function/.svn/wcprops/RealEscapeString.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 87 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/RealEscapeString.php +END diff --git a/Function/.svn/wcprops/SelectDB.php.svn-work b/Function/.svn/wcprops/SelectDB.php.svn-work new file mode 100644 index 0000000..3d205f1 --- /dev/null +++ b/Function/.svn/wcprops/SelectDB.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 79 +/svnpublic/mysqli_converter/!svn/ver/8/MySQLConverterTool/Function/SelectDB.php +END diff --git a/Function/.svn/wcprops/Tablename.php.svn-work b/Function/.svn/wcprops/Tablename.php.svn-work new file mode 100644 index 0000000..872467d --- /dev/null +++ b/Function/.svn/wcprops/Tablename.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 80 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/Tablename.php +END diff --git a/Function/.svn/wcprops/UnbufferedQuery.php.svn-work b/Function/.svn/wcprops/UnbufferedQuery.php.svn-work new file mode 100644 index 0000000..10de772 --- /dev/null +++ b/Function/.svn/wcprops/UnbufferedQuery.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 86 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/Function/UnbufferedQuery.php +END diff --git a/Function/ChangeUser.php b/Function/ChangeUser.php new file mode 100644 index 0000000..3e99d27 --- /dev/null +++ b/Function/ChangeUser.php @@ -0,0 +1,91 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ChangeUser extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_change_user'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_change_user ( string user, string password [, string database [, resource link_identifier]] ) + // mysqli_change_user ( mysqli link, string user, string password, string database ) + + $warning = NULL; + + if (4 == count($params)) { + + list($user, $pass, $db, $conn) = $this->extractParamValues($params); + $ret = "mysqli_change_user($conn, $user, $pass, $db)"; + + } else if (3 == count($params)) { + + list($user, $pass, $db) = $this->extractParamValues($params); + $conn = $this->ston_name; + $ret = "mysqli_change_user($conn, $user, $pass, $db)"; + + } else if (2 == count($params)) { + + list($user, $pass) = $this->extractParamValues($params); + $conn = $this->ston_name; + + // [1] $res = mysqli_query(conn, 'SELECT DATABASE()') + // [2] $row = mysqli_fetch_row($res); + // [3] $row = array_shift($row); + // [4] unset($row); + // [5] mysqli_free_result($res); + // [6] unset($res); + // [7] mysqli_change_user(conn, user, pass, $db) + // + // [1] ( ($res = mysqli_query() ) ? $db : false + // [2] ( ($res = mysqli_query() && row = mysqli_fetch_row($res)) ? $db : false + // [3] ( ($res = mysqli_query() && row = mysqli_fetch_row($res) && ((row = array_shift(row)) !== false) ) ? true : false + // [5] ( ($res = mysqli_query() && row = mysqli_fetch_row($res) && ((row = array_shift(row)) !== false) ) && mysqli_free_result(res) ) ? true : false + // [7] ( ($res = mysqli_query() && row = mysqli_fetch_row($res) && ((row = array_shift(row)) !== false) ) && mysqli_free_result(res) ) ? mysqli_change_user(conn, user, pass, $row) : false + + + $ret = '( '; + $ret.= '( '; + $ret.= '($___mysqli_res = mysqli_query(' . $conn . ', "SELECT DATABASE()")) && '; + $ret.= '($___mysqli_tmp = mysqli_fetch_row($___mysqli_res)) && '; + $ret.= '(($___mysqli_tmp = array_shift($___mysqli_tmp)) !== false) && '; + $ret.= '(mysqli_free_result($___mysqli_res)) '; + $ret.= ') ? '; + $ret.= sprintf('mysqli_change_user(%s, %s, %s, $___mysqli_tmp) : ', $conn, $user, $pass); + $ret.= 'false '; + $ret.= ')'; + + } else { + + $warning = self::PARSE_ERROR_WRONG_PARAMS; + $ret = NULL; + + } + + return array($warning, $ret); + } + + + function getConversionHint() { + + return 'mysql_change_user() can be translated into mysqli_change_user if the database is given. If not, it must be emulated using mysqli_query() and SELECT DATABASE() - which looks a bit like a hack.'; + } + +} +?> \ No newline at end of file diff --git a/Function/ConnParam.php b/Function/ConnParam.php new file mode 100644 index 0000000..4055a25 --- /dev/null +++ b/Function/ConnParam.php @@ -0,0 +1,36 @@ + mysqli_func(resource) +* +* @category Functions +* @package MySQLConverterTool +* @author Andrey Hristov , Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ConnParam extends MySQLConverterTool_Function_Generic { + + function handle(Array $params = array()) { + + if (count($params) > 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(NULL, "$this->new_name($conn)"); + } + + function getConversionHint() { + + return 'Generic class for all functions that look like mysql_foo([]) -> mysqli_bar()'; + } + +} +?> \ No newline at end of file diff --git a/Function/ConnParamBool.php b/Function/ConnParamBool.php new file mode 100644 index 0000000..074efff --- /dev/null +++ b/Function/ConnParamBool.php @@ -0,0 +1,37 @@ + ((bool)mysqli_func(resource)) +* +* @category Functions +* @package MySQLConverterTool +* @author Andrey Hristov , Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ConnParamBool extends MySQLConverterTool_Function_Generic { + + + function handle(Array $params = array()) { + + if (count($params) > 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(NULL, '((is_null($___mysqli_res = ' . $this->new_name . '(' . $conn . '))) ? false : $___mysqli_res)'); + } + + function getConversionHint() { + + return 'Generic class for all functions that look like mysql_foo([]) -> ((bool)mysqli_bar())'; + } + +} +?> \ No newline at end of file diff --git a/Function/Connect.php b/Function/Connect.php new file mode 100644 index 0000000..257b00e --- /dev/null +++ b/Function/Connect.php @@ -0,0 +1,203 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_Connect extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_connect'; + + + public function __construct() { + } + + function handle(Array $params = array()) { + static $last_params = array(); + + /* + Known deficiencies: + - will try to handle unix_socket but not the best solution + */ + + // mysql_connect ( [string server [, string username [, string password [, bool new_link [, int client_flags]]]]] ) + // mysql_pconnect ( [string server [, string username [, string password [, int client_flags]]]] ) + // mysqli_connect ( [string host [, string username [, string passwd [, string dbname [, int port [, string socket]]]]]] ) + + $warning = NULL; + $socket = NULL; + $port = NULL; + + @list($server, $user, $password, $new_link, $client_flags) = $this->extractParamValues($params); + if (!is_null($server)) { + if ($params[0]['dynamic']) { + $warning = 'Cannot analyze server parameter to extract host, socket and port! Conversion cannot be performed automatically. You must manually check the result of the conversion.'; + } else { + list($server, $socket, $port) = $this->expandServerParam($server); + } + } + + $found = false; + if (is_null($new_link) || ($new_link == false)) { + // Maybe someone relies on: + // If a second call is made to mysql_connect() with the same arguments, + // no new link will be established, but instead, the link identifier of the already + // opened link will be returned. The new_link parameter modifies this behavior + // and makes mysql_connect() always open a new link, even if mysql_connect() + // was called before with the same parameters. + // The current converter version cannot catch this. All we can do is throw a warning + + foreach ($last_params as $k => $lparams) { + if ($params == $lparams) { + $warning .= " You're calling mysql_connect() twice with the same parameters. We don't know for sure if you want a new connection or reuse the old connection. You must check your code."; + $found = true; + break; + } + } + + } + if (!$found) + $last_params[] = $params; + + + $dbname = 'NULL'; + $ret = NULL; + $num_params = count($params); + + if ($num_params < 5) { + + if (!is_null($socket)) { + + $ret = sprintf('(%s = %s(%s, %s, %s, %s, %d, \'%s\'))', + $this->ston_name, + $this->new_name, + is_null($server) ? 'NULL' : $server, + is_null($user) ? 'NULL' : $user, + is_null($password) ? 'NULL' : $password, + is_null($dbname) ? 'NULL' : $dbname, + is_null($port) ? 'NULL' : $port, + $socket); + } else { + + if (is_null($server)) { + // mysql_connect() + $ret = sprintf('(%s = %s())', + $this->ston_name, + $this->new_name); + + } else if (!is_null($port)) { + // port used - no chance to generate pretty code + + $ret = sprintf('(%s = %s(%s, %s, %s, %s, %d))', + $this->ston_name, + $this->new_name, + is_null($server) ? 'NULL' : $server, + is_null($user) ? 'NULL' : $user, + is_null($password) ? 'NULL' : $password, + is_null($dbname) ? 'NULL' : $dbname, + $port + ); + + } else if (!is_null($password)) { + + // mysql_connect(, , ) + $ret = sprintf('(%s = %s(%s, %s, %s))', + $this->ston_name, + $this->new_name, + is_null($server) ? 'NULL' : $server, + is_null($user) ? 'NULL' : $user, + $password); + + } else if (!is_null($user)) { + // mysql_connect(, + $ret = sprintf('(%s = %s(%s, %s))', + $this->ston_name, + $this->new_name, + is_null($server) ? 'NULL' : $server, + $user); + + } else { + // mysql_connect() but not mysql_connect() + + $ret = sprintf('(%s = %s(%s))', + $this->ston_name, + $this->new_name, + $server); + + } + + } + + } else if ($num_params == 5) { + + $ret = sprintf('(((%s = mysqli_init()) && (mysqli_real_connect(%s, %s, %s, %s, %s, %d, %s, %s))) ? %s : FALSE)', + $this->ston_name, + $this->ston_name, + $server, + $user, + $password, + $dbname, + is_null($port) ? 3306 : $port, + is_null($socket) ? 'NULL' : $socket, + $client_flags, + $this->ston_name); + + } else { + // too many parameters + + $warning = self::PARSE_ERROR_WRONG_PARAMS; + $ret = NULL; + + } + + return array($warning, $ret); + } + + + protected function expandServerParam($server) { + + $socket = NULL; + $port = NULL; + + $pos = strpos($server, ':/'); + if (FALSE !== $pos) { + // Unix Socket + + $first_ch = $server[0]; + $last_ch = substr($server, -1, 1); + + if (($last_ch == '"' || $last_ch == "'") && $last_ch == $first_ch) { + $server = substr($server, 1, -1); + } + + $socket = substr($server, $pos + 1); + $server = '"localhost"'; + + } else if (preg_match('/(["\']*)([^:]+):(\d+)/iu', $server, $matches)) { + // host:port + + $server = $matches[1] . $matches[2] . $matches[1]; + $port = $matches[3]; + + } + + return array($server, $socket, $port); + } + + function getConversionHint() { + + return 'mysql_connect can be mapped to mysqli_connect with some parameter swapping if no client_flags are used. If client_flags are used, mysqli_init()/mysqli_real_connect() are needed.'; + + } + +} +?> \ No newline at end of file diff --git a/Function/CreateDB.php b/Function/CreateDB.php new file mode 100644 index 0000000..734179d --- /dev/null +++ b/Function/CreateDB.php @@ -0,0 +1,63 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_CreateDB extends MySQLConverterTool_Function_Generic { + + + // not used, but anyway + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_create_db ( string database_name [, resource link_identifier] ) + + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($db, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + list($db, $db_type) = $this->extractValueAndType(trim($db)); + + if ('const' == $db_type) { + $ret = sprintf('((is_null($___mysqli_res = %s(%s, "CREATE DATABASE " . constant(\'%s\')))) ? false : $___mysqli_res)', + $this->new_name, + $conn, + $db + ); + } else { + $ret = sprintf('((is_null($___mysqli_res = %s(%s, "CREATE DATABASE %s"))) ? false : $___mysqli_res)', + $this->new_name, + $conn, + $db + ); + } + + return array('mysql_create_db(string database_name [...]) is emulated using mysqli_query() and CREATE DATABASE database_name. This is a possible SQL injection security bug as no tests are performed what value database_name has. Check your script!', $ret); + } + + function getConversionHint() { + + return 'Emulated using mysqli_query and CREATE DATABASE.'; + } + +} +?> \ No newline at end of file diff --git a/Function/DBQuery.php b/Function/DBQuery.php new file mode 100644 index 0000000..9fb94e0 --- /dev/null +++ b/Function/DBQuery.php @@ -0,0 +1,61 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_DBQuery extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_db_query ( string database, string query [, resource link_identifier] ) + if (count($params) < 2 || count($params) > 3) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($new_db, $query, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + list($new_db, $new_db_type) = $this->extractValueAndType(trim($new_db)); + if ('const' == $new_db_type) { + $ret = sprintf('((mysqli_query(%s, "USE " . constant(\'%s\'))) ? mysqli_query(%s, %s) : false)', + $conn, + $new_db, + $conn, + $query); + } else { + $ret = sprintf('((mysqli_query(%s, "USE %s")) ? mysqli_query(%s, %s) : false)', + $conn, + $new_db, + $conn, + $query); + } + + return array('mysql_db_query(string database_name [...]) is emulated using mysqli_query() and USE database_name. This is a possible SQL injection security bug as no tests are performed what value database_name has. Check your script!', $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query and USE.'; + } + +} +?> \ No newline at end of file diff --git a/Function/DropDB.php b/Function/DropDB.php new file mode 100644 index 0000000..5f55afa --- /dev/null +++ b/Function/DropDB.php @@ -0,0 +1,62 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_DropDB extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_drop_db ( string database_name [, resource link_identifier] ) + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($db, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + list($db, $db_type) = $this->extractValueAndType(trim($db)); + + if ('const' == $db_type) { + $ret = sprintf('((is_null($___mysqli_res = %s(%s, "DROP DATABASE " . constant(\'%s\')))) ? false : $___mysqli_res)', + $this->new_name, + $conn, + $db + ); + } else { + $ret = sprintf('((is_null($___mysqli_res = %s(%s, "DROP DATABASE %s"))) ? false : $___mysqli_res)', + $this->new_name, + $conn, + $db + ); + } + + return array('mysql_drop_db(string database_name [...]) is emulated using mysqli_query() and DROP DATABASE database_name. This is a possible SQL injection security bug as no tests are performed what value database_name has. Check your script!', $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query and DROP DATABASE.'; + } + + +} +?> \ No newline at end of file diff --git a/Function/Error.php b/Function/Error.php new file mode 100644 index 0000000..ce46f38 --- /dev/null +++ b/Function/Error.php @@ -0,0 +1,45 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ + +class MySQLConverterTool_Function_Error extends MySQLConverterTool_Function_Generic { + + function handle(Array $params = array()) { + + if (count($params) > 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($conn) = $this->extractParamValues($params); + if (is_null($conn)) { + $warning = 'mysql_error()/mysql_errno() can be called without a connection handle, mysqli_error()/mysqli_errno() not. As we do not know if a default connection has been opened, we have wrapped the function call in (() ? mysqli_() : mysqli_connect_error()/mysqli_connect_errno()). This is not 100% the same as the original code in all cases. Check the generated code!'; + $conn = $this->ston_name; + } else { + $warning = null; + } + if ('mysqli_error' == $this->new_name) + $ret = sprintf('((is_object(%s)) ? %s(%s) : (($___mysqli_res = mysqli_connect_error()) ? $___mysqli_res : false))', $conn, $this->new_name, $conn); + else + $ret = sprintf('((is_object(%s)) ? %s(%s) : (($___mysqli_res = mysqli_connect_errno()) ? $___mysqli_res : false))', $conn, $this->new_name, $conn); + + return array($warning, $ret); + } + + function getConversionHint() { + + return 'mysql_error()/mysql_errno() do not require a connection handle. When using the default connection for mysqli_error()/mysqli_errno() we throw a warning. We do not know for sure if a connection exists and add some extra code for the case it does not exist.'; + } + +} +?> \ No newline at end of file diff --git a/Function/EscapeString.php b/Function/EscapeString.php new file mode 100644 index 0000000..4c0bb2e --- /dev/null +++ b/Function/EscapeString.php @@ -0,0 +1,47 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_EscapeString extends MySQLConverterTool_Function_Generic { + + + function handle(Array $params = array()) { + + // mysql_escape_string ( string unescaped_string ) + + if (count($params) != 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($par1) = $this->extractParamValues($params); + $conn = $this->ston_name; + + $warning = 'WARNING: mysql_escape_string() is deprecated. If no global connection has been opened already the converter cannot use mysqli_real_escape_string() to emulate the function. We add a runtime test if a connection exists, if not trigger_error() gets used to throw an E_USER_ERROR. It would be a security bug to do anything else. You must fix our code manually!'; + $ret = sprintf('((isset(%s) && is_object(%s)) ? %s(%s, %s) : ((trigger_error("[MySQLConverterToo] Fix the mysql_escape_string() call! This code does not work.", E_USER_ERROR)) ? "" : ""))', + $conn, + $conn, + $this->new_name, + $conn, + $par1 + ); + + return array($warning, $ret); + } + + function getConversionHint() { + + return 'Emulated using mysqli_real_escape_string and the default connection. If not default connection exists an E_USER_ERROR gets thrown.'; + } + +} +?> \ No newline at end of file diff --git a/Function/FetchField.php b/Function/FetchField.php new file mode 100644 index 0000000..5bcb463 --- /dev/null +++ b/Function/FetchField.php @@ -0,0 +1,147 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FetchField extends MySQLConverterTool_Function_Generic { + + public $new_name = "mysqli_fetch_field_direct"; + + + public function __construct() { + } + + function handle(Array $params = array()) { + + // object mysql_fetch_field ( resource result [, int field_offset] ) + // object mysqli_fetch_field_direct ( mysqli_result result, int fieldnr ) + + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($res, $offset) = $this->extractParamValues($params); + + + /* + [01] $f = f() && is_object($f) + [02] $f->primary_key = ($f->flags & MYSQLI_PRI_KEY_FLAG) ? 1 : 0 + [03] $f->multiple_key = ($f->flags & MYSQLI_MULTIPLE_KEY_FLAG) ? 1 : 0 + [04] $f->unique_key = ($f->flags & MYSQLI_UNIQUE_KEY_FLAG) ? 1 : 0 + + MySQL source! #define IS_NUM(t) ((t) <= FIELD_TYPE_INT24 || (t) == FIELD_TYPE_YEAR || (t) == FIELD_TYPE_NEWDECIMAL) + [05] $f->numeric = ($f->type <= MYSQLI_TYPE_INT24 || $f->fype == MYSQLI_TYPE_YEAR || ((defined('MYSQLI_TYPE_NEWDECIMAL')) ? ($f->type == MYSQLI_TYPE_NEWDECIMAL) : false) + + [06] $f->blob = (int)in_array($f->type, array(MYSQLI_TYPE_TINY_BLOB, MYSQLI_TYPE_BLOB, MYSQLI_TYPE_MEDIUM_BLOB, MYSQLI_TYPE_LONG_BLOB)) + + [07] $f->unsinged = ($f->flags & MYSQLI_UNSIGNED_FLAG) ? 1 : 0 + [08] $f->zerofill = ($f->flags & MYSQLI_ZEROFILL_FLAG) ? 1 : 0 + + [09] $type = $f->type + [10] $f->type = (($type == MYSQLI_TYPE_STRING) || ($type == MYSQLI_TYPE_VAR_STRING)) ? 'type' : '' + [11] $f->type = ("" == $f-type && in_array($___mysqli_tmp, array(MYSQLI_TYPE_TINY, MYSQLI_TYPE_SHORT, MYSQLI_TYPE_LONG, MYSQLI_TYPE_LONGLONG, MYSQLI_TYPE_INT24))) ? "int " : "" + [12] $f->type = ("" == $f-type && in_array($___mysqli_tmp, array(MYSQLI_TYPE_FLOAT, MYSQLI_TYPE_DOUBLE, MYSQLI_TYPE_DECIMAL, ((defined("MYSQLI_TYPE_NEWDECIMAL")) ? constant("MYSQLI_TYPE_NEWDECIMAL") : -1)))) ? "real " : "" + [13] $f->type = ("" == $f-type && $___mysqli_tmp == MYSQLI_TYPE_TIMESTAMP) ? "timestamp " : "" + [14] $f->type = ("" == $f-type && $___mysqli_tmp == MYSQLI_TYPE_YEAR) ? "year " : "" + [15] $f->type = ("" == $f-type && ($___mysqli_tmp == MYSQLI_TYPE_DATE) || ($___mysqli_tmp == MYSQLI_TYPE_NEWDATE)) ? "date " : "" + [16] $f->type = ("" == $f-type && $___mysqli_tmp == MYSQLI_TYPE_TIME) ? "time " : "" + [17] $f->type = ("" == $f-type && $___mysqli_tmp == MYSQLI_TYPE_SET) ? "set " : "" + [18] $f->type = ("" == $f-type && ($___mysqli_tmp == MYSQLI_TYPE_ENUM) ? "enum " : "" + [19] $f->type = ("" == $f-type && ($___mysqli_tmp == MYSQLI_TYPE_GEOMETRY) ? "geometry " : "" + [20] $f->type = ("" == $f-type && ($___mysqli_tmp == MYSQLI_TYPE_DATETIME) ? "datetime " : "" + [21] $f->type = ("" == $f-type && (in_array($___mysqli_tmp, array(MYSQLI_TYPE_TINY_BLOB, MYSQLI_TYPE_BLOB, MYSQLI_TYPE_MEDIUM_BLOB, MYSQLI_TYPE_LONG_BLOB))) ? "blob " : "" + [22] $f->type = ("" == $f-type && ($___mysqli_tmp == MYSQLI_TYPE_NULL) ? "null " : "unknown"; + + [23] $f->not_null = ($f->flags & MYSQLI_NOT_NULL_FLAG) ? 1 : 0 + + ( + ([01] && is_object($f) ? ( + !is_null([02]) && !is_null([03]) && !is_null([04]) && + !is_null([05]) && !is_null([06]) && !is_null([07]) && + !is_null([08]) && !is_null([09]) ... + ) : false) ? $___mysqli_tmp : false) + */ + + $warning = 'You should rewrite all your mysql_fetch_field() calls. The generated code should be compatible. But have a look at the generated code, it is unmaintainable! FIX your code!'; + + + $ret = '('; + $ret.= '('; + // [01] + $ret.= sprintf('(($___mysqli_tmp = mysqli_fetch_field_direct(%s, %s)) && is_object($___mysqli_tmp))', $res, + (is_null($offset)) ? sprintf('mysqli_field_tell(%s)', $res) : (int)$offset); + $ret.= ' ? ( '; + // [02] + $ret.= '(!is_null($___mysqli_tmp->primary_key = ($___mysqli_tmp->flags & MYSQLI_PRI_KEY_FLAG) ? 1 : 0)) && '; + // [03] + $ret.= '(!is_null($___mysqli_tmp->multiple_key = ($___mysqli_tmp->flags & MYSQLI_MULTIPLE_KEY_FLAG) ? 1 : 0)) && '; + // [04] + $ret.= '(!is_null($___mysqli_tmp->unique_key = ($___mysqli_tmp->flags & MYSQLI_UNIQUE_KEY_FLAG) ? 1 : 0)) && '; + // [05] + $ret.= '(!is_null($___mysqli_tmp->numeric = (int)(($___mysqli_tmp->type <= MYSQLI_TYPE_INT24) || ($___mysqli_tmp->type == MYSQLI_TYPE_YEAR) || ((defined("MYSQLI_TYPE_NEWDECIMAL")) ? ($___mysqli_tmp->type == MYSQLI_TYPE_NEWDECIMAL) : 0)))) && '; + // [06] + $ret.= '(!is_null($___mysqli_tmp->blob = (int)in_array($___mysqli_tmp->type, array(MYSQLI_TYPE_TINY_BLOB, MYSQLI_TYPE_BLOB, MYSQLI_TYPE_MEDIUM_BLOB, MYSQLI_TYPE_LONG_BLOB)))) && '; + // [07] + $ret.= '(!is_null($___mysqli_tmp->unsigned = ($___mysqli_tmp->flags & MYSQLI_UNSIGNED_FLAG) ? 1 : 0)) && '; + // [08] + $ret.= '(!is_null($___mysqli_tmp->zerofill = ($___mysqli_tmp->flags & MYSQLI_ZEROFILL_FLAG) ? 1 : 0)) && '; + // [09] + $ret.= '(!is_null($___mysqli_type = $___mysqli_tmp->type)) && '; + // [10] + $ret.= '(!is_null($___mysqli_tmp->type = (($___mysqli_type == MYSQLI_TYPE_STRING) || ($___mysqli_type == MYSQLI_TYPE_VAR_STRING)) ? "type" : "")) &&'; + // [11] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && in_array($___mysqli_type, array(MYSQLI_TYPE_TINY, MYSQLI_TYPE_SHORT, MYSQLI_TYPE_LONG, MYSQLI_TYPE_LONGLONG, MYSQLI_TYPE_INT24))) ? "int" : $___mysqli_tmp->type)) &&'; + // [12] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && in_array($___mysqli_type, array(MYSQLI_TYPE_FLOAT, MYSQLI_TYPE_DOUBLE, MYSQLI_TYPE_DECIMAL, ((defined("MYSQLI_TYPE_NEWDECIMAL")) ? constant("MYSQLI_TYPE_NEWDECIMAL") : -1)))) ? "real" : $___mysqli_tmp->type)) && '; + // [13] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_TIMESTAMP) ? "timestamp" : $___mysqli_tmp->type)) && '; + // [14] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_YEAR) ? "year" : $___mysqli_tmp->type)) && '; + // [15] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && (($___mysqli_type == MYSQLI_TYPE_DATE) || ($___mysqli_type == MYSQLI_TYPE_NEWDATE))) ? "date " : $___mysqli_tmp->type)) && '; + // [16] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_TIME) ? "time" : $___mysqli_tmp->type)) && '; + // [17] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_SET) ? "set" : $___mysqli_tmp->type)) &&'; + // [18] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_ENUM) ? "enum" : $___mysqli_tmp->type)) && '; + // [19] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_GEOMETRY) ? "geometry" : $___mysqli_tmp->type)) && '; + // [20] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_DATETIME) ? "datetime" : $___mysqli_tmp->type)) && '; + // [21] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && (in_array($___mysqli_type, array(MYSQLI_TYPE_TINY_BLOB, MYSQLI_TYPE_BLOB, MYSQLI_TYPE_MEDIUM_BLOB, MYSQLI_TYPE_LONG_BLOB)))) ? "blob" : $___mysqli_tmp->type)) && '; + // [22] + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type && $___mysqli_type == MYSQLI_TYPE_NULL) ? "null" : $___mysqli_tmp->type)) && '; + $ret.= '(!is_null($___mysqli_tmp->type = ("" == $___mysqli_tmp->type) ? "unknown" : $___mysqli_tmp->type)) && '; + // [23] + $ret.= '(!is_null($___mysqli_tmp->not_null = ($___mysqli_tmp->flags & MYSQLI_NOT_NULL_FLAG) ? 1 : 0))'; + + $ret.= ' ) : false'; + $ret.= ' )'; + $ret.= ' ? $___mysqli_tmp : false)'; + + + return array($warning, $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_field_direct() and a conditional expression.'; + } + + +} +?> \ No newline at end of file diff --git a/Function/FieldFlags.php b/Function/FieldFlags.php new file mode 100644 index 0000000..10c0722 --- /dev/null +++ b/Function/FieldFlags.php @@ -0,0 +1,92 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FieldFlags extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_fetch_field_direct'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // string mysql_field_flags ( resource result, int field_offset ) + // "not_null" NOT_NULL_FLAG MYSQLI_NOT_NULL_FLAG + // "primary_key" PRI_KEY_FLAG MYSQLI_PRI_KEY_FLAG + // "unique_key" UNIQUE_KEY_FLAG MYSQLI_UNIQUE_KEY_FLAG + // "multiple_key" MULTIPLE_KEY_FLAG MYSQLI_MULTIPLE_KEY_FLAG + // "blob" BLOB_FLAG MYSQLI_BLOB_FLAG + // "unsigned" UNSIGNED_FLAG MYSQLI_UNSIGNED_FLAG + // "zerofill" ZEROFILL_FLAG MYSQLI_ZEROFILL_FLAG + // "binary" BINARY_FLAG !!! + // "enum" ENUM_FLAG !!! + // "auto_increment" AUTO_INCREMENT_FLAG MYSQLI_AUTO_INCREMENT_FLAG + // "timestamp" TIMESTAMP_FLAG MYSQLI_TIMESTAMP_FLAG + // "set" SET_FLAG MYSQLI_SET_FLAG + + // object mysqli_fetch_field_direct ( mysqli_result result, int fieldnr ) + + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res, $i) = $this->extractParamValues($params); + + // (($__f = ) ? (string)((substr((($__f & FLAG_CONSTANT) ? 'flag_string' : '')) [. ()], -1)) : false) + // ----------- 1 ---------- ------------------- n --------------------------------------------------- ------- 3 -- + + // ----------- 1 ---------- + $ret = sprintf('(($___mysqli_tmp = %s(%s, %s)->flags) ? ', + $this->new_name, + $res, + $i + ); + + // ------------------- n ------------------------ + $ret .= '(string)(substr('; + $ret .= '(($___mysqli_tmp & MYSQLI_NOT_NULL_FLAG) ? "not_null " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_PRI_KEY_FLAG) ? "primary_key " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_UNIQUE_KEY_FLAG) ? "unique_key " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_MULTIPLE_KEY_FLAG) ? "unique_key " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_BLOB_FLAG) ? "blob " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_UNSIGNED_FLAG) ? "unsigned " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_ZEROFILL_FLAG) ? "zerofill " : "") . ' ; + // FIXME - Constants are missing in ext/mysqli, added to CVS on 20.07.2006 + $ret .= '(($___mysqli_tmp & 128) ? "binary " : "") . ' ; + $ret .= '(($___mysqli_tmp & 256) ? "enum " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_AUTO_INCREMENT_FLAG) ? "auto_increment " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_TIMESTAMP_FLAG) ? "timestamp " : "") . ' ; + $ret .= '(($___mysqli_tmp & MYSQLI_SET_FLAG) ? "set " : "")'; + $ret .= ', 0, -1)'; + + // ------- 3 -------------- + $ret .= ')'; + $ret .= ' : false)'; + + return array(NULL, $ret); + } + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_field_direct and a conditional espression.'; + } + + +} +?> \ No newline at end of file diff --git a/Function/FieldLen.php b/Function/FieldLen.php new file mode 100644 index 0000000..3d37526 --- /dev/null +++ b/Function/FieldLen.php @@ -0,0 +1,48 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FieldLen extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_fetch_fields'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // int mysql_field_len ( resource result, int field_offset ) + // array mysqli_fetch_fields ( mysqli_result result ) + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res, $i) = $this->extractParamValues($params); + + return array(NULL, sprintf('((($___mysqli_tmp = mysqli_fetch_fields(%s)) && (isset($___mysqli_tmp[%d]))) ? $___mysqli_tmp[%d]->length : false)', + $res, + $i, + $i)); + } + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_fields().'; + } + + +} +?> \ No newline at end of file diff --git a/Function/FieldName.php b/Function/FieldName.php new file mode 100644 index 0000000..c5c1507 --- /dev/null +++ b/Function/FieldName.php @@ -0,0 +1,46 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FieldName extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_fetch_field_direct'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // string mysql_field_name ( resource result, int field_offset ) + // mysqli_fetch_field_direct ( mysqli_result result, int fieldnr ) + + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res, $i) = $this->extractParamValues($params); + + return array(NULL, sprintf('((($___mysqli_tmp = mysqli_fetch_field_direct(%s, %d)->name) && (!is_null($___mysqli_tmp))) ? $___mysqli_tmp : false)', $res, $i)); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_field_direct().'; + } + +} +?> \ No newline at end of file diff --git a/Function/FieldTable.php b/Function/FieldTable.php new file mode 100644 index 0000000..64bac95 --- /dev/null +++ b/Function/FieldTable.php @@ -0,0 +1,47 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FieldTable extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_fetch_field_direct'; + + + public function __construct() + { + } + + + function handle(Array $params = array()) + { + // string mysql_field_table ( resource result, int field_offset ) + // object mysqli_fetch_field_direct ( mysqli_result result, int fieldnr ) + + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res, $i) = $this->extractParamValues($params); + + return array(NULL, "(mysqli_fetch_field_direct($res, $i)->table)"); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_field_direct().'; + } + +} +?> \ No newline at end of file diff --git a/Function/FieldType.php b/Function/FieldType.php new file mode 100644 index 0000000..66f5374 --- /dev/null +++ b/Function/FieldType.php @@ -0,0 +1,89 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FieldType extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_fetch_field_direct'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // string mysql_field_type ( resource result, int field_offset ) + // object mysqli_fetch_field_direct ( mysqli_result result, int fieldnr ) + + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + /* + + The following types reported by ext/mysqli are not reported by ext/mysql: + + REGISTER_LONG_CONSTANT("MYSQLI_TYPE_CHAR", FIELD_TYPE_CHAR, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("MYSQLI_TYPE_INTERVAL", FIELD_TYPE_INTERVAL, CONST_CS | CONST_PERSISTENT); + #if MYSQL_VERSION_ID > 50002 + REGISTER_LONG_CONSTANT("MYSQLI_TYPE_BIT", FIELD_TYPE_BIT, CONST_CS | CONST_PERSISTENT); + #endif + */ + list($res, $i) = $this->extractParamValues($params); + + // (($__f = ->type) ? (string)((substr((($__f == FLAG_CONSTANT) ? 'flag_string' : '')) [. ()], -1) : false) + // (($__f = ->type) ? (string)((substr((( ($__f == FLAG_CONSTANT) || (...) ) ? 'flag_string ' : '')) [. ()], -1) : false) + // ----------- 1 ---------- ------------------- n ------------------------ ------- 3 -------------- + // refinement of 1: + // ((is_object($__f = ) && !is_null($__f = $f__->type)) ? + // refinement of n: + // ((($__f == substr()) == "") ? "unknown" : $__f) + + // ----------- 1 ---------- + $ret = '('; + $ret.= sprintf('(is_object($___mysqli_tmp = mysqli_fetch_field_direct(%s, %d)) && !is_null($___mysqli_tmp = $___mysqli_tmp->type)) ? ', $res, $i); + + // ------------------- n ------------------------ + $ret.= '((($___mysqli_tmp = '; + $ret.= '(string)(substr('; + $ret.= '( (($___mysqli_tmp == MYSQLI_TYPE_STRING) || ($___mysqli_tmp == MYSQLI_TYPE_VAR_STRING) ) ? "string " : "" ) . '; + $ret.= '( (in_array($___mysqli_tmp, array(MYSQLI_TYPE_TINY, MYSQLI_TYPE_SHORT, MYSQLI_TYPE_LONG, MYSQLI_TYPE_LONGLONG, MYSQLI_TYPE_INT24))) ? "int " : "" ) . '; + $ret.= '( (in_array($___mysqli_tmp, array(MYSQLI_TYPE_FLOAT, MYSQLI_TYPE_DOUBLE, MYSQLI_TYPE_DECIMAL, ((defined("MYSQLI_TYPE_NEWDECIMAL")) ? constant("MYSQLI_TYPE_NEWDECIMAL") : -1)))) ? "real " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_TIMESTAMP) ? "timestamp " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_YEAR) ? "year " : "" ) . '; + $ret.= '( (($___mysqli_tmp == MYSQLI_TYPE_DATE) || ($___mysqli_tmp == MYSQLI_TYPE_NEWDATE) ) ? "date " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_TIME) ? "time " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_SET) ? "set " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_ENUM) ? "enum " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_GEOMETRY) ? "geometry " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_DATETIME) ? "datetime " : "" ) . '; + $ret.= '( (in_array($___mysqli_tmp, array(MYSQLI_TYPE_TINY_BLOB, MYSQLI_TYPE_BLOB, MYSQLI_TYPE_MEDIUM_BLOB, MYSQLI_TYPE_LONG_BLOB))) ? "blob " : "" ) . '; + $ret.= '( ($___mysqli_tmp == MYSQLI_TYPE_NULL) ? "null " : "" )'; + $ret.= ', 0, -1))'; + $ret.= ') == "") ? "unknown" : $___mysqli_tmp)'; + + // ------- 3 -------------- + $ret.= ' : false)'; + + return array(NULL, $ret); + } + + function getConversionHint() { + + return 'Emulated using mysqli_fetch_field_direct() and a conditional expression. The following types reported by ext/mysqli are not reposted by ext/mysql: MYSQLI_TYPE_CHAR, MYSQLI_TYPE_INTERVAL, MYSQLI_TYPE_BIT'; + } + +} +?> \ No newline at end of file diff --git a/Function/FreeResult.php b/Function/FreeResult.php new file mode 100644 index 0000000..d7012f8 --- /dev/null +++ b/Function/FreeResult.php @@ -0,0 +1,42 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_FreeResult extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_free_result'; + + + public function __construct() { + } + + public function handle(Array $params = array()) { + + if (count($params) != 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res) = $this->extractParamValues($params); + + return array(NULL, sprintf('((mysqli_free_result(%s) || (is_object(%s) && (get_class(%s) == "mysqli_result"))) ? true : false)', $res, $res, $res)); + } + + + function getConversionHint() { + + return 'Emulated using a conditional expression and mysqli_free_result().'; + } + + +} +?> \ No newline at end of file diff --git a/Function/Generic.php b/Function/Generic.php new file mode 100644 index 0000000..ab2537f --- /dev/null +++ b/Function/Generic.php @@ -0,0 +1,152 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_Generic { + + /** + * + * @const PARSE_ERROR_WRONG_PARAMS + */ + const PARSE_ERROR_WRONG_PARAMS = 'Wrong parameter count. Function call not converted, resulting code is incomplete -- original code used. You must check your source!'; + + + // + // public + // + + /** + * New name of the converted function + * + * Used only for functions that have MySQLi counterpart that takes the same + * parameters as the originial MySQL extension function. + * + * + * @var string + */ + public $new_name; + + + /** + * Name of a variable holding the connection identifier of all functions that rely on default connections + * + * @var string + */ + public $ston_name = '$GLOBALS["___mysqli_ston"]'; + + + // + // public + // + + public function __construct($new_name, $ston_name = NULL) { + + $this->new_name = $new_name; + if (!is_null($ston_name)) + $this->ston_name = $ston_name; + + } + + + /* + * Try to use less concats - dots - in the output string + * + * @param string + * @param string + */ + public function smart_concat($par1, $par2) { + + if ($par2[0] !== '"' && $par2[0] !== "'") + return '"' . $par1 . '" . ' . $par2; + + return $par2[0] . $par1 . substr($par2, 1); + } + + + /** + * Returns a string with the functions call + * + * @param array list of parameters of the returned function call + */ + public function handle(Array $params = array()) { + + $params = $this->extractParamValues($params); + return array(NULL, $this->new_name."(".implode(", ", $params).")"); + } + + + /** + * Returns a string which describes who the conversion is done + * + * @return string + */ + public function getConversionHint() { + + return 'Using 1:1 counterpart from the MySQLi extension'; + } + + + /** + * Returns a PHP comment which describes how the conversion is done + * + * @return string + */ + public function getConversionPHPComment() { + + $ret = wordwrap($this->getConversionHint(), 60); + $ret = explode("\n", $ret); + $ret = "\n// [MySQL->MySQLi] " . implode("\n// [MySQL->MySQLi] ", $ret); + $ret .= "\n"; + + return $ret; + } + + // + // protected + // + + /** + * Extracts the parameter values from the parameter scanner hash + * + * @param array + * @return array + */ + protected function extractParamValues($params) { + + $ret = array(); + foreach ($params as $k => $param) { + $ret[] = $param['value']; + } + + return $ret; + } + + + /** + * + */ + protected function extractValueAndType($var) { + + $var_type = 'const'; + if ("" != $var && ($var[0] == '"' || $var[0] == "'") && $var[0] == substr($var, -1)) { + $var = substr($var, 1, -1); + $var_type = 'string_or_var'; + } + if ("" != ($tmp = trim($var)) && $tmp[0] == '$') { + $var_type = 'string_or_var'; + } + + return array($var, $var_type); + } + +} +?> \ No newline at end of file diff --git a/Function/GenericBoolean.php b/Function/GenericBoolean.php new file mode 100644 index 0000000..15b48c2 --- /dev/null +++ b/Function/GenericBoolean.php @@ -0,0 +1,26 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_GenericBoolean extends MySQLConverterTool_Function_Generic { + + + public function handle(Array $params = array()) { + + $params = $this->extractParamValues($params); + return array(NULL, sprintf('(($___mysqli_tmp = %s(%s)) ? $___mysqli_tmp : false)', $this->new_name, implode(", ", $params))); + } + +} +?> \ No newline at end of file diff --git a/Function/ListDBs.php b/Function/ListDBs.php new file mode 100644 index 0000000..41ad3f9 --- /dev/null +++ b/Function/ListDBs.php @@ -0,0 +1,45 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ListDBs extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_list_dbs ( [resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + if (count($params) > 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(NULL, sprintf('(($___mysqli_tmp = mysqli_query(%s, "SHOW DATABASES")) ? $___mysqli_tmp : false)', $conn)); + } + + function getConversionHint() { + + return 'Emulated using mysqli_query() and SHOW DATABASES. Returns NULL instead of false in case of an error'; + } + +} +?> \ No newline at end of file diff --git a/Function/ListFields.php b/Function/ListFields.php new file mode 100644 index 0000000..b6bca34 --- /dev/null +++ b/Function/ListFields.php @@ -0,0 +1,66 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ListFields extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_list_fields ( string database_name, string table_name [, resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + + if (count($params) < 2 || count($params) > 3) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($db, $table, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + + list($db, $db_type) = $this->extractValueAndType(trim($db)); + list($table, $table_type) = $this->extractValueAndType(trim($table)); + + $sql = '"SHOW COLUMNS FROM '; + if ($db_type == 'const') + $sql .= '" . constant(\'' . $db . '\') . ".'; + else + $sql .= $db . '.'; + + if ($table_type == 'const') + $sql .= '" . constant(\'' . $table . '\')'; + else + $sql .= $table . '"'; + + $ret = sprintf('(($___mysqli_tmp = mysqli_query(%s, %s)) ? $___mysqli_tmp : false)', $conn, $sql); + + return array( + 'mysql_list_fields(string database_name, string table_name [...]) is emulated using mysqli_query() and SHOW COLUMNS FROM database_name.table_name . This is a possible SQL injection security bug as no tests are performed what value database_name and/or table_name have. Check your script! Additionally, this is not fully compatible to the original expression, check the mysql_list_fields() documentation on php.net!', $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query() and SHOW COLUMNS FROM table'; + } + +} +?> \ No newline at end of file diff --git a/Function/ListProcesses.php b/Function/ListProcesses.php new file mode 100644 index 0000000..b6a1cd8 --- /dev/null +++ b/Function/ListProcesses.php @@ -0,0 +1,48 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ListProcesses extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // resource mysql_list_processes ( [resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + + if (count($params) > 1) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(NULL, sprintf('mysqli_query(%s, "SHOW PROCESSLIST")', $conn)); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query() and SHOW PROCESSLIST.'; + } + +} +?> \ No newline at end of file diff --git a/Function/ListTables.php b/Function/ListTables.php new file mode 100644 index 0000000..54a3144 --- /dev/null +++ b/Function/ListTables.php @@ -0,0 +1,54 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ListTables extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_list_tables ( string database [, resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($db, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + list($db, $db_type) = $this->extractValueAndType(trim($db)); + if ('const' == $db_type) { + $ret = sprintf('mysqli_query(%s, "SHOW TABLES FROM " . constant(\'%s\'))', $conn, $db); + } else { + $ret = sprintf('mysqli_query(%s, "SHOW TABLES FROM %s")', $conn, $db); + } + + return array('mysql_list_tables(string database_name [...]) is emulated using mysqli_query() and SHOW TABLES FROM database_name. This is a possible SQL injection security bug as no tests are performed what value database_name has. Check your script!', $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query() and SHOW TABLES FROM.'; + } +} +?> \ No newline at end of file diff --git a/Function/ParReversed.php b/Function/ParReversed.php new file mode 100644 index 0000000..de0a2d1 --- /dev/null +++ b/Function/ParReversed.php @@ -0,0 +1,41 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_ParReversed extends MySQLConverterTool_Function_Generic { + + + function handle(Array $params = array()) { + + // mysql_query ( string query [, resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($par1, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(NULL, "$this->new_name($conn, $par1)"); + } + + + function getConversionHint() { + + return 'Generic function for: mysql_func(param1, param2) => mysqli_func(param2, param1). Currently used for mysql_query(), mysql_real_escape_string()'; + } + +} +?> \ No newline at end of file diff --git a/Function/RealEscapeString.php b/Function/RealEscapeString.php new file mode 100644 index 0000000..096e744 --- /dev/null +++ b/Function/RealEscapeString.php @@ -0,0 +1,59 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_RealEscapeString extends MySQLConverterTool_Function_Generic { + + + function handle(Array $params = array()) { + + // string mysql_real_escape_string ( string unescaped_string [, resource link_identifier] ) + // string mysqli_real_escape_string ( mysqli link, string escapestr ) + + if (count($params) == 1) { + + list($string) = $this->extractParamValues($params); + $conn = $this->ston_name; + $warning = 'If no global connection has been opened already the converter cannot use mysqli_real_escape_string() to emulate the function. We add a runtime test if a connection exists, if not trigger_error() gets used to throw an E_USER_ERROR. It would be a security bug to do anything else. You must fix our code manually!'; + $ret = sprintf('((isset(%s) && is_object(%s)) ? %s(%s, %s) : ((trigger_error("[MySQLConverterToo] Fix the mysql_escape_string() call! This code does not work.", E_USER_ERROR)) ? "" : ""))', + $conn, + $conn, + $this->new_name, + $conn, + $string + ); + + } else if (count($params) == 2) { + + list($string, $conn) = @$this->extractParamValues($params); + $warning = null; + $ret = sprintf('%s(%s, %s)', $this->new_name, $conn, $string); + + } else { + + $warning = self::PARSE_ERROR_WRONG_PARAMS; + $ret = null; + + } + + return array($warning, $ret); + } + + function getConversionHint() { + + return 'Emulated using mysqli_real_escape_string and the default connection if no connection is given. If no default connection exists an E_USER_ERROR gets thrown.'; + } + +} +?> \ No newline at end of file diff --git a/Function/SelectDB.php b/Function/SelectDB.php new file mode 100644 index 0000000..9cf4c53 --- /dev/null +++ b/Function/SelectDB.php @@ -0,0 +1,56 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_SelectDB extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // bool mysql_select_db ( string database_name [, resource link_identifier] ) + // mixed mysqli_query ( mysqli link, string query [, int resultmode] ) + + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($db, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + list($db, $db_type) = $this->extractValueAndType(trim($db)); + if ('const' == $db_type) { + $ret = sprintf('((bool)mysqli_query(%s, "USE " . constant(\'%s\')))', $conn, $db); + } else { + $ret = sprintf('((bool)mysqli_query(%s, "USE %s"))', $conn, $db); + } + + return array('mysql_select_db(string database_name [...]) is emulated using mysqli_query() and USE database_name. This is a possible SQL injection security bug as no tests are performed what value database_name has. Check your script!', $ret); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query() and USE.'; + } + + +} +?> \ No newline at end of file diff --git a/Function/Tablename.php b/Function/Tablename.php new file mode 100644 index 0000000..b9e4058 --- /dev/null +++ b/Function/Tablename.php @@ -0,0 +1,45 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_Tablename extends MySQLConverterTool_Function_Generic { + + public $new_name = 'mysqli_fetch_row'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_db_name ( resource result, int row [, mixed field] ) + // string mysql_tablename ( resource result, int i ) + + if (count($params) != 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + list($res, $i) = $this->extractParamValues($params); + + return array(NULL, sprintf('((mysqli_data_seek(%s, %s) && (($___mysqli_tmp = mysqli_fetch_row(%s)) !== NULL)) ? array_shift($___mysqli_tmp) : false)', $res, $i, $res)); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_data_seek(), mysqli_fetch_row() and a conditional expression.'; + } + +} +?> \ No newline at end of file diff --git a/Function/UnbufferedQuery.php b/Function/UnbufferedQuery.php new file mode 100644 index 0000000..348ad0b --- /dev/null +++ b/Function/UnbufferedQuery.php @@ -0,0 +1,48 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Class available since Release 1.0 +*/ +class MySQLConverterTool_Function_UnbufferedQuery extends MySQLConverterTool_Function_Generic { + + + public $new_name = 'mysqli_query'; + + + public function __construct() { + } + + + function handle(Array $params = array()) { + + // mysql_unbuffered_query ( string query [, resource link_identifier] ) + if (count($params) < 1 || count($params) > 2) + return array(self::PARSE_ERROR_WRONG_PARAMS, NULL); + + @list($q, $conn) = $this->extractParamValues($params); + if (is_null($conn)) + $conn = $this->ston_name; + + return array(null, "mysqli_query($conn, $q, MYSQLI_USE_RESULT)"); + } + + + function getConversionHint() { + + return 'Emulated using mysqli_query and MYSQLI_USE_RESULT.'; + } + + +} +?> \ No newline at end of file diff --git a/GUI/.svn/README.txt b/GUI/.svn/README.txt new file mode 100644 index 0000000..271a8ce --- /dev/null +++ b/GUI/.svn/README.txt @@ -0,0 +1,2 @@ +This is a Subversion working copy administrative directory. +Visit http://subversion.tigris.org/ for more information. diff --git a/GUI/.svn/dir-wcprops b/GUI/.svn/dir-wcprops new file mode 100644 index 0000000..3811a85 --- /dev/null +++ b/GUI/.svn/dir-wcprops @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 61 +/svnpublic/mysqli_converter/!svn/ver/6/MySQLConverterTool/GUI +END diff --git a/GUI/.svn/empty-file b/GUI/.svn/empty-file new file mode 100644 index 0000000..e69de29 diff --git a/GUI/.svn/entries b/GUI/.svn/entries new file mode 100644 index 0000000..1713588 --- /dev/null +++ b/GUI/.svn/entries @@ -0,0 +1,65 @@ + + + + + + + + + + + diff --git a/GUI/.svn/format b/GUI/.svn/format new file mode 100644 index 0000000..b8626c4 --- /dev/null +++ b/GUI/.svn/format @@ -0,0 +1 @@ +4 diff --git a/GUI/.svn/prop-base/convert_directory.php.svn-base b/GUI/.svn/prop-base/convert_directory.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/GUI/.svn/prop-base/convert_file.php.svn-base b/GUI/.svn/prop-base/convert_file.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/GUI/.svn/prop-base/convert_snippet.php.svn-base b/GUI/.svn/prop-base/convert_snippet.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/GUI/.svn/prop-base/help.php.svn-base b/GUI/.svn/prop-base/help.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/GUI/.svn/prop-base/index.php.svn-base b/GUI/.svn/prop-base/index.php.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/GUI/.svn/props/convert_directory.php.svn-work b/GUI/.svn/props/convert_directory.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/GUI/.svn/props/convert_file.php.svn-work b/GUI/.svn/props/convert_file.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/GUI/.svn/props/convert_snippet.php.svn-work b/GUI/.svn/props/convert_snippet.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/GUI/.svn/props/help.php.svn-work b/GUI/.svn/props/help.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/GUI/.svn/props/index.php.svn-work b/GUI/.svn/props/index.php.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/GUI/.svn/text-base/convert_directory.php.svn-base b/GUI/.svn/text-base/convert_directory.php.svn-base new file mode 100644 index 0000000..65a4736 --- /dev/null +++ b/GUI/.svn/text-base/convert_directory.php.svn-base @@ -0,0 +1,109 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ + +if (isset($_POST['cancel'])) { + // Cancel button + header('Location: index.php'); + exit(0); +} + +require_once('snippets/MySQLConverterTool_GUI_Snippets.php'); + +$snippet_title = 'MySQL ext/mysql Converter Tool'; +$snippet_greeting = 'Convert all files from a directory'; +$snippet_nav_path = array($_SERVER['PHP_SELF'] => 'Convert a directory'); +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/header.php'); + +if (empty($_POST) || !isset($_POST['start'])) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_directory.php'); + +} else { + // process the form + $snippet_errors = array(); + if ("" == trim($_POST['directory'])) { + $snippet_errors['directory'] = 'Please specify a directory'; + } + + if ("" == trim($_POST['pattern'])) + $_POST['pattern'] = '*.*'; + + require_once('../Converter.php'); + $conv = new MySQLConverterTool_Converter(); + $files = $conv->getFilesOfDirectory($_POST['directory'], $_POST['pattern']); + + if (empty($files)) { + $snippet_errors['directory'] = 'No matching files found in the specified directory'; + } + + if (!empty($snippet_errors)) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_directory.php'); + } else { + // let's try to convert some files... + + $snippet_conv_found = 0; + $snippet_conv_converted = 0; + $snippet_conv_ok = 0; + $snippet_conv_warnings = 0; + $snippet_conv_errors = 0; + $snippet_conv_count = count($files); + $snippet_conv_length = 0; + $outputs = array(); + foreach ($files as $k => $snippet_file) { + $output = $conv->convertFile($snippet_file); + $snippet_conv_found += $output['found']; + $snippet_conv_converted += $output['converted']; + $snippet_conv_ok += ($output['found'] == $output['converted']) && (count($output['errors']) == 0) ? 1 : 0; + $snippet_conv_warnings += ($output['found'] == $output['converted']) && (count($output['errors']) > 0) ? 1 : 0; + $snippet_conv_errors += ($output['found'] != $output['converted']) && (count($output['errors']) > 0) ? 1 : 0; + $snippet_conv_length += strlen($output['output']); + + if (isset($_POST['update']) && $_POST['update'] == 'yes') { + if (isset($_POST['backup']) && $_POST['backup'] == 'on') { + if (file_exists($snippet_file . '.org')) + unlink($snippet_file . '.org'); + $output['rename'] = rename($snippet_file, $snippet_file . '.org'); + } else { + $output['rename'] = false; + } + $fp = fopen($snippet_file, 'w'); + if (!$fp) { + $output['update'] = false; + } else { + $output['update'] = true; + fwrite($fp, $output['output']); + fclose($fp); + } + } else { + $output['rename'] = false; + $output['update'] = false; + } + + $outputs[$snippet_file] = $output; + } + + // Display some summary information... + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/show_converted_directory.php'); + + // Display the results for every file + $snippet_show_details = (count($files) == 1) ? true : false; + foreach ($outputs as $snippet_file => $snippet_conv) + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/show_converted_file.php'); + + } + +} +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/footer.php'); +?> \ No newline at end of file diff --git a/GUI/.svn/text-base/convert_file.php.svn-base b/GUI/.svn/text-base/convert_file.php.svn-base new file mode 100644 index 0000000..7614df7 --- /dev/null +++ b/GUI/.svn/text-base/convert_file.php.svn-base @@ -0,0 +1,84 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ + +if (isset($_POST['cancel'])) { + // Cancel button + header('Location: index.php'); + exit(0); +} + +require_once('snippets/MySQLConverterTool_GUI_Snippets.php'); + +$snippet_title = 'MySQL ext/mysql Converter Tool'; +$snippet_greeting = 'Convert a file'; +$snippet_nav_path = array($_SERVER['PHP_SELF'] => 'Convert a file'); +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/header.php'); + +if (empty($_POST) || !isset($_POST['start'])) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_file.php'); + +} else { + // process the form + $snippet_errors = array(); + if ("" == trim($_POST['file'])) { + $snippet_errors['file'] = 'Please specify a file.'; + } + + if (!file_exists($_POST['file']) || !is_file($_POST['file']) || !is_readable($_POST['file'])) { + $snippet_errors['file'] = 'Problems reading the file. Please verify that it exists and can be read.'; + } + + + if (!empty($snippet_errors)) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_file.php'); + } else { + // let's try to convert some files... + + require_once('../Converter.php'); + $conv = new MySQLConverterTool_Converter(); + + $snippet_file = $_POST['file']; + $snippet_conv = $conv->convertFile($_POST['file']); + + if (isset($_POST['update']) && $_POST['update'] == 'yes') { + if (isset($_POST['backup']) && $_POST['backup'] == 'on') { + if (file_exists($snippet_file . '.org')) + unlink($snippet_file . '.org'); + $snippet_conv['rename'] = rename($snippet_file, $snippet_file . '.org'); + } else { + $snippet_conv['rename'] = false; + } + $fp = fopen($snippet_file, 'w'); + if (!$fp) { + $snippet_conv['update'] = false; + } else { + $snippet_conv['update'] = true; + fwrite($fp, $snippet_conv['output']); + fclose($fp); + } + } else { + $snippet_conv['rename'] = false; + $snippet_conv['update'] = false; + } + $snippet_show_details = true; + + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/show_converted_file.php'); + + } + +} +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/footer.php'); +?> \ No newline at end of file diff --git a/GUI/.svn/text-base/convert_snippet.php.svn-base b/GUI/.svn/text-base/convert_snippet.php.svn-base new file mode 100644 index 0000000..b83cd8b --- /dev/null +++ b/GUI/.svn/text-base/convert_snippet.php.svn-base @@ -0,0 +1,57 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ + +if (isset($_POST['cancel'])) { + // Cancel button + header('Location: index.php'); + exit(0); +} + +require_once('snippets/MySQLConverterTool_GUI_Snippets.php'); + +$snippet_title = 'MySQL ext/mysql Converter Tool'; +$snippet_greeting = 'Convert a code snippet'; +$snippet_nav_path = array($_SERVER['PHP_SELF'] => 'Convert a code snippet'); +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/header.php'); + +if (empty($_POST) || !isset($_POST['start'])) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_snippet.php'); + +} else { + // process the form + $snippet_errors = array(); + if ("" == trim($_POST['snippet'])) { + $snippet_errors['snippet'] = 'Please provide some code to be converted.'; + } + + if (!empty($snippet_errors)) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_snippet.php'); + } else { + // let's try to convert some files... + + require_once('../Converter.php'); + $conv = new MySQLConverterTool_Converter(); + + $snippet_conv = $conv->convertString($_POST['snippet']); + $snippet_show_details = true; + + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/show_converted_snippet.php'); + + } + +} +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/footer.php'); +?> \ No newline at end of file diff --git a/GUI/.svn/text-base/help.php.svn-base b/GUI/.svn/text-base/help.php.svn-base new file mode 100644 index 0000000..34f7b94 --- /dev/null +++ b/GUI/.svn/text-base/help.php.svn-base @@ -0,0 +1,138 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ + +require_once('snippets/MySQLConverterTool_GUI_Snippets.php'); + +$snippet_title = 'MySQL ext/mysql Converter Tool'; +$snippet_greeting = 'Help'; +$snippet_nav_path = array($_SERVER['PHP_SELF'] => 'Help'); +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/header.php'); +?> +

About

+

+This is the MySQL ext/mysql Converter Tool. The tool can be used to convert PHP +files using the PHP MySQL extension (ext/mysql) to make the scripts use the PHP MySQLi extension. +The PHP MySQL extension has been designed to work with the MySQL Server up to version 4.1.0. +Some features introduced later, for example prepared statements, are not supported by the extension. +To use these features, you have to use the PHP MySQLi extension. This tool helps you to convert +your existing scripts from the old MySQL extension to the new MySQLi extension. +

+

+The tool uses a simple approach to map mysql_*-functions to their mysqli_*-counterparts. +All mysql_*-functions can be converted automatically. The generated code will run out of +the box. However, the tool does not take context and runtime informationn into account +when it does the conversion. This can lead to situations where the tool is not sure if the +generated code is semantically identical to the original code in all ways. If this happens, +a warning will the thrown and you will be requested to check the automatically generated tool +

+

+The tool has been originally developed by MySQL AB. It is released under the terms of the +PHP Licence 3.0. +

+

Where can I get more information?

+

+Plase consult the MySQL Forge Wiki for additional information. +

+

What cannot be converted automatically?

+

+Use the function MySQLConvertTool_Converter::getUnsupportedFunctions() to get a list of all +functions which cannot be converted automatically. Currently, the tool does not support +the conversion of the following, rarely used functions: +

    +
  • mysql_result()
  • +
  • mysql_fetch_field2()
  • +
+All other mysql_*-functions can be converted automatically. +

+

What is considered to be a warning?

+

+The converter tool works stateless. It does not take any context or runtime information into account. +It does nothing but analyze existing mysql_*-functions and tries to translate them into their +mysqli_*-counterparts. Most expressions can be translated into semantically identical expressions +using this approach. But there are limits. Whenever such a limit gets hit, the tool throws +an error and asks you to check your code manually. +

+

A simple example of an expression which cannot be converted without context information is mysql_error(). +Consider the following PHP code: +

+

+ +

+if (!mysql_connect())
+    die(sprintf("[%d] %s\n", mysql_errno(), mysql_error()));
+
+ +

+

+The author of the code relies on the default connection feature. mysql_errno() can be called with or without a +link identifier. The function accepts one optional parameter: +

+

+ +

+mysql_errno ( [resource link_identifier] )
+
+ +

+

+The mysqli_errno() counterpart of the MySQLi extension must be provided with a link identifier. +

+

+ +

+mysqli_errno ( mysqli link )
+
+ +

+

+The tool is clever enough to store the return value of mysql_connect() [mysqli_connect()] in a global variable +and pass the global variable to the mysqli_errno() function call. But if mysqli_connect() fails and does not +return a link identifier, mysqli_errno() will be called with an invalid parameter. Again, the conversion tool +is clever enough to add a conditional expression to ensure that the generated code behaves like the original +code, but this is considered as a "hack" and a "warning" will be thrown. The warning tells you to check manually +that the generated code is semantically identical to the original code. You could, for example, +have a mysql_errno() somewhere in your code without a preceding mysql_connect(). That does not make too much sense, +but it could be. As the converter tool does not consider any state and context information it cannot detect +such problems. When the mysql_errno() call gets converted no information is available if it is preceded by a mysql_connect() +call or not. +

+

+Yes, we think it is worth to throw a warning. You can call it picky. Most of the warnings can be safely +ignored. But we give no warranty. Check your code manually! +

+

+There are many more situations when a warning gets thrown. For example, mysql_fetch_field() will be replaced +by a semantically identical expression, but the replacement is a huge, ugly piece of code which you should streamline. +

+

Can I safely ignore the warnings?

+

+No, you are strongly requested to check the generated code manually. It is likely that the generated code +works as expected in most cases, but not in all cases! +

+

What is considered to be an error?

+

+The tool considers a conversion as failed and all warnings as errors if the number of converted functions +differs from the number of mysql_*-functions found in the given PHP source. +

+

Where can I learn more about limitations?

+

+The converter tool comes with more than 50 "real-life" test cases. At least one test case exists for every +mysql_-function which can be handled by the tool. If a test case contains code which cannot be +converted automatically into a semantically identical mysqli*-function, the test case name is preceded with +the word "FAILURE". Check the test cases in the folder UnitTests/Converter/TestCode +for details. +

+ \ No newline at end of file diff --git a/GUI/.svn/text-base/index.php.svn-base b/GUI/.svn/text-base/index.php.svn-base new file mode 100644 index 0000000..d89db47 --- /dev/null +++ b/GUI/.svn/text-base/index.php.svn-base @@ -0,0 +1,46 @@ +, Ulf Wendel +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ + +require_once('snippets/MySQLConverterTool_GUI_Snippets.php'); + +$snippet_title = 'Welcome to the MySQL ext/mysql Converter Tool'; +$snippet_greeting = 'Welcome to the MySQL ext/mysq Converter Tool'; + +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/header.php'); +?> +
+ You have successfully installed the MySQL ext/mysql Converter Tool. + The tool helps you to migrate existing PHP code using the PHP MySQL Extension + (ext/mysql) to the PHP MySQLi Extension (ext/mysqli). The tool reads the source code + and converts all MySQL functions into their MySQLi counterparts. +
+
+ Select one of the following actions: +
+
+

Convert a directory

+ Use this to convert all PHP files contained in one + directory. +
+
+

Convert a file

+ Use this to convert a single PHP file. +
+
+

Convert a code snippet

+ Use this to convert a snippet, a piece of PHP code. +
+ \ No newline at end of file diff --git a/GUI/.svn/wcprops/convert_directory.php.svn-work b/GUI/.svn/wcprops/convert_directory.php.svn-work new file mode 100644 index 0000000..adf0370 --- /dev/null +++ b/GUI/.svn/wcprops/convert_directory.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 83 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/GUI/convert_directory.php +END diff --git a/GUI/.svn/wcprops/convert_file.php.svn-work b/GUI/.svn/wcprops/convert_file.php.svn-work new file mode 100644 index 0000000..1be5d1e --- /dev/null +++ b/GUI/.svn/wcprops/convert_file.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 78 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/GUI/convert_file.php +END diff --git a/GUI/.svn/wcprops/convert_snippet.php.svn-work b/GUI/.svn/wcprops/convert_snippet.php.svn-work new file mode 100644 index 0000000..bf9defc --- /dev/null +++ b/GUI/.svn/wcprops/convert_snippet.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 81 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/GUI/convert_snippet.php +END diff --git a/GUI/.svn/wcprops/help.php.svn-work b/GUI/.svn/wcprops/help.php.svn-work new file mode 100644 index 0000000..33833cc --- /dev/null +++ b/GUI/.svn/wcprops/help.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 70 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/GUI/help.php +END diff --git a/GUI/.svn/wcprops/index.php.svn-work b/GUI/.svn/wcprops/index.php.svn-work new file mode 100644 index 0000000..0a01b28 --- /dev/null +++ b/GUI/.svn/wcprops/index.php.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 71 +/svnpublic/mysqli_converter/!svn/ver/5/MySQLConverterTool/GUI/index.php +END diff --git a/GUI/convert_directory.php b/GUI/convert_directory.php new file mode 100644 index 0000000..dfbd166 --- /dev/null +++ b/GUI/convert_directory.php @@ -0,0 +1,109 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ + +if (isset($_POST['cancel'])) { + // Cancel button + header('Location: index.php'); + exit(0); +} + +require_once('snippets/MySQLConverterTool_GUI_Snippets.php'); + +$snippet_title = 'MySQL ext/mysql Converter Tool'; +$snippet_greeting = 'Convert all files from a directory'; +$snippet_nav_path = array($_SERVER['PHP_SELF'] => 'Convert a directory'); +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/header.php'); + +if (empty($_POST) || !isset($_POST['start'])) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_directory.php'); + +} else { + // process the form + $snippet_errors = array(); + if ("" == trim($_POST['directory'])) { + $snippet_errors['directory'] = 'Please specify a directory'; + } + + if ("" == trim($_POST['pattern'])) + $_POST['pattern'] = '*.*'; + + require_once('../Converter.php'); + $conv = new MySQLConverterTool_Converter(); + $files = $conv->getFilesOfDirectory($_POST['directory'], $_POST['pattern']); + + if (empty($files)) { + $snippet_errors['directory'] = 'No matching files found in the specified directory'; + } + + if (!empty($snippet_errors)) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_directory.php'); + } else { + // let's try to convert some files... + + $snippet_conv_found = 0; + $snippet_conv_converted = 0; + $snippet_conv_ok = 0; + $snippet_conv_warnings = 0; + $snippet_conv_errors = 0; + $snippet_conv_count = count($files); + $snippet_conv_length = 0; + $outputs = array(); + foreach ($files as $k => $snippet_file) { + $output = $conv->convertFile($snippet_file); + $snippet_conv_found += $output['found']; + $snippet_conv_converted += $output['converted']; + $snippet_conv_ok += ($output['found'] == $output['converted']) && (count($output['errors']) == 0) ? 1 : 0; + $snippet_conv_warnings += ($output['found'] == $output['converted']) && (count($output['errors']) > 0) ? 1 : 0; + $snippet_conv_errors += ($output['found'] != $output['converted']) && (count($output['errors']) > 0) ? 1 : 0; + $snippet_conv_length += strlen($output['output']); + + if (isset($_POST['update']) && $_POST['update'] == 'yes') { + if (isset($_POST['backup']) && $_POST['backup'] == 'on') { + if (file_exists($snippet_file . '.org')) + unlink($snippet_file . '.org'); + $output['rename'] = rename($snippet_file, $snippet_file . '.org'); + } else { + $output['rename'] = false; + } + $fp = fopen($snippet_file, 'w'); + if (!$fp) { + $output['update'] = false; + } else { + $output['update'] = true; + fwrite($fp, $output['output']); + fclose($fp); + } + } else { + $output['rename'] = false; + $output['update'] = false; + } + + $outputs[$snippet_file] = $output; + } + + // Display some summary information... + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/show_converted_directory.php'); + + // Display the results for every file + $snippet_show_details = (count($files) == 1) ? true : false; + foreach ($outputs as $snippet_file => $snippet_conv) + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/show_converted_file.php'); + + } + +} +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/footer.php'); +?> \ No newline at end of file diff --git a/GUI/convert_file.php b/GUI/convert_file.php new file mode 100644 index 0000000..0da745c --- /dev/null +++ b/GUI/convert_file.php @@ -0,0 +1,84 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ + +if (isset($_POST['cancel'])) { + // Cancel button + header('Location: index.php'); + exit(0); +} + +require_once('snippets/MySQLConverterTool_GUI_Snippets.php'); + +$snippet_title = 'MySQL ext/mysql Converter Tool'; +$snippet_greeting = 'Convert a file'; +$snippet_nav_path = array($_SERVER['PHP_SELF'] => 'Convert a file'); +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/header.php'); + +if (empty($_POST) || !isset($_POST['start'])) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_file.php'); + +} else { + // process the form + $snippet_errors = array(); + if ("" == trim($_POST['file'])) { + $snippet_errors['file'] = 'Please specify a file.'; + } + + if (!file_exists($_POST['file']) || !is_file($_POST['file']) || !is_readable($_POST['file'])) { + $snippet_errors['file'] = 'Problems reading the file. Please verify that it exists and can be read.'; + } + + + if (!empty($snippet_errors)) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_file.php'); + } else { + // let's try to convert some files... + + require_once('../Converter.php'); + $conv = new MySQLConverterTool_Converter(); + + $snippet_file = $_POST['file']; + $snippet_conv = $conv->convertFile($_POST['file']); + + if (isset($_POST['update']) && $_POST['update'] == 'yes') { + if (isset($_POST['backup']) && $_POST['backup'] == 'on') { + if (file_exists($snippet_file . '.org')) + unlink($snippet_file . '.org'); + $snippet_conv['rename'] = rename($snippet_file, $snippet_file . '.org'); + } else { + $snippet_conv['rename'] = false; + } + $fp = fopen($snippet_file, 'w'); + if (!$fp) { + $snippet_conv['update'] = false; + } else { + $snippet_conv['update'] = true; + fwrite($fp, $snippet_conv['output']); + fclose($fp); + } + } else { + $snippet_conv['rename'] = false; + $snippet_conv['update'] = false; + } + $snippet_show_details = true; + + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/show_converted_file.php'); + + } + +} +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/footer.php'); +?> \ No newline at end of file diff --git a/GUI/convert_snippet.php b/GUI/convert_snippet.php new file mode 100644 index 0000000..fdf5617 --- /dev/null +++ b/GUI/convert_snippet.php @@ -0,0 +1,57 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ + +if (isset($_POST['cancel'])) { + // Cancel button + header('Location: index.php'); + exit(0); +} + +require_once('snippets/MySQLConverterTool_GUI_Snippets.php'); + +$snippet_title = 'MySQL ext/mysql Converter Tool'; +$snippet_greeting = 'Convert a code snippet'; +$snippet_nav_path = array($_SERVER['PHP_SELF'] => 'Convert a code snippet'); +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/header.php'); + +if (empty($_POST) || !isset($_POST['start'])) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_snippet.php'); + +} else { + // process the form + $snippet_errors = array(); + if ("" == trim($_POST['snippet'])) { + $snippet_errors['snippet'] = 'Please provide some code to be converted.'; + } + + if (!empty($snippet_errors)) { + // show the form + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/form_snippet.php'); + } else { + // let's try to convert some files... + + require_once('../Converter.php'); + $conv = new MySQLConverterTool_Converter(); + + $snippet_conv = $conv->convertString($_POST['snippet']); + $snippet_show_details = true; + + MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/show_converted_snippet.php'); + + } + +} +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/footer.php'); +?> \ No newline at end of file diff --git a/GUI/css/.svn/README.txt b/GUI/css/.svn/README.txt new file mode 100644 index 0000000..271a8ce --- /dev/null +++ b/GUI/css/.svn/README.txt @@ -0,0 +1,2 @@ +This is a Subversion working copy administrative directory. +Visit http://subversion.tigris.org/ for more information. diff --git a/GUI/css/.svn/dir-wcprops b/GUI/css/.svn/dir-wcprops new file mode 100644 index 0000000..c6c2c7f --- /dev/null +++ b/GUI/css/.svn/dir-wcprops @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 65 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/GUI/css +END diff --git a/GUI/css/.svn/empty-file b/GUI/css/.svn/empty-file new file mode 100644 index 0000000..e69de29 diff --git a/GUI/css/.svn/entries b/GUI/css/.svn/entries new file mode 100644 index 0000000..2d941d7 --- /dev/null +++ b/GUI/css/.svn/entries @@ -0,0 +1,23 @@ + + + + + diff --git a/GUI/css/.svn/format b/GUI/css/.svn/format new file mode 100644 index 0000000..b8626c4 --- /dev/null +++ b/GUI/css/.svn/format @@ -0,0 +1 @@ +4 diff --git a/GUI/css/.svn/prop-base/main.css.svn-base b/GUI/css/.svn/prop-base/main.css.svn-base new file mode 100644 index 0000000..e69de29 diff --git a/GUI/css/.svn/props/main.css.svn-work b/GUI/css/.svn/props/main.css.svn-work new file mode 100644 index 0000000..e69de29 diff --git a/GUI/css/.svn/text-base/main.css.svn-base b/GUI/css/.svn/text-base/main.css.svn-base new file mode 100644 index 0000000..4145896 --- /dev/null +++ b/GUI/css/.svn/text-base/main.css.svn-base @@ -0,0 +1,274 @@ +body { + font-family:sans-serif; + font-size:12px; + background-color: #ffffff; + padding-left:1em; + padding-right:3em; + margin-top:0px; + margin-left:0px; +} + +h1 { font-size:18px; } + +h2 { + font-size:14px; + color:#F89331; +} + +h3 { + font-size:12px; + font-weight:bold; + color:#006486; +} + +a { text-decoration:none; } +a:hover { text-decoration:underline; } +a:focus { text-decoration:underline; } +a:active { text-decoration:underline; } + +fieldset { padding-bottom:1em } + +table { margin:0px; padding:0px; } +th { background-color:#f2f2f2; padding:0.25em; } + +legend { + font-size:14px; +} + +.conversionok { + color:#2BD95C; + font-weight:bold; +} + +.conversionwarning { + color:#FADF65; + font-weight:bold; +} + +.conversionerror { + color:#F89331; + font-weight:bold; +} + +.conversionheadline { + background-color:#006486; + width:100% +} + +.conversiondetails { + display:none; + padding:1em; +} + +.tddark { + background-color:#f6f6f6; +} + +.tdbright { + background-color:#ffffff; +} + +.conversiondetailstable { + + margin-left:1em; + margin-right:1em; + padding:0px; + + border-top-width:1px; + border-top-style:solid; + border-top-color:#f2f2f2; + + border-left-width:1px; + border-left-style:solid; + border-left-color:#f2f2f2; + + border-right-width:1px; + border-right-style:solid; + border-right-color:#f2f2f2; + + border-bottom-width:1px; + border-bottom-style:solid; + border-bottom-color:#f2f2f2; +} + + +.conversion { + + margin-bottom:0.5em; + + background-color:#ffffff; + + border-top-width:1px; + border-top-style:solid; + border-top-color:#006486; + + border-left-width:1px; + border-left-style:solid; + border-left-color:#006486; + + border-right-width:1px; + border-right-style:solid; + border-right-color:#006486; + + border-bottom-width:1px; + border-bottom-style:solid; + border-bottom-color:#006486; +} + +.formhint { + text-align:left; +} + +.formlabel { + font-weight:bold; + text-align:right; + vertical-align:top; + padding-right:0.5em; +} + +.formlabelerror { + color:#F89331; + font-weight:bold; + text-align:right; + vertical-align:top; + padding-right:0.5em; +} + +.error { + color:#F89331; + font-weight:bold; +} + +.formelement { + text-align:left; + vertical-align:top; + padding-bottom:0.5em; + width:450px; +} + +.formsubmit { + text-align:right; + padding-right:1em; + padding-top:0.5em; +} +.topnav { + width:100%; + + padding:0.25em; + padding-left:0.5em; + + background-color:#006486; + + font-size:10px; + color:#ffffff; + + border-bottom-width:1px; + border-bottom-style:solid; + border-bottom-color:#006486; + + border-left-width:1px; + border-left-style:solid; + border-left-color:#F2F2F2; + + border-right-width:1px; + border-right-style:solid; + border-right-color:#F2F2F2; +} + +.topnavlink { + color:#ffffff; +} + +.topgreetings { + + width:100%; + + padding:0.25em; + padding-left:0.5em; + padding-top:1em; + + background-color:#F2F2F2; + + border-top-width:1px; + border-top-style:solid; + border-top-color:#ffffff; + + border-left-width:1px; + border-left-style:solid; + border-left-color:#F2F2F2; + + border-right-width:1px; + border-right-style:solid; + border-right-color:#F2F2F2; + + border-bottom-width:1px; + border-bottom-style:solid; + border-bottom-color:#F2F2F2; + +} + +.main { + + margin-top:0.25em; + background-color:#FCFCFC; + + width:100%; + + padding:0.25em; + padding-left:0.5em; + padding-top:1em; + + text-align:left; + vertical-align:top; + + border-top-width:1px; + border-top-style:solid; + border-top-color:#F2F2F2; + + border-left-width:1px; + border-left-style:solid; + border-left-color:#F2F2F2; + + border-right-width:1px; + border-right-style:solid; + border-right-color:#F2F2F2; + + border-bottom-width:1px; + border-bottom-style:solid; + border-bottom-color:#F2F2F2; + +} + +.maintextbox { + width:600px; + margin-bottom:1em; +} + +.bottom { + + width:100%; + background-color:#FCFCFC; + + font-size:10px; + + margin-top:1em; + + padding:0.25em; + padding-left:0.5em; + + border-top-width:1px; + border-top-style:solid; + border-top-color:#F2F2F2; + + border-left-width:1px; + border-left-style:solid; + border-left-color:#F2F2F2; + + border-right-width:1px; + border-right-style:solid; + border-right-color:#F2F2F2; + + border-bottom-width:1px; + border-bottom-style:solid; + border-bottom-color:#F2F2F2 +} \ No newline at end of file diff --git a/GUI/css/.svn/wcprops/main.css.svn-work b/GUI/css/.svn/wcprops/main.css.svn-work new file mode 100644 index 0000000..db74437 --- /dev/null +++ b/GUI/css/.svn/wcprops/main.css.svn-work @@ -0,0 +1,5 @@ +K 25 +svn:wc:ra_dav:version-url +V 74 +/svnpublic/mysqli_converter/!svn/ver/3/MySQLConverterTool/GUI/css/main.css +END diff --git a/GUI/css/bootstrap-theme.css b/GUI/css/bootstrap-theme.css new file mode 100644 index 0000000..51352bb --- /dev/null +++ b/GUI/css/bootstrap-theme.css @@ -0,0 +1,372 @@ +.btn-default, +.btn-primary, +.btn-success, +.btn-info, +.btn-warning, +.btn-danger { + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.2); + -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 1px rgba(0, 0, 0, 0.075); +} + +.btn-default:active, +.btn-primary:active, +.btn-success:active, +.btn-info:active, +.btn-warning:active, +.btn-danger:active, +.btn-default.active, +.btn-primary.active, +.btn-success.active, +.btn-info.active, +.btn-warning.active, +.btn-danger.active { + -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); + box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); +} + +.btn:active, +.btn.active { + background-image: none; +} + +.btn-default { + text-shadow: 0 1px 0 #fff; + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#ffffff), to(#e6e6e6)); + background-image: -webkit-linear-gradient(top, #ffffff, 0%, #e6e6e6, 100%); + background-image: -moz-linear-gradient(top, #ffffff 0%, #e6e6e6 100%); + background-image: linear-gradient(to bottom, #ffffff 0%, #e6e6e6 100%); + background-repeat: repeat-x; + border-color: #e0e0e0; + border-color: #ccc; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#ffe6e6e6', GradientType=0); +} + +.btn-default:active, +.btn-default.active { + background-color: #e6e6e6; + border-color: #e0e0e0; +} + +.btn-primary { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#428bca), to(#3071a9)); + background-image: -webkit-linear-gradient(top, #428bca, 0%, #3071a9, 100%); + background-image: -moz-linear-gradient(top, #428bca 0%, #3071a9 100%); + background-image: linear-gradient(to bottom, #428bca 0%, #3071a9 100%); + background-repeat: repeat-x; + border-color: #2d6ca2; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff3071a9', GradientType=0); +} + +.btn-primary:active, +.btn-primary.active { + background-color: #3071a9; + border-color: #2d6ca2; +} + +.btn-success { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#5cb85c), to(#449d44)); + background-image: -webkit-linear-gradient(top, #5cb85c, 0%, #449d44, 100%); + background-image: -moz-linear-gradient(top, #5cb85c 0%, #449d44 100%); + background-image: linear-gradient(to bottom, #5cb85c 0%, #449d44 100%); + background-repeat: repeat-x; + border-color: #419641; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0); +} + +.btn-success:active, +.btn-success.active { + background-color: #449d44; + border-color: #419641; +} + +.btn-warning { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#f0ad4e), to(#ec971f)); + background-image: -webkit-linear-gradient(top, #f0ad4e, 0%, #ec971f, 100%); + background-image: -moz-linear-gradient(top, #f0ad4e 0%, #ec971f 100%); + background-image: linear-gradient(to bottom, #f0ad4e 0%, #ec971f 100%); + background-repeat: repeat-x; + border-color: #eb9316; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0); +} + +.btn-warning:active, +.btn-warning.active { + background-color: #ec971f; + border-color: #eb9316; +} + +.btn-danger { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#d9534f), to(#c9302c)); + background-image: -webkit-linear-gradient(top, #d9534f, 0%, #c9302c, 100%); + background-image: -moz-linear-gradient(top, #d9534f 0%, #c9302c 100%); + background-image: linear-gradient(to bottom, #d9534f 0%, #c9302c 100%); + background-repeat: repeat-x; + border-color: #c12e2a; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0); +} + +.btn-danger:active, +.btn-danger.active { + background-color: #c9302c; + border-color: #c12e2a; +} + +.btn-info { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#5bc0de), to(#31b0d5)); + background-image: -webkit-linear-gradient(top, #5bc0de, 0%, #31b0d5, 100%); + background-image: -moz-linear-gradient(top, #5bc0de 0%, #31b0d5 100%); + background-image: linear-gradient(to bottom, #5bc0de 0%, #31b0d5 100%); + background-repeat: repeat-x; + border-color: #2aabd2; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0); +} + +.btn-info:active, +.btn-info.active { + background-color: #31b0d5; + border-color: #2aabd2; +} + +.thumbnail, +.img-thumbnail { + -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.075); + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.075); +} + +.dropdown-menu > li > a:hover, +.dropdown-menu > li > a:focus, +.dropdown-menu > .active > a, +.dropdown-menu > .active > a:hover, +.dropdown-menu > .active > a:focus { + background-color: #357ebd; + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#428bca), to(#357ebd)); + background-image: -webkit-linear-gradient(top, #428bca, 0%, #357ebd, 100%); + background-image: -moz-linear-gradient(top, #428bca 0%, #357ebd 100%); + background-image: linear-gradient(to bottom, #428bca 0%, #357ebd 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff357ebd', GradientType=0); +} + +.navbar { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#ffffff), to(#f8f8f8)); + background-image: -webkit-linear-gradient(top, #ffffff, 0%, #f8f8f8, 100%); + background-image: -moz-linear-gradient(top, #ffffff 0%, #f8f8f8 100%); + background-image: linear-gradient(to bottom, #ffffff 0%, #f8f8f8 100%); + background-repeat: repeat-x; + border-radius: 4px; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffffffff', endColorstr='#fff8f8f8', GradientType=0); + -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 5px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 1px 5px rgba(0, 0, 0, 0.075); +} + +.navbar .navbar-nav > .active > a { + background-color: #f8f8f8; +} + +.navbar-brand, +.navbar-nav > li > a { + text-shadow: 0 1px 0 rgba(255, 255, 255, 0.25); +} + +.navbar-inverse { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#3c3c3c), to(#222222)); + background-image: -webkit-linear-gradient(top, #3c3c3c, 0%, #222222, 100%); + background-image: -moz-linear-gradient(top, #3c3c3c 0%, #222222 100%); + background-image: linear-gradient(to bottom, #3c3c3c 0%, #222222 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff3c3c3c', endColorstr='#ff222222', GradientType=0); +} + +.navbar-inverse .navbar-nav > .active > a { + background-color: #222222; +} + +.navbar-inverse .navbar-brand, +.navbar-inverse .navbar-nav > li > a { + text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25); +} + +.navbar-static-top, +.navbar-fixed-top, +.navbar-fixed-bottom { + border-radius: 0; +} + +.alert { + text-shadow: 0 1px 0 rgba(255, 255, 255, 0.2); + -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 1px 2px rgba(0, 0, 0, 0.05); + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 1px 2px rgba(0, 0, 0, 0.05); +} + +.alert-success { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#dff0d8), to(#c8e5bc)); + background-image: -webkit-linear-gradient(top, #dff0d8, 0%, #c8e5bc, 100%); + background-image: -moz-linear-gradient(top, #dff0d8 0%, #c8e5bc 100%); + background-image: linear-gradient(to bottom, #dff0d8 0%, #c8e5bc 100%); + background-repeat: repeat-x; + border-color: #b2dba1; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffc8e5bc', GradientType=0); +} + +.alert-info { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#d9edf7), to(#b9def0)); + background-image: -webkit-linear-gradient(top, #d9edf7, 0%, #b9def0, 100%); + background-image: -moz-linear-gradient(top, #d9edf7 0%, #b9def0 100%); + background-image: linear-gradient(to bottom, #d9edf7 0%, #b9def0 100%); + background-repeat: repeat-x; + border-color: #9acfea; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffb9def0', GradientType=0); +} + +.alert-warning { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#fcf8e3), to(#f8efc0)); + background-image: -webkit-linear-gradient(top, #fcf8e3, 0%, #f8efc0, 100%); + background-image: -moz-linear-gradient(top, #fcf8e3 0%, #f8efc0 100%); + background-image: linear-gradient(to bottom, #fcf8e3 0%, #f8efc0 100%); + background-repeat: repeat-x; + border-color: #f5e79e; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fff8efc0', GradientType=0); +} + +.alert-danger { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#f2dede), to(#e7c3c3)); + background-image: -webkit-linear-gradient(top, #f2dede, 0%, #e7c3c3, 100%); + background-image: -moz-linear-gradient(top, #f2dede 0%, #e7c3c3 100%); + background-image: linear-gradient(to bottom, #f2dede 0%, #e7c3c3 100%); + background-repeat: repeat-x; + border-color: #dca7a7; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffe7c3c3', GradientType=0); +} + +.progress { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#ebebeb), to(#f5f5f5)); + background-image: -webkit-linear-gradient(top, #ebebeb, 0%, #f5f5f5, 100%); + background-image: -moz-linear-gradient(top, #ebebeb 0%, #f5f5f5 100%); + background-image: linear-gradient(to bottom, #ebebeb 0%, #f5f5f5 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffebebeb', endColorstr='#fff5f5f5', GradientType=0); +} + +.progress-bar { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#428bca), to(#3071a9)); + background-image: -webkit-linear-gradient(top, #428bca, 0%, #3071a9, 100%); + background-image: -moz-linear-gradient(top, #428bca 0%, #3071a9 100%); + background-image: linear-gradient(to bottom, #428bca 0%, #3071a9 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff3071a9', GradientType=0); +} + +.progress-bar-success { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#5cb85c), to(#449d44)); + background-image: -webkit-linear-gradient(top, #5cb85c, 0%, #449d44, 100%); + background-image: -moz-linear-gradient(top, #5cb85c 0%, #449d44 100%); + background-image: linear-gradient(to bottom, #5cb85c 0%, #449d44 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5cb85c', endColorstr='#ff449d44', GradientType=0); +} + +.progress-bar-info { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#5bc0de), to(#31b0d5)); + background-image: -webkit-linear-gradient(top, #5bc0de, 0%, #31b0d5, 100%); + background-image: -moz-linear-gradient(top, #5bc0de 0%, #31b0d5 100%); + background-image: linear-gradient(to bottom, #5bc0de 0%, #31b0d5 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff5bc0de', endColorstr='#ff31b0d5', GradientType=0); +} + +.progress-bar-warning { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#f0ad4e), to(#ec971f)); + background-image: -webkit-linear-gradient(top, #f0ad4e, 0%, #ec971f, 100%); + background-image: -moz-linear-gradient(top, #f0ad4e 0%, #ec971f 100%); + background-image: linear-gradient(to bottom, #f0ad4e 0%, #ec971f 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff0ad4e', endColorstr='#ffec971f', GradientType=0); +} + +.progress-bar-danger { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#d9534f), to(#c9302c)); + background-image: -webkit-linear-gradient(top, #d9534f, 0%, #c9302c, 100%); + background-image: -moz-linear-gradient(top, #d9534f 0%, #c9302c 100%); + background-image: linear-gradient(to bottom, #d9534f 0%, #c9302c 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9534f', endColorstr='#ffc9302c', GradientType=0); +} + +.list-group { + border-radius: 4px; + -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.075); + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.075); +} + +.list-group-item.active, +.list-group-item.active:hover, +.list-group-item.active:focus { + text-shadow: 0 -1px 0 #3071a9; + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#428bca), to(#3278b3)); + background-image: -webkit-linear-gradient(top, #428bca, 0%, #3278b3, 100%); + background-image: -moz-linear-gradient(top, #428bca 0%, #3278b3 100%); + background-image: linear-gradient(to bottom, #428bca 0%, #3278b3 100%); + background-repeat: repeat-x; + border-color: #3278b3; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff3278b3', GradientType=0); +} + +.panel { + -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); + box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); +} + +.panel-default > .panel-heading { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#f5f5f5), to(#e8e8e8)); + background-image: -webkit-linear-gradient(top, #f5f5f5, 0%, #e8e8e8, 100%); + background-image: -moz-linear-gradient(top, #f5f5f5 0%, #e8e8e8 100%); + background-image: linear-gradient(to bottom, #f5f5f5 0%, #e8e8e8 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff5f5f5', endColorstr='#ffe8e8e8', GradientType=0); +} + +.panel-primary > .panel-heading { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#428bca), to(#357ebd)); + background-image: -webkit-linear-gradient(top, #428bca, 0%, #357ebd, 100%); + background-image: -moz-linear-gradient(top, #428bca 0%, #357ebd 100%); + background-image: linear-gradient(to bottom, #428bca 0%, #357ebd 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff428bca', endColorstr='#ff357ebd', GradientType=0); +} + +.panel-success > .panel-heading { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#dff0d8), to(#d0e9c6)); + background-image: -webkit-linear-gradient(top, #dff0d8, 0%, #d0e9c6, 100%); + background-image: -moz-linear-gradient(top, #dff0d8 0%, #d0e9c6 100%); + background-image: linear-gradient(to bottom, #dff0d8 0%, #d0e9c6 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0); +} + +.panel-info > .panel-heading { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#d9edf7), to(#c4e3f3)); + background-image: -webkit-linear-gradient(top, #d9edf7, 0%, #c4e3f3, 100%); + background-image: -moz-linear-gradient(top, #d9edf7 0%, #c4e3f3 100%); + background-image: linear-gradient(to bottom, #d9edf7 0%, #c4e3f3 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0); +} + +.panel-warning > .panel-heading { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#fcf8e3), to(#faf2cc)); + background-image: -webkit-linear-gradient(top, #fcf8e3, 0%, #faf2cc, 100%); + background-image: -moz-linear-gradient(top, #fcf8e3 0%, #faf2cc 100%); + background-image: linear-gradient(to bottom, #fcf8e3 0%, #faf2cc 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0); +} + +.panel-danger > .panel-heading { + background-image: -webkit-gradient(linear, left 0%, left 100%, from(#f2dede), to(#ebcccc)); + background-image: -webkit-linear-gradient(top, #f2dede, 0%, #ebcccc, 100%); + background-image: -moz-linear-gradient(top, #f2dede 0%, #ebcccc 100%); + background-image: linear-gradient(to bottom, #f2dede 0%, #ebcccc 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0); +} \ No newline at end of file diff --git a/GUI/css/bootstrap.css b/GUI/css/bootstrap.css new file mode 100644 index 0000000..d34990b --- /dev/null +++ b/GUI/css/bootstrap.css @@ -0,0 +1,7686 @@ +/*! + * Bootstrap v3.0.0 + * + * Copyright 2013 Twitter, Inc + * Licensed under the Apache License v2.0 + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Designed and built with all the love in the world by @mdo and @fat. + */ + +/*! normalize.css v2.1.0 | MIT License | git.io/normalize */ + +article, +aside, +details, +figcaption, +figure, +footer, +header, +hgroup, +main, +nav, +section, +summary { + display: block; +} + +audio, +canvas, +video { + display: inline-block; +} + +audio:not([controls]) { + display: none; + height: 0; +} + +[hidden] { + display: none; +} + +html { + font-family: sans-serif; + -webkit-text-size-adjust: 100%; + -ms-text-size-adjust: 100%; +} + +body { + margin: 0; +} + +a:focus { + outline: thin dotted; +} + +a:active, +a:hover { + outline: 0; +} + +h1 { + margin: 0.67em 0; + font-size: 2em; +} + +abbr[title] { + border-bottom: 1px dotted; +} + +b, +strong { + font-weight: bold; +} + +dfn { + font-style: italic; +} + +hr { + height: 0; + -moz-box-sizing: content-box; + box-sizing: content-box; +} + +mark { + color: #000; + background: #ff0; +} + +code, +kbd, +pre, +samp { + font-family: monospace, serif; + font-size: 1em; +} + +pre { + white-space: pre-wrap; +} + +q { + quotes: "\201C" "\201D" "\2018" "\2019"; +} + +small { + font-size: 80%; +} + +sub, +sup { + position: relative; + font-size: 75%; + line-height: 0; + vertical-align: baseline; +} + +sup { + top: -0.5em; +} + +sub { + bottom: -0.25em; +} + +img { + border: 0; +} + +svg:not(:root) { + overflow: hidden; +} + +figure { + margin: 0; +} + +fieldset { + padding: 0.35em 0.625em 0.75em; + margin: 0 2px; + border: 1px solid #c0c0c0; +} + +legend { + padding: 0; + border: 0; +} + +button, +input, +select, +textarea { + margin: 0; + font-family: inherit; + font-size: 100%; +} + +button, +input { + line-height: normal; +} + +button, +select { + text-transform: none; +} + +button, +html input[type="button"], +input[type="reset"], +input[type="submit"] { + cursor: pointer; + -webkit-appearance: button; +} + +button[disabled], +html input[disabled] { + cursor: default; +} + +input[type="checkbox"], +input[type="radio"] { + padding: 0; + box-sizing: border-box; +} + +input[type="search"] { + -webkit-box-sizing: content-box; + -moz-box-sizing: content-box; + box-sizing: content-box; + -webkit-appearance: textfield; +} + +input[type="search"]::-webkit-search-cancel-button, +input[type="search"]::-webkit-search-decoration { + -webkit-appearance: none; +} + +button::-moz-focus-inner, +input::-moz-focus-inner { + padding: 0; + border: 0; +} + +textarea { + overflow: auto; + vertical-align: top; +} + +table { + border-collapse: collapse; + border-spacing: 0; +} + +@media print { + * { + color: #000 !important; + text-shadow: none !important; + background: transparent !important; + box-shadow: none !important; + } + a, + a:visited { + text-decoration: underline; + } + a[href]:after { + content: " (" attr(href) ")"; + } + abbr[title]:after { + content: " (" attr(title) ")"; + } + .ir a:after, + a[href^="javascript:"]:after, + a[href^="#"]:after { + content: ""; + } + pre, + blockquote { + border: 1px solid #999; + page-break-inside: avoid; + } + thead { + display: table-header-group; + } + tr, + img { + page-break-inside: avoid; + } + img { + max-width: 100% !important; + } + @page { + margin: 2cm .5cm; + } + p, + h2, + h3 { + orphans: 3; + widows: 3; + } + h2, + h3 { + page-break-after: avoid; + } + .navbar { + display: none; + } + .table td, + .table th { + background-color: #fff !important; + } + .btn > .caret, + .dropup > .btn > .caret { + border-top-color: #000 !important; + } + .label { + border: 1px solid #000; + } + .table { + border-collapse: collapse !important; + } + .table-bordered th, + .table-bordered td { + border: 1px solid #ddd !important; + } +} + +*, +*:before, +*:after { + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; +} + +html { + font-size: 62.5%; + -webkit-tap-highlight-color: rgba(0, 0, 0, 0); +} + +body { + font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-size: 14px; + line-height: 1.428571429; + color: #c8c8c8; + background-color: #272b30; +} + +input, +button, +select, +textarea { + font-family: inherit; + font-size: inherit; + line-height: inherit; +} + +button, +input, +select[multiple], +textarea { + background-image: none; +} + +a { + color: #ffffff; + text-decoration: none; +} + +a:hover, +a:focus { + color: #ffffff; + text-decoration: underline; +} + +a:focus { + outline: thin dotted #333; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; +} + +img { + vertical-align: middle; +} + +.img-responsive { + display: block; + height: auto; + max-width: 100%; +} + +.img-rounded { + border-radius: 6px; +} + +.img-thumbnail { + display: inline-block; + height: auto; + max-width: 100%; + padding: 4px; + line-height: 1.428571429; + background-color: #272b30; + border: 1px solid #dddddd; + border-radius: 4px; + -webkit-transition: all 0.2s ease-in-out; + transition: all 0.2s ease-in-out; +} + +.img-circle { + border-radius: 50%; +} + +hr { + margin-top: 20px; + margin-bottom: 20px; + border: 0; + border-top: 1px solid #1c1e22; +} + +.sr-only { + position: absolute; + width: 1px; + height: 1px; + padding: 0; + margin: -1px; + overflow: hidden; + clip: rect(0 0 0 0); + border: 0; +} + +p { + margin: 0 0 10px; +} + +.lead { + margin-bottom: 20px; + font-size: 16.099999999999998px; + font-weight: 200; + line-height: 1.4; +} + +@media (min-width: 768px) { + .lead { + font-size: 21px; + } +} + +small { + font-size: 85%; +} + +cite { + font-style: normal; +} + +.text-muted { + color: #7a8288; +} + +.text-primary { + color: #7a8288; +} + +.text-warning { + color: #ffffff; +} + +.text-danger { + color: #ffffff; +} + +.text-success { + color: #ffffff; +} + +.text-info { + color: #ffffff; +} + +.text-left { + text-align: left; +} + +.text-right { + text-align: right; +} + +.text-center { + text-align: center; +} + +h1, +h2, +h3, +h4, +h5, +h6, +.h1, +.h2, +.h3, +.h4, +.h5, +.h6 { + font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-weight: 500; + line-height: 1.1; +} + +h1 small, +h2 small, +h3 small, +h4 small, +h5 small, +h6 small, +.h1 small, +.h2 small, +.h3 small, +.h4 small, +.h5 small, +.h6 small { + font-weight: normal; + line-height: 1; + color: #7a8288; +} + +h1, +h2, +h3 { + margin-top: 20px; + margin-bottom: 10px; +} + +h4, +h5, +h6 { + margin-top: 10px; + margin-bottom: 10px; +} + +h1, +.h1 { + font-size: 36px; +} + +h2, +.h2 { + font-size: 30px; +} + +h3, +.h3 { + font-size: 24px; +} + +h4, +.h4 { + font-size: 18px; +} + +h5, +.h5 { + font-size: 14px; +} + +h6, +.h6 { + font-size: 12px; +} + +h1 small, +.h1 small { + font-size: 24px; +} + +h2 small, +.h2 small { + font-size: 18px; +} + +h3 small, +.h3 small, +h4 small, +.h4 small { + font-size: 14px; +} + +.page-header { + padding-bottom: 9px; + margin: 40px 0 20px; + border-bottom: 1px solid #1c1e22; +} + +ul, +ol { + margin-top: 0; + margin-bottom: 10px; +} + +ul ul, +ol ul, +ul ol, +ol ol { + margin-bottom: 0; +} + +.list-unstyled { + padding-left: 0; + list-style: none; +} + +.list-inline { + padding-left: 0; + list-style: none; +} + +.list-inline > li { + display: inline-block; + padding-right: 5px; + padding-left: 5px; +} + +dl { + margin-bottom: 20px; +} + +dt, +dd { + line-height: 1.428571429; +} + +dt { + font-weight: bold; +} + +dd { + margin-left: 0; +} + +@media (min-width: 768px) { + .dl-horizontal dt { + float: left; + width: 160px; + overflow: hidden; + clear: left; + text-align: right; + text-overflow: ellipsis; + white-space: nowrap; + } + .dl-horizontal dd { + margin-left: 180px; + } + .dl-horizontal dd:before, + .dl-horizontal dd:after { + display: table; + content: " "; + } + .dl-horizontal dd:after { + clear: both; + } + .dl-horizontal dd:before, + .dl-horizontal dd:after { + display: table; + content: " "; + } + .dl-horizontal dd:after { + clear: both; + } + .dl-horizontal dd:before, + .dl-horizontal dd:after { + display: table; + content: " "; + } + .dl-horizontal dd:after { + clear: both; + } + .dl-horizontal dd:before, + .dl-horizontal dd:after { + display: table; + content: " "; + } + .dl-horizontal dd:after { + clear: both; + } + .dl-horizontal dd:before, + .dl-horizontal dd:after { + display: table; + content: " "; + } + .dl-horizontal dd:after { + clear: both; + } +} + +abbr[title], +abbr[data-original-title] { + cursor: help; + border-bottom: 1px dotted #7a8288; +} + +abbr.initialism { + font-size: 90%; + text-transform: uppercase; +} + +blockquote { + padding: 10px 20px; + margin: 0 0 20px; + border-left: 5px solid #7a8288; +} + +blockquote p { + font-size: 17.5px; + font-weight: 300; + line-height: 1.25; +} + +blockquote p:last-child { + margin-bottom: 0; +} + +blockquote small { + display: block; + line-height: 1.428571429; + color: #7a8288; +} + +blockquote small:before { + content: '\2014 \00A0'; +} + +blockquote.pull-right { + padding-right: 15px; + padding-left: 0; + border-right: 5px solid #7a8288; + border-left: 0; +} + +blockquote.pull-right p, +blockquote.pull-right small { + text-align: right; +} + +blockquote.pull-right small:before { + content: ''; +} + +blockquote.pull-right small:after { + content: '\00A0 \2014'; +} + +q:before, +q:after, +blockquote:before, +blockquote:after { + content: ""; +} + +address { + display: block; + margin-bottom: 20px; + font-style: normal; + line-height: 1.428571429; +} + +code, +pre { + font-family: Monaco, Menlo, Consolas, "Courier New", monospace; +} + +code { + padding: 2px 4px; + font-size: 90%; + color: #c7254e; + white-space: nowrap; + background-color: #f9f2f4; + border-radius: 4px; +} + +pre { + display: block; + padding: 9.5px; + margin: 0 0 10px; + font-size: 13px; + line-height: 1.428571429; + color: #3a3f44; + word-break: break-all; + word-wrap: break-word; + background-color: #f5f5f5; + border: 1px solid #cccccc; + border-radius: 4px; +} + +pre.prettyprint { + margin-bottom: 20px; +} + +pre code { + padding: 0; + font-size: inherit; + color: inherit; + white-space: pre-wrap; + background-color: transparent; + border: 0; +} + +.pre-scrollable { + max-height: 340px; + overflow-y: scroll; +} + +.container { + padding-right: 15px; + padding-left: 15px; + margin-right: auto; + margin-left: auto; +} + +.container:before, +.container:after { + display: table; + content: " "; +} + +.container:after { + clear: both; +} + +.container:before, +.container:after { + display: table; + content: " "; +} + +.container:after { + clear: both; +} + +.container:before, +.container:after { + display: table; + content: " "; +} + +.container:after { + clear: both; +} + +.container:before, +.container:after { + display: table; + content: " "; +} + +.container:after { + clear: both; +} + +.container:before, +.container:after { + display: table; + content: " "; +} + +.container:after { + clear: both; +} + +.row { + margin-right: -15px; + margin-left: -15px; +} + +.row:before, +.row:after { + display: table; + content: " "; +} + +.row:after { + clear: both; +} + +.row:before, +.row:after { + display: table; + content: " "; +} + +.row:after { + clear: both; +} + +.row:before, +.row:after { + display: table; + content: " "; +} + +.row:after { + clear: both; +} + +.row:before, +.row:after { + display: table; + content: " "; +} + +.row:after { + clear: both; +} + +.row:before, +.row:after { + display: table; + content: " "; +} + +.row:after { + clear: both; +} + +.col-xs-1, +.col-xs-2, +.col-xs-3, +.col-xs-4, +.col-xs-5, +.col-xs-6, +.col-xs-7, +.col-xs-8, +.col-xs-9, +.col-xs-10, +.col-xs-11, +.col-xs-12, +.col-sm-1, +.col-sm-2, +.col-sm-3, +.col-sm-4, +.col-sm-5, +.col-sm-6, +.col-sm-7, +.col-sm-8, +.col-sm-9, +.col-sm-10, +.col-sm-11, +.col-sm-12, +.col-md-1, +.col-md-2, +.col-md-3, +.col-md-4, +.col-md-5, +.col-md-6, +.col-md-7, +.col-md-8, +.col-md-9, +.col-md-10, +.col-md-11, +.col-md-12, +.col-lg-1, +.col-lg-2, +.col-lg-3, +.col-lg-4, +.col-lg-5, +.col-lg-6, +.col-lg-7, +.col-lg-8, +.col-lg-9, +.col-lg-10, +.col-lg-11, +.col-lg-12 { + position: relative; + min-height: 1px; + padding-right: 15px; + padding-left: 15px; +} + +.col-xs-1, +.col-xs-2, +.col-xs-3, +.col-xs-4, +.col-xs-5, +.col-xs-6, +.col-xs-7, +.col-xs-8, +.col-xs-9, +.col-xs-10, +.col-xs-11 { + float: left; +} + +.col-xs-1 { + width: 8.333333333333332%; +} + +.col-xs-2 { + width: 16.666666666666664%; +} + +.col-xs-3 { + width: 25%; +} + +.col-xs-4 { + width: 33.33333333333333%; +} + +.col-xs-5 { + width: 41.66666666666667%; +} + +.col-xs-6 { + width: 50%; +} + +.col-xs-7 { + width: 58.333333333333336%; +} + +.col-xs-8 { + width: 66.66666666666666%; +} + +.col-xs-9 { + width: 75%; +} + +.col-xs-10 { + width: 83.33333333333334%; +} + +.col-xs-11 { + width: 91.66666666666666%; +} + +.col-xs-12 { + width: 100%; +} + +@media (min-width: 768px) { + .container { + max-width: 750px; + } + .col-sm-1, + .col-sm-2, + .col-sm-3, + .col-sm-4, + .col-sm-5, + .col-sm-6, + .col-sm-7, + .col-sm-8, + .col-sm-9, + .col-sm-10, + .col-sm-11 { + float: left; + } + .col-sm-1 { + width: 8.333333333333332%; + } + .col-sm-2 { + width: 16.666666666666664%; + } + .col-sm-3 { + width: 25%; + } + .col-sm-4 { + width: 33.33333333333333%; + } + .col-sm-5 { + width: 41.66666666666667%; + } + .col-sm-6 { + width: 50%; + } + .col-sm-7 { + width: 58.333333333333336%; + } + .col-sm-8 { + width: 66.66666666666666%; + } + .col-sm-9 { + width: 75%; + } + .col-sm-10 { + width: 83.33333333333334%; + } + .col-sm-11 { + width: 91.66666666666666%; + } + .col-sm-12 { + width: 100%; + } + .col-sm-push-1 { + left: 8.333333333333332%; + } + .col-sm-push-2 { + left: 16.666666666666664%; + } + .col-sm-push-3 { + left: 25%; + } + .col-sm-push-4 { + left: 33.33333333333333%; + } + .col-sm-push-5 { + left: 41.66666666666667%; + } + .col-sm-push-6 { + left: 50%; + } + .col-sm-push-7 { + left: 58.333333333333336%; + } + .col-sm-push-8 { + left: 66.66666666666666%; + } + .col-sm-push-9 { + left: 75%; + } + .col-sm-push-10 { + left: 83.33333333333334%; + } + .col-sm-push-11 { + left: 91.66666666666666%; + } + .col-sm-pull-1 { + right: 8.333333333333332%; + } + .col-sm-pull-2 { + right: 16.666666666666664%; + } + .col-sm-pull-3 { + right: 25%; + } + .col-sm-pull-4 { + right: 33.33333333333333%; + } + .col-sm-pull-5 { + right: 41.66666666666667%; + } + .col-sm-pull-6 { + right: 50%; + } + .col-sm-pull-7 { + right: 58.333333333333336%; + } + .col-sm-pull-8 { + right: 66.66666666666666%; + } + .col-sm-pull-9 { + right: 75%; + } + .col-sm-pull-10 { + right: 83.33333333333334%; + } + .col-sm-pull-11 { + right: 91.66666666666666%; + } + .col-sm-offset-1 { + margin-left: 8.333333333333332%; + } + .col-sm-offset-2 { + margin-left: 16.666666666666664%; + } + .col-sm-offset-3 { + margin-left: 25%; + } + .col-sm-offset-4 { + margin-left: 33.33333333333333%; + } + .col-sm-offset-5 { + margin-left: 41.66666666666667%; + } + .col-sm-offset-6 { + margin-left: 50%; + } + .col-sm-offset-7 { + margin-left: 58.333333333333336%; + } + .col-sm-offset-8 { + margin-left: 66.66666666666666%; + } + .col-sm-offset-9 { + margin-left: 75%; + } + .col-sm-offset-10 { + margin-left: 83.33333333333334%; + } + .col-sm-offset-11 { + margin-left: 91.66666666666666%; + } +} + +@media (min-width: 992px) { + .container { + max-width: 970px; + } + .col-md-1, + .col-md-2, + .col-md-3, + .col-md-4, + .col-md-5, + .col-md-6, + .col-md-7, + .col-md-8, + .col-md-9, + .col-md-10, + .col-md-11 { + float: left; + } + .col-md-1 { + width: 8.333333333333332%; + } + .col-md-2 { + width: 16.666666666666664%; + } + .col-md-3 { + width: 25%; + } + .col-md-4 { + width: 33.33333333333333%; + } + .col-md-5 { + width: 41.66666666666667%; + } + .col-md-6 { + width: 50%; + } + .col-md-7 { + width: 58.333333333333336%; + } + .col-md-8 { + width: 66.66666666666666%; + } + .col-md-9 { + width: 75%; + } + .col-md-10 { + width: 83.33333333333334%; + } + .col-md-11 { + width: 91.66666666666666%; + } + .col-md-12 { + width: 100%; + } + .col-md-push-0 { + left: auto; + } + .col-md-push-1 { + left: 8.333333333333332%; + } + .col-md-push-2 { + left: 16.666666666666664%; + } + .col-md-push-3 { + left: 25%; + } + .col-md-push-4 { + left: 33.33333333333333%; + } + .col-md-push-5 { + left: 41.66666666666667%; + } + .col-md-push-6 { + left: 50%; + } + .col-md-push-7 { + left: 58.333333333333336%; + } + .col-md-push-8 { + left: 66.66666666666666%; + } + .col-md-push-9 { + left: 75%; + } + .col-md-push-10 { + left: 83.33333333333334%; + } + .col-md-push-11 { + left: 91.66666666666666%; + } + .col-md-pull-0 { + right: auto; + } + .col-md-pull-1 { + right: 8.333333333333332%; + } + .col-md-pull-2 { + right: 16.666666666666664%; + } + .col-md-pull-3 { + right: 25%; + } + .col-md-pull-4 { + right: 33.33333333333333%; + } + .col-md-pull-5 { + right: 41.66666666666667%; + } + .col-md-pull-6 { + right: 50%; + } + .col-md-pull-7 { + right: 58.333333333333336%; + } + .col-md-pull-8 { + right: 66.66666666666666%; + } + .col-md-pull-9 { + right: 75%; + } + .col-md-pull-10 { + right: 83.33333333333334%; + } + .col-md-pull-11 { + right: 91.66666666666666%; + } + .col-md-offset-0 { + margin-left: 0; + } + .col-md-offset-1 { + margin-left: 8.333333333333332%; + } + .col-md-offset-2 { + margin-left: 16.666666666666664%; + } + .col-md-offset-3 { + margin-left: 25%; + } + .col-md-offset-4 { + margin-left: 33.33333333333333%; + } + .col-md-offset-5 { + margin-left: 41.66666666666667%; + } + .col-md-offset-6 { + margin-left: 50%; + } + .col-md-offset-7 { + margin-left: 58.333333333333336%; + } + .col-md-offset-8 { + margin-left: 66.66666666666666%; + } + .col-md-offset-9 { + margin-left: 75%; + } + .col-md-offset-10 { + margin-left: 83.33333333333334%; + } + .col-md-offset-11 { + margin-left: 91.66666666666666%; + } +} + +@media (min-width: 1200px) { + .container { + max-width: 1170px; + } + .col-lg-1, + .col-lg-2, + .col-lg-3, + .col-lg-4, + .col-lg-5, + .col-lg-6, + .col-lg-7, + .col-lg-8, + .col-lg-9, + .col-lg-10, + .col-lg-11 { + float: left; + } + .col-lg-1 { + width: 8.333333333333332%; + } + .col-lg-2 { + width: 16.666666666666664%; + } + .col-lg-3 { + width: 25%; + } + .col-lg-4 { + width: 33.33333333333333%; + } + .col-lg-5 { + width: 41.66666666666667%; + } + .col-lg-6 { + width: 50%; + } + .col-lg-7 { + width: 58.333333333333336%; + } + .col-lg-8 { + width: 66.66666666666666%; + } + .col-lg-9 { + width: 75%; + } + .col-lg-10 { + width: 83.33333333333334%; + } + .col-lg-11 { + width: 91.66666666666666%; + } + .col-lg-12 { + width: 100%; + } + .col-lg-push-0 { + left: auto; + } + .col-lg-push-1 { + left: 8.333333333333332%; + } + .col-lg-push-2 { + left: 16.666666666666664%; + } + .col-lg-push-3 { + left: 25%; + } + .col-lg-push-4 { + left: 33.33333333333333%; + } + .col-lg-push-5 { + left: 41.66666666666667%; + } + .col-lg-push-6 { + left: 50%; + } + .col-lg-push-7 { + left: 58.333333333333336%; + } + .col-lg-push-8 { + left: 66.66666666666666%; + } + .col-lg-push-9 { + left: 75%; + } + .col-lg-push-10 { + left: 83.33333333333334%; + } + .col-lg-push-11 { + left: 91.66666666666666%; + } + .col-lg-pull-0 { + right: auto; + } + .col-lg-pull-1 { + right: 8.333333333333332%; + } + .col-lg-pull-2 { + right: 16.666666666666664%; + } + .col-lg-pull-3 { + right: 25%; + } + .col-lg-pull-4 { + right: 33.33333333333333%; + } + .col-lg-pull-5 { + right: 41.66666666666667%; + } + .col-lg-pull-6 { + right: 50%; + } + .col-lg-pull-7 { + right: 58.333333333333336%; + } + .col-lg-pull-8 { + right: 66.66666666666666%; + } + .col-lg-pull-9 { + right: 75%; + } + .col-lg-pull-10 { + right: 83.33333333333334%; + } + .col-lg-pull-11 { + right: 91.66666666666666%; + } + .col-lg-offset-0 { + margin-left: 0; + } + .col-lg-offset-1 { + margin-left: 8.333333333333332%; + } + .col-lg-offset-2 { + margin-left: 16.666666666666664%; + } + .col-lg-offset-3 { + margin-left: 25%; + } + .col-lg-offset-4 { + margin-left: 33.33333333333333%; + } + .col-lg-offset-5 { + margin-left: 41.66666666666667%; + } + .col-lg-offset-6 { + margin-left: 50%; + } + .col-lg-offset-7 { + margin-left: 58.333333333333336%; + } + .col-lg-offset-8 { + margin-left: 66.66666666666666%; + } + .col-lg-offset-9 { + margin-left: 75%; + } + .col-lg-offset-10 { + margin-left: 83.33333333333334%; + } + .col-lg-offset-11 { + margin-left: 91.66666666666666%; + } +} + +table { + max-width: 100%; + background-color: #2e3338; +} + +th { + text-align: left; +} + +.table { + width: 100%; + margin-bottom: 20px; +} + +.table thead > tr > th, +.table tbody > tr > th, +.table tfoot > tr > th, +.table thead > tr > td, +.table tbody > tr > td, +.table tfoot > tr > td { + padding: 8px; + line-height: 1.428571429; + vertical-align: top; + border-top: 1px solid #1c1e22; +} + +.table thead > tr > th { + vertical-align: bottom; + border-bottom: 2px solid #1c1e22; +} + +.table caption + thead tr:first-child th, +.table colgroup + thead tr:first-child th, +.table thead:first-child tr:first-child th, +.table caption + thead tr:first-child td, +.table colgroup + thead tr:first-child td, +.table thead:first-child tr:first-child td { + border-top: 0; +} + +.table tbody + tbody { + border-top: 2px solid #1c1e22; +} + +.table .table { + background-color: #272b30; +} + +.table-condensed thead > tr > th, +.table-condensed tbody > tr > th, +.table-condensed tfoot > tr > th, +.table-condensed thead > tr > td, +.table-condensed tbody > tr > td, +.table-condensed tfoot > tr > td { + padding: 5px; +} + +.table-bordered { + border: 1px solid #1c1e22; +} + +.table-bordered > thead > tr > th, +.table-bordered > tbody > tr > th, +.table-bordered > tfoot > tr > th, +.table-bordered > thead > tr > td, +.table-bordered > tbody > tr > td, +.table-bordered > tfoot > tr > td { + border: 1px solid #1c1e22; +} + +.table-bordered > thead > tr > th, +.table-bordered > thead > tr > td { + border-bottom-width: 2px; +} + +.table-striped > tbody > tr:nth-child(odd) > td, +.table-striped > tbody > tr:nth-child(odd) > th { + background-color: #353a41; +} + +.table-hover > tbody > tr:hover > td, +.table-hover > tbody > tr:hover > th { + background-color: #49515a; +} + +table col[class*="col-"] { + display: table-column; + float: none; +} + +table td[class*="col-"], +table th[class*="col-"] { + display: table-cell; + float: none; +} + +.table > thead > tr > td.active, +.table > tbody > tr > td.active, +.table > tfoot > tr > td.active, +.table > thead > tr > th.active, +.table > tbody > tr > th.active, +.table > tfoot > tr > th.active, +.table > thead > tr.active > td, +.table > tbody > tr.active > td, +.table > tfoot > tr.active > td, +.table > thead > tr.active > th, +.table > tbody > tr.active > th, +.table > tfoot > tr.active > th { + background-color: #49515a; +} + +.table > thead > tr > td.success, +.table > tbody > tr > td.success, +.table > tfoot > tr > td.success, +.table > thead > tr > th.success, +.table > tbody > tr > th.success, +.table > tfoot > tr > th.success, +.table > thead > tr.success > td, +.table > tbody > tr.success > td, +.table > tfoot > tr.success > td, +.table > thead > tr.success > th, +.table > tbody > tr.success > th, +.table > tfoot > tr.success > th { + background-color: #62c462; + border-color: #62bd4f; +} + +.table-hover > tbody > tr > td.success:hover, +.table-hover > tbody > tr > th.success:hover, +.table-hover > tbody > tr.success:hover > td { + background-color: #4fbd4f; + border-color: #55b142; +} + +.table > thead > tr > td.danger, +.table > tbody > tr > td.danger, +.table > tfoot > tr > td.danger, +.table > thead > tr > th.danger, +.table > tbody > tr > th.danger, +.table > tfoot > tr > th.danger, +.table > thead > tr.danger > td, +.table > tbody > tr.danger > td, +.table > tfoot > tr.danger > td, +.table > thead > tr.danger > th, +.table > tbody > tr.danger > th, +.table > tfoot > tr.danger > th { + background-color: #ee5f5b; + border-color: #ed4d63; +} + +.table-hover > tbody > tr > td.danger:hover, +.table-hover > tbody > tr > th.danger:hover, +.table-hover > tbody > tr.danger:hover > td { + background-color: #ec4844; + border-color: #ea364f; +} + +.table > thead > tr > td.warning, +.table > tbody > tr > td.warning, +.table > tfoot > tr > td.warning, +.table > thead > tr > th.warning, +.table > tbody > tr > th.warning, +.table > tfoot > tr > th.warning, +.table > thead > tr.warning > td, +.table > tbody > tr.warning > td, +.table > tfoot > tr.warning > td, +.table > thead > tr.warning > th, +.table > tbody > tr.warning > th, +.table > tfoot > tr.warning > th { + background-color: #f89406; + border-color: #e96506; +} + +.table-hover > tbody > tr > td.warning:hover, +.table-hover > tbody > tr > th.warning:hover, +.table-hover > tbody > tr.warning:hover > td { + background-color: #df8505; + border-color: #d05a05; +} + +@media (max-width: 768px) { + .table-responsive { + width: 100%; + margin-bottom: 15px; + overflow-x: scroll; + overflow-y: hidden; + border: 1px solid #1c1e22; + } + .table-responsive > .table { + margin-bottom: 0; + background-color: #fff; + } + .table-responsive > .table > thead > tr > th, + .table-responsive > .table > tbody > tr > th, + .table-responsive > .table > tfoot > tr > th, + .table-responsive > .table > thead > tr > td, + .table-responsive > .table > tbody > tr > td, + .table-responsive > .table > tfoot > tr > td { + white-space: nowrap; + } + .table-responsive > .table-bordered { + border: 0; + } + .table-responsive > .table-bordered > thead > tr > th:first-child, + .table-responsive > .table-bordered > tbody > tr > th:first-child, + .table-responsive > .table-bordered > tfoot > tr > th:first-child, + .table-responsive > .table-bordered > thead > tr > td:first-child, + .table-responsive > .table-bordered > tbody > tr > td:first-child, + .table-responsive > .table-bordered > tfoot > tr > td:first-child { + border-left: 0; + } + .table-responsive > .table-bordered > thead > tr > th:last-child, + .table-responsive > .table-bordered > tbody > tr > th:last-child, + .table-responsive > .table-bordered > tfoot > tr > th:last-child, + .table-responsive > .table-bordered > thead > tr > td:last-child, + .table-responsive > .table-bordered > tbody > tr > td:last-child, + .table-responsive > .table-bordered > tfoot > tr > td:last-child { + border-right: 0; + } + .table-responsive > .table-bordered > thead > tr:last-child > th, + .table-responsive > .table-bordered > tbody > tr:last-child > th, + .table-responsive > .table-bordered > tfoot > tr:last-child > th, + .table-responsive > .table-bordered > thead > tr:last-child > td, + .table-responsive > .table-bordered > tbody > tr:last-child > td, + .table-responsive > .table-bordered > tfoot > tr:last-child > td { + border-bottom: 0; + } +} + +fieldset { + padding: 0; + margin: 0; + border: 0; +} + +legend { + display: block; + width: 100%; + padding: 0; + margin-bottom: 20px; + font-size: 21px; + line-height: inherit; + color: #c8c8c8; + border: 0; + border-bottom: 1px solid #1c1e22; +} + +label { + display: inline-block; + margin-bottom: 5px; + font-weight: bold; +} + +input[type="search"] { + -webkit-box-sizing: border-box; + -moz-box-sizing: border-box; + box-sizing: border-box; +} + +input[type="radio"], +input[type="checkbox"] { + margin: 4px 0 0; + margin-top: 1px \9; + /* IE8-9 */ + + line-height: normal; +} + +input[type="file"] { + display: block; +} + +select[multiple], +select[size] { + height: auto; +} + +select optgroup { + font-family: inherit; + font-size: inherit; + font-style: inherit; +} + +input[type="file"]:focus, +input[type="radio"]:focus, +input[type="checkbox"]:focus { + outline: thin dotted #333; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; +} + +input[type="number"]::-webkit-outer-spin-button, +input[type="number"]::-webkit-inner-spin-button { + height: auto; +} + +.form-control:-moz-placeholder { + color: #7a8288; +} + +.form-control::-moz-placeholder { + color: #7a8288; +} + +.form-control:-ms-input-placeholder { + color: #7a8288; +} + +.form-control::-webkit-input-placeholder { + color: #7a8288; +} + +.form-control { + display: block; + width: 100%; + height: 38px; + padding: 8px 12px; + font-size: 14px; + line-height: 1.428571429; + color: #272b30; + vertical-align: middle; + background-color: #ffffff; + border: 1px solid #cccccc; + border-radius: 4px; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + -webkit-transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s; + transition: border-color ease-in-out 0.15s, box-shadow ease-in-out 0.15s; +} + +.form-control:focus { + border-color: #66afe9; + outline: 0; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(102, 175, 233, 0.6); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 8px rgba(102, 175, 233, 0.6); +} + +.form-control[disabled], +.form-control[readonly], +fieldset[disabled] .form-control { + cursor: not-allowed; + background-color: #999999; +} + +textarea.form-control { + height: auto; +} + +.form-group { + margin-bottom: 15px; +} + +.radio, +.checkbox { + display: block; + min-height: 20px; + padding-left: 20px; + margin-top: 10px; + margin-bottom: 10px; + vertical-align: middle; +} + +.radio label, +.checkbox label { + display: inline; + margin-bottom: 0; + font-weight: normal; + cursor: pointer; +} + +.radio input[type="radio"], +.radio-inline input[type="radio"], +.checkbox input[type="checkbox"], +.checkbox-inline input[type="checkbox"] { + float: left; + margin-left: -20px; +} + +.radio + .radio, +.checkbox + .checkbox { + margin-top: -5px; +} + +.radio-inline, +.checkbox-inline { + display: inline-block; + padding-left: 20px; + margin-bottom: 0; + font-weight: normal; + vertical-align: middle; + cursor: pointer; +} + +.radio-inline + .radio-inline, +.checkbox-inline + .checkbox-inline { + margin-top: 0; + margin-left: 10px; +} + +input[type="radio"][disabled], +input[type="checkbox"][disabled], +.radio[disabled], +.radio-inline[disabled], +.checkbox[disabled], +.checkbox-inline[disabled], +fieldset[disabled] input[type="radio"], +fieldset[disabled] input[type="checkbox"], +fieldset[disabled] .radio, +fieldset[disabled] .radio-inline, +fieldset[disabled] .checkbox, +fieldset[disabled] .checkbox-inline { + cursor: not-allowed; +} + +.input-sm { + height: 30px; + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; +} + +select.input-sm { + height: 30px; + line-height: 30px; +} + +textarea.input-sm { + height: auto; +} + +.input-lg { + height: 56px; + padding: 14px 16px; + font-size: 18px; + line-height: 1.33; + border-radius: 6px; +} + +select.input-lg { + height: 56px; + line-height: 56px; +} + +textarea.input-lg { + height: auto; +} + +.has-warning .help-block, +.has-warning .control-label { + color: #ffffff; +} + +.has-warning .form-control { + border-color: #ffffff; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); +} + +.has-warning .form-control:focus { + border-color: #e6e6e6; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ffffff; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ffffff; +} + +.has-warning .input-group-addon { + color: #ffffff; + background-color: #f89406; + border-color: #ffffff; +} + +.has-error .help-block, +.has-error .control-label { + color: #ffffff; +} + +.has-error .form-control { + border-color: #ffffff; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); +} + +.has-error .form-control:focus { + border-color: #e6e6e6; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ffffff; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ffffff; +} + +.has-error .input-group-addon { + color: #ffffff; + background-color: #ee5f5b; + border-color: #ffffff; +} + +.has-success .help-block, +.has-success .control-label { + color: #ffffff; +} + +.has-success .form-control { + border-color: #ffffff; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); +} + +.has-success .form-control:focus { + border-color: #e6e6e6; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ffffff; + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075), 0 0 6px #ffffff; +} + +.has-success .input-group-addon { + color: #ffffff; + background-color: #62c462; + border-color: #ffffff; +} + +.form-control-static { + padding-top: 9px; + margin-bottom: 0; +} + +.help-block { + display: block; + margin-top: 5px; + margin-bottom: 10px; + color: #ffffff; +} + +@media (min-width: 768px) { + .form-inline .form-group { + display: inline-block; + margin-bottom: 0; + vertical-align: middle; + } + .form-inline .form-control { + display: inline-block; + } + .form-inline .radio, + .form-inline .checkbox { + display: inline-block; + padding-left: 0; + margin-top: 0; + margin-bottom: 0; + } + .form-inline .radio input[type="radio"], + .form-inline .checkbox input[type="checkbox"] { + float: none; + margin-left: 0; + } +} + +.form-horizontal .control-label, +.form-horizontal .radio, +.form-horizontal .checkbox, +.form-horizontal .radio-inline, +.form-horizontal .checkbox-inline { + padding-top: 9px; + margin-top: 0; + margin-bottom: 0; +} + +.form-horizontal .form-group { + margin-right: -15px; + margin-left: -15px; +} + +.form-horizontal .form-group:before, +.form-horizontal .form-group:after { + display: table; + content: " "; +} + +.form-horizontal .form-group:after { + clear: both; +} + +.form-horizontal .form-group:before, +.form-horizontal .form-group:after { + display: table; + content: " "; +} + +.form-horizontal .form-group:after { + clear: both; +} + +.form-horizontal .form-group:before, +.form-horizontal .form-group:after { + display: table; + content: " "; +} + +.form-horizontal .form-group:after { + clear: both; +} + +.form-horizontal .form-group:before, +.form-horizontal .form-group:after { + display: table; + content: " "; +} + +.form-horizontal .form-group:after { + clear: both; +} + +.form-horizontal .form-group:before, +.form-horizontal .form-group:after { + display: table; + content: " "; +} + +.form-horizontal .form-group:after { + clear: both; +} + +@media (min-width: 768px) { + .form-horizontal .control-label { + text-align: right; + } +} + +.btn { + display: inline-block; + padding: 8px 12px; + margin-bottom: 0; + font-size: 14px; + font-weight: normal; + line-height: 1.428571429; + text-align: center; + white-space: nowrap; + vertical-align: middle; + cursor: pointer; + border: 1px solid transparent; + border-radius: 4px; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + -o-user-select: none; + user-select: none; +} + +.btn:focus { + outline: thin dotted #333; + outline: 5px auto -webkit-focus-ring-color; + outline-offset: -2px; +} + +.btn:hover, +.btn:focus { + color: #ffffff; + text-decoration: none; +} + +.btn:active, +.btn.active { + background-image: none; + outline: 0; + -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); + box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); +} + +.btn.disabled, +.btn[disabled], +fieldset[disabled] .btn { + pointer-events: none; + cursor: not-allowed; + opacity: 0.65; + filter: alpha(opacity=65); + -webkit-box-shadow: none; + box-shadow: none; +} + +.btn-default { + color: #ffffff; + background-color: #3a3f44; + border-color: #3a3f44; +} + +.btn-default:hover, +.btn-default:focus, +.btn-default:active, +.btn-default.active, +.open .dropdown-toggle.btn-default { + color: #ffffff; + background-color: #272b2e; + border-color: #1e2023; +} + +.btn-default:active, +.btn-default.active, +.open .dropdown-toggle.btn-default { + background-image: none; +} + +.btn-default.disabled, +.btn-default[disabled], +fieldset[disabled] .btn-default, +.btn-default.disabled:hover, +.btn-default[disabled]:hover, +fieldset[disabled] .btn-default:hover, +.btn-default.disabled:focus, +.btn-default[disabled]:focus, +fieldset[disabled] .btn-default:focus, +.btn-default.disabled:active, +.btn-default[disabled]:active, +fieldset[disabled] .btn-default:active, +.btn-default.disabled.active, +.btn-default[disabled].active, +fieldset[disabled] .btn-default.active { + background-color: #3a3f44; + border-color: #3a3f44; +} + +.btn-primary { + color: #ffffff; + background-color: #7a8288; + border-color: #7a8288; +} + +.btn-primary:hover, +.btn-primary:focus, +.btn-primary:active, +.btn-primary.active, +.open .dropdown-toggle.btn-primary { + color: #ffffff; + background-color: #676d73; + border-color: #5d6368; +} + +.btn-primary:active, +.btn-primary.active, +.open .dropdown-toggle.btn-primary { + background-image: none; +} + +.btn-primary.disabled, +.btn-primary[disabled], +fieldset[disabled] .btn-primary, +.btn-primary.disabled:hover, +.btn-primary[disabled]:hover, +fieldset[disabled] .btn-primary:hover, +.btn-primary.disabled:focus, +.btn-primary[disabled]:focus, +fieldset[disabled] .btn-primary:focus, +.btn-primary.disabled:active, +.btn-primary[disabled]:active, +fieldset[disabled] .btn-primary:active, +.btn-primary.disabled.active, +.btn-primary[disabled].active, +fieldset[disabled] .btn-primary.active { + background-color: #7a8288; + border-color: #7a8288; +} + +.btn-warning { + color: #ffffff; + background-color: #f89406; + border-color: #f89406; +} + +.btn-warning:hover, +.btn-warning:focus, +.btn-warning:active, +.btn-warning.active, +.open .dropdown-toggle.btn-warning { + color: #ffffff; + background-color: #d07c05; + border-color: #bc7005; +} + +.btn-warning:active, +.btn-warning.active, +.open .dropdown-toggle.btn-warning { + background-image: none; +} + +.btn-warning.disabled, +.btn-warning[disabled], +fieldset[disabled] .btn-warning, +.btn-warning.disabled:hover, +.btn-warning[disabled]:hover, +fieldset[disabled] .btn-warning:hover, +.btn-warning.disabled:focus, +.btn-warning[disabled]:focus, +fieldset[disabled] .btn-warning:focus, +.btn-warning.disabled:active, +.btn-warning[disabled]:active, +fieldset[disabled] .btn-warning:active, +.btn-warning.disabled.active, +.btn-warning[disabled].active, +fieldset[disabled] .btn-warning.active { + background-color: #f89406; + border-color: #f89406; +} + +.btn-danger { + color: #ffffff; + background-color: #ee5f5b; + border-color: #ee5f5b; +} + +.btn-danger:hover, +.btn-danger:focus, +.btn-danger:active, +.btn-danger.active, +.open .dropdown-toggle.btn-danger { + color: #ffffff; + background-color: #ea3b36; + border-color: #e82924; +} + +.btn-danger:active, +.btn-danger.active, +.open .dropdown-toggle.btn-danger { + background-image: none; +} + +.btn-danger.disabled, +.btn-danger[disabled], +fieldset[disabled] .btn-danger, +.btn-danger.disabled:hover, +.btn-danger[disabled]:hover, +fieldset[disabled] .btn-danger:hover, +.btn-danger.disabled:focus, +.btn-danger[disabled]:focus, +fieldset[disabled] .btn-danger:focus, +.btn-danger.disabled:active, +.btn-danger[disabled]:active, +fieldset[disabled] .btn-danger:active, +.btn-danger.disabled.active, +.btn-danger[disabled].active, +fieldset[disabled] .btn-danger.active { + background-color: #ee5f5b; + border-color: #ee5f5b; +} + +.btn-success { + color: #ffffff; + background-color: #62c462; + border-color: #62c462; +} + +.btn-success:hover, +.btn-success:focus, +.btn-success:active, +.btn-success.active, +.open .dropdown-toggle.btn-success { + color: #ffffff; + background-color: #45b845; + border-color: #40a940; +} + +.btn-success:active, +.btn-success.active, +.open .dropdown-toggle.btn-success { + background-image: none; +} + +.btn-success.disabled, +.btn-success[disabled], +fieldset[disabled] .btn-success, +.btn-success.disabled:hover, +.btn-success[disabled]:hover, +fieldset[disabled] .btn-success:hover, +.btn-success.disabled:focus, +.btn-success[disabled]:focus, +fieldset[disabled] .btn-success:focus, +.btn-success.disabled:active, +.btn-success[disabled]:active, +fieldset[disabled] .btn-success:active, +.btn-success.disabled.active, +.btn-success[disabled].active, +fieldset[disabled] .btn-success.active { + background-color: #62c462; + border-color: #62c462; +} + +.btn-info { + color: #ffffff; + background-color: #5bc0de; + border-color: #5bc0de; +} + +.btn-info:hover, +.btn-info:focus, +.btn-info:active, +.btn-info.active, +.open .dropdown-toggle.btn-info { + color: #ffffff; + background-color: #39b3d7; + border-color: #2aabd2; +} + +.btn-info:active, +.btn-info.active, +.open .dropdown-toggle.btn-info { + background-image: none; +} + +.btn-info.disabled, +.btn-info[disabled], +fieldset[disabled] .btn-info, +.btn-info.disabled:hover, +.btn-info[disabled]:hover, +fieldset[disabled] .btn-info:hover, +.btn-info.disabled:focus, +.btn-info[disabled]:focus, +fieldset[disabled] .btn-info:focus, +.btn-info.disabled:active, +.btn-info[disabled]:active, +fieldset[disabled] .btn-info:active, +.btn-info.disabled.active, +.btn-info[disabled].active, +fieldset[disabled] .btn-info.active { + background-color: #5bc0de; + border-color: #5bc0de; +} + +.btn-link { + font-weight: normal; + color: #ffffff; + cursor: pointer; + border-radius: 0; +} + +.btn-link, +.btn-link:active, +.btn-link[disabled], +fieldset[disabled] .btn-link { + background-color: transparent; + -webkit-box-shadow: none; + box-shadow: none; +} + +.btn-link, +.btn-link:hover, +.btn-link:focus, +.btn-link:active { + border-color: transparent; +} + +.btn-link:hover, +.btn-link:focus { + color: #ffffff; + text-decoration: underline; + background-color: transparent; +} + +.btn-link[disabled]:hover, +fieldset[disabled] .btn-link:hover, +.btn-link[disabled]:focus, +fieldset[disabled] .btn-link:focus { + color: #7a8288; + text-decoration: none; +} + +.btn-lg { + padding: 14px 16px; + font-size: 18px; + line-height: 1.33; + border-radius: 6px; +} + +.btn-sm, +.btn-xs { + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; +} + +.btn-xs { + padding: 1px 5px; +} + +.btn-block { + display: block; + width: 100%; + padding-right: 0; + padding-left: 0; +} + +.btn-block + .btn-block { + margin-top: 5px; +} + +input[type="submit"].btn-block, +input[type="reset"].btn-block, +input[type="button"].btn-block { + width: 100%; +} + +.fade { + opacity: 0; + -webkit-transition: opacity 0.15s linear; + transition: opacity 0.15s linear; +} + +.fade.in { + opacity: 1; +} + +.collapse { + display: none; +} + +.collapse.in { + display: block; +} + +.collapsing { + position: relative; + height: 0; + overflow: hidden; + -webkit-transition: height 0.35s ease; + transition: height 0.35s ease; +} + +@font-face { + font-family: 'Glyphicons Halflings'; + src: url('../fonts/glyphicons-halflings-regular.eot'); + src: url('../fonts/glyphicons-halflings-regular.eot?#iefix') format('embedded-opentype'), url('../fonts/glyphicons-halflings-regular.woff') format('woff'), url('../fonts/glyphicons-halflings-regular.ttf') format('truetype'), url('../fonts/glyphicons-halflings-regular.svg#glyphicons-halflingsregular') format('svg'); +} + +.glyphicon { + position: relative; + top: 1px; + display: inline-block; + font-family: 'Glyphicons Halflings'; + -webkit-font-smoothing: antialiased; + font-style: normal; + font-weight: normal; + line-height: 1; +} + +.glyphicon-asterisk:before { + content: "\2a"; +} + +.glyphicon-plus:before { + content: "\2b"; +} + +.glyphicon-euro:before { + content: "\20ac"; +} + +.glyphicon-minus:before { + content: "\2212"; +} + +.glyphicon-cloud:before { + content: "\2601"; +} + +.glyphicon-envelope:before { + content: "\2709"; +} + +.glyphicon-pencil:before { + content: "\270f"; +} + +.glyphicon-glass:before { + content: "\e001"; +} + +.glyphicon-music:before { + content: "\e002"; +} + +.glyphicon-search:before { + content: "\e003"; +} + +.glyphicon-heart:before { + content: "\e005"; +} + +.glyphicon-star:before { + content: "\e006"; +} + +.glyphicon-star-empty:before { + content: "\e007"; +} + +.glyphicon-user:before { + content: "\e008"; +} + +.glyphicon-film:before { + content: "\e009"; +} + +.glyphicon-th-large:before { + content: "\e010"; +} + +.glyphicon-th:before { + content: "\e011"; +} + +.glyphicon-th-list:before { + content: "\e012"; +} + +.glyphicon-ok:before { + content: "\e013"; +} + +.glyphicon-remove:before { + content: "\e014"; +} + +.glyphicon-zoom-in:before { + content: "\e015"; +} + +.glyphicon-zoom-out:before { + content: "\e016"; +} + +.glyphicon-off:before { + content: "\e017"; +} + +.glyphicon-signal:before { + content: "\e018"; +} + +.glyphicon-cog:before { + content: "\e019"; +} + +.glyphicon-trash:before { + content: "\e020"; +} + +.glyphicon-home:before { + content: "\e021"; +} + +.glyphicon-file:before { + content: "\e022"; +} + +.glyphicon-time:before { + content: "\e023"; +} + +.glyphicon-road:before { + content: "\e024"; +} + +.glyphicon-download-alt:before { + content: "\e025"; +} + +.glyphicon-download:before { + content: "\e026"; +} + +.glyphicon-upload:before { + content: "\e027"; +} + +.glyphicon-inbox:before { + content: "\e028"; +} + +.glyphicon-play-circle:before { + content: "\e029"; +} + +.glyphicon-repeat:before { + content: "\e030"; +} + +.glyphicon-refresh:before { + content: "\e031"; +} + +.glyphicon-list-alt:before { + content: "\e032"; +} + +.glyphicon-flag:before { + content: "\e034"; +} + +.glyphicon-headphones:before { + content: "\e035"; +} + +.glyphicon-volume-off:before { + content: "\e036"; +} + +.glyphicon-volume-down:before { + content: "\e037"; +} + +.glyphicon-volume-up:before { + content: "\e038"; +} + +.glyphicon-qrcode:before { + content: "\e039"; +} + +.glyphicon-barcode:before { + content: "\e040"; +} + +.glyphicon-tag:before { + content: "\e041"; +} + +.glyphicon-tags:before { + content: "\e042"; +} + +.glyphicon-book:before { + content: "\e043"; +} + +.glyphicon-print:before { + content: "\e045"; +} + +.glyphicon-font:before { + content: "\e047"; +} + +.glyphicon-bold:before { + content: "\e048"; +} + +.glyphicon-italic:before { + content: "\e049"; +} + +.glyphicon-text-height:before { + content: "\e050"; +} + +.glyphicon-text-width:before { + content: "\e051"; +} + +.glyphicon-align-left:before { + content: "\e052"; +} + +.glyphicon-align-center:before { + content: "\e053"; +} + +.glyphicon-align-right:before { + content: "\e054"; +} + +.glyphicon-align-justify:before { + content: "\e055"; +} + +.glyphicon-list:before { + content: "\e056"; +} + +.glyphicon-indent-left:before { + content: "\e057"; +} + +.glyphicon-indent-right:before { + content: "\e058"; +} + +.glyphicon-facetime-video:before { + content: "\e059"; +} + +.glyphicon-picture:before { + content: "\e060"; +} + +.glyphicon-map-marker:before { + content: "\e062"; +} + +.glyphicon-adjust:before { + content: "\e063"; +} + +.glyphicon-tint:before { + content: "\e064"; +} + +.glyphicon-edit:before { + content: "\e065"; +} + +.glyphicon-share:before { + content: "\e066"; +} + +.glyphicon-check:before { + content: "\e067"; +} + +.glyphicon-move:before { + content: "\e068"; +} + +.glyphicon-step-backward:before { + content: "\e069"; +} + +.glyphicon-fast-backward:before { + content: "\e070"; +} + +.glyphicon-backward:before { + content: "\e071"; +} + +.glyphicon-play:before { + content: "\e072"; +} + +.glyphicon-pause:before { + content: "\e073"; +} + +.glyphicon-stop:before { + content: "\e074"; +} + +.glyphicon-forward:before { + content: "\e075"; +} + +.glyphicon-fast-forward:before { + content: "\e076"; +} + +.glyphicon-step-forward:before { + content: "\e077"; +} + +.glyphicon-eject:before { + content: "\e078"; +} + +.glyphicon-chevron-left:before { + content: "\e079"; +} + +.glyphicon-chevron-right:before { + content: "\e080"; +} + +.glyphicon-plus-sign:before { + content: "\e081"; +} + +.glyphicon-minus-sign:before { + content: "\e082"; +} + +.glyphicon-remove-sign:before { + content: "\e083"; +} + +.glyphicon-ok-sign:before { + content: "\e084"; +} + +.glyphicon-question-sign:before { + content: "\e085"; +} + +.glyphicon-info-sign:before { + content: "\e086"; +} + +.glyphicon-screenshot:before { + content: "\e087"; +} + +.glyphicon-remove-circle:before { + content: "\e088"; +} + +.glyphicon-ok-circle:before { + content: "\e089"; +} + +.glyphicon-ban-circle:before { + content: "\e090"; +} + +.glyphicon-arrow-left:before { + content: "\e091"; +} + +.glyphicon-arrow-right:before { + content: "\e092"; +} + +.glyphicon-arrow-up:before { + content: "\e093"; +} + +.glyphicon-arrow-down:before { + content: "\e094"; +} + +.glyphicon-share-alt:before { + content: "\e095"; +} + +.glyphicon-resize-full:before { + content: "\e096"; +} + +.glyphicon-resize-small:before { + content: "\e097"; +} + +.glyphicon-exclamation-sign:before { + content: "\e101"; +} + +.glyphicon-gift:before { + content: "\e102"; +} + +.glyphicon-leaf:before { + content: "\e103"; +} + +.glyphicon-eye-open:before { + content: "\e105"; +} + +.glyphicon-eye-close:before { + content: "\e106"; +} + +.glyphicon-warning-sign:before { + content: "\e107"; +} + +.glyphicon-plane:before { + content: "\e108"; +} + +.glyphicon-random:before { + content: "\e110"; +} + +.glyphicon-comment:before { + content: "\e111"; +} + +.glyphicon-magnet:before { + content: "\e112"; +} + +.glyphicon-chevron-up:before { + content: "\e113"; +} + +.glyphicon-chevron-down:before { + content: "\e114"; +} + +.glyphicon-retweet:before { + content: "\e115"; +} + +.glyphicon-shopping-cart:before { + content: "\e116"; +} + +.glyphicon-folder-close:before { + content: "\e117"; +} + +.glyphicon-folder-open:before { + content: "\e118"; +} + +.glyphicon-resize-vertical:before { + content: "\e119"; +} + +.glyphicon-resize-horizontal:before { + content: "\e120"; +} + +.glyphicon-hdd:before { + content: "\e121"; +} + +.glyphicon-bullhorn:before { + content: "\e122"; +} + +.glyphicon-certificate:before { + content: "\e124"; +} + +.glyphicon-thumbs-up:before { + content: "\e125"; +} + +.glyphicon-thumbs-down:before { + content: "\e126"; +} + +.glyphicon-hand-right:before { + content: "\e127"; +} + +.glyphicon-hand-left:before { + content: "\e128"; +} + +.glyphicon-hand-up:before { + content: "\e129"; +} + +.glyphicon-hand-down:before { + content: "\e130"; +} + +.glyphicon-circle-arrow-right:before { + content: "\e131"; +} + +.glyphicon-circle-arrow-left:before { + content: "\e132"; +} + +.glyphicon-circle-arrow-up:before { + content: "\e133"; +} + +.glyphicon-circle-arrow-down:before { + content: "\e134"; +} + +.glyphicon-globe:before { + content: "\e135"; +} + +.glyphicon-tasks:before { + content: "\e137"; +} + +.glyphicon-filter:before { + content: "\e138"; +} + +.glyphicon-fullscreen:before { + content: "\e140"; +} + +.glyphicon-dashboard:before { + content: "\e141"; +} + +.glyphicon-heart-empty:before { + content: "\e143"; +} + +.glyphicon-link:before { + content: "\e144"; +} + +.glyphicon-phone:before { + content: "\e145"; +} + +.glyphicon-usd:before { + content: "\e148"; +} + +.glyphicon-gbp:before { + content: "\e149"; +} + +.glyphicon-sort:before { + content: "\e150"; +} + +.glyphicon-sort-by-alphabet:before { + content: "\e151"; +} + +.glyphicon-sort-by-alphabet-alt:before { + content: "\e152"; +} + +.glyphicon-sort-by-order:before { + content: "\e153"; +} + +.glyphicon-sort-by-order-alt:before { + content: "\e154"; +} + +.glyphicon-sort-by-attributes:before { + content: "\e155"; +} + +.glyphicon-sort-by-attributes-alt:before { + content: "\e156"; +} + +.glyphicon-unchecked:before { + content: "\e157"; +} + +.glyphicon-expand:before { + content: "\e158"; +} + +.glyphicon-collapse-down:before { + content: "\e159"; +} + +.glyphicon-collapse-up:before { + content: "\e160"; +} + +.glyphicon-log-in:before { + content: "\e161"; +} + +.glyphicon-flash:before { + content: "\e162"; +} + +.glyphicon-log-out:before { + content: "\e163"; +} + +.glyphicon-new-window:before { + content: "\e164"; +} + +.glyphicon-record:before { + content: "\e165"; +} + +.glyphicon-save:before { + content: "\e166"; +} + +.glyphicon-open:before { + content: "\e167"; +} + +.glyphicon-saved:before { + content: "\e168"; +} + +.glyphicon-import:before { + content: "\e169"; +} + +.glyphicon-export:before { + content: "\e170"; +} + +.glyphicon-send:before { + content: "\e171"; +} + +.glyphicon-floppy-disk:before { + content: "\e172"; +} + +.glyphicon-floppy-saved:before { + content: "\e173"; +} + +.glyphicon-floppy-remove:before { + content: "\e174"; +} + +.glyphicon-floppy-save:before { + content: "\e175"; +} + +.glyphicon-floppy-open:before { + content: "\e176"; +} + +.glyphicon-credit-card:before { + content: "\e177"; +} + +.glyphicon-transfer:before { + content: "\e178"; +} + +.glyphicon-cutlery:before { + content: "\e179"; +} + +.glyphicon-header:before { + content: "\e180"; +} + +.glyphicon-compressed:before { + content: "\e181"; +} + +.glyphicon-earphone:before { + content: "\e182"; +} + +.glyphicon-phone-alt:before { + content: "\e183"; +} + +.glyphicon-tower:before { + content: "\e184"; +} + +.glyphicon-stats:before { + content: "\e185"; +} + +.glyphicon-sd-video:before { + content: "\e186"; +} + +.glyphicon-hd-video:before { + content: "\e187"; +} + +.glyphicon-subtitles:before { + content: "\e188"; +} + +.glyphicon-sound-stereo:before { + content: "\e189"; +} + +.glyphicon-sound-dolby:before { + content: "\e190"; +} + +.glyphicon-sound-5-1:before { + content: "\e191"; +} + +.glyphicon-sound-6-1:before { + content: "\e192"; +} + +.glyphicon-sound-7-1:before { + content: "\e193"; +} + +.glyphicon-copyright-mark:before { + content: "\e194"; +} + +.glyphicon-registration-mark:before { + content: "\e195"; +} + +.glyphicon-cloud-download:before { + content: "\e197"; +} + +.glyphicon-cloud-upload:before { + content: "\e198"; +} + +.glyphicon-tree-conifer:before { + content: "\e199"; +} + +.glyphicon-tree-deciduous:before { + content: "\e200"; +} + +.glyphicon-briefcase:before { + content: "\1f4bc"; +} + +.glyphicon-calendar:before { + content: "\1f4c5"; +} + +.glyphicon-pushpin:before { + content: "\1f4cc"; +} + +.glyphicon-paperclip:before { + content: "\1f4ce"; +} + +.glyphicon-camera:before { + content: "\1f4f7"; +} + +.glyphicon-lock:before { + content: "\1f512"; +} + +.glyphicon-bell:before { + content: "\1f514"; +} + +.glyphicon-bookmark:before { + content: "\1f516"; +} + +.glyphicon-fire:before { + content: "\1f525"; +} + +.glyphicon-wrench:before { + content: "\1f527"; +} + +.caret { + display: inline-block; + width: 0; + height: 0; + margin-left: 2px; + vertical-align: middle; + border-top: 4px solid #000000; + border-right: 4px solid transparent; + border-bottom: 0 dotted; + border-left: 4px solid transparent; + content: ""; +} + +.dropdown { + position: relative; +} + +.dropdown-toggle:focus { + outline: 0; +} + +.dropdown-menu { + position: absolute; + top: 100%; + left: 0; + z-index: 1000; + display: none; + float: left; + min-width: 160px; + padding: 5px 0; + margin: 2px 0 0; + font-size: 14px; + list-style: none; + background-color: #3a3f44; + border: 1px solid #272b30; + border: 1px solid rgba(0, 0, 0, 0.15); + border-radius: 4px; + -webkit-box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175); + box-shadow: 0 6px 12px rgba(0, 0, 0, 0.175); + background-clip: padding-box; +} + +.dropdown-menu.pull-right { + right: 0; + left: auto; +} + +.dropdown-menu .divider { + height: 1px; + margin: 9px 0; + overflow: hidden; + background-color: #272b30; +} + +.dropdown-menu > li > a { + display: block; + padding: 3px 20px; + clear: both; + font-weight: normal; + line-height: 1.428571429; + color: #c8c8c8; + white-space: nowrap; +} + +.dropdown-menu > li > a:hover, +.dropdown-menu > li > a:focus { + color: #ffffff; + text-decoration: none; + background-color: #272b30; +} + +.dropdown-menu > .active > a, +.dropdown-menu > .active > a:hover, +.dropdown-menu > .active > a:focus { + color: #ffffff; + text-decoration: none; + background-color: #272b30; + outline: 0; +} + +.dropdown-menu > .disabled > a, +.dropdown-menu > .disabled > a:hover, +.dropdown-menu > .disabled > a:focus { + color: #7a8288; +} + +.dropdown-menu > .disabled > a:hover, +.dropdown-menu > .disabled > a:focus { + text-decoration: none; + cursor: not-allowed; + background-color: transparent; + background-image: none; + filter: progid:DXImageTransform.Microsoft.gradient(enabled=false); +} + +.open > .dropdown-menu { + display: block; +} + +.open > a { + outline: 0; +} + +.dropdown-header { + display: block; + padding: 3px 20px; + font-size: 12px; + line-height: 1.428571429; + color: #7a8288; +} + +.dropdown-backdrop { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 990; +} + +.pull-right > .dropdown-menu { + right: 0; + left: auto; +} + +.dropup .caret, +.navbar-fixed-bottom .dropdown .caret { + border-top: 0 dotted; + border-bottom: 4px solid #000000; + content: ""; +} + +.dropup .dropdown-menu, +.navbar-fixed-bottom .dropdown .dropdown-menu { + top: auto; + bottom: 100%; + margin-bottom: 1px; +} + +@media (min-width: 768px) { + .navbar-right .dropdown-menu { + right: 0; + left: auto; + } +} + +.btn-default .caret { + border-top-color: #ffffff; +} + +.btn-primary .caret, +.btn-success .caret, +.btn-warning .caret, +.btn-danger .caret, +.btn-info .caret { + border-top-color: #fff; +} + +.dropup .btn-default .caret { + border-bottom-color: #ffffff; +} + +.dropup .btn-primary .caret, +.dropup .btn-success .caret, +.dropup .btn-warning .caret, +.dropup .btn-danger .caret, +.dropup .btn-info .caret { + border-bottom-color: #fff; +} + +.btn-group, +.btn-group-vertical { + position: relative; + display: inline-block; + vertical-align: middle; +} + +.btn-group > .btn, +.btn-group-vertical > .btn { + position: relative; + float: left; +} + +.btn-group > .btn:hover, +.btn-group-vertical > .btn:hover, +.btn-group > .btn:focus, +.btn-group-vertical > .btn:focus, +.btn-group > .btn:active, +.btn-group-vertical > .btn:active, +.btn-group > .btn.active, +.btn-group-vertical > .btn.active { + z-index: 2; +} + +.btn-group > .btn:focus, +.btn-group-vertical > .btn:focus { + outline: none; +} + +.btn-group .btn + .btn, +.btn-group .btn + .btn-group, +.btn-group .btn-group + .btn, +.btn-group .btn-group + .btn-group { + margin-left: -1px; +} + +.btn-toolbar:before, +.btn-toolbar:after { + display: table; + content: " "; +} + +.btn-toolbar:after { + clear: both; +} + +.btn-toolbar:before, +.btn-toolbar:after { + display: table; + content: " "; +} + +.btn-toolbar:after { + clear: both; +} + +.btn-toolbar:before, +.btn-toolbar:after { + display: table; + content: " "; +} + +.btn-toolbar:after { + clear: both; +} + +.btn-toolbar:before, +.btn-toolbar:after { + display: table; + content: " "; +} + +.btn-toolbar:after { + clear: both; +} + +.btn-toolbar:before, +.btn-toolbar:after { + display: table; + content: " "; +} + +.btn-toolbar:after { + clear: both; +} + +.btn-toolbar .btn-group { + float: left; +} + +.btn-toolbar > .btn + .btn, +.btn-toolbar > .btn-group + .btn, +.btn-toolbar > .btn + .btn-group, +.btn-toolbar > .btn-group + .btn-group { + margin-left: 5px; +} + +.btn-group > .btn:not(:first-child):not(:last-child):not(.dropdown-toggle) { + border-radius: 0; +} + +.btn-group > .btn:first-child { + margin-left: 0; +} + +.btn-group > .btn:first-child:not(:last-child):not(.dropdown-toggle) { + border-top-right-radius: 0; + border-bottom-right-radius: 0; +} + +.btn-group > .btn:last-child:not(:first-child), +.btn-group > .dropdown-toggle:not(:first-child) { + border-bottom-left-radius: 0; + border-top-left-radius: 0; +} + +.btn-group > .btn-group { + float: left; +} + +.btn-group > .btn-group:not(:first-child):not(:last-child) > .btn { + border-radius: 0; +} + +.btn-group > .btn-group:first-child > .btn:last-child, +.btn-group > .btn-group:first-child > .dropdown-toggle { + border-top-right-radius: 0; + border-bottom-right-radius: 0; +} + +.btn-group > .btn-group:last-child > .btn:first-child { + border-bottom-left-radius: 0; + border-top-left-radius: 0; +} + +.btn-group .dropdown-toggle:active, +.btn-group.open .dropdown-toggle { + outline: 0; +} + +.btn-group-xs > .btn { + padding: 5px 10px; + padding: 1px 5px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; +} + +.btn-group-sm > .btn { + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; +} + +.btn-group-lg > .btn { + padding: 14px 16px; + font-size: 18px; + line-height: 1.33; + border-radius: 6px; +} + +.btn-group > .btn + .dropdown-toggle { + padding-right: 8px; + padding-left: 8px; +} + +.btn-group > .btn-lg + .dropdown-toggle { + padding-right: 12px; + padding-left: 12px; +} + +.btn-group.open .dropdown-toggle { + -webkit-box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); + box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.125); +} + +.btn .caret { + margin-left: 0; +} + +.btn-lg .caret { + border-width: 5px 5px 0; + border-bottom-width: 0; +} + +.dropup .btn-lg .caret { + border-width: 0 5px 5px; +} + +.btn-group-vertical > .btn, +.btn-group-vertical > .btn-group { + display: block; + float: none; + width: 100%; + max-width: 100%; +} + +.btn-group-vertical > .btn-group:before, +.btn-group-vertical > .btn-group:after { + display: table; + content: " "; +} + +.btn-group-vertical > .btn-group:after { + clear: both; +} + +.btn-group-vertical > .btn-group:before, +.btn-group-vertical > .btn-group:after { + display: table; + content: " "; +} + +.btn-group-vertical > .btn-group:after { + clear: both; +} + +.btn-group-vertical > .btn-group:before, +.btn-group-vertical > .btn-group:after { + display: table; + content: " "; +} + +.btn-group-vertical > .btn-group:after { + clear: both; +} + +.btn-group-vertical > .btn-group:before, +.btn-group-vertical > .btn-group:after { + display: table; + content: " "; +} + +.btn-group-vertical > .btn-group:after { + clear: both; +} + +.btn-group-vertical > .btn-group:before, +.btn-group-vertical > .btn-group:after { + display: table; + content: " "; +} + +.btn-group-vertical > .btn-group:after { + clear: both; +} + +.btn-group-vertical > .btn-group > .btn { + float: none; +} + +.btn-group-vertical > .btn + .btn, +.btn-group-vertical > .btn + .btn-group, +.btn-group-vertical > .btn-group + .btn, +.btn-group-vertical > .btn-group + .btn-group { + margin-top: -1px; + margin-left: 0; +} + +.btn-group-vertical > .btn:not(:first-child):not(:last-child) { + border-radius: 0; +} + +.btn-group-vertical > .btn:first-child:not(:last-child) { + border-top-right-radius: 4px; + border-bottom-right-radius: 0; + border-bottom-left-radius: 0; +} + +.btn-group-vertical > .btn:last-child:not(:first-child) { + border-top-right-radius: 0; + border-bottom-left-radius: 4px; + border-top-left-radius: 0; +} + +.btn-group-vertical > .btn-group:not(:first-child):not(:last-child) > .btn { + border-radius: 0; +} + +.btn-group-vertical > .btn-group:first-child > .btn:last-child, +.btn-group-vertical > .btn-group:first-child > .dropdown-toggle { + border-bottom-right-radius: 0; + border-bottom-left-radius: 0; +} + +.btn-group-vertical > .btn-group:last-child > .btn:first-child { + border-top-right-radius: 0; + border-top-left-radius: 0; +} + +.btn-group-justified { + display: table; + width: 100%; + border-collapse: separate; + table-layout: fixed; +} + +.btn-group-justified .btn { + display: table-cell; + float: none; + width: 1%; +} + +[data-toggle="buttons"] > .btn > input[type="radio"], +[data-toggle="buttons"] > .btn > input[type="checkbox"] { + display: none; +} + +.input-group { + position: relative; + display: table; + border-collapse: separate; +} + +.input-group.col { + float: none; + padding-right: 0; + padding-left: 0; +} + +.input-group .form-control { + width: 100%; + margin-bottom: 0; +} + +.input-group-lg > .form-control, +.input-group-lg > .input-group-addon, +.input-group-lg > .input-group-btn > .btn { + height: 56px; + padding: 14px 16px; + font-size: 18px; + line-height: 1.33; + border-radius: 6px; +} + +select.input-group-lg > .form-control, +select.input-group-lg > .input-group-addon, +select.input-group-lg > .input-group-btn > .btn { + height: 56px; + line-height: 56px; +} + +textarea.input-group-lg > .form-control, +textarea.input-group-lg > .input-group-addon, +textarea.input-group-lg > .input-group-btn > .btn { + height: auto; +} + +.input-group-sm > .form-control, +.input-group-sm > .input-group-addon, +.input-group-sm > .input-group-btn > .btn { + height: 30px; + padding: 5px 10px; + font-size: 12px; + line-height: 1.5; + border-radius: 3px; +} + +select.input-group-sm > .form-control, +select.input-group-sm > .input-group-addon, +select.input-group-sm > .input-group-btn > .btn { + height: 30px; + line-height: 30px; +} + +textarea.input-group-sm > .form-control, +textarea.input-group-sm > .input-group-addon, +textarea.input-group-sm > .input-group-btn > .btn { + height: auto; +} + +.input-group-addon, +.input-group-btn, +.input-group .form-control { + display: table-cell; +} + +.input-group-addon:not(:first-child):not(:last-child), +.input-group-btn:not(:first-child):not(:last-child), +.input-group .form-control:not(:first-child):not(:last-child) { + border-radius: 0; +} + +.input-group-addon, +.input-group-btn { + width: 1%; + white-space: nowrap; + vertical-align: middle; +} + +.input-group-addon { + padding: 8px 12px; + font-size: 14px; + font-weight: normal; + line-height: 1; + text-align: center; + background-color: #999999; + border: 1px solid #cccccc; + border-radius: 4px; +} + +.input-group-addon.input-sm { + padding: 5px 10px; + font-size: 12px; + border-radius: 3px; +} + +.input-group-addon.input-lg { + padding: 14px 16px; + font-size: 18px; + border-radius: 6px; +} + +.input-group-addon input[type="radio"], +.input-group-addon input[type="checkbox"] { + margin-top: 0; +} + +.input-group .form-control:first-child, +.input-group-addon:first-child, +.input-group-btn:first-child > .btn, +.input-group-btn:first-child > .dropdown-toggle, +.input-group-btn:last-child > .btn:not(:last-child):not(.dropdown-toggle) { + border-top-right-radius: 0; + border-bottom-right-radius: 0; +} + +.input-group-addon:first-child { + border-right: 0; +} + +.input-group .form-control:last-child, +.input-group-addon:last-child, +.input-group-btn:last-child > .btn, +.input-group-btn:last-child > .dropdown-toggle, +.input-group-btn:first-child > .btn:not(:first-child) { + border-bottom-left-radius: 0; + border-top-left-radius: 0; +} + +.input-group-addon:last-child { + border-left: 0; +} + +.input-group-btn { + position: relative; + white-space: nowrap; +} + +.input-group-btn > .btn { + position: relative; +} + +.input-group-btn > .btn + .btn { + margin-left: -4px; +} + +.input-group-btn > .btn:hover, +.input-group-btn > .btn:active { + z-index: 2; +} + +.nav { + padding-left: 0; + margin-bottom: 0; + list-style: none; +} + +.nav:before, +.nav:after { + display: table; + content: " "; +} + +.nav:after { + clear: both; +} + +.nav:before, +.nav:after { + display: table; + content: " "; +} + +.nav:after { + clear: both; +} + +.nav:before, +.nav:after { + display: table; + content: " "; +} + +.nav:after { + clear: both; +} + +.nav:before, +.nav:after { + display: table; + content: " "; +} + +.nav:after { + clear: both; +} + +.nav:before, +.nav:after { + display: table; + content: " "; +} + +.nav:after { + clear: both; +} + +.nav > li { + position: relative; + display: block; +} + +.nav > li > a { + position: relative; + display: block; + padding: 10px 15px; +} + +.nav > li > a:hover, +.nav > li > a:focus { + text-decoration: none; + background-color: #3e444c; +} + +.nav > li.disabled > a { + color: #7a8288; +} + +.nav > li.disabled > a:hover, +.nav > li.disabled > a:focus { + color: #7a8288; + text-decoration: none; + cursor: not-allowed; + background-color: transparent; +} + +.nav .open > a, +.nav .open > a:hover, +.nav .open > a:focus { + background-color: #3e444c; + border-color: #ffffff; +} + +.nav .nav-divider { + height: 1px; + margin: 9px 0; + overflow: hidden; + background-color: #e5e5e5; +} + +.nav > li > a > img { + max-width: none; +} + +.nav-tabs { + border-bottom: 1px solid #1c1e22; +} + +.nav-tabs > li { + float: left; + margin-bottom: -1px; +} + +.nav-tabs > li > a { + margin-right: 2px; + line-height: 1.428571429; + border: 1px solid transparent; + border-radius: 4px 4px 0 0; +} + +.nav-tabs > li > a:hover { + border-color: #1c1e22 #1c1e22 #1c1e22; +} + +.nav-tabs > li.active > a, +.nav-tabs > li.active > a:hover, +.nav-tabs > li.active > a:focus { + color: #ffffff; + cursor: default; + background-color: #3e444c; + border: 1px solid #1c1e22; + border-bottom-color: transparent; +} + +.nav-tabs.nav-justified { + width: 100%; + border-bottom: 0; +} + +.nav-tabs.nav-justified > li { + float: none; +} + +.nav-tabs.nav-justified > li > a { + text-align: center; +} + +@media (min-width: 768px) { + .nav-tabs.nav-justified > li { + display: table-cell; + width: 1%; + } +} + +.nav-tabs.nav-justified > li > a { + margin-right: 0; + border-bottom: 1px solid #dddddd; +} + +.nav-tabs.nav-justified > .active > a { + border-bottom-color: #272b30; +} + +.nav-pills > li { + float: left; +} + +.nav-pills > li > a { + border-radius: 5px; +} + +.nav-pills > li + li { + margin-left: 2px; +} + +.nav-pills > li.active > a, +.nav-pills > li.active > a:hover, +.nav-pills > li.active > a:focus { + color: #ffffff; + background-color: transparent; +} + +.nav-stacked > li { + float: none; +} + +.nav-stacked > li + li { + margin-top: 2px; + margin-left: 0; +} + +.nav-justified { + width: 100%; +} + +.nav-justified > li { + float: none; +} + +.nav-justified > li > a { + text-align: center; +} + +@media (min-width: 768px) { + .nav-justified > li { + display: table-cell; + width: 1%; + } +} + +.nav-tabs-justified { + border-bottom: 0; +} + +.nav-tabs-justified > li > a { + margin-right: 0; + border-bottom: 1px solid #dddddd; +} + +.nav-tabs-justified > .active > a { + border-bottom-color: #272b30; +} + +.tabbable:before, +.tabbable:after { + display: table; + content: " "; +} + +.tabbable:after { + clear: both; +} + +.tabbable:before, +.tabbable:after { + display: table; + content: " "; +} + +.tabbable:after { + clear: both; +} + +.tabbable:before, +.tabbable:after { + display: table; + content: " "; +} + +.tabbable:after { + clear: both; +} + +.tabbable:before, +.tabbable:after { + display: table; + content: " "; +} + +.tabbable:after { + clear: both; +} + +.tabbable:before, +.tabbable:after { + display: table; + content: " "; +} + +.tabbable:after { + clear: both; +} + +.tab-content > .tab-pane, +.pill-content > .pill-pane { + display: none; +} + +.tab-content > .active, +.pill-content > .active { + display: block; +} + +.nav .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; +} + +.nav a:hover .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; +} + +.nav-tabs .dropdown-menu { + margin-top: -1px; + border-top-right-radius: 0; + border-top-left-radius: 0; +} + +.navbar { + position: relative; + z-index: 1000; + min-height: 50px; + margin-bottom: 20px; + border: 1px solid transparent; +} + +.navbar:before, +.navbar:after { + display: table; + content: " "; +} + +.navbar:after { + clear: both; +} + +.navbar:before, +.navbar:after { + display: table; + content: " "; +} + +.navbar:after { + clear: both; +} + +.navbar:before, +.navbar:after { + display: table; + content: " "; +} + +.navbar:after { + clear: both; +} + +.navbar:before, +.navbar:after { + display: table; + content: " "; +} + +.navbar:after { + clear: both; +} + +.navbar:before, +.navbar:after { + display: table; + content: " "; +} + +.navbar:after { + clear: both; +} + +@media (min-width: 768px) { + .navbar { + border-radius: 4px; + } +} + +.navbar-header:before, +.navbar-header:after { + display: table; + content: " "; +} + +.navbar-header:after { + clear: both; +} + +.navbar-header:before, +.navbar-header:after { + display: table; + content: " "; +} + +.navbar-header:after { + clear: both; +} + +.navbar-header:before, +.navbar-header:after { + display: table; + content: " "; +} + +.navbar-header:after { + clear: both; +} + +.navbar-header:before, +.navbar-header:after { + display: table; + content: " "; +} + +.navbar-header:after { + clear: both; +} + +.navbar-header:before, +.navbar-header:after { + display: table; + content: " "; +} + +.navbar-header:after { + clear: both; +} + +@media (min-width: 768px) { + .navbar-header { + float: left; + } +} + +.navbar-collapse { + max-height: 340px; + padding-right: 15px; + padding-left: 15px; + overflow-x: visible; + border-top: 1px solid transparent; + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1); + -webkit-overflow-scrolling: touch; +} + +.navbar-collapse:before, +.navbar-collapse:after { + display: table; + content: " "; +} + +.navbar-collapse:after { + clear: both; +} + +.navbar-collapse:before, +.navbar-collapse:after { + display: table; + content: " "; +} + +.navbar-collapse:after { + clear: both; +} + +.navbar-collapse:before, +.navbar-collapse:after { + display: table; + content: " "; +} + +.navbar-collapse:after { + clear: both; +} + +.navbar-collapse:before, +.navbar-collapse:after { + display: table; + content: " "; +} + +.navbar-collapse:after { + clear: both; +} + +.navbar-collapse:before, +.navbar-collapse:after { + display: table; + content: " "; +} + +.navbar-collapse:after { + clear: both; +} + +.navbar-collapse.in { + overflow-y: auto; +} + +@media (min-width: 768px) { + .navbar-collapse { + width: auto; + border-top: 0; + box-shadow: none; + } + .navbar-collapse.collapse { + display: block !important; + height: auto !important; + padding-bottom: 0; + overflow: visible !important; + } + .navbar-collapse.in { + overflow-y: visible; + } + .navbar-collapse .navbar-nav.navbar-left:first-child { + margin-left: -15px; + } + .navbar-collapse .navbar-nav.navbar-right:last-child { + margin-right: -15px; + } + .navbar-collapse .navbar-text:last-child { + margin-right: 0; + } +} + +.container > .navbar-header, +.container > .navbar-collapse { + margin-right: -15px; + margin-left: -15px; +} + +@media (min-width: 768px) { + .container > .navbar-header, + .container > .navbar-collapse { + margin-right: 0; + margin-left: 0; + } +} + +.navbar-static-top { + border-width: 0 0 1px; +} + +@media (min-width: 768px) { + .navbar-static-top { + border-radius: 0; + } +} + +.navbar-fixed-top, +.navbar-fixed-bottom { + position: fixed; + right: 0; + left: 0; + border-width: 0 0 1px; +} + +@media (min-width: 768px) { + .navbar-fixed-top, + .navbar-fixed-bottom { + border-radius: 0; + } +} + +.navbar-fixed-top { + top: 0; + z-index: 1030; +} + +.navbar-fixed-bottom { + bottom: 0; + margin-bottom: 0; +} + +.navbar-brand { + float: left; + padding: 15px 15px; + font-size: 18px; + line-height: 20px; +} + +.navbar-brand:hover, +.navbar-brand:focus { + text-decoration: none; +} + +@media (min-width: 768px) { + .navbar > .container .navbar-brand { + margin-left: -15px; + } +} + +.navbar-toggle { + position: relative; + float: right; + padding: 9px 10px; + margin-top: 8px; + margin-right: 15px; + margin-bottom: 8px; + background-color: transparent; + border: 1px solid transparent; + border-radius: 4px; +} + +.navbar-toggle .icon-bar { + display: block; + width: 22px; + height: 2px; + border-radius: 1px; +} + +.navbar-toggle .icon-bar + .icon-bar { + margin-top: 4px; +} + +@media (min-width: 768px) { + .navbar-toggle { + display: none; + } +} + +.navbar-nav { + margin: 7.5px -15px; +} + +.navbar-nav > li > a { + padding-top: 10px; + padding-bottom: 10px; + line-height: 20px; +} + +@media (max-width: 767px) { + .navbar-nav .open .dropdown-menu { + position: static; + float: none; + width: auto; + margin-top: 0; + background-color: transparent; + border: 0; + box-shadow: none; + } + .navbar-nav .open .dropdown-menu > li > a, + .navbar-nav .open .dropdown-menu .dropdown-header { + padding: 5px 15px 5px 25px; + } + .navbar-nav .open .dropdown-menu > li > a { + line-height: 20px; + } + .navbar-nav .open .dropdown-menu > li > a:hover, + .navbar-nav .open .dropdown-menu > li > a:focus { + background-image: none; + } +} + +@media (min-width: 768px) { + .navbar-nav { + float: left; + margin: 0; + } + .navbar-nav > li { + float: left; + } + .navbar-nav > li > a { + padding-top: 15px; + padding-bottom: 15px; + } +} + +@media (min-width: 768px) { + .navbar-left { + float: left !important; + } + .navbar-right { + float: right !important; + } +} + +.navbar-form { + padding: 10px 15px; + margin-top: 6px; + margin-right: -15px; + margin-bottom: 6px; + margin-left: -15px; + border-top: 1px solid transparent; + border-bottom: 1px solid transparent; + -webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1); + box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 1px 0 rgba(255, 255, 255, 0.1); +} + +@media (min-width: 768px) { + .navbar-form .form-group { + display: inline-block; + margin-bottom: 0; + vertical-align: middle; + } + .navbar-form .form-control { + display: inline-block; + } + .navbar-form .radio, + .navbar-form .checkbox { + display: inline-block; + padding-left: 0; + margin-top: 0; + margin-bottom: 0; + } + .navbar-form .radio input[type="radio"], + .navbar-form .checkbox input[type="checkbox"] { + float: none; + margin-left: 0; + } +} + +@media (max-width: 767px) { + .navbar-form .form-group { + margin-bottom: 5px; + } +} + +@media (min-width: 768px) { + .navbar-form { + width: auto; + padding-top: 0; + padding-bottom: 0; + margin-right: 0; + margin-left: 0; + border: 0; + -webkit-box-shadow: none; + box-shadow: none; + } +} + +.navbar-nav > li > .dropdown-menu { + margin-top: 0; + border-top-right-radius: 0; + border-top-left-radius: 0; +} + +.navbar-fixed-bottom .navbar-nav > li > .dropdown-menu { + border-bottom-right-radius: 0; + border-bottom-left-radius: 0; +} + +.navbar-nav.pull-right > li > .dropdown-menu, +.navbar-nav > li > .dropdown-menu.pull-right { + right: 0; + left: auto; +} + +.navbar-btn { + margin-top: 6px; + margin-bottom: 6px; +} + +.navbar-text { + float: left; + margin-top: 15px; + margin-bottom: 15px; +} + +@media (min-width: 768px) { + .navbar-text { + margin-right: 15px; + margin-left: 15px; + } +} + +.navbar-default { + background-color: #3a3f44; + border-color: #2b2e32; +} + +.navbar-default .navbar-brand { + color: #c8c8c8; +} + +.navbar-default .navbar-brand:hover, +.navbar-default .navbar-brand:focus { + color: #ffffff; + background-color: none; +} + +.navbar-default .navbar-text { + color: #c8c8c8; +} + +.navbar-default .navbar-nav > li > a { + color: #c8c8c8; +} + +.navbar-default .navbar-nav > li > a:hover, +.navbar-default .navbar-nav > li > a:focus { + color: #ffffff; + background-color: #272b2e; +} + +.navbar-default .navbar-nav > .active > a, +.navbar-default .navbar-nav > .active > a:hover, +.navbar-default .navbar-nav > .active > a:focus { + color: #ffffff; + background-color: #272b2e; +} + +.navbar-default .navbar-nav > .disabled > a, +.navbar-default .navbar-nav > .disabled > a:hover, +.navbar-default .navbar-nav > .disabled > a:focus { + color: #cccccc; + background-color: transparent; +} + +.navbar-default .navbar-toggle { + border-color: #272b2e; +} + +.navbar-default .navbar-toggle:hover, +.navbar-default .navbar-toggle:focus { + background-color: #272b2e; +} + +.navbar-default .navbar-toggle .icon-bar { + background-color: #c8c8c8; +} + +.navbar-default .navbar-collapse, +.navbar-default .navbar-form { + border-color: #2a2d31; +} + +.navbar-default .navbar-nav > .dropdown > a:hover .caret, +.navbar-default .navbar-nav > .dropdown > a:focus .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; +} + +.navbar-default .navbar-nav > .open > a, +.navbar-default .navbar-nav > .open > a:hover, +.navbar-default .navbar-nav > .open > a:focus { + color: #ffffff; + background-color: #272b2e; +} + +.navbar-default .navbar-nav > .open > a .caret, +.navbar-default .navbar-nav > .open > a:hover .caret, +.navbar-default .navbar-nav > .open > a:focus .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; +} + +.navbar-default .navbar-nav > .dropdown > a .caret { + border-top-color: #c8c8c8; + border-bottom-color: #c8c8c8; +} + +@media (max-width: 767px) { + .navbar-default .navbar-nav .open .dropdown-menu > li > a { + color: #c8c8c8; + } + .navbar-default .navbar-nav .open .dropdown-menu > li > a:hover, + .navbar-default .navbar-nav .open .dropdown-menu > li > a:focus { + color: #ffffff; + background-color: #272b2e; + } + .navbar-default .navbar-nav .open .dropdown-menu > .active > a, + .navbar-default .navbar-nav .open .dropdown-menu > .active > a:hover, + .navbar-default .navbar-nav .open .dropdown-menu > .active > a:focus { + color: #ffffff; + background-color: #272b2e; + } + .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a, + .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:hover, + .navbar-default .navbar-nav .open .dropdown-menu > .disabled > a:focus { + color: #cccccc; + background-color: transparent; + } +} + +.navbar-default .navbar-link { + color: #c8c8c8; +} + +.navbar-default .navbar-link:hover { + color: #ffffff; +} + +.navbar-inverse { + background-color: #7a8288; + border-color: #62686d; +} + +.navbar-inverse .navbar-brand { + color: #cccccc; +} + +.navbar-inverse .navbar-brand:hover, +.navbar-inverse .navbar-brand:focus { + color: #ffffff; + background-color: none; +} + +.navbar-inverse .navbar-text { + color: #cccccc; +} + +.navbar-inverse .navbar-nav > li > a { + color: #cccccc; +} + +.navbar-inverse .navbar-nav > li > a:hover, +.navbar-inverse .navbar-nav > li > a:focus { + color: #ffffff; + background-color: #5d6368; +} + +.navbar-inverse .navbar-nav > .active > a, +.navbar-inverse .navbar-nav > .active > a:hover, +.navbar-inverse .navbar-nav > .active > a:focus { + color: #ffffff; + background-color: #5d6368; +} + +.navbar-inverse .navbar-nav > .disabled > a, +.navbar-inverse .navbar-nav > .disabled > a:hover, +.navbar-inverse .navbar-nav > .disabled > a:focus { + color: #cccccc; + background-color: transparent; +} + +.navbar-inverse .navbar-toggle { + border-color: #5d6368; +} + +.navbar-inverse .navbar-toggle:hover, +.navbar-inverse .navbar-toggle:focus { + background-color: #5d6368; +} + +.navbar-inverse .navbar-toggle .icon-bar { + background-color: #ffffff; +} + +.navbar-inverse .navbar-collapse, +.navbar-inverse .navbar-form { + border-color: #697075; +} + +.navbar-inverse .navbar-nav > .open > a, +.navbar-inverse .navbar-nav > .open > a:hover, +.navbar-inverse .navbar-nav > .open > a:focus { + color: #ffffff; + background-color: #5d6368; +} + +.navbar-inverse .navbar-nav > .dropdown > a:hover .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; +} + +.navbar-inverse .navbar-nav > .dropdown > a .caret { + border-top-color: #cccccc; + border-bottom-color: #cccccc; +} + +.navbar-inverse .navbar-nav > .open > a .caret, +.navbar-inverse .navbar-nav > .open > a:hover .caret, +.navbar-inverse .navbar-nav > .open > a:focus .caret { + border-top-color: #ffffff; + border-bottom-color: #ffffff; +} + +@media (max-width: 767px) { + .navbar-inverse .navbar-nav .open .dropdown-menu > .dropdown-header { + border-color: #62686d; + } + .navbar-inverse .navbar-nav .open .dropdown-menu > li > a { + color: #cccccc; + } + .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:hover, + .navbar-inverse .navbar-nav .open .dropdown-menu > li > a:focus { + color: #ffffff; + background-color: #5d6368; + } + .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a, + .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:hover, + .navbar-inverse .navbar-nav .open .dropdown-menu > .active > a:focus { + color: #ffffff; + background-color: #5d6368; + } + .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a, + .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:hover, + .navbar-inverse .navbar-nav .open .dropdown-menu > .disabled > a:focus { + color: #cccccc; + background-color: transparent; + } +} + +.navbar-inverse .navbar-link { + color: #cccccc; +} + +.navbar-inverse .navbar-link:hover { + color: #ffffff; +} + +.breadcrumb { + padding: 8px 15px; + margin-bottom: 20px; + list-style: none; + background-color: transparent; + border-radius: 4px; +} + +.breadcrumb > li { + display: inline-block; +} + +.breadcrumb > li + li:before { + padding: 0 5px; + color: #cccccc; + content: "/\00a0"; +} + +.breadcrumb > .active { + color: #7a8288; +} + +.pagination { + display: inline-block; + padding-left: 0; + margin: 20px 0; + border-radius: 4px; +} + +.pagination > li { + display: inline; +} + +.pagination > li > a, +.pagination > li > span { + position: relative; + float: left; + padding: 8px 12px; + margin-left: -1px; + line-height: 1.428571429; + text-decoration: none; + background-color: #3a3f44; + border: 1px solid rgba(0, 0, 0, 0.6); +} + +.pagination > li:first-child > a, +.pagination > li:first-child > span { + margin-left: 0; + border-bottom-left-radius: 4px; + border-top-left-radius: 4px; +} + +.pagination > li:last-child > a, +.pagination > li:last-child > span { + border-top-right-radius: 4px; + border-bottom-right-radius: 4px; +} + +.pagination > li > a:hover, +.pagination > li > span:hover, +.pagination > li > a:focus, +.pagination > li > span:focus { + background-color: transparent; +} + +.pagination > .active > a, +.pagination > .active > span, +.pagination > .active > a:hover, +.pagination > .active > span:hover, +.pagination > .active > a:focus, +.pagination > .active > span:focus { + z-index: 2; + color: #ffffff; + cursor: default; + background-color: #232628; + border-color: #232628; +} + +.pagination > .disabled > span, +.pagination > .disabled > a, +.pagination > .disabled > a:hover, +.pagination > .disabled > a:focus { + color: #7a8288; + cursor: not-allowed; + background-color: #3a3f44; + border-color: rgba(0, 0, 0, 0.6); +} + +.pagination-lg > li > a, +.pagination-lg > li > span { + padding: 14px 16px; + font-size: 18px; +} + +.pagination-lg > li:first-child > a, +.pagination-lg > li:first-child > span { + border-bottom-left-radius: 6px; + border-top-left-radius: 6px; +} + +.pagination-lg > li:last-child > a, +.pagination-lg > li:last-child > span { + border-top-right-radius: 6px; + border-bottom-right-radius: 6px; +} + +.pagination-sm > li > a, +.pagination-sm > li > span { + padding: 5px 10px; + font-size: 12px; +} + +.pagination-sm > li:first-child > a, +.pagination-sm > li:first-child > span { + border-bottom-left-radius: 3px; + border-top-left-radius: 3px; +} + +.pagination-sm > li:last-child > a, +.pagination-sm > li:last-child > span { + border-top-right-radius: 3px; + border-bottom-right-radius: 3px; +} + +.pager { + padding-left: 0; + margin: 20px 0; + text-align: center; + list-style: none; +} + +.pager:before, +.pager:after { + display: table; + content: " "; +} + +.pager:after { + clear: both; +} + +.pager:before, +.pager:after { + display: table; + content: " "; +} + +.pager:after { + clear: both; +} + +.pager:before, +.pager:after { + display: table; + content: " "; +} + +.pager:after { + clear: both; +} + +.pager:before, +.pager:after { + display: table; + content: " "; +} + +.pager:after { + clear: both; +} + +.pager:before, +.pager:after { + display: table; + content: " "; +} + +.pager:after { + clear: both; +} + +.pager li { + display: inline; +} + +.pager li > a, +.pager li > span { + display: inline-block; + padding: 5px 14px; + background-color: #3a3f44; + border: 1px solid rgba(0, 0, 0, 0.6); + border-radius: 15px; +} + +.pager li > a:hover, +.pager li > a:focus { + text-decoration: none; + background-color: transparent; +} + +.pager .next > a, +.pager .next > span { + float: right; +} + +.pager .previous > a, +.pager .previous > span { + float: left; +} + +.pager .disabled > a, +.pager .disabled > a:hover, +.pager .disabled > a:focus, +.pager .disabled > span { + color: #7a8288; + cursor: not-allowed; + background-color: #3a3f44; +} + +.label { + display: inline; + padding: .2em .6em .3em; + font-size: 75%; + font-weight: bold; + line-height: 1; + color: #ffffff; + text-align: center; + white-space: nowrap; + vertical-align: baseline; + border-radius: .25em; +} + +.label[href]:hover, +.label[href]:focus { + color: #ffffff; + text-decoration: none; + cursor: pointer; +} + +.label:empty { + display: none; +} + +.label-default { + background-color: #3a3f44; +} + +.label-default[href]:hover, +.label-default[href]:focus { + background-color: #232628; +} + +.label-primary { + background-color: #7a8288; +} + +.label-primary[href]:hover, +.label-primary[href]:focus { + background-color: #62686d; +} + +.label-success { + background-color: #62c462; +} + +.label-success[href]:hover, +.label-success[href]:focus { + background-color: #42b142; +} + +.label-info { + background-color: #5bc0de; +} + +.label-info[href]:hover, +.label-info[href]:focus { + background-color: #31b0d5; +} + +.label-warning { + background-color: #f89406; +} + +.label-warning[href]:hover, +.label-warning[href]:focus { + background-color: #c67605; +} + +.label-danger { + background-color: #ee5f5b; +} + +.label-danger[href]:hover, +.label-danger[href]:focus { + background-color: #e9322d; +} + +.badge { + display: inline-block; + min-width: 10px; + padding: 3px 7px; + font-size: 12px; + font-weight: bold; + line-height: 1; + color: #ffffff; + text-align: center; + white-space: nowrap; + vertical-align: baseline; + background-color: #7a8288; + border-radius: 10px; +} + +.badge:empty { + display: none; +} + +a.badge:hover, +a.badge:focus { + color: #ffffff; + text-decoration: none; + cursor: pointer; +} + +.btn .badge { + position: relative; + top: -1px; +} + +a.list-group-item.active > .badge, +.nav-pills > .active > a > .badge { + color: #ffffff; + background-color: #7a8288; +} + +.nav-pills > li > a > .badge { + margin-left: 3px; +} + +.jumbotron { + padding: 30px; + margin-bottom: 30px; + font-size: 21px; + font-weight: 200; + line-height: 2.1428571435; + color: inherit; + background-color: #1c1e22; +} + +.jumbotron h1 { + line-height: 1; + color: inherit; +} + +.jumbotron p { + line-height: 1.4; +} + +.container .jumbotron { + border-radius: 6px; +} + +@media screen and (min-width: 768px) { + .jumbotron { + padding-top: 48px; + padding-bottom: 48px; + } + .container .jumbotron { + padding-right: 60px; + padding-left: 60px; + } + .jumbotron h1 { + font-size: 63px; + } +} + +.thumbnail { + display: inline-block; + display: block; + height: auto; + max-width: 100%; + padding: 4px; + line-height: 1.428571429; + background-color: #272b30; + border: 1px solid #dddddd; + border-radius: 4px; + -webkit-transition: all 0.2s ease-in-out; + transition: all 0.2s ease-in-out; +} + +.thumbnail > img { + display: block; + height: auto; + max-width: 100%; +} + +a.thumbnail:hover, +a.thumbnail:focus { + border-color: #ffffff; +} + +.thumbnail > img { + margin-right: auto; + margin-left: auto; +} + +.thumbnail .caption { + padding: 9px; + color: #c8c8c8; +} + +.alert { + padding: 15px; + margin-bottom: 20px; + border: 1px solid transparent; + border-radius: 4px; +} + +.alert h4 { + margin-top: 0; + color: inherit; +} + +.alert .alert-link { + font-weight: bold; +} + +.alert > p, +.alert > ul { + margin-bottom: 0; +} + +.alert > p + p { + margin-top: 5px; +} + +.alert-dismissable { + padding-right: 35px; +} + +.alert-dismissable .close { + position: relative; + top: -2px; + right: -21px; + color: inherit; +} + +.alert-success { + color: #ffffff; + background-color: #62c462; + border-color: #62bd4f; +} + +.alert-success hr { + border-top-color: #55b142; +} + +.alert-success .alert-link { + color: #e6e6e6; +} + +.alert-info { + color: #ffffff; + background-color: #5bc0de; + border-color: #3dced8; +} + +.alert-info hr { + border-top-color: #2ac7d2; +} + +.alert-info .alert-link { + color: #e6e6e6; +} + +.alert-warning { + color: #ffffff; + background-color: #f89406; + border-color: #e96506; +} + +.alert-warning hr { + border-top-color: #d05a05; +} + +.alert-warning .alert-link { + color: #e6e6e6; +} + +.alert-danger { + color: #ffffff; + background-color: #ee5f5b; + border-color: #ed4d63; +} + +.alert-danger hr { + border-top-color: #ea364f; +} + +.alert-danger .alert-link { + color: #e6e6e6; +} + +@-webkit-keyframes progress-bar-stripes { + from { + background-position: 40px 0; + } + to { + background-position: 0 0; + } +} + +@-moz-keyframes progress-bar-stripes { + from { + background-position: 40px 0; + } + to { + background-position: 0 0; + } +} + +@-o-keyframes progress-bar-stripes { + from { + background-position: 0 0; + } + to { + background-position: 40px 0; + } +} + +@keyframes progress-bar-stripes { + from { + background-position: 40px 0; + } + to { + background-position: 0 0; + } +} + +.progress { + height: 20px; + margin-bottom: 20px; + overflow: hidden; + background-color: #1c1e22; + border-radius: 4px; + -webkit-box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); + box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1); +} + +.progress-bar { + float: left; + width: 0; + height: 100%; + font-size: 12px; + color: #ffffff; + text-align: center; + background-color: #7a8288; + -webkit-box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); + box-shadow: inset 0 -1px 0 rgba(0, 0, 0, 0.15); + -webkit-transition: width 0.6s ease; + transition: width 0.6s ease; +} + +.progress-striped .progress-bar { + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-size: 40px 40px; +} + +.progress.active .progress-bar { + -webkit-animation: progress-bar-stripes 2s linear infinite; + -moz-animation: progress-bar-stripes 2s linear infinite; + -ms-animation: progress-bar-stripes 2s linear infinite; + -o-animation: progress-bar-stripes 2s linear infinite; + animation: progress-bar-stripes 2s linear infinite; +} + +.progress-bar-success { + background-color: #62c462; +} + +.progress-striped .progress-bar-success { + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); +} + +.progress-bar-info { + background-color: #5bc0de; +} + +.progress-striped .progress-bar-info { + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); +} + +.progress-bar-warning { + background-color: #f89406; +} + +.progress-striped .progress-bar-warning { + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); +} + +.progress-bar-danger { + background-color: #ee5f5b; +} + +.progress-striped .progress-bar-danger { + background-image: -webkit-gradient(linear, 0 100%, 100% 0, color-stop(0.25, rgba(255, 255, 255, 0.15)), color-stop(0.25, transparent), color-stop(0.5, transparent), color-stop(0.5, rgba(255, 255, 255, 0.15)), color-stop(0.75, rgba(255, 255, 255, 0.15)), color-stop(0.75, transparent), to(transparent)); + background-image: -webkit-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: -moz-linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); + background-image: linear-gradient(45deg, rgba(255, 255, 255, 0.15) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.15) 50%, rgba(255, 255, 255, 0.15) 75%, transparent 75%, transparent); +} + +.media, +.media-body { + overflow: hidden; + zoom: 1; +} + +.media, +.media .media { + margin-top: 15px; +} + +.media:first-child { + margin-top: 0; +} + +.media-object { + display: block; +} + +.media-heading { + margin: 0 0 5px; +} + +.media > .pull-left { + margin-right: 10px; +} + +.media > .pull-right { + margin-left: 10px; +} + +.media-list { + padding-left: 0; + list-style: none; +} + +.list-group { + padding-left: 0; + margin-bottom: 20px; +} + +.list-group-item { + position: relative; + display: block; + padding: 10px 15px; + margin-bottom: -1px; + background-color: transparent; + border: 1px solid rgba(0, 0, 0, 0.6); +} + +.list-group-item:first-child { + border-top-right-radius: 4px; + border-top-left-radius: 4px; +} + +.list-group-item:last-child { + margin-bottom: 0; + border-bottom-right-radius: 4px; + border-bottom-left-radius: 4px; +} + +.list-group-item > .badge { + float: right; +} + +.list-group-item > .badge + .badge { + margin-right: 5px; +} + +a.list-group-item { + color: #c8c8c8; +} + +a.list-group-item .list-group-item-heading { + color: #ffffff; +} + +a.list-group-item:hover, +a.list-group-item:focus { + text-decoration: none; + background-color: #3e444c; +} + +.list-group-item.active, +.list-group-item.active:hover, +.list-group-item.active:focus { + z-index: 2; + color: #ffffff; + background-color: #3e444c; + border-color: rgba(0, 0, 0, 0.6); +} + +.list-group-item.active .list-group-item-heading, +.list-group-item.active:hover .list-group-item-heading, +.list-group-item.active:focus .list-group-item-heading { + color: inherit; +} + +.list-group-item.active .list-group-item-text, +.list-group-item.active:hover .list-group-item-text, +.list-group-item.active:focus .list-group-item-text { + color: #a2aab4; +} + +.list-group-item-heading { + margin-top: 0; + margin-bottom: 5px; +} + +.list-group-item-text { + margin-bottom: 0; + line-height: 1.3; +} + +.panel { + margin-bottom: 20px; + background-color: #2e3338; + border: 1px solid transparent; + border-radius: 4px; + -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05); + box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05); +} + +.panel-body { + padding: 15px; +} + +.panel-body:before, +.panel-body:after { + display: table; + content: " "; +} + +.panel-body:after { + clear: both; +} + +.panel-body:before, +.panel-body:after { + display: table; + content: " "; +} + +.panel-body:after { + clear: both; +} + +.panel-body:before, +.panel-body:after { + display: table; + content: " "; +} + +.panel-body:after { + clear: both; +} + +.panel-body:before, +.panel-body:after { + display: table; + content: " "; +} + +.panel-body:after { + clear: both; +} + +.panel-body:before, +.panel-body:after { + display: table; + content: " "; +} + +.panel-body:after { + clear: both; +} + +.panel > .list-group { + margin-bottom: 0; +} + +.panel > .list-group .list-group-item { + border-width: 1px 0; +} + +.panel > .list-group .list-group-item:first-child { + border-top-right-radius: 0; + border-top-left-radius: 0; +} + +.panel > .list-group .list-group-item:last-child { + border-bottom: 0; +} + +.panel-heading + .list-group .list-group-item:first-child { + border-top-width: 0; +} + +.panel > .table { + margin-bottom: 0; +} + +.panel > .panel-body + .table { + border-top: 1px solid #1c1e22; +} + +.panel-heading { + padding: 10px 15px; + border-bottom: 1px solid transparent; + border-top-right-radius: 3px; + border-top-left-radius: 3px; +} + +.panel-title { + margin-top: 0; + margin-bottom: 0; + font-size: 16px; +} + +.panel-title > a { + color: inherit; +} + +.panel-footer { + padding: 10px 15px; + background-color: #3e444c; + border-top: 1px solid rgba(0, 0, 0, 0.6); + border-bottom-right-radius: 3px; + border-bottom-left-radius: 3px; +} + +.panel-group .panel { + margin-bottom: 0; + overflow: hidden; + border-radius: 4px; +} + +.panel-group .panel + .panel { + margin-top: 5px; +} + +.panel-group .panel-heading { + border-bottom: 0; +} + +.panel-group .panel-heading + .panel-collapse .panel-body { + border-top: 1px solid rgba(0, 0, 0, 0.6); +} + +.panel-group .panel-footer { + border-top: 0; +} + +.panel-group .panel-footer + .panel-collapse .panel-body { + border-bottom: 1px solid rgba(0, 0, 0, 0.6); +} + +.panel-default { + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-default > .panel-heading { + color: #c8c8c8; + background-color: #3e444c; + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-default > .panel-heading + .panel-collapse .panel-body { + border-top-color: rgba(0, 0, 0, 0.6); +} + +.panel-default > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: rgba(0, 0, 0, 0.6); +} + +.panel-primary { + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-primary > .panel-heading { + color: #ffffff; + background-color: #7a8288; + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-primary > .panel-heading + .panel-collapse .panel-body { + border-top-color: rgba(0, 0, 0, 0.6); +} + +.panel-primary > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: rgba(0, 0, 0, 0.6); +} + +.panel-success { + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-success > .panel-heading { + color: #ffffff; + background-color: #62c462; + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-success > .panel-heading + .panel-collapse .panel-body { + border-top-color: rgba(0, 0, 0, 0.6); +} + +.panel-success > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: rgba(0, 0, 0, 0.6); +} + +.panel-warning { + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-warning > .panel-heading { + color: #ffffff; + background-color: #f89406; + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-warning > .panel-heading + .panel-collapse .panel-body { + border-top-color: rgba(0, 0, 0, 0.6); +} + +.panel-warning > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: rgba(0, 0, 0, 0.6); +} + +.panel-danger { + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-danger > .panel-heading { + color: #ffffff; + background-color: #ee5f5b; + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-danger > .panel-heading + .panel-collapse .panel-body { + border-top-color: rgba(0, 0, 0, 0.6); +} + +.panel-danger > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: rgba(0, 0, 0, 0.6); +} + +.panel-info { + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-info > .panel-heading { + color: #ffffff; + background-color: #5bc0de; + border-color: rgba(0, 0, 0, 0.6); +} + +.panel-info > .panel-heading + .panel-collapse .panel-body { + border-top-color: rgba(0, 0, 0, 0.6); +} + +.panel-info > .panel-footer + .panel-collapse .panel-body { + border-bottom-color: rgba(0, 0, 0, 0.6); +} + +.well { + min-height: 20px; + padding: 19px; + margin-bottom: 20px; + background-color: #1c1e22; + border: 1px solid #0c0d0e; + border-radius: 4px; + -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); + box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); +} + +.well blockquote { + border-color: #ddd; + border-color: rgba(0, 0, 0, 0.15); +} + +.well-lg { + padding: 24px; + border-radius: 6px; +} + +.well-sm { + padding: 9px; + border-radius: 3px; +} + +.close { + float: right; + font-size: 21px; + font-weight: bold; + line-height: 1; + color: #000000; + text-shadow: 0 1px 0 #ffffff; + opacity: 0.2; + filter: alpha(opacity=20); +} + +.close:hover, +.close:focus { + color: #000000; + text-decoration: none; + cursor: pointer; + opacity: 0.5; + filter: alpha(opacity=50); +} + +button.close { + padding: 0; + cursor: pointer; + background: transparent; + border: 0; + -webkit-appearance: none; +} + +.modal-open { + overflow: hidden; +} + +body.modal-open, +.modal-open .navbar-fixed-top, +.modal-open .navbar-fixed-bottom { + margin-right: 15px; +} + +.modal { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 1040; + display: none; + overflow: auto; + overflow-y: scroll; +} + +.modal.fade .modal-dialog { + -webkit-transform: translate(0, -25%); + -ms-transform: translate(0, -25%); + transform: translate(0, -25%); + -webkit-transition: -webkit-transform 0.3s ease-out; + -moz-transition: -moz-transform 0.3s ease-out; + -o-transition: -o-transform 0.3s ease-out; + transition: transform 0.3s ease-out; +} + +.modal.in .modal-dialog { + -webkit-transform: translate(0, 0); + -ms-transform: translate(0, 0); + transform: translate(0, 0); +} + +.modal-dialog { + z-index: 1050; + width: auto; + padding: 10px; + margin-right: auto; + margin-left: auto; +} + +.modal-content { + position: relative; + background-color: #2e3338; + border: 1px solid #999999; + border: 1px solid rgba(0, 0, 0, 0.2); + border-radius: 6px; + outline: none; + -webkit-box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5); + box-shadow: 0 3px 9px rgba(0, 0, 0, 0.5); + background-clip: padding-box; +} + +.modal-backdrop { + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + z-index: 1030; + background-color: #000000; +} + +.modal-backdrop.fade { + opacity: 0; + filter: alpha(opacity=0); +} + +.modal-backdrop.in { + opacity: 0.5; + filter: alpha(opacity=50); +} + +.modal-header { + min-height: 16.428571429px; + padding: 15px; + border-bottom: 1px solid #1c1e22; +} + +.modal-header .close { + margin-top: -2px; +} + +.modal-title { + margin: 0; + line-height: 1.428571429; +} + +.modal-body { + position: relative; + padding: 20px; +} + +.modal-footer { + padding: 19px 20px 20px; + margin-top: 15px; + text-align: right; + border-top: 1px solid #1c1e22; +} + +.modal-footer:before, +.modal-footer:after { + display: table; + content: " "; +} + +.modal-footer:after { + clear: both; +} + +.modal-footer:before, +.modal-footer:after { + display: table; + content: " "; +} + +.modal-footer:after { + clear: both; +} + +.modal-footer:before, +.modal-footer:after { + display: table; + content: " "; +} + +.modal-footer:after { + clear: both; +} + +.modal-footer:before, +.modal-footer:after { + display: table; + content: " "; +} + +.modal-footer:after { + clear: both; +} + +.modal-footer:before, +.modal-footer:after { + display: table; + content: " "; +} + +.modal-footer:after { + clear: both; +} + +.modal-footer .btn + .btn { + margin-bottom: 0; + margin-left: 5px; +} + +.modal-footer .btn-group .btn + .btn { + margin-left: -1px; +} + +.modal-footer .btn-block + .btn-block { + margin-left: 0; +} + +@media screen and (min-width: 768px) { + .modal-dialog { + right: auto; + left: 50%; + width: 600px; + padding-top: 30px; + padding-bottom: 30px; + } + .modal-content { + -webkit-box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5); + box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5); + } +} + +.tooltip { + position: absolute; + z-index: 1030; + display: block; + font-size: 12px; + line-height: 1.4; + opacity: 0; + filter: alpha(opacity=0); + visibility: visible; +} + +.tooltip.in { + opacity: 0.9; + filter: alpha(opacity=90); +} + +.tooltip.top { + padding: 5px 0; + margin-top: -3px; +} + +.tooltip.right { + padding: 0 5px; + margin-left: 3px; +} + +.tooltip.bottom { + padding: 5px 0; + margin-top: 3px; +} + +.tooltip.left { + padding: 0 5px; + margin-left: -3px; +} + +.tooltip-inner { + max-width: 200px; + padding: 3px 8px; + color: #ffffff; + text-align: center; + text-decoration: none; + background-color: rgba(0, 0, 0, 0.9); + border-radius: 4px; +} + +.tooltip-arrow { + position: absolute; + width: 0; + height: 0; + border-color: transparent; + border-style: solid; +} + +.tooltip.top .tooltip-arrow { + bottom: 0; + left: 50%; + margin-left: -5px; + border-top-color: rgba(0, 0, 0, 0.9); + border-width: 5px 5px 0; +} + +.tooltip.top-left .tooltip-arrow { + bottom: 0; + left: 5px; + border-top-color: rgba(0, 0, 0, 0.9); + border-width: 5px 5px 0; +} + +.tooltip.top-right .tooltip-arrow { + right: 5px; + bottom: 0; + border-top-color: rgba(0, 0, 0, 0.9); + border-width: 5px 5px 0; +} + +.tooltip.right .tooltip-arrow { + top: 50%; + left: 0; + margin-top: -5px; + border-right-color: rgba(0, 0, 0, 0.9); + border-width: 5px 5px 5px 0; +} + +.tooltip.left .tooltip-arrow { + top: 50%; + right: 0; + margin-top: -5px; + border-left-color: rgba(0, 0, 0, 0.9); + border-width: 5px 0 5px 5px; +} + +.tooltip.bottom .tooltip-arrow { + top: 0; + left: 50%; + margin-left: -5px; + border-bottom-color: rgba(0, 0, 0, 0.9); + border-width: 0 5px 5px; +} + +.tooltip.bottom-left .tooltip-arrow { + top: 0; + left: 5px; + border-bottom-color: rgba(0, 0, 0, 0.9); + border-width: 0 5px 5px; +} + +.tooltip.bottom-right .tooltip-arrow { + top: 0; + right: 5px; + border-bottom-color: rgba(0, 0, 0, 0.9); + border-width: 0 5px 5px; +} + +.popover { + position: absolute; + top: 0; + left: 0; + z-index: 1010; + display: none; + max-width: 276px; + padding: 1px; + text-align: left; + white-space: normal; + background-color: #2e3338; + border: 1px solid #999999; + border: 1px solid rgba(0, 0, 0, 0.2); + border-radius: 6px; + -webkit-box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); + box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2); + background-clip: padding-box; +} + +.popover.top { + margin-top: -10px; +} + +.popover.right { + margin-left: 10px; +} + +.popover.bottom { + margin-top: 10px; +} + +.popover.left { + margin-left: -10px; +} + +.popover-title { + padding: 8px 14px; + margin: 0; + font-size: 14px; + font-weight: normal; + line-height: 18px; + background-color: #2e3338; + border-bottom: 1px solid #22262a; + border-radius: 5px 5px 0 0; +} + +.popover-content { + padding: 9px 14px; +} + +.popover .arrow, +.popover .arrow:after { + position: absolute; + display: block; + width: 0; + height: 0; + border-color: transparent; + border-style: solid; +} + +.popover .arrow { + border-width: 11px; +} + +.popover .arrow:after { + border-width: 10px; + content: ""; +} + +.popover.top .arrow { + bottom: -11px; + left: 50%; + margin-left: -11px; + border-top-color: #999999; + border-top-color: rgba(0, 0, 0, 0.25); + border-bottom-width: 0; +} + +.popover.top .arrow:after { + bottom: 1px; + margin-left: -10px; + border-top-color: #2e3338; + border-bottom-width: 0; + content: " "; +} + +.popover.right .arrow { + top: 50%; + left: -11px; + margin-top: -11px; + border-right-color: #999999; + border-right-color: rgba(0, 0, 0, 0.25); + border-left-width: 0; +} + +.popover.right .arrow:after { + bottom: -10px; + left: 1px; + border-right-color: #2e3338; + border-left-width: 0; + content: " "; +} + +.popover.bottom .arrow { + top: -11px; + left: 50%; + margin-left: -11px; + border-bottom-color: #999999; + border-bottom-color: rgba(0, 0, 0, 0.25); + border-top-width: 0; +} + +.popover.bottom .arrow:after { + top: 1px; + margin-left: -10px; + border-bottom-color: #2e3338; + border-top-width: 0; + content: " "; +} + +.popover.left .arrow { + top: 50%; + right: -11px; + margin-top: -11px; + border-left-color: #999999; + border-left-color: rgba(0, 0, 0, 0.25); + border-right-width: 0; +} + +.popover.left .arrow:after { + right: 1px; + bottom: -10px; + border-left-color: #2e3338; + border-right-width: 0; + content: " "; +} + +.carousel { + position: relative; +} + +.carousel-inner { + position: relative; + width: 100%; + overflow: hidden; +} + +.carousel-inner > .item { + position: relative; + display: none; + -webkit-transition: 0.6s ease-in-out left; + transition: 0.6s ease-in-out left; +} + +.carousel-inner > .item > img, +.carousel-inner > .item > a > img { + display: block; + height: auto; + max-width: 100%; + line-height: 1; +} + +.carousel-inner > .active, +.carousel-inner > .next, +.carousel-inner > .prev { + display: block; +} + +.carousel-inner > .active { + left: 0; +} + +.carousel-inner > .next, +.carousel-inner > .prev { + position: absolute; + top: 0; + width: 100%; +} + +.carousel-inner > .next { + left: 100%; +} + +.carousel-inner > .prev { + left: -100%; +} + +.carousel-inner > .next.left, +.carousel-inner > .prev.right { + left: 0; +} + +.carousel-inner > .active.left { + left: -100%; +} + +.carousel-inner > .active.right { + left: 100%; +} + +.carousel-control { + position: absolute; + top: 0; + bottom: 0; + left: 0; + width: 15%; + font-size: 20px; + color: #ffffff; + text-align: center; + text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); + opacity: 0.5; + filter: alpha(opacity=50); +} + +.carousel-control.left { + background-image: -webkit-gradient(linear, 0 top, 100% top, from(rgba(0, 0, 0, 0.5)), to(rgba(0, 0, 0, 0.0001))); + background-image: -webkit-linear-gradient(left, color-stop(rgba(0, 0, 0, 0.5) 0), color-stop(rgba(0, 0, 0, 0.0001) 100%)); + background-image: -moz-linear-gradient(left, rgba(0, 0, 0, 0.5) 0, rgba(0, 0, 0, 0.0001) 100%); + background-image: linear-gradient(to right, rgba(0, 0, 0, 0.5) 0, rgba(0, 0, 0, 0.0001) 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1); +} + +.carousel-control.right { + right: 0; + left: auto; + background-image: -webkit-gradient(linear, 0 top, 100% top, from(rgba(0, 0, 0, 0.0001)), to(rgba(0, 0, 0, 0.5))); + background-image: -webkit-linear-gradient(left, color-stop(rgba(0, 0, 0, 0.0001) 0), color-stop(rgba(0, 0, 0, 0.5) 100%)); + background-image: -moz-linear-gradient(left, rgba(0, 0, 0, 0.0001) 0, rgba(0, 0, 0, 0.5) 100%); + background-image: linear-gradient(to right, rgba(0, 0, 0, 0.0001) 0, rgba(0, 0, 0, 0.5) 100%); + background-repeat: repeat-x; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1); +} + +.carousel-control:hover, +.carousel-control:focus { + color: #ffffff; + text-decoration: none; + opacity: 0.9; + filter: alpha(opacity=90); +} + +.carousel-control .icon-prev, +.carousel-control .icon-next, +.carousel-control .glyphicon-chevron-left, +.carousel-control .glyphicon-chevron-right { + position: absolute; + top: 50%; + left: 50%; + z-index: 5; + display: inline-block; +} + +.carousel-control .icon-prev, +.carousel-control .icon-next { + width: 20px; + height: 20px; + margin-top: -10px; + margin-left: -10px; + font-family: serif; +} + +.carousel-control .icon-prev:before { + content: '\2039'; +} + +.carousel-control .icon-next:before { + content: '\203a'; +} + +.carousel-indicators { + position: absolute; + bottom: 10px; + left: 50%; + z-index: 15; + width: 60%; + padding-left: 0; + margin-left: -30%; + text-align: center; + list-style: none; +} + +.carousel-indicators li { + display: inline-block; + width: 10px; + height: 10px; + margin: 1px; + text-indent: -999px; + cursor: pointer; + border: 1px solid #ffffff; + border-radius: 10px; +} + +.carousel-indicators .active { + width: 12px; + height: 12px; + margin: 0; + background-color: #ffffff; +} + +.carousel-caption { + position: absolute; + right: 15%; + bottom: 20px; + left: 15%; + z-index: 10; + padding-top: 20px; + padding-bottom: 20px; + color: #ffffff; + text-align: center; + text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); +} + +.carousel-caption .btn { + text-shadow: none; +} + +@media screen and (min-width: 768px) { + .carousel-control .icon-prev, + .carousel-control .icon-next { + width: 30px; + height: 30px; + margin-top: -15px; + margin-left: -15px; + font-size: 30px; + } + .carousel-caption { + right: 20%; + left: 20%; + padding-bottom: 30px; + } + .carousel-indicators { + bottom: 20px; + } +} + +.clearfix:before, +.clearfix:after { + display: table; + content: " "; +} + +.clearfix:after { + clear: both; +} + +.clearfix:before, +.clearfix:after { + display: table; + content: " "; +} + +.clearfix:after { + clear: both; +} + +.pull-right { + float: right !important; +} + +.pull-left { + float: left !important; +} + +.hide { + display: none !important; +} + +.show { + display: block !important; +} + +.invisible { + visibility: hidden; +} + +.text-hide { + font: 0/0 a; + color: transparent; + text-shadow: none; + background-color: transparent; + border: 0; +} + +.affix { + position: fixed; +} + +@-ms-viewport { + width: device-width; +} + +@media screen and (max-width: 400px) { + @-ms-viewport { + width: 320px; + } +} + +.hidden { + display: none !important; + visibility: hidden !important; +} + +.visible-xs { + display: none !important; +} + +tr.visible-xs { + display: none !important; +} + +th.visible-xs, +td.visible-xs { + display: none !important; +} + +@media (max-width: 767px) { + .visible-xs { + display: block !important; + } + tr.visible-xs { + display: table-row !important; + } + th.visible-xs, + td.visible-xs { + display: table-cell !important; + } +} + +@media (min-width: 768px) and (max-width: 991px) { + .visible-xs.visible-sm { + display: block !important; + } + tr.visible-xs.visible-sm { + display: table-row !important; + } + th.visible-xs.visible-sm, + td.visible-xs.visible-sm { + display: table-cell !important; + } +} + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-xs.visible-md { + display: block !important; + } + tr.visible-xs.visible-md { + display: table-row !important; + } + th.visible-xs.visible-md, + td.visible-xs.visible-md { + display: table-cell !important; + } +} + +@media (min-width: 1200px) { + .visible-xs.visible-lg { + display: block !important; + } + tr.visible-xs.visible-lg { + display: table-row !important; + } + th.visible-xs.visible-lg, + td.visible-xs.visible-lg { + display: table-cell !important; + } +} + +.visible-sm { + display: none !important; +} + +tr.visible-sm { + display: none !important; +} + +th.visible-sm, +td.visible-sm { + display: none !important; +} + +@media (max-width: 767px) { + .visible-sm.visible-xs { + display: block !important; + } + tr.visible-sm.visible-xs { + display: table-row !important; + } + th.visible-sm.visible-xs, + td.visible-sm.visible-xs { + display: table-cell !important; + } +} + +@media (min-width: 768px) and (max-width: 991px) { + .visible-sm { + display: block !important; + } + tr.visible-sm { + display: table-row !important; + } + th.visible-sm, + td.visible-sm { + display: table-cell !important; + } +} + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-sm.visible-md { + display: block !important; + } + tr.visible-sm.visible-md { + display: table-row !important; + } + th.visible-sm.visible-md, + td.visible-sm.visible-md { + display: table-cell !important; + } +} + +@media (min-width: 1200px) { + .visible-sm.visible-lg { + display: block !important; + } + tr.visible-sm.visible-lg { + display: table-row !important; + } + th.visible-sm.visible-lg, + td.visible-sm.visible-lg { + display: table-cell !important; + } +} + +.visible-md { + display: none !important; +} + +tr.visible-md { + display: none !important; +} + +th.visible-md, +td.visible-md { + display: none !important; +} + +@media (max-width: 767px) { + .visible-md.visible-xs { + display: block !important; + } + tr.visible-md.visible-xs { + display: table-row !important; + } + th.visible-md.visible-xs, + td.visible-md.visible-xs { + display: table-cell !important; + } +} + +@media (min-width: 768px) and (max-width: 991px) { + .visible-md.visible-sm { + display: block !important; + } + tr.visible-md.visible-sm { + display: table-row !important; + } + th.visible-md.visible-sm, + td.visible-md.visible-sm { + display: table-cell !important; + } +} + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-md { + display: block !important; + } + tr.visible-md { + display: table-row !important; + } + th.visible-md, + td.visible-md { + display: table-cell !important; + } +} + +@media (min-width: 1200px) { + .visible-md.visible-lg { + display: block !important; + } + tr.visible-md.visible-lg { + display: table-row !important; + } + th.visible-md.visible-lg, + td.visible-md.visible-lg { + display: table-cell !important; + } +} + +.visible-lg { + display: none !important; +} + +tr.visible-lg { + display: none !important; +} + +th.visible-lg, +td.visible-lg { + display: none !important; +} + +@media (max-width: 767px) { + .visible-lg.visible-xs { + display: block !important; + } + tr.visible-lg.visible-xs { + display: table-row !important; + } + th.visible-lg.visible-xs, + td.visible-lg.visible-xs { + display: table-cell !important; + } +} + +@media (min-width: 768px) and (max-width: 991px) { + .visible-lg.visible-sm { + display: block !important; + } + tr.visible-lg.visible-sm { + display: table-row !important; + } + th.visible-lg.visible-sm, + td.visible-lg.visible-sm { + display: table-cell !important; + } +} + +@media (min-width: 992px) and (max-width: 1199px) { + .visible-lg.visible-md { + display: block !important; + } + tr.visible-lg.visible-md { + display: table-row !important; + } + th.visible-lg.visible-md, + td.visible-lg.visible-md { + display: table-cell !important; + } +} + +@media (min-width: 1200px) { + .visible-lg { + display: block !important; + } + tr.visible-lg { + display: table-row !important; + } + th.visible-lg, + td.visible-lg { + display: table-cell !important; + } +} + +.hidden-xs { + display: block !important; +} + +tr.hidden-xs { + display: table-row !important; +} + +th.hidden-xs, +td.hidden-xs { + display: table-cell !important; +} + +@media (max-width: 767px) { + .hidden-xs { + display: none !important; + } + tr.hidden-xs { + display: none !important; + } + th.hidden-xs, + td.hidden-xs { + display: none !important; + } +} + +@media (min-width: 768px) and (max-width: 991px) { + .hidden-xs.hidden-sm { + display: none !important; + } + tr.hidden-xs.hidden-sm { + display: none !important; + } + th.hidden-xs.hidden-sm, + td.hidden-xs.hidden-sm { + display: none !important; + } +} + +@media (min-width: 992px) and (max-width: 1199px) { + .hidden-xs.hidden-md { + display: none !important; + } + tr.hidden-xs.hidden-md { + display: none !important; + } + th.hidden-xs.hidden-md, + td.hidden-xs.hidden-md { + display: none !important; + } +} + +@media (min-width: 1200px) { + .hidden-xs.hidden-lg { + display: none !important; + } + tr.hidden-xs.hidden-lg { + display: none !important; + } + th.hidden-xs.hidden-lg, + td.hidden-xs.hidden-lg { + display: none !important; + } +} + +.hidden-sm { + display: block !important; +} + +tr.hidden-sm { + display: table-row !important; +} + +th.hidden-sm, +td.hidden-sm { + display: table-cell !important; +} + +@media (max-width: 767px) { + .hidden-sm.hidden-xs { + display: none !important; + } + tr.hidden-sm.hidden-xs { + display: none !important; + } + th.hidden-sm.hidden-xs, + td.hidden-sm.hidden-xs { + display: none !important; + } +} + +@media (min-width: 768px) and (max-width: 991px) { + .hidden-sm { + display: none !important; + } + tr.hidden-sm { + display: none !important; + } + th.hidden-sm, + td.hidden-sm { + display: none !important; + } +} + +@media (min-width: 992px) and (max-width: 1199px) { + .hidden-sm.hidden-md { + display: none !important; + } + tr.hidden-sm.hidden-md { + display: none !important; + } + th.hidden-sm.hidden-md, + td.hidden-sm.hidden-md { + display: none !important; + } +} + +@media (min-width: 1200px) { + .hidden-sm.hidden-lg { + display: none !important; + } + tr.hidden-sm.hidden-lg { + display: none !important; + } + th.hidden-sm.hidden-lg, + td.hidden-sm.hidden-lg { + display: none !important; + } +} + +.hidden-md { + display: block !important; +} + +tr.hidden-md { + display: table-row !important; +} + +th.hidden-md, +td.hidden-md { + display: table-cell !important; +} + +@media (max-width: 767px) { + .hidden-md.hidden-xs { + display: none !important; + } + tr.hidden-md.hidden-xs { + display: none !important; + } + th.hidden-md.hidden-xs, + td.hidden-md.hidden-xs { + display: none !important; + } +} + +@media (min-width: 768px) and (max-width: 991px) { + .hidden-md.hidden-sm { + display: none !important; + } + tr.hidden-md.hidden-sm { + display: none !important; + } + th.hidden-md.hidden-sm, + td.hidden-md.hidden-sm { + display: none !important; + } +} + +@media (min-width: 992px) and (max-width: 1199px) { + .hidden-md { + display: none !important; + } + tr.hidden-md { + display: none !important; + } + th.hidden-md, + td.hidden-md { + display: none !important; + } +} + +@media (min-width: 1200px) { + .hidden-md.hidden-lg { + display: none !important; + } + tr.hidden-md.hidden-lg { + display: none !important; + } + th.hidden-md.hidden-lg, + td.hidden-md.hidden-lg { + display: none !important; + } +} + +.hidden-lg { + display: block !important; +} + +tr.hidden-lg { + display: table-row !important; +} + +th.hidden-lg, +td.hidden-lg { + display: table-cell !important; +} + +@media (max-width: 767px) { + .hidden-lg.hidden-xs { + display: none !important; + } + tr.hidden-lg.hidden-xs { + display: none !important; + } + th.hidden-lg.hidden-xs, + td.hidden-lg.hidden-xs { + display: none !important; + } +} + +@media (min-width: 768px) and (max-width: 991px) { + .hidden-lg.hidden-sm { + display: none !important; + } + tr.hidden-lg.hidden-sm { + display: none !important; + } + th.hidden-lg.hidden-sm, + td.hidden-lg.hidden-sm { + display: none !important; + } +} + +@media (min-width: 992px) and (max-width: 1199px) { + .hidden-lg.hidden-md { + display: none !important; + } + tr.hidden-lg.hidden-md { + display: none !important; + } + th.hidden-lg.hidden-md, + td.hidden-lg.hidden-md { + display: none !important; + } +} + +@media (min-width: 1200px) { + .hidden-lg { + display: none !important; + } + tr.hidden-lg { + display: none !important; + } + th.hidden-lg, + td.hidden-lg { + display: none !important; + } +} + +.visible-print { + display: none !important; +} + +tr.visible-print { + display: none !important; +} + +th.visible-print, +td.visible-print { + display: none !important; +} + +@media print { + .visible-print { + display: block !important; + } + tr.visible-print { + display: table-row !important; + } + th.visible-print, + td.visible-print { + display: table-cell !important; + } + .hidden-print { + display: none !important; + } + tr.hidden-print { + display: none !important; + } + th.hidden-print, + td.hidden-print { + display: none !important; + } +} + +.navbar { + text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#484e55), color-stop(60%, #3a3f44), to(#313539)); + background-image: -webkit-linear-gradient(#484e55, #3a3f44 60%, #313539); + background-image: -moz-linear-gradient(top, #484e55, #3a3f44 60%, #313539); + background-image: linear-gradient(#484e55, #3a3f44 60%, #313539); + background-repeat: no-repeat; + border: 1px solid rgba(0, 0, 0, 0.6); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff484e55', endColorstr='#ff313539', GradientType=0); +} + +.navbar-inverse { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#8a9196), color-stop(60%, #7a8288), to(#70787d)); + background-image: -webkit-linear-gradient(#8a9196, #7a8288 60%, #70787d); + background-image: -moz-linear-gradient(top, #8a9196, #7a8288 60%, #70787d); + background-image: linear-gradient(#8a9196, #7a8288 60%, #70787d); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff8a9196', endColorstr='#ff70787d', GradientType=0); +} + +.navbar-nav > li > a { + border-right: 1px solid rgba(0, 0, 0, 0.2); + border-left: 1px solid rgba(255, 255, 255, 0.1); +} + +.navbar-nav > li > a:hover { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#020202), color-stop(40%, #101112), to(#191b1d)); + background-image: -webkit-linear-gradient(#020202, #101112 40%, #191b1d); + background-image: -moz-linear-gradient(top, #020202, #101112 40%, #191b1d); + background-image: linear-gradient(#020202, #101112 40%, #191b1d); + background-repeat: no-repeat; + border-left-color: transparent; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff020202', endColorstr='#ff191b1d', GradientType=0); +} + +.navbar .nav .open > a { + border-color: transparent; +} + +.navbar-nav > li.active > a { + border-left-color: transparent; +} + +.navbar-form { + margin-right: 5px; + margin-left: 5px; +} + +.btn, +.btn:hover { + text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3); + border-color: rgba(0, 0, 0, 0.6); +} + +.btn-default { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#484e55), color-stop(60%, #3a3f44), to(#313539)); + background-image: -webkit-linear-gradient(#484e55, #3a3f44 60%, #313539); + background-image: -moz-linear-gradient(top, #484e55, #3a3f44 60%, #313539); + background-image: linear-gradient(#484e55, #3a3f44 60%, #313539); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff484e55', endColorstr='#ff313539', GradientType=0); +} + +.btn-primary { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#8a9196), color-stop(60%, #7a8288), to(#70787d)); + background-image: -webkit-linear-gradient(#8a9196, #7a8288 60%, #70787d); + background-image: -moz-linear-gradient(top, #8a9196, #7a8288 60%, #70787d); + background-image: linear-gradient(#8a9196, #7a8288 60%, #70787d); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff8a9196', endColorstr='#ff70787d', GradientType=0); +} + +.btn-success { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#78cc78), color-stop(60%, #62c462), to(#53be53)); + background-image: -webkit-linear-gradient(#78cc78, #62c462 60%, #53be53); + background-image: -moz-linear-gradient(top, #78cc78, #62c462 60%, #53be53); + background-image: linear-gradient(#78cc78, #62c462 60%, #53be53); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff78cc78', endColorstr='#ff53be53', GradientType=0); +} + +.btn-info { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#74cae3), color-stop(60%, #5bc0de), to(#4ab9db)); + background-image: -webkit-linear-gradient(#74cae3, #5bc0de 60%, #4ab9db); + background-image: -moz-linear-gradient(top, #74cae3, #5bc0de 60%, #4ab9db); + background-image: linear-gradient(#74cae3, #5bc0de 60%, #4ab9db); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff74cae3', endColorstr='#ff4ab9db', GradientType=0); +} + +.btn-warning { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#faa123), color-stop(60%, #f89406), to(#e48806)); + background-image: -webkit-linear-gradient(#faa123, #f89406 60%, #e48806); + background-image: -moz-linear-gradient(top, #faa123, #f89406 60%, #e48806); + background-image: linear-gradient(#faa123, #f89406 60%, #e48806); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffaa123', endColorstr='#ffe48806', GradientType=0); +} + +.btn-danger { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#f17a77), color-stop(60%, #ee5f5b), to(#ec4d49)); + background-image: -webkit-linear-gradient(#f17a77, #ee5f5b 60%, #ec4d49); + background-image: -moz-linear-gradient(top, #f17a77, #ee5f5b 60%, #ec4d49); + background-image: linear-gradient(#f17a77, #ee5f5b 60%, #ec4d49); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff17a77', endColorstr='#ffec4d49', GradientType=0); +} + +.btn-default:hover { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#020202), color-stop(40%, #101112), to(#191b1d)); + background-image: -webkit-linear-gradient(#020202, #101112 40%, #191b1d); + background-image: -moz-linear-gradient(top, #020202, #101112 40%, #191b1d); + background-image: linear-gradient(#020202, #101112 40%, #191b1d); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff020202', endColorstr='#ff191b1d', GradientType=0); +} + +.btn-primary:hover { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#404448), color-stop(40%, #4e5458), to(#585e62)); + background-image: -webkit-linear-gradient(#404448, #4e5458 40%, #585e62); + background-image: -moz-linear-gradient(top, #404448, #4e5458 40%, #585e62); + background-image: linear-gradient(#404448, #4e5458 40%, #585e62); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff404448', endColorstr='#ff585e62', GradientType=0); +} + +.btn-success:hover { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#2f7d2f), color-stop(40%, #379337), to(#3da23d)); + background-image: -webkit-linear-gradient(#2f7d2f, #379337 40%, #3da23d); + background-image: -moz-linear-gradient(top, #2f7d2f, #379337 40%, #3da23d); + background-image: linear-gradient(#2f7d2f, #379337 40%, #3da23d); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff2f7d2f', endColorstr='#ff3da23d', GradientType=0); +} + +.btn-info:hover { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#20829f), color-stop(40%, #2596b8), to(#28a4c9)); + background-image: -webkit-linear-gradient(#20829f, #2596b8 40%, #28a4c9); + background-image: -moz-linear-gradient(top, #20829f, #2596b8 40%, #28a4c9); + background-image: linear-gradient(#20829f, #2596b8 40%, #28a4c9); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff20829f', endColorstr='#ff28a4c9', GradientType=0); +} + +.btn-warning:hover { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#804d03), color-stop(40%, #9e5f04), to(#b26a04)); + background-image: -webkit-linear-gradient(#804d03, #9e5f04 40%, #b26a04); + background-image: -moz-linear-gradient(top, #804d03, #9e5f04 40%, #b26a04); + background-image: linear-gradient(#804d03, #9e5f04 40%, #b26a04); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff804d03', endColorstr='#ffb26a04', GradientType=0); +} + +.btn-danger:hover { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#bb1813), color-stop(40%, #d71c16), to(#e7201a)); + background-image: -webkit-linear-gradient(#bb1813, #d71c16 40%, #e7201a); + background-image: -moz-linear-gradient(top, #bb1813, #d71c16 40%, #e7201a); + background-image: linear-gradient(#bb1813, #d71c16 40%, #e7201a); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffbb1813', endColorstr='#ffe7201a', GradientType=0); +} + +h1, +h2, +h3, +h4, +h5, +h6 { + text-shadow: -1px -1px 0 rgba(0, 0, 0, 0.3); +} + +.text-primary { + color: #7a8288; +} + +.text-success { + color: #62c462; +} + +.text-danger { + color: #ee5f5b; +} + +.text-warning { + color: #f89406; +} + +.text-info { + color: #5bc0de; +} + +.table tr.success, +.table tr.warning, +.table tr.danger { + color: #fff; +} + +.table-bordered tbody tr.success td, +.table-bordered tbody tr.warning td, +.table-bordered tbody tr.danger td, +.table-bordered tbody tr.success:hover td, +.table-bordered tbody tr.warning:hover td, +.table-bordered tbody tr.danger:hover td { + border-color: #1c1e22; +} + +.has-warning .help-block, +.has-warning .control-label { + color: #f89406; +} + +.has-warning .form-control, +.has-warning .form-control:focus { + border-color: #f89406; +} + +.has-error .help-block, +.has-error .control-label { + color: #ee5f5b; +} + +.has-error .form-control, +.has-error .form-control:focus { + border-color: #ee5f5b; +} + +.has-success .help-block, +.has-success .control-label { + color: #62c462; +} + +.has-success .form-control, +.has-success .form-control:focus { + border-color: #62c462; +} + +legend { + color: #fff; +} + +.input-group-addon { + text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#484e55), color-stop(60%, #3a3f44), to(#313539)); + background-image: -webkit-linear-gradient(#484e55, #3a3f44 60%, #313539); + background-image: -moz-linear-gradient(top, #484e55, #3a3f44 60%, #313539); + background-image: linear-gradient(#484e55, #3a3f44 60%, #313539); + background-repeat: no-repeat; + border-color: rgba(0, 0, 0, 0.6); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff484e55', endColorstr='#ff313539', GradientType=0); +} + +.nav .open > a, +.nav .open > a:hover, +.nav .open > a:focus { + border-color: rgba(0, 0, 0, 0.6); +} + +.nav-pills > li > a { + text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#484e55), color-stop(60%, #3a3f44), to(#313539)); + background-image: -webkit-linear-gradient(#484e55, #3a3f44 60%, #313539); + background-image: -moz-linear-gradient(top, #484e55, #3a3f44 60%, #313539); + background-image: linear-gradient(#484e55, #3a3f44 60%, #313539); + background-repeat: no-repeat; + border: 1px solid rgba(0, 0, 0, 0.6); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff484e55', endColorstr='#ff313539', GradientType=0); +} + +.nav-pills > li > a:hover { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#020202), color-stop(40%, #101112), to(#191b1d)); + background-image: -webkit-linear-gradient(#020202, #101112 40%, #191b1d); + background-image: -moz-linear-gradient(top, #020202, #101112 40%, #191b1d); + background-image: linear-gradient(#020202, #101112 40%, #191b1d); + background-repeat: no-repeat; + border: 1px solid rgba(0, 0, 0, 0.6); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff020202', endColorstr='#ff191b1d', GradientType=0); +} + +.nav-pills > li.active > a, +.nav-pills > li.active > a:hover { + background-color: none; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#020202), color-stop(40%, #101112), to(#191b1d)); + background-image: -webkit-linear-gradient(#020202, #101112 40%, #191b1d); + background-image: -moz-linear-gradient(top, #020202, #101112 40%, #191b1d); + background-image: linear-gradient(#020202, #101112 40%, #191b1d); + background-repeat: no-repeat; + border: 1px solid rgba(0, 0, 0, 0.6); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff020202', endColorstr='#ff191b1d', GradientType=0); +} + +.nav-pills > li.disabled > a, +.nav-pills > li.disabled > a:hover { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#484e55), color-stop(60%, #3a3f44), to(#313539)); + background-image: -webkit-linear-gradient(#484e55, #3a3f44 60%, #313539); + background-image: -moz-linear-gradient(top, #484e55, #3a3f44 60%, #313539); + background-image: linear-gradient(#484e55, #3a3f44 60%, #313539); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff484e55', endColorstr='#ff313539', GradientType=0); +} + +.pagination > li > a { + text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#484e55), color-stop(60%, #3a3f44), to(#313539)); + background-image: -webkit-linear-gradient(#484e55, #3a3f44 60%, #313539); + background-image: -moz-linear-gradient(top, #484e55, #3a3f44 60%, #313539); + background-image: linear-gradient(#484e55, #3a3f44 60%, #313539); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff484e55', endColorstr='#ff313539', GradientType=0); +} + +.pagination > li > a:hover { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#020202), color-stop(40%, #101112), to(#191b1d)); + background-image: -webkit-linear-gradient(#020202, #101112 40%, #191b1d); + background-image: -moz-linear-gradient(top, #020202, #101112 40%, #191b1d); + background-image: linear-gradient(#020202, #101112 40%, #191b1d); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff020202', endColorstr='#ff191b1d', GradientType=0); +} + +.pagination > li.active > a { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#020202), color-stop(40%, #101112), to(#191b1d)); + background-image: -webkit-linear-gradient(#020202, #101112 40%, #191b1d); + background-image: -moz-linear-gradient(top, #020202, #101112 40%, #191b1d); + background-image: linear-gradient(#020202, #101112 40%, #191b1d); + background-repeat: no-repeat; + border-color: rgba(0, 0, 0, 0.6); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff020202', endColorstr='#ff191b1d', GradientType=0); +} + +.pagination > li.disabled > a, +.pagination > li.disabled > a:hover { + background-color: transparent; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#484e55), color-stop(60%, #3a3f44), to(#313539)); + background-image: -webkit-linear-gradient(#484e55, #3a3f44 60%, #313539); + background-image: -moz-linear-gradient(top, #484e55, #3a3f44 60%, #313539); + background-image: linear-gradient(#484e55, #3a3f44 60%, #313539); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff484e55', endColorstr='#ff313539', GradientType=0); +} + +.pager > li > a { + text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#484e55), color-stop(60%, #3a3f44), to(#313539)); + background-image: -webkit-linear-gradient(#484e55, #3a3f44 60%, #313539); + background-image: -moz-linear-gradient(top, #484e55, #3a3f44 60%, #313539); + background-image: linear-gradient(#484e55, #3a3f44 60%, #313539); + background-repeat: no-repeat; + border: 1px solid rgba(0, 0, 0, 0.6); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff484e55', endColorstr='#ff313539', GradientType=0); +} + +.pager > li > a:hover { + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#020202), color-stop(40%, #101112), to(#191b1d)); + background-image: -webkit-linear-gradient(#020202, #101112 40%, #191b1d); + background-image: -moz-linear-gradient(top, #020202, #101112 40%, #191b1d); + background-image: linear-gradient(#020202, #101112 40%, #191b1d); + background-repeat: no-repeat; + border: 1px solid rgba(0, 0, 0, 0.6); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff020202', endColorstr='#ff191b1d', GradientType=0); +} + +.pager > li.disabled > a, +.pager > li.disabled > a:hover { + background-color: transparent; + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#484e55), color-stop(60%, #3a3f44), to(#313539)); + background-image: -webkit-linear-gradient(#484e55, #3a3f44 60%, #313539); + background-image: -moz-linear-gradient(top, #484e55, #3a3f44 60%, #313539); + background-image: linear-gradient(#484e55, #3a3f44 60%, #313539); + background-repeat: no-repeat; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff484e55', endColorstr='#ff313539', GradientType=0); +} + +.breadcrumb { + text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.3); + background-image: -webkit-gradient(linear, 0 0, 0 100%, from(#484e55), color-stop(60%, #3a3f44), to(#313539)); + background-image: -webkit-linear-gradient(#484e55, #3a3f44 60%, #313539); + background-image: -moz-linear-gradient(top, #484e55, #3a3f44 60%, #313539); + background-image: linear-gradient(#484e55, #3a3f44 60%, #313539); + background-repeat: no-repeat; + border: 1px solid rgba(0, 0, 0, 0.6); + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff484e55', endColorstr='#ff313539', GradientType=0); +} + +.alert .alert-link, +.alert a { + color: #fff; + text-decoration: underline; +} + +.jumbotron { + border: 1px solid rgba(0, 0, 0, 0.6); +} + +.list-group-item { + background-color: #32383e; +} + +.panel-primary .panel-heading, +.panel-success .panel-heading, +.panel-danger .panel-heading, +.panel-warning .panel-heading, +.panel-info .panel-heading { + border-color: #000; +} + +.clearfix:before, +.clearfix:after { + display: table; + content: " "; +} + +.clearfix:after { + clear: both; +} + +.clearfix:before, +.clearfix:after { + display: table; + content: " "; +} + +.clearfix:after { + clear: both; +} + +.pull-right { + float: right !important; +} + +.pull-left { + float: left !important; +} + +.hide { + display: none !important; +} + +.show { + display: block !important; +} + +.invisible { + visibility: hidden; +} + +.text-hide { + font: 0/0 a; + color: transparent; + text-shadow: none; + background-color: transparent; + border: 0; +} + +.affix { + position: fixed; +} \ No newline at end of file diff --git a/GUI/css/main.css b/GUI/css/main.css new file mode 100644 index 0000000..30aacea --- /dev/null +++ b/GUI/css/main.css @@ -0,0 +1,241 @@ +body { + font-family: Helvetica, Arial, sans-serif; + font-size: 14px; + color: #c8c8c8; + background:#272B30; +} + +h1 { font-size:18px; } + +h2 { + font-size:14px; + color:#F89331; +} + +h3 { + font-size:12px; + font-weight:bold; + color:#006486; +} + +a { text-decoration:none; } +a:hover { text-decoration:underline; } +a:focus { text-decoration:underline; } +a:active { text-decoration:underline; } + +fieldset { padding-bottom:1em } + +table { margin:0px; padding:0px; } +th { background-color:#f2f2f2; padding:0.25em; } + +legend { + font-size:14px; +} + +.conversionok { + color:#2BD95C; + font-weight:bold; +} + +.conversionwarning { + color:#FADF65; + font-weight:bold; +} + +.conversionerror { + color:#F89331; + font-weight:bold; +} + +.conversionheadline { + background-color:#006486; + width:100% +} + +.conversiondetails { + display:none; + padding:1em; +} + +.tddark { + background-color:#f6f6f6; +} + +.tdbright { + background-color:#ffffff; +} + +.formhint { + text-align:left; +} + +.formlabel { + font-weight:bold; + text-align:left; + vertical-align:top; + padding-right:0.5em; +} + +.formlabelerror { + color:#F89331; + font-weight:bold; + text-align:left; + vertical-align:top; + padding-right:0.5em; +} + +.error { + color:#F89331; + font-weight:bold; +} + +.formelement { + text-align:left; + vertical-align:top; + padding-bottom:0.5em; + width:450px; +} + +.formsubmit { + text-align:right; + padding-right:1em; + padding-top:0.5em; +} +.topnav { + width:100%; + + padding:0.25em; + padding-left:0.5em; + + background-color:#006486; + + font-size:10px; + color:#ffffff; + + border-bottom-width:1px; + border-bottom-style:solid; + border-bottom-color:#006486; + + border-left-width:1px; + border-left-style:solid; + border-left-color:#F2F2F2; + + border-right-width:1px; + border-right-style:solid; + border-right-color:#F2F2F2; +} + +.topnavlink { + color:#ffffff; +} + +.main { + + margin-top:0.25em; + background-color:#FCFCFC; + + width:100%; + + padding:0.25em; + padding-left:0.5em; + padding-top:1em; + + text-align:left; + vertical-align:top; + + border-top-width:1px; + border-top-style:solid; + border-top-color:#F2F2F2; + + border-left-width:1px; + border-left-style:solid; + border-left-color:#F2F2F2; + + border-right-width:1px; + border-right-style:solid; + border-right-color:#F2F2F2; + + border-bottom-width:1px; + border-bottom-style:solid; + border-bottom-color:#F2F2F2; + +} + +.maintextbox { + margin-bottom:1em; +} + +.bottom { + + width:100%; + background-color:#FCFCFC; + + font-size:10px; + + margin-top:1em; + + padding:0.25em; + padding-left:0.5em; + + border-top-width:1px; + border-top-style:solid; + border-top-color:#F2F2F2; + + border-left-width:1px; + border-left-style:solid; + border-left-color:#F2F2F2; + + border-right-width:1px; + border-right-style:solid; + border-right-color:#F2F2F2; + + border-bottom-width:1px; + border-bottom-style:solid; + border-bottom-color:#F2F2F2 +} +@media (min-width: 768px) { + .nav-justified { + max-height: 52px; + } + .nav-justified > li > a { + border-left: 1px solid #fff; + border-right: 1px solid #d5d5d5; + } + .nav-justified > li:first-child > a { + border-left: 0; + border-radius: 5px 0 0 5px; + } + .nav-justified > li:last-child > a { + border-radius: 0 5px 5px 0; + border-right: 0; + } +} + +/ Responsive: Portrait tablets and up */ +@media screen and (min-width: 768px) { + /* Remove the padding we set earlier */ +* .masthead, + .marketing, + .footer { + padding-left: 0; + padding-right: 0; + } +} +.footer { + margin-top: 40px; + padding: 40px; +} +.sep{ + margin-bottom: 90px; +} +.table{ + color:#fff; + text-align: left; + border-radius: 4px; +} +.toggle:hover{ + cursor: pointer; +} +.well{ + overflow: auto; +} \ No newline at end of file diff --git a/GUI/file.php b/GUI/file.php new file mode 100644 index 0000000..054d3d1 --- /dev/null +++ b/GUI/file.php @@ -0,0 +1,169 @@ + + + + + Dedax - Eurl Automotive Engineering & Development + + + + + + + + + + + +
+ + + +
+

Fiche Technique

+
+ +

Produit :

+ + +

+ +
+

Application

+
+
+ +
+
+ + + + +
+ + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/GUI/help.php b/GUI/help.php new file mode 100644 index 0000000..31cc689 --- /dev/null +++ b/GUI/help.php @@ -0,0 +1,138 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ + +require_once('snippets/MySQLConverterTool_GUI_Snippets.php'); + +$snippet_title = 'MySQL ext/mysql Converter Tool'; +$snippet_greeting = 'Help'; +$snippet_nav_path = array($_SERVER['PHP_SELF'] => 'Help'); +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/header.php'); +?> +

About

+

+This is the MySQL ext/mysql Converter Tool. The tool can be used to convert PHP +files using the PHP MySQL extension (ext/mysql) to make the scripts use the PHP MySQLi extension. +The PHP MySQL extension has been designed to work with the MySQL Server up to version 4.1.0. +Some features introduced later, for example prepared statements, are not supported by the extension. +To use these features, you have to use the PHP MySQLi extension. This tool helps you to convert +your existing scripts from the old MySQL extension to the new MySQLi extension. +

+

+The tool uses a simple approach to map mysql_*-functions to their mysqli_*-counterparts. +All mysql_*-functions can be converted automatically. The generated code will run out of +the box. However, the tool does not take context and runtime informationn into account +when it does the conversion. This can lead to situations where the tool is not sure if the +generated code is semantically identical to the original code in all ways. If this happens, +a warning will the thrown and you will be requested to check the automatically generated tool +

+

+The tool has been originally developed by MySQL AB. It is released under the terms of the +PHP Licence 3.0. +

+

Where can I get more information?

+

+Plase consult the MySQL Forge Wiki for additional information. +

+

What cannot be converted automatically?

+

+Use the function MySQLConvertTool_Converter::getUnsupportedFunctions() to get a list of all +functions which cannot be converted automatically. Currently, the tool does not support +the conversion of the following, rarely used functions: +

    +
  • mysql_result()
  • +
  • mysql_fetch_field2()
  • +
+All other mysql_*-functions can be converted automatically. +

+

What is considered to be a warning?

+

+The converter tool works stateless. It does not take any context or runtime information into account. +It does nothing but analyze existing mysql_*-functions and tries to translate them into their +mysqli_*-counterparts. Most expressions can be translated into semantically identical expressions +using this approach. But there are limits. Whenever such a limit gets hit, the tool throws +an error and asks you to check your code manually. +

+

A simple example of an expression which cannot be converted without context information is mysql_error(). +Consider the following PHP code: +

+

+ +

+if (!mysql_connect())
+    die(sprintf("[%d] %s\n", mysql_errno(), mysql_error()));
+
+ +

+

+The author of the code relies on the default connection feature. mysql_errno() can be called with or without a +link identifier. The function accepts one optional parameter: +

+

+ +

+mysql_errno ( [resource link_identifier] )
+
+ +

+

+The mysqli_errno() counterpart of the MySQLi extension must be provided with a link identifier. +

+

+ +

+mysqli_errno ( mysqli link )
+
+ +

+

+The tool is clever enough to store the return value of mysql_connect() [mysqli_connect()] in a global variable +and pass the global variable to the mysqli_errno() function call. But if mysqli_connect() fails and does not +return a link identifier, mysqli_errno() will be called with an invalid parameter. Again, the conversion tool +is clever enough to add a conditional expression to ensure that the generated code behaves like the original +code, but this is considered as a "hack" and a "warning" will be thrown. The warning tells you to check manually +that the generated code is semantically identical to the original code. You could, for example, +have a mysql_errno() somewhere in your code without a preceding mysql_connect(). That does not make too much sense, +but it could be. As the converter tool does not consider any state and context information it cannot detect +such problems. When the mysql_errno() call gets converted no information is available if it is preceded by a mysql_connect() +call or not. +

+

+Yes, we think it is worth to throw a warning. You can call it picky. Most of the warnings can be safely +ignored. But we give no warranty. Check your code manually! +

+

+There are many more situations when a warning gets thrown. For example, mysql_fetch_field() will be replaced +by a semantically identical expression, but the replacement is a huge, ugly piece of code which you should streamline. +

+

Can I safely ignore the warnings?

+

+No, you are strongly requested to check the generated code manually. It is likely that the generated code +works as expected in most cases, but not in all cases! +

+

What is considered to be an error?

+

+The tool considers a conversion as failed and all warnings as errors if the number of converted functions +differs from the number of mysql_*-functions found in the given PHP source. +

+

Where can I learn more about limitations?

+

+The converter tool comes with more than 50 "real-life" test cases. At least one test case exists for every +mysql_-function which can be handled by the tool. If a test case contains code which cannot be +converted automatically into a semantically identical mysqli*-function, the test case name is preceded with +the word "FAILURE". Check the test cases in the folder UnitTests/Converter/TestCode +for details. +

+ \ No newline at end of file diff --git a/GUI/index.php b/GUI/index.php new file mode 100644 index 0000000..89ebbd6 --- /dev/null +++ b/GUI/index.php @@ -0,0 +1,47 @@ +, Ulf Wendel , Saif Lacrimosa +* @copyright 1997-2006 The PHP Group +* @license http://www.php.net/license/3_0.txt PHP License 3.0 +* @version CVS: $Id:$, Release: @package_version@ +* @link http://www.mysql.com +* @since Available since Release 1.0 +*/ + +require_once('snippets/MySQLConverterTool_GUI_Snippets.php'); + +$snippet_title = 'Welcome to the MySQL ext/mysql Converter Tool'; +$snippet_greeting = 'Welcome to the MySQL ext/mysq Converter Tool'; + +MySQLConverterTool_GUI_Snippets::load(dirname(__FILE__) . '/snippets/header.php'); +?> + +
+

You have successfully installed the MySQL ext/mysql Converter Tool. + The tool helps you to migrate existing PHP code using the PHP MySQL Extension + (ext/mysql) to the PHP MySQLi Extension (ext/mysqli). The tool reads the source code + and converts all MySQL functions into their MySQLi counterparts.


+
+
+

Select one of the following actions:

+
+
+ Convert a directory + Use this to convert all PHP files contained in one + directory. +
+
+ Convert a file + Use this to convert a single PHP file. +
+
+ Convert a code snippet + Use this to convert a snippet, a piece of PHP code. +
+ \ No newline at end of file diff --git a/GUI/js/application.js b/GUI/js/application.js new file mode 100644 index 0000000..81b644b --- /dev/null +++ b/GUI/js/application.js @@ -0,0 +1,83 @@ +// NOTICE!! DO NOT USE ANY OF THIS JAVASCRIPT +// IT'S ALL JUST JUNK FOR OUR DOCS! +// ++++++++++++++++++++++++++++++++++++++++++ + +!function ($) { + + $(function(){ + + var $window = $(window) + var $body = $(document.body) + + var navHeight = $('.navbar').outerHeight(true) + 10 + + $body.scrollspy({ + target: '.bs-sidebar', + offset: navHeight + }) + + $window.on('load', function () { + $body.scrollspy('refresh') + }) + + $('.bs-docs-container [href=#]').click(function (e) { + e.preventDefault() + }) + + // back to top + setTimeout(function () { + var $sideBar = $('.bs-sidebar') + + $sideBar.affix({ + offset: { + top: function () { + var offsetTop = $sideBar.offset().top + var sideBarMargin = parseInt($sideBar.children(0).css('margin-top'), 10) + var navOuterHeight = $('.bs-docs-nav').height() + + return (this.top = offsetTop - navOuterHeight - sideBarMargin) + } + , bottom: function () { + return (this.bottom = $('.bs-footer').outerHeight(true)) + } + } + }) + }, 100) + + setTimeout(function () { + $('.bs-top').affix() + }, 100) + + // tooltip demo + $('.tooltip-demo').tooltip({ + selector: "[data-toggle=tooltip]", + container: "body" + }) + + $('.tooltip-test').tooltip() + $('.popover-test').popover() + + $('.bs-docs-navbar').tooltip({ + selector: "a[data-toggle=tooltip]", + container: ".bs-docs-navbar .nav" + }) + + // popover demo + $("[data-toggle=popover]") + .popover() + + // button state demo + $('#fat-btn') + .click(function () { + var btn = $(this) + btn.button('loading') + setTimeout(function () { + btn.button('reset') + }, 3000) + }) + + // carousel demo + $('.bs-docs-carousel-example').carousel() +}) + +}(window.jQuery) diff --git a/GUI/js/bootstrap.js b/GUI/js/bootstrap.js new file mode 100644 index 0000000..2c64257 --- /dev/null +++ b/GUI/js/bootstrap.js @@ -0,0 +1,1999 @@ +/** +* bootstrap.js v3.0.0 by @fat and @mdo +* Copyright 2013 Twitter Inc. +* http://www.apache.org/licenses/LICENSE-2.0 +*/ +if (!jQuery) { throw new Error("Bootstrap requires jQuery") } + +/* ======================================================================== + * Bootstrap: transition.js v3.0.0 + * http://twbs.github.com/bootstrap/javascript.html#transitions + * ======================================================================== + * Copyright 2013 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ======================================================================== */ + + ++function ($) { "use strict"; + + // CSS TRANSITION SUPPORT (Shoutout: http://www.modernizr.com/) + // ============================================================ + + function transitionEnd() { + var el = document.createElement('bootstrap') + + var transEndEventNames = { + 'WebkitTransition' : 'webkitTransitionEnd' + , 'MozTransition' : 'transitionend' + , 'OTransition' : 'oTransitionEnd otransitionend' + , 'transition' : 'transitionend' + } + + for (var name in transEndEventNames) { + if (el.style[name] !== undefined) { + return { end: transEndEventNames[name] } + } + } + } + + // http://blog.alexmaccaw.com/css-transitions + $.fn.emulateTransitionEnd = function (duration) { + var called = false, $el = this + $(this).one($.support.transition.end, function () { called = true }) + var callback = function () { if (!called) $($el).trigger($.support.transition.end) } + setTimeout(callback, duration) + return this + } + + $(function () { + $.support.transition = transitionEnd() + }) + +}(window.jQuery); + +/* ======================================================================== + * Bootstrap: alert.js v3.0.0 + * http://twbs.github.com/bootstrap/javascript.html#alerts + * ======================================================================== + * Copyright 2013 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ======================================================================== */ + + ++function ($) { "use strict"; + + // ALERT CLASS DEFINITION + // ====================== + + var dismiss = '[data-dismiss="alert"]' + var Alert = function (el) { + $(el).on('click', dismiss, this.close) + } + + Alert.prototype.close = function (e) { + var $this = $(this) + var selector = $this.attr('data-target') + + if (!selector) { + selector = $this.attr('href') + selector = selector && selector.replace(/.*(?=#[^\s]*$)/, '') // strip for ie7 + } + + var $parent = $(selector) + + if (e) e.preventDefault() + + if (!$parent.length) { + $parent = $this.hasClass('alert') ? $this : $this.parent() + } + + $parent.trigger(e = $.Event('close.bs.alert')) + + if (e.isDefaultPrevented()) return + + $parent.removeClass('in') + + function removeElement() { + $parent.trigger('closed.bs.alert').remove() + } + + $.support.transition && $parent.hasClass('fade') ? + $parent + .one($.support.transition.end, removeElement) + .emulateTransitionEnd(150) : + removeElement() + } + + + // ALERT PLUGIN DEFINITION + // ======================= + + var old = $.fn.alert + + $.fn.alert = function (option) { + return this.each(function () { + var $this = $(this) + var data = $this.data('bs.alert') + + if (!data) $this.data('bs.alert', (data = new Alert(this))) + if (typeof option == 'string') data[option].call($this) + }) + } + + $.fn.alert.Constructor = Alert + + + // ALERT NO CONFLICT + // ================= + + $.fn.alert.noConflict = function () { + $.fn.alert = old + return this + } + + + // ALERT DATA-API + // ============== + + $(document).on('click.bs.alert.data-api', dismiss, Alert.prototype.close) + +}(window.jQuery); + +/* ======================================================================== + * Bootstrap: button.js v3.0.0 + * http://twbs.github.com/bootstrap/javascript.html#buttons + * ======================================================================== + * Copyright 2013 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ======================================================================== */ + + ++function ($) { "use strict"; + + // BUTTON PUBLIC CLASS DEFINITION + // ============================== + + var Button = function (element, options) { + this.$element = $(element) + this.options = $.extend({}, Button.DEFAULTS, options) + } + + Button.DEFAULTS = { + loadingText: 'loading...' + } + + Button.prototype.setState = function (state) { + var d = 'disabled' + var $el = this.$element + var val = $el.is('input') ? 'val' : 'html' + var data = $el.data() + + state = state + 'Text' + + if (!data.resetText) $el.data('resetText', $el[val]()) + + $el[val](data[state] || this.options[state]) + + // push to event loop to allow forms to submit + setTimeout(function () { + state == 'loadingText' ? + $el.addClass(d).attr(d, d) : + $el.removeClass(d).removeAttr(d); + }, 0) + } + + Button.prototype.toggle = function () { + var $parent = this.$element.closest('[data-toggle="buttons"]') + + if ($parent.length) { + var $input = this.$element.find('input') + .prop('checked', !this.$element.hasClass('active')) + .trigger('change') + if ($input.prop('type') === 'radio') $parent.find('.active').removeClass('active') + } + + this.$element.toggleClass('active') + } + + + // BUTTON PLUGIN DEFINITION + // ======================== + + var old = $.fn.button + + $.fn.button = function (option) { + return this.each(function () { + var $this = $(this) + var data = $this.data('bs.button') + var options = typeof option == 'object' && option + + if (!data) $this.data('bs.button', (data = new Button(this, options))) + + if (option == 'toggle') data.toggle() + else if (option) data.setState(option) + }) + } + + $.fn.button.Constructor = Button + + + // BUTTON NO CONFLICT + // ================== + + $.fn.button.noConflict = function () { + $.fn.button = old + return this + } + + + // BUTTON DATA-API + // =============== + + $(document).on('click.bs.button.data-api', '[data-toggle^=button]', function (e) { + var $btn = $(e.target) + if (!$btn.hasClass('btn')) $btn = $btn.closest('.btn') + $btn.button('toggle') + e.preventDefault() + }) + +}(window.jQuery); + +/* ======================================================================== + * Bootstrap: carousel.js v3.0.0 + * http://twbs.github.com/bootstrap/javascript.html#carousel + * ======================================================================== + * Copyright 2012 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ======================================================================== */ + + ++function ($) { "use strict"; + + // CAROUSEL CLASS DEFINITION + // ========================= + + var Carousel = function (element, options) { + this.$element = $(element) + this.$indicators = this.$element.find('.carousel-indicators') + this.options = options + this.paused = + this.sliding = + this.interval = + this.$active = + this.$items = null + + this.options.pause == 'hover' && this.$element + .on('mouseenter', $.proxy(this.pause, this)) + .on('mouseleave', $.proxy(this.cycle, this)) + } + + Carousel.DEFAULTS = { + interval: 5000 + , pause: 'hover' + , wrap: true + } + + Carousel.prototype.cycle = function (e) { + e || (this.paused = false) + + this.interval && clearInterval(this.interval) + + this.options.interval + && !this.paused + && (this.interval = setInterval($.proxy(this.next, this), this.options.interval)) + + return this + } + + Carousel.prototype.getActiveIndex = function () { + this.$active = this.$element.find('.item.active') + this.$items = this.$active.parent().children() + + return this.$items.index(this.$active) + } + + Carousel.prototype.to = function (pos) { + var that = this + var activeIndex = this.getActiveIndex() + + if (pos > (this.$items.length - 1) || pos < 0) return + + if (this.sliding) return this.$element.one('slid', function () { that.to(pos) }) + if (activeIndex == pos) return this.pause().cycle() + + return this.slide(pos > activeIndex ? 'next' : 'prev', $(this.$items[pos])) + } + + Carousel.prototype.pause = function (e) { + e || (this.paused = true) + + if (this.$element.find('.next, .prev').length && $.support.transition.end) { + this.$element.trigger($.support.transition.end) + this.cycle(true) + } + + this.interval = clearInterval(this.interval) + + return this + } + + Carousel.prototype.next = function () { + if (this.sliding) return + return this.slide('next') + } + + Carousel.prototype.prev = function () { + if (this.sliding) return + return this.slide('prev') + } + + Carousel.prototype.slide = function (type, next) { + var $active = this.$element.find('.item.active') + var $next = next || $active[type]() + var isCycling = this.interval + var direction = type == 'next' ? 'left' : 'right' + var fallback = type == 'next' ? 'first' : 'last' + var that = this + + if (!$next.length) { + if (!this.options.wrap) return + $next = this.$element.find('.item')[fallback]() + } + + this.sliding = true + + isCycling && this.pause() + + var e = $.Event('slide.bs.carousel', { relatedTarget: $next[0], direction: direction }) + + if ($next.hasClass('active')) return + + if (this.$indicators.length) { + this.$indicators.find('.active').removeClass('active') + this.$element.one('slid', function () { + var $nextIndicator = $(that.$indicators.children()[that.getActiveIndex()]) + $nextIndicator && $nextIndicator.addClass('active') + }) + } + + if ($.support.transition && this.$element.hasClass('slide')) { + this.$element.trigger(e) + if (e.isDefaultPrevented()) return + $next.addClass(type) + $next[0].offsetWidth // force reflow + $active.addClass(direction) + $next.addClass(direction) + $active + .one($.support.transition.end, function () { + $next.removeClass([type, direction].join(' ')).addClass('active') + $active.removeClass(['active', direction].join(' ')) + that.sliding = false + setTimeout(function () { that.$element.trigger('slid') }, 0) + }) + .emulateTransitionEnd(600) + } else { + this.$element.trigger(e) + if (e.isDefaultPrevented()) return + $active.removeClass('active') + $next.addClass('active') + this.sliding = false + this.$element.trigger('slid') + } + + isCycling && this.cycle() + + return this + } + + + // CAROUSEL PLUGIN DEFINITION + // ========================== + + var old = $.fn.carousel + + $.fn.carousel = function (option) { + return this.each(function () { + var $this = $(this) + var data = $this.data('bs.carousel') + var options = $.extend({}, Carousel.DEFAULTS, $this.data(), typeof option == 'object' && option) + var action = typeof option == 'string' ? option : options.slide + + if (!data) $this.data('bs.carousel', (data = new Carousel(this, options))) + if (typeof option == 'number') data.to(option) + else if (action) data[action]() + else if (options.interval) data.pause().cycle() + }) + } + + $.fn.carousel.Constructor = Carousel + + + // CAROUSEL NO CONFLICT + // ==================== + + $.fn.carousel.noConflict = function () { + $.fn.carousel = old + return this + } + + + // CAROUSEL DATA-API + // ================= + + $(document).on('click.bs.carousel.data-api', '[data-slide], [data-slide-to]', function (e) { + var $this = $(this), href + var $target = $($this.attr('data-target') || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '')) //strip for ie7 + var options = $.extend({}, $target.data(), $this.data()) + var slideIndex = $this.attr('data-slide-to') + if (slideIndex) options.interval = false + + $target.carousel(options) + + if (slideIndex = $this.attr('data-slide-to')) { + $target.data('bs.carousel').to(slideIndex) + } + + e.preventDefault() + }) + + $(window).on('load', function () { + $('[data-ride="carousel"]').each(function () { + var $carousel = $(this) + $carousel.carousel($carousel.data()) + }) + }) + +}(window.jQuery); + +/* ======================================================================== + * Bootstrap: collapse.js v3.0.0 + * http://twbs.github.com/bootstrap/javascript.html#collapse + * ======================================================================== + * Copyright 2012 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ======================================================================== */ + + ++function ($) { "use strict"; + + // COLLAPSE PUBLIC CLASS DEFINITION + // ================================ + + var Collapse = function (element, options) { + this.$element = $(element) + this.options = $.extend({}, Collapse.DEFAULTS, options) + this.transitioning = null + + if (this.options.parent) this.$parent = $(this.options.parent) + if (this.options.toggle) this.toggle() + } + + Collapse.DEFAULTS = { + toggle: true + } + + Collapse.prototype.dimension = function () { + var hasWidth = this.$element.hasClass('width') + return hasWidth ? 'width' : 'height' + } + + Collapse.prototype.show = function () { + if (this.transitioning || this.$element.hasClass('in')) return + + var startEvent = $.Event('show.bs.collapse') + this.$element.trigger(startEvent) + if (startEvent.isDefaultPrevented()) return + + var actives = this.$parent && this.$parent.find('> .panel > .in') + + if (actives && actives.length) { + var hasData = actives.data('bs.collapse') + if (hasData && hasData.transitioning) return + actives.collapse('hide') + hasData || actives.data('bs.collapse', null) + } + + var dimension = this.dimension() + + this.$element + .removeClass('collapse') + .addClass('collapsing') + [dimension](0) + + this.transitioning = 1 + + var complete = function () { + this.$element + .removeClass('collapsing') + .addClass('in') + [dimension]('auto') + this.transitioning = 0 + this.$element.trigger('shown.bs.collapse') + } + + if (!$.support.transition) return complete.call(this) + + var scrollSize = $.camelCase(['scroll', dimension].join('-')) + + this.$element + .one($.support.transition.end, $.proxy(complete, this)) + .emulateTransitionEnd(350) + [dimension](this.$element[0][scrollSize]) + } + + Collapse.prototype.hide = function () { + if (this.transitioning || !this.$element.hasClass('in')) return + + var startEvent = $.Event('hide.bs.collapse') + this.$element.trigger(startEvent) + if (startEvent.isDefaultPrevented()) return + + var dimension = this.dimension() + + this.$element + [dimension](this.$element[dimension]()) + [0].offsetHeight + + this.$element + .addClass('collapsing') + .removeClass('collapse') + .removeClass('in') + + this.transitioning = 1 + + var complete = function () { + this.transitioning = 0 + this.$element + .trigger('hidden.bs.collapse') + .removeClass('collapsing') + .addClass('collapse') + } + + if (!$.support.transition) return complete.call(this) + + this.$element + [dimension](0) + .one($.support.transition.end, $.proxy(complete, this)) + .emulateTransitionEnd(350) + } + + Collapse.prototype.toggle = function () { + this[this.$element.hasClass('in') ? 'hide' : 'show']() + } + + + // COLLAPSE PLUGIN DEFINITION + // ========================== + + var old = $.fn.collapse + + $.fn.collapse = function (option) { + return this.each(function () { + var $this = $(this) + var data = $this.data('bs.collapse') + var options = $.extend({}, Collapse.DEFAULTS, $this.data(), typeof option == 'object' && option) + + if (!data) $this.data('bs.collapse', (data = new Collapse(this, options))) + if (typeof option == 'string') data[option]() + }) + } + + $.fn.collapse.Constructor = Collapse + + + // COLLAPSE NO CONFLICT + // ==================== + + $.fn.collapse.noConflict = function () { + $.fn.collapse = old + return this + } + + + // COLLAPSE DATA-API + // ================= + + $(document).on('click.bs.collapse.data-api', '[data-toggle=collapse]', function (e) { + var $this = $(this), href + var target = $this.attr('data-target') + || e.preventDefault() + || (href = $this.attr('href')) && href.replace(/.*(?=#[^\s]+$)/, '') //strip for ie7 + var $target = $(target) + var data = $target.data('bs.collapse') + var option = data ? 'toggle' : $this.data() + var parent = $this.attr('data-parent') + var $parent = parent && $(parent) + + if (!data || !data.transitioning) { + if ($parent) $parent.find('[data-toggle=collapse][data-parent="' + parent + '"]').not($this).addClass('collapsed') + $this[$target.hasClass('in') ? 'addClass' : 'removeClass']('collapsed') + } + + $target.collapse(option) + }) + +}(window.jQuery); + +/* ======================================================================== + * Bootstrap: dropdown.js v3.0.0 + * http://twbs.github.com/bootstrap/javascript.html#dropdowns + * ======================================================================== + * Copyright 2012 Twitter, Inc. + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * ======================================================================== */ + + ++function ($) { "use strict"; + + // DROPDOWN CLASS DEFINITION + // ========================= + + var backdrop = '.dropdown-backdrop' + var toggle = '[data-toggle=dropdown]' + var Dropdown = function (element) { + var $el = $(element).on('click.bs.dropdown', this.toggle) + } + + Dropdown.prototype.toggle = function (e) { + var $this = $(this) + + if ($this.is('.disabled, :disabled')) return + + var $parent = getParent($this) + var isActive = $parent.hasClass('open') + + clearMenus() + + if (!isActive) { + if ('ontouchstart' in document.documentElement && !$parent.closest('.navbar-nav').length) { + // if mobile we we use a backdrop because click events don't delegate + $('