Tilted Forum Project Discussion Community  

Go Back   Tilted Forum Project Discussion Community > Interests > Tilted Technology


 
 
LinkBack Thread Tools
Old 11-17-2004, 04:20 AM   #1 (permalink)
d*d
Addict
 
d*d's Avatar
 
PHP or ASP

I'm creating a database for a website. I have a basic understanding of PHP (reading and writing from files, passing variables around).
Would it be better to carry on with PHP or to learn ASP to connect the site with my database. I also wouldn't mind knowing what the best database would be, microsoft access seems appealing because I can create tables through the programme itself, but php seems to be linked with mysql

any advice on this would be appreciated
d*d is offline  
Old 11-17-2004, 05:44 AM   #2 (permalink)
Addict
 
php IS closely linked with mysql, but mainly because both are free alternatives and opensource.

I'm currently learning php because my job dictates it, but it looks like ASP.NET will also feature highly in my near future.

You need to pay for Access or MS SQL.
ASP/ ASP.NET servers and hosting packages tend to cost more.

With MySQL Admin and other programs out there, you can also create tables visually. Have a look around.

As php/mysql is cheap and MS XP comes with one instance of IIS, you can just buy a beginner book, like the 'for dummies' series (I have one on my desk) and make your own mind up by trialling it on your desktop.

Dreamweaver and other web editing tools also feature support for php/mysql now too.
WillyPete is offline  
Old 11-17-2004, 06:02 AM   #3 (permalink)
Too hot in the hot tub!
 
pixelbend's Avatar
 
Check out PHPMyAdmin. It's a web based MySQL admin program. Lets you create tables, edit data, copy, dupe, and lots more.
__________________
But I don't want ANY Spam!
pixelbend is offline  
Old 11-17-2004, 08:22 AM   #4 (permalink)
Addict
 
ooops that's the one. not mysql admin.
WillyPete is offline  
Old 11-17-2004, 08:46 AM   #5 (permalink)
Rookie
 
cliche's Avatar
 
Location: Oxford, UK
I had to make this exact choice a while ago - but if you know what you're doing I'd go with PHP. Access and Microsoft-type solutions might have the nice point-and-clickiness, but PHP is nowadays an extremely powerful language and works very well with mySQL for database apps. Best of all it's a free solution and works exceptionally well cross-platform (my app has been served from Windows, Linux and Mac OS without anyone knowing the difference)
__________________
I can't understand why people are frightened of new ideas. I'm frightened of the old ones. -- John Cage (1912 - 1992)
cliche is offline  
Old 11-17-2004, 08:47 AM   #6 (permalink)
Professional Loafer
 
bendsley's Avatar
 
Location: texas
I would tell you to go with PHP also. PHP will work with both windows and linux, unlike ASP.NET. Incase something happens to your server, you won't have to port code over to make it work with something else.
__________________
"You hear the one about the fella who died, went to the pearly gates? St. Peter let him in. Sees a guy in a suit making a closing argument. Says, "Who's that?" St. Peter says, "Oh, that's God. Thinks he's Denny Crane."
bendsley is offline  
Old 11-17-2004, 09:40 AM   #7 (permalink)
Crazy
 
Location: here and there
php works best with MySQL, but it also works with PostgreSQL and any ODBC compliant database. It can also run on any webserver and with any operating system.

For building databases graphically, check out DBDesigner4 http://www.fabforce.net/dbdesigner4/ its opensource, works best with mysql but also works with other databases. can reverse engineer and you can actually graphically build the db.

I like phpMyAdmin for administration of a database, but i like DBDesigner for building them.
__________________
# chmod 111 /bin/Laden
theFez is offline  
Old 11-17-2004, 09:07 PM   #8 (permalink)
Junkie
 
Location: Florida
Ahh, what a timely thread. I'm ready for a rant.

Windows is such a godawful atrocious platform for web development that it even managed to make php suck ass. Let me compare:

Install PHP + access MySQL DB on Red Hat / Fedora:

-up2date -i php
-mysql_connect($host,$user,$pass)
-voi fucking la.

Install PHP + access MSSQL DB on Windows:

