A few days ago I had a thread called "How to search several PHP files for certain values??" Several people suggested that a database would be better for my purposes than php, which could do my tasks but wasn't really the most efficient way. So for the past few days I've been trying to set up my table with phpMyAdmin on my cpanel and it just doesn't seem to be working. For some weird reason I have found it very difficult to find any information online geared toward a newbie using phpMyAdmin. I can't find clear explanations of data types. I can't find explanations for words like null and UNIQUE. I can't find clear explanations about auto-increment possibilities. The info I have found is scattershot and dense. The official documentation has been worthless to me; I'm getting by on random blogs and other dubious sources. Most frustrating, I CAN'T FIND OUT if I can do arrays or not!!! I know php can do them, and several times I've felt that php would be much easier. I want to have several (for example) book reviews. For each book, I will have an entry in my SQL database for title, author, publish date, chapter titles, the review text, etc. The part I'm having problems with now is the chapter titles. I want to read each chapter into my html/php document, and apply <li> formatting to it and stuff. It was simple with php only, but nobody wants to tell me if I can do this with a field. I did a title search in DP's Database forum for "array" and got no results! WTF?? Do I need multiple fields, one for each chapter? That seems ridiculous. Anyway, if I'm missing some obvious resource, please let me know. I've found some good stuff, and I indeed am able to retrieve and echo things from my table, but it's like all the simple newbie SQL information is behind a dam somewhere. php was easy to learn! phpmyadmin, ehh not so much. Bizarre. Thanks, you guys are very helpful. I'm just way more frustrated with databases than I ever got with php
Dear Friend, You don't need to know PHPmyadmin or study it . It is a Web interface to administrate the Mysql Databases and Mysql server. You have to study PHP Mysql Connectivity first. How to do that. As well as you have to know some SQL . That is must. In PHP you need to study some basic PHP Mysql Functions. Like http://php.net/mysql_connect http://php.net/mysql_select_db http://php.net/mysql_query http://php.net/mysql_fetch_row http://php.net/mysql_fetch_array http://php.net/mysql_num_rows http://php.net/mysql_free_result These functions are needed to use Mysql from PHP. Study them first. Then i wish PhpMyadmin will become easier for you to understand. Thanks. Coolsaint
If your hosting allows forking you should look into. GREP Follow the tutorial here: www.sitepoint.com/article/php-command-line-2
A database is an array. Sort of. What PHP does when it opens a database and retrieves its contents is putting them in an array that you can then manipulate as usual. It would be better to create one table to hold information on books and another for information on chapters. The good news is that you know PHP already, so it will be easy to make the transition to PHP + MySQL. As always, I can't recommend w3schools enough. Check www .w3schools .com/ php/php_mysql_intro.asp (when can one use live links?) and also www .w3schools .com/ sql/default.asp
Actually, I discovered the php explode command, so I load all the chapter titles into one field separated by dummy characters. Works great! I've been there, it is good. And http://php.net as always helps me through most things. I've gotten over my initial frustrations and now that I understand the basic concepts things are starting to work out. Thanks everyone