<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="FeedCreator 1.8" -->
<?xml-stylesheet href="https://neil.mckillop.org/lib/exe/css.php?s=feed" type="text/css"?>
<rdf:RDF
    xmlns="http://purl.org/rss/1.0/"
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
    xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
    xmlns:dc="http://purl.org/dc/elements/1.1/">
    <channel rdf:about="https://neil.mckillop.org/feed.php">
        <title>neil.mckillop.org teaching:php</title>
        <description></description>
        <link>https://neil.mckillop.org/</link>
        <image rdf:resource="https://neil.mckillop.org/lib/tpl/dokuwiki/images/favicon.ico" />
       <dc:date>2026-05-21T04:21:20+0100</dc:date>
        <items>
            <rdf:Seq>
                <rdf:li rdf:resource="https://neil.mckillop.org/teaching/php/database?rev=1587330128&amp;do=diff"/>
            </rdf:Seq>
        </items>
    </channel>
    <image rdf:about="https://neil.mckillop.org/lib/tpl/dokuwiki/images/favicon.ico">
        <title>neil.mckillop.org</title>
        <link>https://neil.mckillop.org/</link>
        <url>https://neil.mckillop.org/lib/tpl/dokuwiki/images/favicon.ico</url>
    </image>
    <item rdf:about="https://neil.mckillop.org/teaching/php/database?rev=1587330128&amp;do=diff">
        <dc:format>text/html</dc:format>
        <dc:date>2020-04-19T22:02:08+0100</dc:date>
        <dc:creator>Anonymous (anonymous@undisclosed.example.com)</dc:creator>
        <title>teaching:php:database</title>
        <link>https://neil.mckillop.org/teaching/php/database?rev=1587330128&amp;do=diff</link>
        <description>Teaching PHP

Making a MySQL database connection


$host = &quot;localhost&quot;;
$dbname = &quot;database_name&quot;;
$username = &quot;username&quot;;
$password = &quot;password&quot;;
$port = 3306;
$charset = &quot;utf8mb4&quot;;

$connection_string = &quot;mysql:host=$host;dbname=$dbname;port=$port;charset=$charset&quot;;
$db_settings = array(PDO::ATTR_ERRMODE =&gt; PDO::ERRMODE_WARNING,
                     PDO::ATTR_PERSISTENT =&gt; true);

$db = new PDO($connection_string, $username, $password, $db_settings);</description>
    </item>
</rdf:RDF>