-Go through PHP installer wizard.
-Select "install under IIS 6 or above" option since I'm running IIS 6 on Win2k3
-Roll back install when it breaks, re-run setup and choose "IIS 4 or above" option.
-Change permissions so IIS user can access PHP stuff.
-Configure IIS to recognize index.php
-Enable MSSQL extension
-Wait for 10 minutes as all .php files refuse to load and eventually time out
-Attempt to restart IIS service.
-Wait 5 minutes as it attempts to shut down, times out, and is caught in limbo where it's eternally in a state of shutting down.
-Reboot server.
-Find out that IIS user does not have access to MSSQL extension DLL. Why in the FUCK did that make IIS just sit there? That doesn't even make sense. Would it kill them to throw in a simple "access denied" error?
-MSSQL login failed: "Not associated with a trusted SQL Server connection"
-Make sure integrated security is disabled in php.ini since I'm using SQL authentication and sending a username & password. it is.
-Try ODBC connection. "No such DSN".
-Remove User DSN, re-add it as System DSN.
-Some sort of different error message.
-Try ADODB library
-"Not associated with a trusted SQL Server connection"
-Go back to MSSQL library
-Try running PHP script from the command line. For no fucking reason at all, this works like a charm.
-Loosen up permissions to MSSQL extension and associated DLL's knowing it won't fix a damn thing. Of course it doesn't.
-Give up for the night and start drinking.

Windows is excellent for word processing. It does a fine job of checking e-mail and Web browsing. Hell, it's even great for gaming. But whoever the fuckhole is who said "Hey, let's take this pile of crap and rig it into being a server platform!" needs to be dragged by his balls through broken glass and razor blades and then drowned in a vat of rubbing alcohol.
irseg is offline  
Old 11-18-2004, 03:56 AM   #9 (permalink)
d*d
Addict
 
d*d's Avatar
 
so you'd go for php then
d*d is offline  
Old 11-22-2004, 09:06 AM   #10 (permalink)
Insane
 
Location: Michigan
Quote:
Originally Posted by irseg
Windows is excellent for word processing. It does a fine job of checking e-mail and Web browsing. Hell, it's even great for gaming. But whoever the fuckhole is who said "Hey, let's take this pile of crap and rig it into being a server platform!" needs to be dragged by his balls through broken glass and razor blades and then drowned in a vat of rubbing alcohol.
PHP sucks on *IIS*, not Windows, but php was not designed for IIS, it's a plug-in, it was designed with Apache in mind. It was bandaided for IIS via ISAPI. Run Apache with PHP on Windows and you have the same environment as Linux. As with Linux, make sure your Apache user can execute php.exe and can read/write temp/session files and you are good to go.

IIS works just fine if you use the tools designed around/for IIS. ASP.NET is quite nice and works just as easily as php does on Apache. I use both OS's and both Webservers and I tend to keep php/mysql on Linux and use my Windows boxes for MSSQL ASP/ASP.NET.
asshopo is offline  
Old 11-22-2004, 07:23 PM   #11 (permalink)
Insane
 
Location: Wales, UK, Europe, Earth, Milky Way, Universe
Quote:
Originally Posted by irseg
Ahh, what a timely thread. I'm ready for a rant.

...
I actually quite enjoyed reading that, maybe because i had similar problems a few years ago. Thanks

Totally agree with most of the other replies. Just bare in mind how M$ likes everyone to use only software written by them so they tend to ignore other technologies out in the real world and don't provide compatibility with them unless the technology gets popular and then its only "ohhh, ok, if we _must_... but we're only devoting $5 to the development...."
__________________
There are only two industries that refer to their customers as "users". - Edward Tufte

Last edited by welshbyte; 11-22-2004 at 07:27 PM..
welshbyte is offline  
Old 11-23-2004, 07:07 AM   #12 (permalink)
Upright
 
It depends what you need. I started with ASP but quickly took up PHP, I've been doing PHP for about 4 years now.

I love PHP, the speed is fantastic, the code is very structured and easy to write, it's very easy to debug, it's extremely cheap to role out. It works very well with mySQL.

However. If you're looking to work as a developer, you'd be hard pushed not to go down the .NET route, everywhere I look I see people advertising for .NET developers, .NET fits in great with Windows Servers, if you're running a Windows based server, active directory or the like, .NET will give you massive scope that you will not get with PHP.

Again, it's another example of the best technology losing out to the Microsoft Money Machine.

Access is a fine desktop database for organising your CD collection, but you need to get over it very quickly and start writing proper ANSI spec SQL. You don't need a visual editor to build tables, you just need to spend an hour or so getting to grips with the syntax, then you'll be able to migrate to Oracle, MSSQL or any other DB that comes up very easily.

Andrew
andrewtayloruk is offline  
Old 11-23-2004, 07:47 AM   #13 (permalink)
Addict
 
