Forum Moderators: mack

Message Too Old, No Replies

Creating a Web Server for testing

I'm trying to create a form to connect to a Database, It never works.

         

Admin55

9:35 pm on Dec 6, 2007 (gmt 0)



I don't know if i have to use a Webserver to CONNECT to a database. I try Ms Access on Window Server 2003, but i would love to use SQL.

Oh, yeah... it's my first time on this site.

And whosoever answers thanx in advance.

LifeinAsia

9:52 pm on Dec 6, 2007 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Welcome to WW!

It would help immensely if you added some details. For example, what have you tried so far, what error messages are you getting. What language are you using for your pages (ASP, PHP, .NET, etc.)? Perhaps even the specific code that is causing the problem.

jtara

2:10 am on Dec 7, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Not quite sure what you are asking, but I'll try to take a stab.

Do you mean you would like to use SQL - the language - or MySQL, the database server?

SQL is a computer language for database queries that is used (with variations) by many different database servers - including MySQL, PostGreSQL, Oracle, Microsfot SQL Server, etc.

Microsoft is a GUI program for accessing and manipulating databases, which has a built-in non-server database engine call Jet, but can also access a number of external database servers.

Yes, you can use Microsoft Access to work with a MySQL database server. You will need to install the MyODBC ODBC driver. There are other drivers that can be used to access many of the other common database servers as well.

You can access most database servers in a variety of ways. In the case of MySQL, the most fundamental would be with the "mysql" command-line program, or the MySQL Query Browser GUI browser. There are literally hundreds of different "clients" that can be used to connect to MySQL (or other) database servers. So, no, you don't have to use a web server (with a scripting language containing database access support). That's but one of many ways to access the data stored on a database server.

Hope that helps!

Admin55

2:16 pm on Dec 7, 2007 (gmt 0)



This is nice, really nice.
I never thought people would join in. Saying thanx alot to jtara and LifeinAsia.

I agree. I never present what i was asking well. Let me try again.

Ok. I want to create a Webpage Form that collect information and sends it to a database.

The tools i have is Windows Server 2003, Dreamweaver, FronPage, Microsoft SQL Express Server, Microsoft Access 2003.

Now tell me, how can i use these tool to connect to a database, weither it be Sql or Ms Access.

Further more, I know SQL codes (i practise in Ms Access)but in Microsoft SQL Express Server i don't see where i can create tables.

I hope its more clear. Thanx for answering.

jtara

4:17 pm on Dec 7, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Well, for the webpage, you will need to install a web server - you could use Microsoft IIS or Apache.

You will need to use a scripting language that can connect to a database. ASP, .net, PHP, etc.

In SQL Express Server, you can create a database the same way you would in any SQL database - using the CREATE DATABASE statement. Then you would use CREATE TABLE to create tables and columns.

Or, you can just use Microsoft Access to create the tables in the GUI rather than using SQL statements. As I said in my previous post, you can use Access as a front-end to connect to SQL Express Server.

Another alternative is to use the Microsoft SQL Server Management Studio Express. I'm not familiar with this, but I would presume it gives you the ability to create and drop tables and columns.

Admin55

5:27 pm on Dec 7, 2007 (gmt 0)



Ok, I'm going to install IIS
but i know nothing about script language.

So can you give me step by step to connect to MS Access?

Say i want users email address, Name, and Comment.
I understand my database would have all of these tables, but teach me how do i connect?

Alternative....
If you want i can send you my email address so you can send me an attachment of an example.

LifeinAsia

5:45 pm on Dec 7, 2007 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



You're not going to be be able to conenct to the database with static HTML pages- you MUST use some sort of language, whether PHP, ASP, .NET, etc.

So first, pick a language and start learning it. Pick up a good book for learning (or most will have some sites devoted to it), which will give instructions for how to setup a datasource to connect to the database server and some sample code for testing.

jtara

5:47 pm on Dec 7, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I would suggest you start with with Wikipedia articles on ASP, .net, and PHP. Decide which one you like better. Perhaps explore some other alternatives.

There are excellent books and websites on all of these, and, again, Wikipedia is a good starting point - it will have links to some of the top sites on the subjects.

It's way too big a subject to address here or in an email!

Since you are in a Microsoft environment, perhaps ASP is the way to go.

I don't know your specific reasons for going with Windows Server and SQL Server. You may have no choice - it's usually something imposed on one by your company. I don't think many choose this on their own. ;)

On the other hand, it will probably be easier to get help and learn if you use WAMP, a variation on LAMP.

LAMP = Linux + Apache + MySQL + PHP
WAMP = Windows + Apache + MySQL + PHP

Unless you have specific reasons why you have to do otherwise, I think you will be better-served with this combination. It is the most commonly used set of software for creating interactive websites, and so you will be able to more easily get the greatest amount of help and information.

Myself - I am a Ruby on Rails fan lately. A simple database with a form is literally a 5-minute project. The ROR "bible", Agile Web Development With Rails will take you through a simple hypothetical project that creates a store, shopping cart, and checkout in a day. So, you might want to look at this option as well. There's a great, enthusiastic ROR community that can help you, but certainly not the overwhelming usage and information associated with LAMP/WAMP.

