{"id":11306,"date":"2018-06-02T07:30:04","date_gmt":"2018-06-02T05:30:04","guid":{"rendered":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/"},"modified":"2018-06-02T07:30:04","modified_gmt":"2018-06-02T05:30:04","slug":"installing-mamp-to-play-with-php-mysql-and-openflights","status":"publish","type":"post","link":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/","title":{"rendered":"Installing MAMP to play with PHP, MySQL and OpenFlights"},"content":{"rendered":"<h2>By Franck Pachot<\/h2>\n<p>.<br \/>\nYou may wonder what I&#8217;m doing with those technologies that are completely different from what I usually do. I&#8217;ll detail in a future blog post but the idea is giving a short introduction to databases to students at <a href=\"https:\/\/powercoders.org\/\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/powercoders.org\/<\/a>, a coding academy for refugees in Switzerland. They install MAMP (My Apache &#8211; MySQL &#8211; PHP) during their curriculum for website development, and then I&#8217;ll use this environment to teach data modeling and SQL basics. Thus, I&#8217;ve to look at MAMP, PHP and MySQL for the first time&#8230; And I decided to load the <a href=\"https:\/\/openflights.org\/data.html\" target=\"_blank\" rel=\"noopener noreferrer\">OpenFlights<\/a> open data to play with.<br \/>\nThat explains the title.<br \/>\n<!--more--><br \/>\n<a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png\" alt=\"CaptureMAMP002\" width=\"300\" height=\"231\" class=\"alignright size-medium wp-image-24123\" \/><\/a><br \/>\nSo MAMP is like LAMP (Linux+Apache+PHP+MySQL) but with a M for MacOS, but also Windows (W being an upside-down M after all). Let&#8217;s install that on my laptop. I download it from <a href=\"https:\/\/www.mamp.info\/en\/downloads\/\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/www.mamp.info\/en\/downloads\/<\/a>, run the .exe, all is straightforward and the installer notifies me that the installation will be completed after a reboot.<\/p>\n<p>What? Reboot? Seriously, we are in 2018, that&#8217;s Windows 10, I refuse to reboot to install a simple Apache server!<\/p>\n<p>This bundle is very easy to use: a simple window to start and stop the servers (Apache and MySQL) . A setup menu to configure them, but I keep the default. And a link to the start page. All that is installed under C:\\MAMP (you can change it, I just kept the default settings). The first time you start the servers, the Windows Firewall configuration is raised and you have to accept it:<\/p>\n<p><a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP003.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP003.png\" alt=\"CaptureMAMP003\" width=\"1024\" height=\"291\" class=\"aligncenter size-large wp-image-24124\" \/><\/a><\/p>\n<p>With all defaults (Apache on port 80) my web server pages are on <a href=\"http:\/\/localhost\/MAMP\/index.php?page=phpmyadmin&amp;language=English\" target=\"_blank\" rel=\"noopener noreferrer\">http:\/\/localhost<\/a> (serving the files in C:\\MAMP\\htdocs) and administration page is at <a href=\"http:\/\/localhost\/MAMP\/\" target=\"_blank\" rel=\"noopener noreferrer\">http:\/\/localhost\/MAMP\/<\/a><br \/>\nThe MySQL administration page (phpMyAdmin) is at <a href=\"http:\/\/localhost\/MAMP\/index.php?page=phpmyadmin&amp;language=English\" target=\"_blank\" rel=\"noopener noreferrer\">http:\/\/localhost\/MAMP\/index.php?page=phpmyadmin<\/a>. It seems that, at least by default, I don&#8217;t need a password to go to the admin pages.<\/p>\n<h3>display_errors<\/h3>\n<p>I&#8217;ll write some PHP and because it&#8217;s the first time in my life, I will have some errors. With the default configuration, Apache just raises and Error 500 which does not help me a lot for debugging. This configuration is ok for production because displaying errors may give clues to hackers. But I&#8217;m there to play and I want to see the error messages and line numbers.<\/p>\n<p>I have to set display_errors=on for that. The current setting is displayed in <a href=\"http:\/\/localhost\/MAMP\/index.php?language=English&amp;page=phpinfo#module_core\" target=\"_blank\" rel=\"noopener noreferrer\">http:\/\/localhost\/MAMP\/index.php?language=English&amp;page=phpinfo#module_core<\/a> and I can change it in C:\\MAMP\\conf\\php7.2.1\\php.ini and after a restart of the Apache server I can see full error messages:<\/p>\n<pre><code>\nWarning: mysqli_real_connect(): (28000\/1045): Access denied for user 'root'@'localhost' (using password: YES) in C:\\MAMP\\htdocs\\index.php on line 123\n<\/code><\/pre>\n<h3>Little fix<\/h3>\n<p>But now that I display the errors, I get this annoying message each time I try to do something in phpMyAdmin (which runs as PHP in the same Apache server):<\/p>\n<pre><code>\nMAMP \"count(): Parameter must be an array or an object that implements Countable\"\n<\/code><\/pre>\n<p><a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP004.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP004.png\" alt=\"CaptureMAMP004\" width=\"1024\" height=\"469\" class=\"aligncenter size-large wp-image-24146\" \/><\/a><\/p>\n<p>So this product, which is free but has also a &#8216;PRO&#8217; version, probably running the same code, is delivered with bad code, raising errors that were ignored. Don&#8217;t tell me that it is just a warning. You will see that parentheses are missing, this is a syntax error and raising only a warning for that is quite bad.<br \/>\n<a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP006.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP006.png\" alt=\"CaptureMAMP006\" width=\"300\" height=\"218\" class=\"alignright size-medium wp-image-24149\" \/><\/a><br \/>\nMy common sense tells me that we should set display_errors=on and test a few screens before releasing a software. But that step has probably been skipped. Fortunately, the message is clear: line 615 of C:\\MAMP\\bin\\phpMyAdmin\\libraries\\sql.lib.php<\/p>\n<p>The message is about count() not having the correct parameter. The line 615 shows count($analyzed_sql_results[&#8216;select_expr&#8217;] == 1 ) which is probably not correct because it counts a boolean expression. I&#8217;ve changed it to (count($analyzed_sql_results[&#8216;select_expr&#8217;]) == 1 ) as I suppose they want to count and compare to one. <\/p>\n<p>Well, I&#8217;ve never written one line of PHP and I already hate it for its error handling weakness.<\/p>\n<h3>Load some data<\/h3>\n<p>I want to initialize the database with some data and I&#8217;ll use the <a href=\"https:\/\/openflights.org\/data.html\" target=\"_blank\" rel=\"noopener noreferrer\">OpenFlights<\/a> database. I&#8217;ve downloaded and unzipped <a href=\"https:\/\/github.com\/jpatokal\/openflights\/blob\/master\/sql\/master.zip\" target=\"_blank\" rel=\"noopener noreferrer\">https:\/\/github.com\/jpatokal\/openflights\/blob\/master\/sql\/master.zip<\/a><br \/>\nI go to the unzipped directory and run MySQL:<\/p>\n<pre><code>\ncd \/d D:\\Downloads\\openflights-master\n<\/code><\/pre>\n<p>Another little thing to fix here: the sql\\create.sql and sql\\load-data.sql files contain some lines starting with &#8220;\\! echo&#8221; but this \\! command (to run a system command) exists on Linux but not on the Windows port of MySQL. We have to remove them before running the SQL scripts. I&#8217;m used to Oracle where I can port my code and scripts from one platform to the other, and was a but surprised by this.<\/p>\n<p>Ready to connect:<\/p>\n<pre><code>\nC:\\MAMP\\bin\\mysql\\bin\\mysql test --port=3306 --host=localhost --user root --password\nEnter password:\n<\/code><\/pre>\n<p>The MySQL connection parameters are displayed on <a href=\"http:\/\/localhost\/MAMP\/\" target=\"_blank\" rel=\"noopener noreferrer\">http:\/\/localhost\/MAMP\/<\/a> including the password (root)<\/p>\n<pre><code>\nsource sql\\create.sql\n&nbsp;\nmysql&gt; source sql\\create.sql\nQuery OK, 0 rows affected (0.00 sec)\n&nbsp;\nConnection id:    314\nCurrent database: flightdb2\n&nbsp;\nQuery OK, 0 rows affected (0.02 sec)\n&nbsp;\nQuery OK, 0 rows affected (0.02 sec)\n&nbsp;\nQuery OK, 0 rows affected (0.01 sec)\n&nbsp;\nQuery OK, 0 rows affected (0.01 sec)\n&nbsp;\nQuery OK, 0 rows affected (0.02 sec)\nRecords: 0  Duplicates: 0  Warnings: 0\n&nbsp;\nQuery OK, 0 rows affected (0.02 sec)\nRecords: 0  Duplicates: 0  Warnings: 0\n&nbsp;\nQuery OK, 0 rows affected (0.00 sec)\n...\n<\/code><\/pre>\n<p>This has created the flightdb2 database, with openflights user, and 15 tables.<\/p>\n<p>Now, if you are still in the unzipped directory, you can load data with the source sql\\load-data.sql script which loads from the data\\*.dat files<\/p>\n<pre><code>\nmysql&gt; source sql\\load-data.sql\nQuery OK, 6162 rows affected, 4 warnings (0.04 sec)\nRecords: 6162  Deleted: 0  Skipped: 0  Warnings: 4\n&nbsp;\nQuery OK, 7184 rows affected, 7184 warnings (0.12 sec)\nRecords: 7184  Deleted: 0  Skipped: 0  Warnings: 7184\n&nbsp;\nQuery OK, 67663 rows affected (0.53 sec)\nRecords: 67663  Deleted: 0  Skipped: 0  Warnings: 0\n&nbsp;\nQuery OK, 260 rows affected (0.01 sec)\nRecords: 260  Deleted: 0  Skipped: 0  Warnings: 0\n&nbsp;\nQuery OK, 12 rows affected (0.01 sec)\nRecords: 12  Deleted: 0  Skipped: 0  Warnings: 0\n<\/code><\/pre>\n<h3>Query from PHP<\/h3>\n<p>So, for my first lines of PHP I&#8217;ve added the following to C:\\MAMP\\htdocs\\index.php:<\/p>\n<pre><code>\n&lt;?php\n$user = 'openflights'; $password = '';\n$db   = 'flightdb2';   $host = 'localhost'; $port = 3306;\n&nbsp;\n$conn = mysqli_init();\nif (!$conn) { \n\tdie(\"mysqli_init failed\"); \n}\nif (!$success = mysqli_real_connect( $conn, $host, $user, $password, $db, $port)) { \n\tdie(\"&#128544; Connection Error: \" . mysqli_connect_error());\n}\necho \"&#128526; Connected to database &lt;b&gt;$db&lt;\/b&gt; as user &lt;b&gt;$user&lt;\/b&gt;.\";\n?&gt;\n&nbsp;\n&lt;p&gt;\nHere are the Airports:\n &lt;table border=1&gt;\n &lt;tr&gt;&lt;th&gt;IATA&lt;\/th&gt;&lt;th&gt;Name&lt;\/th&gt;&lt;\/tr&gt;\n&nbsp;\n&lt;?php\n$result = $conn-&gt;query(\"select iata,name from airports where country='Greenland' order by 2\");\nif ($result-&gt;num_rows &gt; 0) {\n    while($row = $result-&gt;fetch_assoc()) {\n        echo \"&lt;tr&gt;&lt;td&gt;\" . $row[\"iata\"]. \"&lt;\/td&gt;&lt;td&gt; \" . $row[\"name\"]. \"&lt;\/tr&gt;\";\n    }\n} else {\n    echo \"0 results\";\n}\nmysqli_close($conn);\n?&gt;\n &lt;\/table&gt;\n<\/code><\/pre>\n<p><a href=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP008.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP008.png\" alt=\"CaptureMAMP008\" width=\"221\" height=\"300\" class=\"alignright size-medium wp-image-24157\" \/><\/a><\/p>\n<p>Here, I call mysqli_init(), set the credentials and call mysqli_real_connect() to get the connection handle. Then I run my query and display the result as an HTML table. Nothing difficult here. The main challenge is probably to keep the code maintainable.<\/p>\n<p>In my opinion, and despite the small issues encountered, MAMP is a simple way to setup a development environment on Windows. All is there to introduce SQL and Database for developers, and show how to call it from a programming language.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>By Franck Pachot . You may wonder what I&#8217;m doing with those technologies that are completely different from what I usually do. I&#8217;ll detail in a future blog post but the idea is giving a short introduction to databases to students at https:\/\/powercoders.org\/, a coding academy for refugees in Switzerland. They install MAMP (My Apache [&hellip;]<\/p>\n","protected":false},"author":27,"featured_media":11307,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[229,59],"tags":[1367,144,1368],"type_dbi":[],"class_list":["post-11306","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-database-administration-monitoring","category-oracle","tag-mamp","tag-mysql","tag-php"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.2 (Yoast SEO v27.2) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Installing MAMP to play with PHP, MySQL and OpenFlights - dbi Blog<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Installing MAMP to play with PHP, MySQL and OpenFlights\" \/>\n<meta property=\"og:description\" content=\"By Franck Pachot . You may wonder what I&#8217;m doing with those technologies that are completely different from what I usually do. I&#8217;ll detail in a future blog post but the idea is giving a short introduction to databases to students at https:\/\/powercoders.org\/, a coding academy for refugees in Switzerland. They install MAMP (My Apache [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/\" \/>\n<meta property=\"og:site_name\" content=\"dbi Blog\" \/>\n<meta property=\"article:published_time\" content=\"2018-06-02T05:30:04+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png\" \/>\n\t<meta property=\"og:image:width\" content=\"514\" \/>\n\t<meta property=\"og:image:height\" content=\"395\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Oracle Team\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Oracle Team\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/\"},\"author\":{\"name\":\"Oracle Team\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/66ab87129f2d357f09971bc7936a77ee\"},\"headline\":\"Installing MAMP to play with PHP, MySQL and OpenFlights\",\"datePublished\":\"2018-06-02T05:30:04+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/\"},\"wordCount\":946,\"commentCount\":0,\"image\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png\",\"keywords\":[\"MAMP\",\"MySQL\",\"PHP\"],\"articleSection\":[\"Database Administration &amp; Monitoring\",\"Oracle\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/\",\"name\":\"Installing MAMP to play with PHP, MySQL and OpenFlights - dbi Blog\",\"isPartOf\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png\",\"datePublished\":\"2018-06-02T05:30:04+00:00\",\"author\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/66ab87129f2d357f09971bc7936a77ee\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#primaryimage\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png\",\"contentUrl\":\"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png\",\"width\":514,\"height\":395},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Accueil\",\"item\":\"https:\/\/www.dbi-services.com\/blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Installing MAMP to play with PHP, MySQL and OpenFlights\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#website\",\"url\":\"https:\/\/www.dbi-services.com\/blog\/\",\"name\":\"dbi Blog\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.dbi-services.com\/blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/66ab87129f2d357f09971bc7936a77ee\",\"name\":\"Oracle Team\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/secure.gravatar.com\/avatar\/f711f7cd2c9b09bf2627133755b569fb5be0694810cfd33033bdd095fedba86d?s=96&d=mm&r=g\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/f711f7cd2c9b09bf2627133755b569fb5be0694810cfd33033bdd095fedba86d?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/f711f7cd2c9b09bf2627133755b569fb5be0694810cfd33033bdd095fedba86d?s=96&d=mm&r=g\",\"caption\":\"Oracle Team\"},\"url\":\"https:\/\/www.dbi-services.com\/blog\/author\/oracle-team\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Installing MAMP to play with PHP, MySQL and OpenFlights - dbi Blog","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/","og_locale":"en_US","og_type":"article","og_title":"Installing MAMP to play with PHP, MySQL and OpenFlights","og_description":"By Franck Pachot . You may wonder what I&#8217;m doing with those technologies that are completely different from what I usually do. I&#8217;ll detail in a future blog post but the idea is giving a short introduction to databases to students at https:\/\/powercoders.org\/, a coding academy for refugees in Switzerland. They install MAMP (My Apache [&hellip;]","og_url":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/","og_site_name":"dbi Blog","article_published_time":"2018-06-02T05:30:04+00:00","og_image":[{"width":514,"height":395,"url":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png","type":"image\/png"}],"author":"Oracle Team","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Oracle Team","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#article","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/"},"author":{"name":"Oracle Team","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/66ab87129f2d357f09971bc7936a77ee"},"headline":"Installing MAMP to play with PHP, MySQL and OpenFlights","datePublished":"2018-06-02T05:30:04+00:00","mainEntityOfPage":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/"},"wordCount":946,"commentCount":0,"image":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png","keywords":["MAMP","MySQL","PHP"],"articleSection":["Database Administration &amp; Monitoring","Oracle"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/","url":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/","name":"Installing MAMP to play with PHP, MySQL and OpenFlights - dbi Blog","isPartOf":{"@id":"https:\/\/www.dbi-services.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#primaryimage"},"image":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#primaryimage"},"thumbnailUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png","datePublished":"2018-06-02T05:30:04+00:00","author":{"@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/66ab87129f2d357f09971bc7936a77ee"},"breadcrumb":{"@id":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#primaryimage","url":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png","contentUrl":"https:\/\/www.dbi-services.com\/blog\/wp-content\/uploads\/sites\/2\/2022\/04\/CaptureMAMP002.png","width":514,"height":395},{"@type":"BreadcrumbList","@id":"https:\/\/www.dbi-services.com\/blog\/installing-mamp-to-play-with-php-mysql-and-openflights\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Accueil","item":"https:\/\/www.dbi-services.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Installing MAMP to play with PHP, MySQL and OpenFlights"}]},{"@type":"WebSite","@id":"https:\/\/www.dbi-services.com\/blog\/#website","url":"https:\/\/www.dbi-services.com\/blog\/","name":"dbi Blog","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.dbi-services.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.dbi-services.com\/blog\/#\/schema\/person\/66ab87129f2d357f09971bc7936a77ee","name":"Oracle Team","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/f711f7cd2c9b09bf2627133755b569fb5be0694810cfd33033bdd095fedba86d?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/f711f7cd2c9b09bf2627133755b569fb5be0694810cfd33033bdd095fedba86d?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/f711f7cd2c9b09bf2627133755b569fb5be0694810cfd33033bdd095fedba86d?s=96&d=mm&r=g","caption":"Oracle Team"},"url":"https:\/\/www.dbi-services.com\/blog\/author\/oracle-team\/"}]}},"_links":{"self":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/11306","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/users\/27"}],"replies":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/comments?post=11306"}],"version-history":[{"count":0,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/posts\/11306\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/media\/11307"}],"wp:attachment":[{"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/media?parent=11306"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/categories?post=11306"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/tags?post=11306"},{"taxonomy":"type","embeddable":true,"href":"https:\/\/www.dbi-services.com\/blog\/wp-json\/wp\/v2\/type_dbi?post=11306"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}