I guess this belongs in another thread and has probably been hashed to death, but having dealt with the procurement process and middle management I don't think that the swing to microsoft servers is as much of a money mochine thing as laziness on the part of the less technical decision makers.

It's easier fr a manager or director to justify a purchase of hardware or software X in order to meet compliance with MS driven industry. There's just SO MANY options available to save money with *nix and open source alternatives that it makes the whole decision making and purchasing process bog down.
It's easier for them to regurgitate the very good MS marketing schpiel. When your IT director keeps seeing the IBM advert in his Financial Times, CNN, airplane adverts and TV then it makes it easier for you to swing him in that direction.

Same with this. Anyway.
Back to topic....?
WillyPete is offline  
Old 11-24-2004, 02:32 AM   #14 (permalink)
Upright
 
If you are going to have to parse text files for data php is the one to stick with. I could never get it working in asp
skipjack is offline  
Old 11-24-2004, 06:01 AM   #15 (permalink)
Insane
 
Location: Michigan
Quote:
Originally Posted by skipjack
If you are going to have to parse text files for data php is the one to stick with. I could never get it working in asp
Uhm, ya, you don't recomend someone else do what you didbecause *you* could get a file open or not. Opening files for in/out in asp is as easy as php. Lets be real, php might be better for certain types of things as well as asp is for certain things, lets not say "stick with php because *I* couldnt open a file".
asshopo is offline  
Old 11-24-2004, 12:06 PM   #16 (permalink)
beauty in the breakdown
 
Location: Chapel Hill, NC
Quote:
Originally Posted by asshopo
Uhm, ya, you don't recomend someone else do what you didbecause *you* could get a file open or not. Opening files for in/out in asp is as easy as php. Lets be real, php might be better for certain types of things as well as asp is for certain things, lets not say "stick with php because *I* couldnt open a file".
Agreed. Ive never used ASP, but saying someone should avoid it because you couldnt get a relatively simple thing running says more about your ability than the suitability of the language/platform.
__________________
"Good people do not need laws to tell them to act responsibly, while bad people will find a way around the laws."
--Plato
sailor is offline  
Old 12-10-2004, 08:14 PM   #17 (permalink)
Upright
 
Location: Rochester, MN
asp requires you to use IIS as the server.....and php/mySQL is free.....
WillySJU is offline  
Old 12-10-2004, 10:20 PM   #18 (permalink)
Crazy
 
Location: here and there
Quote:
Originally Posted by WillySJU
asp requires you to use IIS as the server.....and php/mySQL is free.....
not entirely true, or accurate.

PHP and MySQL are a scripting language and a database while IIS is a webserver. PHP and MySQL run just fine on windows with either Apache or IIS as the web server. with
mono you can run asp.net on a linux box and serve asp.net pages just fine under apache.

Also while it's not free (about $500), Sun has bought Chilisoft ASP and renamed it Java System Active Server Pages which can serve VBscript.

There is also a Perl module which works with Apache and mod_perl to serve ASP.

But i still think PHP is a better way to go.
__________________
# chmod 111 /bin/Laden
theFez is offline  
Old 12-11-2004, 07:53 AM   #19 (permalink)
Crazy
 
Quote:
Also while it's not free (about $500), Sun has bought Chilisoft ASP and renamed it Java System Active Server Pages which can serve VBScript.
I have had a pretty hard time ever porting ASP/VBScript written for IIS/windows to Chilisoft. Most of the time if you code for Chilisoft It gets the job done fine.

When I started programming I learned Perl, and then quickly moved on to PHP. ~5 years or so ago I got hired at the company I still worked for and we are a Microsoft shop pretty much. I learned VB and ASP and still code in it today.

The biggest difference when it comes to coding is the syntax. PHP is C based, ASP/VBScript is well, VB based. I find it kind of difficult when coding to switch between VB style and C style (JavaScript), so as we progress into the .NET realm I'm going to move on to C# and try to leave VB behind as much as possible.
gh0ti is offline  
Old 12-11-2004, 09:58 AM   #20 (permalink)
Crazy
 
Location: here and there
i work as a programer for an e-commerce company and we have been running on a LAMP shopping cart for a while now, the PHB decided to buy a new shopping cart which is all VBScript. So now I am learning VBScript from fixing/tweaking a poorly coded, undocumented shopping cart.

and i hate that language. Just plain hard on the eyes.
__________________
# chmod 111 /bin/Laden
theFez is offline  
Old 12-11-2004, 10:53 AM   #21 (permalink)
Junkie
 
