TalkPHP

TalkPHP (http://www.talkphp.com/forums.php)
-   Absolute Beginners (http://www.talkphp.com/absolute-beginners/)
-   -   Why hello there (http://www.talkphp.com/absolute-beginners/10-why-hello-there.html)

Danny Needs Help 04-08-2005 01:25 AM

Why hello there
 
Well, I just started PHP, so bear with me :).

Here are my first questions:
  • What does '=>' mean?
  • How do you define/call classes?
  • How do you delete things stored in a MySQL table?
  • How do you edit things stored in a MySQL table?

Thanks :)

CreativeLogic 04-08-2005 01:42 AM

What does '=>' mean?
The => operator is used to define arrays. When you create an array, you will have both indexes and values. You then create the array with the following syntax seperated by commas, index => values.

How do you define/call classes?
This is a bit more complicated. Are you asking how to create and use the class? I'll write up a tutorial for you soon to show you how to do this.

How do you delete things stored in a MySQL table?
You will create a query using php's mysql_query function. Here is an example of how you would delete something:
PHP Code:

mysql_query("DELETE FROM table WHERE column = 'value'"

How do you edit things stored in a MySQL table?
You will first use the same function as above creating a new query. Follows is an example:
PHP Code:

mysql_query("UPDATE table SET column = 'newvalue' WHERE column = 'value'"

Note: You don't have to include WHERE or any of the following information in the above two examples.

Let me know if that helps any. If you don't understand it I'll do my best to change my words.

By the way, welcome to the forums and hope to see you around more! ;)

Danny Needs Help 04-08-2005 03:18 PM

Thanks for the help :). I still dont quite get Arrays, but I just got my SitePoint book "Build Your Own Database Driven Website Using PHP and MySQL", so I should learn a little faster.

Edit// By the way, if you ever run out of ideas on what to write tutorials about, I am full of things I need to learn ;).

CreativeLogic 04-08-2005 06:25 PM

Check out www.php.net/array - it's full of information. Read through it and it will help you a ton. If you don't understand still feel free to keep asking.

As for the tutorials, yes we could use some ideas from someone who would actually use the tutorials.

Danny Needs Help 04-08-2005 06:58 PM

Form Processing/Mailing would be a good first tutorial :).

CreativeLogic 04-09-2005 09:40 PM

Don't forget there are also multi-dementional arrays. You probably wouldn't need them for sometime until you fully understand single-dementional arrays.

William 04-10-2005 12:48 AM

Quote:

Originally Posted by Danny Needs Help
Form Processing/Mailing would be a good first tutorial :).

mailing is done. Form processing next.

William 04-10-2005 12:59 AM

Form Processing is done.

Danny Needs Help 04-10-2005 12:52 PM

Omghai2ujon!

So I geuss saying a URL means you go and register there now? But yes, thanks for the help.

I'll go check out those tutorials William :).

Danny Needs Help 04-10-2005 07:35 PM

I mean I mentioned this site, and you came, and registered. Oh well :).


All times are GMT. The time now is 08:44 PM.

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0