-
Posts
2,134 -
Joined
-
Last visited
-
Days Won
42
Posts posted by benanamen
-
-
Here is your guidance, go to http://www.w3schools.com/ and study the tutorials. If you get stuck on something we will be happy to help when we see what you have attempted. Your not quite ready for us.
-
You are not able to get private messages on this site yet. If you want help, all you have to do is provide what was asked for. Your code and your form and preferably an SQL dump of your database.
-
The reason why is you NEVER store more than one value in a column. It is beyond a recommendation or an opinion, it is the way it needs to be done. PERIOD.
Kinda like you drive cars from the front seat, not the back seat. Its just the way its done.
Also, study up on database normalization.
-
While you are still working with those silly double-delimited strings of yours, forget about using SQL.
Break you string into separate records (Prt_id, Oth_id) and store in a separate db table. Then you can do your deletions by matching the tables.
This is the "real" answer.
-
Since you are not providing what I asked for, you are now on your own as far as I go. You come here asking for FREE help and wont provide what is asked of you.
-
Is it not http://www.padihamca...splay.php/image
?? I need it in the above format, to use inside the Android app..
No. Attach a zip of ALL your files and an sql dump of your DB so we can handle this once and for all. It doesnt matter about Android.
AND STOP MAKING NEW THREADS
-
@mac_gyver, to the second part, the query he now has already gives him the the highest single id. He just needs to output the result.
SELECT image FROM test_image ORDER BY id DESC LIMIT 1
-
echo "<img src=\"<?= {$row['image']} ?>\">"; -
I think your missing the most basic of basic coding.
mysqli_fetch_all() Fetches all result rows as an associative array, a numeric array, or both
mysqli_fetch_array() Fetches a result row as an associative, a numeric array, or both
mysqli_fetch_assoc() Fetches a result row as an associative array
Your still better off using PDO.
-
The coding you have is obsolete and will not work at all in the latest version of Php. You need to us PDO or Mysqli.
Besides that, your flow is a mess. Why are you checking the login info twice?
-
If you want the best answer for your situation, post your code and form.
-
The problem is your missing value=" " (I think that's what @Barand was pointing out.)
You can also clean up your php by letting Mysql do the uppercase
SELECT id,UPPER(name) FROM stud ORDER BY studName
and by using parenthesis instead of escaping your variables.
echo "<option value=\"{$row['id']}\" id=\"dropdown\" >{$row['name']}</option>";
-
After reading your response 10 times I think I understand your response. If I understand correctly, you are using the exact single DB connect file for multiple apps, not duplicates of that file for every app. If that is the case, you will run into problems when you have different groups of Mysql DB users having different logins (Not app users). Really, each app should be self contained and have its own copy of a DB config file. While it is fine for your own personal use to do it that way, it really shouldn't be used as an example to beginners. To be honest, it's a bit lazy.
-
Dude, why did you start a whole new thread on the same thing?
-
You're still using PHP to format your date. Let my SQL do the work.
-
Actually it doesn't. If the db connection file is included in all your scripts then so will the connection without having to call a function, let alone pass a database name. You set the database name in the connection string for that particular app one time and never touch it again for the rest of your life. The only thing you might ever have to change is the database username and password if you move it somewhere else.
-
Dude, why are you starting a whole new thread on the same exact thing? You're totally trying to do this wrong and if you provided what I asked for I would show you how to do it. I give up.
Attention moderator, this is a duplicate post.
-
Speechless.
-
Post your form and your current code. You are definitely going about this all wrong.
-
As @Barand said, you need to get those dates updated properly before you do anything else as well as update the code that is putting it into the database.
-
You obviously do not have $row2['Completion Date'] stored in your db as y-m-d
What is the format and what type of column do you have it in. Best thing to do is let mysql format it in your query.
-
If there is any personal information in the document you should secure it. If you leave it in a public directory, at least put an index file in there to stop directory browsing if you have it enabled.
-
I assumed you wanted the entire row based on a particular date. Exactly what "columns" of the data do you want?
-
I will leave it up to you to handle the dates
<?php $url = "http://ichart.finance.yahoo.com/table.csv?s=f"; $file = file($url); foreach ($file as $value) { if (stristr($value, '2015-09-10')) { echo $value; } } ?>
can PHP count white and black cats?
in PHP Coding Help
Posted
Ok, heres the real deal that I got from another forum site. She is using a handheld scanner to scan barcodes on books and putting all the scan data into one text box. No details on the scanner. Pretty sure their is a better option for the scanner output then dumping it all to one textarea.