Location: Florida
Quote:
Originally Posted by theFez
i work as a programer for an e-commerce company and we have been running on a LAMP shopping cart for a while now, the PHB decided to buy a new shopping cart which is all VBScript. So now I am learning VBScript from fixing/tweaking a poorly coded, undocumented shopping cart.
I feel your pain. God I hate VBScript. Overly verbose languages piss me off.

If (blah blah blah) Then -- you don't need a fucking "Then"! It's implied!

php's functions are guilty of this to some extent. For instance, "mysql_escape_string". As opposed to what? "mysql_escape_ramdisk"? Of course I'm going to be escaping a string, don't make me needlessly type it.

I assume you're dealing with ASP pages on IIS? If so, does randomly choose whether it wants to give you a nice error output or just do a '500 Server Error'?

Sometimes when I'm debugging a script it'll just spit out a 500 error. Then I'll cut out the entire contents, put in a 'response.write "xxx"', reload, then delete that and paste in the exact same original code. THEN, about 60% of the time, it will give me the nice debugger output. Programming on Microsoft platforms really friggin' sucks.
irseg is offline  
Old 12-11-2004, 12:30 PM   #22 (permalink)
Crazy
 
Location: here and there
no, i usually get the debugger errors.

The main thing that bugs me about PHP is the lack of consistency in function names and parameters.

like why is there a underscore between 'words' in some functions (i.e. preg_match) and not others (i.e. stripos)

and why do some functions take parameters in the order subject, pattern (i.e. trim, strip_tags) and others pattern, subject (i.e. preg_match)

or some take arguments of handle, string (i.e. fwrite) while others take string, handle (i.e. mysql_query)
__________________
# chmod 111 /bin/Laden
theFez is offline  
Old 12-11-2004, 02:07 PM   #23 (permalink)
Junkie
 
Location: Florida
Yes, exactly. I can never remember if it's "urlencode" or "url_encode" because the use of underscores seems to be totally random.

They seem to be trying to make it a little more consistent, though. For instance the new mysqli library conforms to the "handle, string" standard. Of course this makes it a pain to convert existing code if you don't have an abstraction class.

