BetaONE will rise again!

BetaONE will rise again! (http:\\b1.hcanet.com\forum/index.php)
-   Web Development (http:\\b1.hcanet.com\forum/forumdisplay.php?f=50)
-   -   A Php Script To Insert Values Into Mysql? (http:\\b1.hcanet.com\forum/showthread.php?t=9405)

robinwilson16 7th Aug 03 07:13 PM

I really need help with a script I want to create which will add values in a textarea into tables into the database as records

It needs to have

Quote:


Name:

Quote:


Address:

Quote:


Tel:

So that all those values are submitted as a record into mysql

I have the basic database connect routine set up and already have a page that can show the results

I would also maybe like a page that allows you to delete/edit records but this is probably too hard

I'm not very experienced with mysql :(
Thanks a lot :D

E3 8th Aug 03 01:19 AM

Hi robinwilson16,

I'm sure you could find what you're looking for pretty easily at www.mysql.com. Alternatively there's a pretty good book available from Team LiB called 'Mastering Dreamweaver MX Databases'. It not only teaches you, but it helps you tie everything together in a 'real world' kind of way.

I've attached an example below that I think will give you what you need too.

All the best,
E3 :)

robinwilson16 8th Aug 03 10:39 AM

Thanks a lot

I could never have written anything like that

You are very helpful :D :thumbup1:

robinwilson16 8th Aug 03 11:27 AM

Sorry but I need help creating the mysql tables

I created all the ones I thought I needed but when I try to add an entry I get:

Quote:


Column count doesn't match value count at row 1

The tables I have are:

Quote:


master_name
-f_name
-l_name

Quote:


address
-address
-city
-state
-zipcode
-add_type

Quote:


telephone
-tel_number
-tel_type

Quote:


fax
-fax_number
-fax_type

Quote:


email
-email
-email_type

Quote:


note
-note

I also tried adding master_id as a primary table on each one but I still get the same error

Thanks for helping, I'm a n00b when it comes to this sort of thing ;)

E3 10th Aug 03 11:41 PM

Hi robinwilson16,

Check your PM's :).

All the best,
E3

robinwilson16 15th Aug 03 09:14 PM

Thanks a lot, that was really useful :D

Script is working just how I wanted :thumbup1:


All times are GMT +1. The time now is 06:18 PM.

Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.