I would like to display my boolean output on the webpage as "Yes" or "No instead of "1" or "0". Can I get a simple example on how/where that should go?
My current code
<?php
while($row = mysql_fetch_array($result))
{
?>
<tr>
<td><?php echo $row['aa']?></td>...
Thanks for the reply!
The delete query deletes all records in the table and works fine when I run it by itself. I have no code as the jpg I attached above shows:
SetWarning
Warning On No
Open Query
Query Name qryErollmentForm Delete
View Design
Data Mode Edit
Open Query...
In a legacy database originally built in Access 95 and now in Access 2013 I have form that runs a simple macro. Originally it opened a table - used sendkey to select all records and delete them, then closed the table. Then it ran an append query to add new records to the table. The append still...
Thanks Skip, but at this point I'm not coding anything. Please see the attached screen print. I may have to go to VBA Code, but if I can avoid it I will.
Thanks again.http://files.engineering.com/getfile.aspx?folder=d19d50fd-bd33-4a94-a764-85c2bc406853&file=macro.jpg
I have a legacy database in Access that we upgraded in the new Office 2013. In there is a form that runs a macro to open a specific table, select all records, delete them and close the table. Then it runs an append query to add in new records. It uses sendkey to select all records and delete...
Apparently I haven't gotten enough sleep. It does work with your code. I was testing with an admin login, but instead of using the actual password, I was using the hashed code. It let's me in, but throws those errors. If I use a correct login and password it works fine now. If I use a non-member...
The sql looks good. I checked it before and triple checked it now. Unless I my host server doesn't allow me to use database.table in a querry. I'll check that. Thanks!
The function is part of the access_user_class.php page. Logging into the site this function and returns the errors on the first page inside the site. The login is working.
These lines:
$this->id = mysql_result($res_info, 0, "id");
$this->user_full_name = mysql_result($res_info, 0...
I need to convert this function that is currently not returning data to mysqli
function get_user_info() {
$sql_info = sprintf("SELECT real_name, extra_info, email, id FROM %s WHERE login = '%s' AND pw = '%s'", $this->table_name, $this->user, md5($this->user_pw));
$res_info =...
Thanks! Say do I have to close the db connection after returning data? Since I removed the pages' connection string $con= I get the error in the close statement. Once place said it isn't necessary to have one.
Thanks again.
I got this to work:
$result = $mysqli->query("SELECT * FROM donors WHERE lastname LIKE '$letter%' ORDER BY lastname, firstname");
Now I have to change this code
<?php
while($row = mysql_fetch_array($result))
{
?>
Hi Vacunita,
So you are saying that I should just have the mySQLi querry and results? That's the confusing part. I don't know the proper syntax for the query and the result. The examples I've found online are all different and I've gotten none of them to work yet. I'll keep working at it...
Hi Chris,
Yes, though I don't understand why. I don't know if it has to do with the inclucde_once statement where that info is located or the $con=mysql_connect() line. The include_once is working for the login.php page to get to this donorList.php page.
Thanks.
I have a PHP connection to a database working:
$username="me";
$host="myHost";
$password="password";
$database="myDatabase";
$con = mysql_connect($HOST,$USER,$PASSWORD,$DATABASE);
if(!$con)
{
die("Unable to select database");
}
mysql_select_db($database,$con);
$sql =...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.