You might want to back-up a bit and tell us a little about why you are using these specific tools. It's just what you had? It's a project for your company, and this is what they have chosen for you? It's a school project? You want to learn? You are creating a website for yourself? A bit of detail and we can steer you in the right direction.

Admin55

8:05 pm on Dec 7, 2007 (gmt 0)



Ok It's a Project for my company.

I'm incharge of the Intranet. And i also edit there external page.

Since both of you are saying PHP, i'll go with it.
I'm going to read up on it.

Jtara, i will go with the WAMP. Linux is too dificult for right now. Mostlikely in the future.

Windows is the tool i have rightnow since i'm going to use the WAMP.
I don't how to ask this, but if there is anything else you think i should know, please let me know cause i'm totally new to this.

I thank you all very much.

jtara

8:18 pm on Dec 7, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



WAMP sounds like a good choice!

It is close enough to LAMP that many developers use it as a development environment for WAMP sites. You can pretty easily move from WAMP to LAMP later.

It certainly is easier setting-up on Windows than in Linux. In fact, there are quite a number of complete WAMP suites that you can get in a single install image, which will save you the trouble of setting-up the web server, database server, and PHP seperately.

Just run the install and you are off and running. Not sure which one is the best/most popular - perhaps others here can help you with that.

There's a Wikipedia comparison of pre-packaged WAMPs. I'm afraid it probably has more choices than you'd like to think about, but it is a starting point:

[en.wikipedia.org...]

One thing you might have to be concerned about is if you need to access already-existing corporate data in a Microsoft SQL server. That's not really a big problem, though, because you can get PHP to talk to just about any popular database server. Your database server needn't dictate your choice of web server and scripting language. If you can get away with it, though, MySQL certainly puts you squarely in the mainstream of web development, where you will have the most help and support.

[edited by: jtara at 8:21 pm (utc) on Dec. 7, 2007]

LifeinAsia

8:19 pm on Dec 7, 2007 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Just a note- I said PHP as an example (and because a lot of people here at WW use it). I've never used it myself, so don't blame me later on! :)

ZydoSEO

8:10 am on Dec 14, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Sounds like you're a Microsoft shop. If so you probably have access to ASP (Active Server Pages) or ASP.NET. This is Microsoft's scripting language, analogous to PhP in a Linux environment.

Not saying you can't use PhP, but being a Microsoft shop you may already have access to and support for ASP in house.

ergophobe

4:04 pm on Dec 14, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



I missed this earlier. Go with WAMP. Do not even think about trying to use MS Access to run a inter/internet application. My first database that I built (actually third now that I think about it, but the first on Windows) was with MS Access.

When it came time to put it online, I explored a number of options from using Access as a DB server to a total LAMP rewrite. Since I already knew some PHP, it was actually quicker and easier for me to do a total rewrite with the plus side that the application is very portable. So a year ago, it got tranferred from a shared sever to a university supercomputing center with no problem(it could still run on a shared server - it doesn't need those resources. We moved it for other reasons).

Take the time to invest in converting this over. I wish I could find some of my old threads on this since there are a couple of tricks to the Access -> MySQL conversion (there may be better conversion scripts out there now though). I'll look around and see if I can find them.

ergophobe

4:15 pm on Dec 14, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Okay, I found a few of the old threads. Some good, some sort of thin, but poke around

MySQL Basics (and then some)
[webmasterworld.com...]

Some threads on Access->MySQL. There should be some more detailed ones, but I don't find them:

[webmasterworld.com...]
[webmasterworld.com...]
[webmasterworld.com...]
[webmasterworld.com...]

Admin55

8:26 pm on Dec 27, 2007 (gmt 0)



Hi everyone, I deeply thank you all for your input.

But i wanna say to Ergophobe, I like you how you put that. I tried WAMP. I have MySQL up and running and also PHP. I use a PHP Generator name PHP Maker 5 to create my codes.
(http://www.hkvstore.com/phpmaker/) But i've encounter some problems which i hope you or anyone else can help me with.

1. Authentication is my problem. I want users to be able to view the data in the tables that matches there login id.

2. I've licence the PHP Generator and still the Logo wont come out.

Thanx in Advance.

Admin55

8:42 pm on Dec 27, 2007 (gmt 0)



...Correcting an error. I'm using WIMP (Windows IIS MySQL PHP).

ergophobe

11:28 pm on Dec 27, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Sorry, don't know anything about PHP Maker.

As for authentication, this trhead from the library might help:
[webmasterworld.com...]

Admin55

9:25 pm on Jan 15, 2008 (gmt 0)



Hello friend, I'm in a bit of a problem.

My website work well on my Windows Xp machine. Thought that i had accomplish my task i brought it to my administrator.

He gave me a Server within a Server (did ask how he dit that)to show it to him. I didn't even past the first section of my project.

On the Windows Server 2003 I install IIS with PHP 5 and MySQL 5. When i'm ready to test it, it said page cannot be displayed.

Then i thought to myself maybe php does not work with IIS on a server. So i tried Apache. Still did not work.

So tell, what i'm i doing wrong?

Or just tell me step by step what to do.

Thank you all!

mack

12:01 pm on Feb 3, 2008 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



Previousw thread...
[webmasterworld.com...]

Mack.