Search found 9 matches

by nickphp
Wed Sep 13, 2017 1:37 am
Forum: mySQL & php coding
Topic: Getting a simple php script to display results
Replies: 14
Views: 465

Re: Getting a simple php script to display results

It is displaying data from a table:- <?php $servername = "localhost"; $username = "abilityi_test1"; $password = "~ws4K+4=kc]V"; $database ="abilityi_myDB"; /* Turn on error reporting */ ini_set('display_errors', 1); ini_set('display_startup_errors', 1); // Create connection $conn = new mysqli($serve...
by nickphp
Tue Sep 12, 2017 1:18 am
Forum: mySQL & php coding
Topic: Getting a simple php script to display results
Replies: 14
Views: 465

Re: Getting a simple php script to display results

I have added the error reporting code back in now, the code is now this:- <?php $servername = "localhost"; $username = "abilityi_test1"; $password = "~ws4K+4=kc]V"; $database ="ability_test"; /* Turn on error reporting */ ini_set('display_errors', 1); ini_set('display_startup_errors', 1); // Create ...
by nickphp
Mon Sep 11, 2017 11:42 pm
Forum: mySQL & php coding
Topic: Getting a simple php script to display results
Replies: 14
Views: 465

Re: Getting a simple php script to display results

Sorry for being a bit dim, what do you mean by:-

Why can't you use the </> code button for code?
by nickphp
Mon Sep 11, 2017 11:41 pm
Forum: mySQL & php coding
Topic: Getting a simple php script to display results
Replies: 14
Views: 465

Re: Getting a simple php script to display results

Sorry i did not put it back in started the code from scratch pretty much will drop it back in
by nickphp
Mon Sep 11, 2017 7:27 am
Forum: mySQL & php coding
Topic: Getting a simple php script to display results
Replies: 14
Views: 465

Re: Getting a simple php script to display results

I have created a new script all using mysqli <?php $servername = "localhost"; $username = "abilityi_test1"; $password = "~ws4K+4=kc]V"; $database ="ability_test"; // Create connection $conn = new mysqli($servername, $username, $password); //check connection if (!conn) { echo "Unable to connect to da...
by nickphp
Mon Sep 11, 2017 4:27 am
Forum: mySQL & php coding
Topic: Getting a simple php script to display results
Replies: 14
Views: 465

Re: Getting a simple php script to display results

mysqli

As far as I understand mysqli

Stands for mysqli improved

So it is best to use mysli

Am i correct?
by nickphp
Fri Sep 08, 2017 7:47 am
Forum: mySQL & php coding
Topic: Getting a simple php script to display results
Replies: 14
Views: 465

Re: Getting a simple php script to display results

I have pasted some of your code this bit:- /* Turn on error reporting */ ini_set('display_errors', 1); ini_set('display_startup_errors', 1); The code now looks like this:- /* Turn on error reporting */ ini_set('display_errors', 1); ini_set('display_startup_errors', 1); // Create connection $conn = n...
by nickphp
Fri Sep 08, 2017 5:07 am
Forum: mySQL & php coding
Topic: Getting a simple php script to display results
Replies: 14
Views: 465

Re: Getting a simple php script to display results

Thank you for getting back to me, i will copy and paste the error reporting section of your code
in to mine and see what happens
by nickphp
Wed Sep 06, 2017 8:46 am
Forum: mySQL & php coding
Topic: Getting a simple php script to display results
Replies: 14
Views: 465

Getting a simple php script to display results

<?php $servername = "localhost"; $username = ""; $password = ""; $dbname = ""; // Create connection $conn = new mysqli($servername, $username, $password, $dname); // Check connection if ($conn->connect_error) { die("Connection failed: " . $conn->connect_error); } echo "Connected successfully"; $sql ...