That's another stupid thing, actually. The new mysqli library is much faster, but they got rid of persistent connections. PHP's line is that they could cause the MySQL server to get clogged with dormant connections (which is a non-issue if you configure it properly, and is rare if you don't). Well when your database server is on a remote network and you have to repeatedly send it small queries, persistent connections are nice. Don't take away useful features to protect me from myself.
irseg is offline  
Old 12-13-2004, 06:31 AM   #24 (permalink)
Tilted
 
I'm just interested in where the results are going to net out on this topic.
VarsityDrinking is offline  
Old 01-08-2005, 06:39 AM   #25 (permalink)
Upright
 
The posts that using IE on Windows are totatly false.

Everytime I reinstall - I do a search, grab anyone of the hundreds of auto Apache/PHP installers available - done like five minutes later. Then I jog over tp httpd.conf - set it up the way I want.


I am sure the correct answer to the original question is which do you want to work with? Do you want the vast amount of powerful Microsoft tools available to you? Then you go with ASP. Do you want the tens of thousands open source scripts available to you, and a much more community orientied group of users? Then go with PHP.

They both work well, they both get the job done, though which one is better is going to be determined by what the job is.

Me I know so little about ASP I couldnt even tell you that it stands for Active Server Pages. I am very happy with PHP and Javascript - have found that there is basically nothing I can not make with the that, and maybe a little client side vbscript or wscript thrown in if I am trying to make something for a desktop.

Though as was mentioned above - if you have a type of code you are used to working with - stick with it. If you really know PHP and Javascript - you would know that there is bascially no difference between the two - makes using the two very simple - as long as you remember you are writing script and dont write your for look like - if ($i=0;$i<count($money);$i++)

Discovered that doesnt work will in javascript
Zach is offline  
Old 01-16-2005, 10:13 PM   #26 (permalink)
Tilted
 
Location: Ontario, Canada
If we're talking PHP vs ASP 3.0, from my experience, I'd choose PHP over ASP easily. It runs smoother, is easier to debug, is free, and implements itself very easily with both IIS and Apache.

However, if you're talking ASP.net, I'd take it anyday over PHP. I have my personal reasons, but as a business application developer (both Web and Windows based applications) its just makes everything much faster in development speed and functionality, as well as full Object-oriented programming. Yes, there is an implementation of OOP in PHP, but not as powerful or structured as that of ASP.net (being that ASP.net's code-functionality is based on VB.net/C#). Plus debugging has been made very simple with it, and it implements well with most databases via ADO.net (including MySQL with a little work). Yet, like anything Microsoft does, there is a fee involved (as IIS is only shipped with Windows 2000/XP/2003 Server) and in order to get the most functionality out of ASP.net, you'll need Visual Studio 2003+ (2002 just doesn't cut it as it doesn't have full ASP.net 1.1 support, only ASP.net 1.0).

This is not to knock PHP though. I have programmed extensively with it in the past, and it is a very powerful web-scripting language. Anything you can do in ASP 3.0 you can do in PHP, and then some. I guess it boils down to whether or not money is somewhat of an issue. If not, I'd look into ASP.net (not ASP 3.0). MS have also released a free slimmed down version of Visual Studio just for ASP.net called WebMatrix (www.asp.net) I haven't used it myself, but it might something worth looking into.
__________________
" Can't keep my eyes from the circling skies, Tongue-tied and twisted just an earth-bound misfit, I "
Nooze2k is offline  
Old 01-21-2005, 10:01 PM   #27 (permalink)
Upright
 
Location: wouldn't you hate to know
I agree with Nooze2k on the benefits of asp.net. Though my experience with PHP has been limited I have had extensive experience with the previous versions of asp and can say that asp.net is simply incredible. WebMatrix is also a very slick editor (for free). The ability to cache datasets/pages based on your business logic can provide HUGE performance increases.

I do believe it is important to do what you know and start learning what you should know.....so I'd suggest completing the project in PHP but start jumping into that next language you are intersted in.
hognose is offline  
Old 01-23-2005, 11:22 PM   #28 (permalink)
Psycho
 
PHP, hands down.
insidious_machinae is offline  
Old 01-24-2005, 01:23 AM   #29 (permalink)
Junkie
 
Location: Florida
I don't have much experience with ASP.NET yet, but the big thing that annoys me is how it tries to do everything for you. I hate how its default behavior has it generating cookies and sessions and viewstate data and form fields, etc., etc. on its own. I think it causes too much overhead and perhaps more importantly, never lets you get experience on how to handle things on your own.

One coworker of mine is a big ASP.NET fan. One time he spent the better part of a day trying to figure out how to make session data portable across servers, because evidently it does not provide you with a way to do this. Eventually he asked me if I had any ideas, I said "why not just generate a session ID on your own and store it along with the data in an SQL database?".. problem solved! That was a no-brainer for me because that's how I did it back in my Perl days. If I had cut my teeth on ASP.NET, that probably never would have occurred to me either.
irseg is offline  
Old 01-27-2005, 10:06 PM   #30 (permalink)
Tilted
 
McFrosticles's Avatar
 
Definitely PHP. There are many more options with it
__________________
Good Grief
McFrosticles is offline  
Old 01-28-2005, 08:46 AM   #31 (permalink)
d*d
Addict
 
d*d's Avatar
 
Well I did it, using php using phpmyadmin and dreamweaver the database works fine and I think after a bit of research on the matter that php is the better solution but asp the more popular through microdofts grasp on all things computerlike. cheers for all the advice
d*d is offline  
Old 01-28-2005, 09:43 AM   #32 (permalink)
Upright
 
Location: massachusetts
XAMP will set up PHP on windows as easy as a hot knife slices butter...

check out XAMPP. It is a installer that installs apache, php, mysql all at the same time, all configured to work with each other, right out of the box. it comes with several useful examples, as well as PHPMyAdmin, which makes mysql almost as point and click as Access.

Much easier than trying to configure all these things on windows from scratch.

http://www.apachefriends.org/en/xampp.html
piismyname is offline  
Old 01-29-2005, 09:10 AM   #33 (permalink)
Junkie
 
Location: RI
Quote:
Originally Posted by piismyname
check out XAMPP. It is a installer that installs apache, php, mysql all at the same time, all configured to work with each other, right out of the box. it comes with several useful examples, as well as PHPMyAdmin, which makes mysql almost as point and click as Access.

Much easier than trying to configure all these things on windows from scratch.

http://www.apachefriends.org/en/xampp.html
Holy crap...thanks for the link. I've been having a hell of a time configuring mine because I've not been following directions and now this? Perfect-o
thanks
Fallon is offline  
 

Tags
asp, php


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT -8. The time now is 01:22 AM.

Tilted Forum Project

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Search Engine Optimization by vBSEO 3.6.0 PL2
© 2002-2012 Tilted Forum Project

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360