Jump to content


Photo

Zend Studio, Windows and MySQL


  • Please log in to reply
8 replies to this topic

#1 onlyican

onlyican
  • Members
  • PipPipPip
  • Advanced Member
  • 921 posts
  • LocationHants - UK

Posted 20 September 2006 - 03:04 PM

Hey guys

I just downloaded Zend Studio
Got to say, I am loving this shing ding (Tryna cut down on my swearing)

BUT
if I type a MySQL function, it comes up with an error

So this tells me that the MySQL is not set up in the settings

I looked for the php.ini file

and it is basic
If you know Zend Studio ya know wha I mean
If not
Then under php5
The php ini is

zend_extension_ts=C:\Program Files\Zend\ZendStudio-5.2.0\lib\php5\ZendDebuggerLocal.dll
zend_debugger.allow_hosts=127.0.0.1/32
session.save_path=C:\Program Files\Zend\ZendStudio-5.2.0\tmp


I done a search for other php.ini files
Theres one in php4 (basicly the same)
and one somewhere else, which is blank

So anyone know how I can get this to work with MySQL?

Tell me the problem, I will try tell you the solution

#2 Daniel0

Daniel0
  • Staff Alumni
  • Advanced Member
  • 11,956 posts

Posted 20 September 2006 - 05:49 PM

Are you talking about its internal debugger?

#3 onlyican

onlyican
  • Members
  • PipPipPip
  • Advanced Member
  • 921 posts
  • LocationHants - UK

Posted 20 September 2006 - 06:00 PM

yes, sorry
Tell me the problem, I will try tell you the solution

#4 Daniel0

Daniel0
  • Staff Alumni
  • Advanced Member
  • 11,956 posts

Posted 20 September 2006 - 06:35 PM

Make sure the MySQL extension is enabled.

Could you possibly paste the error here?

#5 onlyican

onlyican
  • Members
  • PipPipPip
  • Advanced Member
  • 921 posts
  • LocationHants - UK

Posted 20 September 2006 - 06:49 PM

how do I enable the MySQL extension??
the full code is
<?php
$db = mysql_connect("localtion","root","root");
mysql_select_db("market",$db);
?>
This is something I just done quickly
Then I hit Debug
The error on the Debug Output is

Fatal error: Call to undefined function mysql_connect() in PHPDocument1 on line 2


Now, my first post has the php.ini file. SO i am lost
Tell me the problem, I will try tell you the solution

#6 wildteen88

wildteen88
  • Staff Alumni
  • Advanced Member
  • 10,482 posts
  • LocationUK, Bournemouth

Posted 20 September 2006 - 06:56 PM

You need to edit the php.ini and configure the extension_dir directive to point to the PHP extensions folder. The extension folder is located in side the folder you have installed PHP to. So if you have installed PHP in the root of your hard drive in a folder called php. Then the path to the PHP extension folder will C:\php\ext

The next step is to remove the semi-colon (;) from the the start of extension=php_mysql.dll

#7 onlyican

onlyican
  • Members
  • PipPipPip
  • Advanced Member
  • 921 posts
  • LocationHants - UK

Posted 20 September 2006 - 08:01 PM

mmm, one problem, my php.ini is posted above
How would I do that?
Tell me the problem, I will try tell you the solution

#8 wildteen88

wildteen88
  • Staff Alumni
  • Advanced Member
  • 10,482 posts
  • LocationUK, Bournemouth

Posted 20 September 2006 - 08:25 PM

Ah, Umm I'm not sure. I guess it'll be a good idea to check out the zend studio manual. Should be discussed in their somewhere

#9 Daniel0

Daniel0
  • Staff Alumni
  • Advanced Member
  • 11,956 posts

Posted 21 September 2006 - 07:13 PM

I think adding the lines what wildteen mentions should make it work.
Or you could install Zend Platform and configure Zend Studio to use that as its debugger. It is free for development purposes.

That would give you more features too. Like profiling.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users