[PHP-DB] Connecting to MS Access Database using PHP via ODBC.

2007-03-15 Thread ABCOM Support
Hello,

Im using PHP to connect to a Microsoft Access database which is not stored 
on the machine where IIS is installed. It's located on a different file 
server on the network.

I have mapped a network drive to where the database is stored and have used 
it when creating the System DSN.

The problem is the the php script cannot connect. If I move a copy of the 
database over to the server where IIS is installed and update the System DSN 
to point to that it all works fine.

I was made aware that you could have the database on a different machine and 
it would work, but this doesnt seem to be the case.

Can anyone shed some light on this?

Many thanks. 

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DB] Radio buttons

2002-08-26 Thread Support @ Fourthrealm.com

Your radio buttons look fine.  I would ensure to add quotes (single or 
double) around the attribute settings, for HTML compliance.  If you must go 
without quotes, then make sure that you don't put spaces in any of the 
attribute values.

INPUT type=radio value=6 name=surf_erf

As for the form not working... do you have a JavaScript that works with 
these radio buttons?

Or, is the radio button name the same as the Submit button?



At 07:25 PM 8/26/2002 +0200, you wrote:
Hello, I get forms posted and working, but as soon as I include radio
buttons, the whole form doesn't function anymore. The code of the radio
button part is included in this posting.
Can you tell me, what I'm doing wrong?
Help would be greatly appreciated!

S. Maier


 TR
   TD width=35%Wie häufig surfen Sie im Internet? /TD
   TD vAlign=center width=15%
 DIV align=rightFONT size=-1selten/FONT/DIV/TD
   TD width=5% bgColor=#cc
 DIV align=centerFONT size=-1INPUT type=radio value=1
 name=surf_erf /FONT/DIV/TD
   TD width=5% bgColor=#cc
 DIV align=centerFONT size=-1INPUT type=radio value=2
 name=surf_erf /FONT/DIV/TD
   TD width=5% bgColor=#cc
 DIV align=centerFONT size=-1INPUT type=radio value=3
 name=surf_erf /FONT/DIV/TD
   TD width=5% bgColor=#cc
 DIV align=centerFONT size=-1INPUT type=radio value=4
 name=surf_erf /FONT/DIV/TD
   TD width=5% bgColor=#cc
 DIV align=centerFONT size=-1INPUT type=radio value=5
 name=surf_erf /FONT/DIV/TD
   TD width=5% bgColor=#cc
 DIV align=centerFONT size=-1INPUT type=radio value=6
 name=surf_erf /FONT/DIV/TD
   TD vAlign=center width=20%FONT size=-1oft /FONT/TD/TR




--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

- - - - - - - - - - - - - - - - - - - - -
Fourth Realm Solutions
[EMAIL PROTECTED]
http://www.fourthrealm.com
Tel: 519-739-1652
- - - - - - - - - - - - - - - - - - - - -


--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




RE: [PHP-DB] Array HELL!!!!

2002-02-22 Thread SpyProductions Support Team


That's not Array Hell, this is Array Hell:

$Hell = array(satan,fire,brimstone);

-Mike


 -Original Message-
 From: jas [mailto:[EMAIL PROTECTED]]
 Sent: Friday, February 22, 2002 4:37 AM
 To: [EMAIL PROTECTED]
 Subject: [PHP-DB] Array HELL


 I don't know what it is but I am having a hell of a time trying
 to get some
 results of a query setup into an array or variable (too much of a
 newbie to
 know which) that can be passed to a confirmation page before deleting the
 record from a table.  I have given up working on this but for those of you
 that want to finish it here is the code and the table structure...

 [Table Structure]
 id int(30) DEFAULT '0' NOT NULL auto_increment,
car_type varchar(30),
car_model varchar(30),
car_year varchar(15),
car_price varchar(15),
car_vin varchar(25),
dlr_num varchar(25),
PRIMARY KEY (id)

 [Page 1 - Queries DB table for records]
 ?php
 require '../path/to/db.php';
 $result = @mysql_query(SELECT * FROM cur_inv,$dbh) or die(Could not
 execute query, please try again later);
 echo table border=\0\ class=\table-body\ width=\100%\form
 name=\rem_inv\ method=\post\ action=\rem_conf.php3\
 trtd align=\center\ colspan=\3\font size=\4\BCurrent
 Inventory/B/fonthr color=\33\/td/tr;
 $count = -1;
 while ($myrow = mysql_fetch_array($result)) {
  $id = $row[id];
  $car_type = $row[car_type];
  $car_model = $row[car_model];
  $car_year = $row[car_year];
  $car_price = $row[car_price];
  $car_vin = $row[car_vin];
  $count ++;
 echo trtd width=\30%\BType Of Car: /B/tdtd;
 printf(mysql_result($result,$count,car_type));
 echo /tdtdinput type=\checkbox\ name=\id[]\
 value=\.$myrow[id].\remove/td/tr\n;
 echo trtd width=\30%\BModel Of Car: /B/tdtd;
 printf(mysql_result($result,$count,car_model));
 echo /td/tr\n;
 echo trtd width=\30%\BYear Of Car: /B/tdtd;
 printf(mysql_result($result,$count,car_year));
 echo /td/tr\n;
 echo trtd width=\30%\BPrice Of Car: /B/tdtd$;
 printf(mysql_result($result,$count,car_price));
 echo /td/tr\n;
 echo trtd width=\30%\BVIN Of Car: /B/tdtd;
 printf(mysql_result($result,$count,car_vin));
 echo /td/trtrtd colspan=\3\hr color=\33\/td/tr\n;
 }
 echo trtdinput type=\submit\ name=\delete\
 value=\delete\/td/tr/form/table;
 ?

 [Page 2 - Takes records and confirms which ones to be deleted]
 ?php
 print(
 table border=\0\ class=\table-body\ width=\100%\
 form name=\rem_inv\ method=\post\ action=\done2.php3\
 INPUT TYPE=\hidden\ NAME=\id\ VALUE=\$id\
 INPUT TYPE=\hidden\ NAME=\car_type\ VALUE=\$car_type\
 INPUT TYPE=\hidden\ NAME=\car_model\ VALUE=\$car_model\
 INPUT TYPE=\hidden\ NAME=\car_year\ VALUE=\$car_year\
 INPUT TYPE=\hidden\ NAME=\car_price\ VALUE=\$car_price\
 INPUT TYPE=\hidden\ NAME=\car_vin\ VALUE=\$car_vin\
   tr
 td align=\center\ colspan=\3\font size=\4\BConfirm Record
 Deletion/B/fonthr color=\33\/td
   /tr
   tr
 td width=\30%\BType Of Car: /B/td
  td$car_type/td
   /tr
   tr
 td width=\30%\BModel Of Car: /B/td
  td$car_model/td
   /tr
   tr
 td width=\30%\BYear Of Car: /B/td
  td$car_year/td
   /tr
   tr
 td width=\30%\BPrice Of Car: /B/td
  td$car_price/td
   /tr
   tr
 td width=\30%\BVIN Of Car: /B/td
  td$car_vin/td
   /tr
   tr
 td colspan=\3\hr color=\33\/td
   /tr
   tr
 tdinput type=\submit\ name=\delete\ value=\delete\/td
   /tr
 /form
 /table);
 ?

 [Page 3 - Connects to DB and deletes selected records]
 ?php
 require '../path/to/db.php';
 $table_name = cur_inv;
 $sql = DELETE FROM $table_name WHERE id = '$id';
 echo($sql);
 $result = mysql_query($sql,$dbh) or die(mysql_error());
 print(body bgcolor=\ff9900\p class=\done\You have successfully
 removed your items from the database.);
 ?

 If anyone has the time to finish it or give me some pointers on what the
 hell I am doing wrong please let me know, I would be very glad to
 hear your
 opinion and the correct way to accomplish this.  (And, yes I went through
 just about every tutorial I could find on how to delete records, which by
 the way did nothing for putting the results of a select statement into an
 array or variable for futher processing.) Have a good weekend everyone!!!
 Pissed and frustrated...
 Jas



 --
 PHP Database Mailing List (http://www.php.net/)
 To unsubscribe, visit: http://www.php.net/unsub.php




-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DB] RE: Special Insertion Into MySQL - at a loss!

2002-02-21 Thread SpyProductions Support Team



 The following code is how you should retrieve the data from mySQL...
 if you wanted to update all of the information through one button,
 though, I would do it in a slightly different way...

 ?php

 $sql = SELECT whatever FROM whatever...;

 $result = mysql_query($sql);

 while ($row = mysql_fetch_array($result)){
   $domain = $row[0]; // first item in array
   $cancel = $row[1]; // second item in array
 ?

 tr
 tdfont size=2 face=Arial?= $domain ?/font/td
 tdfont size=2 face=ArialCancel This Domain?/font/td
 tdfont size=2 face=Arialinput type=text name=confirm
 value='?= $cancel ?' size=3/font/td
 /tr

 ?  }  ?


 as long as all these are from the same table... the update is easy...


Actually, the data is fetched based from table 2 based on data from table1 -
however, all of the data shown, being from table2, would be updated to table
2.

So, on the second page, when a 'submit' is done, the information would be
updated in mysql likehow?  That is the major problem I am having - how
to keep the arrays in separate identities so that I can update row by row
into the table - based on domain name since they are all unique.

Thanks for your help,

-Mike




-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DB] Special Insertion Into MySQL - at a loss!

2002-02-20 Thread SpyProductions Support Team


I have a special set of information retrieved from a while loop that I would
like a person to be able to edit and send back into a MySQL table.

I know all of the basic MySQL commands for doing such, but the PHP side to
get the input from the form to go in is really stumping me.

This is what I have:

-

$or = 0;

while($or  $orderidrows) {

$orderinfo = mysql_fetch_row($orderidinfo);
$domain[$or] = $orderinfo[2];
$cancel[$or] = $orderinfo[3];

print trtdfont size=2 face=Arial$domain[$or]/font/tdtdfont
size=2 face=ArialCancel This Domain?/font/tdtdfont size=2
face=Arialinput type=text name=confirm value='$cancel[$or]'
size=3/font/td;

$or++;
   }

--

The values I would normally insert into the MySQL from the form would be
$confirm - however, in this case, I have a number of rows with the same
name.  How do I distinguish one from another?  The [$or] doesn't work to do
it (didn't think it would).

Thanks for any help!

-Mike



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DB] PHP CGI Problems.....

2002-02-08 Thread SpyProductions Support Team


I am trying to put PHP into a template HTML document that is used by a CGI
script.  The PHP script isn't working at all - and even when I put some
generic line of PHP (an echo), it doesn't turn out.

Could the CGI be causing this?

Is it possible to compile PHP to allow it in CGI files?

Thanks,

-Mike



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DB] PHP Site Statistics

2002-02-05 Thread SpyProductions Support Team


Just installed Les Visiteurs for php site statistic gathering...looks fine.

Anyone have a favorite site statistic script/program in PHP?  I'm
experimenting with different ones to see what I like.

The only disadvantage I can see with Les Visiteurs is having to put a couple
of lines of code in every page you want tracked.  Fine for a new site, but
not so nifty for sites that already exist.

-Mike



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php




[PHP-DB] phpMyAdmin Problem....

2002-01-31 Thread SpyProductions Support Team


I just added phpMyAdmin to a new Apache Server, and I'm getting this error:

cannot load MySQL extension,
please check PHP Configuration.

I did some research on the web, but couldn't come up with a solution to this
error and couldn't find anyone listing it.

Does anyone know if this is a problem with conf.inc.php in phpMyAdmin or
with the MySQL set up in PHP on the server?

Any suggestions from there?

Thanks,

-Mike



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DB] Copying a MySQL Table

2002-01-11 Thread SpyProductions Support Team


How does one copy a Mysql table?

I poked around on the mysql site and found conventions for renaming one, but
nothing for  duplicating a table (to a new table with a different name).

Thanks,

-Mike


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DB] Checkboxes, PHP, and MySQL

2001-12-20 Thread SpyProductions Support Team


I've looked around in a few of the PHP lists for an answer to this, but
can't come up with one.

Here's what I am doing:

I have a form with a few checkboxes.

When the information as to whether the checkboxes are checked or not is
'saved' into the MySQL table, they are represented by a value of '1' - fine.

When I want to edit this information, in the form of a similar form with
checkboxes, the boxes are not checked off if they were before.

What I am stuck on is how a checkbox can get checked off when pulling
information from the MySQL as an array.

Here's a line of code showing my array coming out.

input type=checkbox name=firstvalue value='$result[32]'

$result is the array.

I guess what I am asking is that if a checkbox is assigned a value of one,
why doesn't it appear as already checked off?

Thanks,

-Mike


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP-DB] PHP Mysql apache economy hosting

2001-07-13 Thread support


I recommend MissoulaWeb for $10/month.

  http://www.missoulaweb.com/testimonials.phtml
  http://www.missoulaweb.com/allfeatures.phtml
  http://www.missoulaweb.com/compare.phtml   (a chart)

As for verifying uptime, try using the tool at
http://uptime.netcraft.com/up/graph/

-- 
Allen Lee
http://MissoulaWeb.com
Hosting, Programming and Design



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP-DB] Need a shopping cart

2001-07-11 Thread support


Here's a list of some free shopping cart stuff
http://www.missoulaweb.com/help/index.phtml?qid=46cat=11

-- 
Allen Lee
http://MissoulaWeb.com
$10/month PHP4 MySQL Hosting

On Thu, 12 Jul 2001, Matthew Loff wrote:


 Ha ha... It makes perfect sense!

 I just assumed that since he was asking, he was implying that he didn't
 have the ability (due to administrative reasons) to install mysql.

 Good point, though. :)


 -Original Message-
 From: Tom Peck [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, July 12, 2001 1:01 AM
 To: [EMAIL PROTECTED]
 Subject: RE: [PHP-DB] Need a shopping cart


 Matthew

 So what's so funny about installing MySQL on a NT system that is already

 running Perl and PHP?  I think it makes perfect sense :-).

 Tom

 At 00:52 12/07/2001 -0400, you wrote:

 Everyone suggesting Easy!  Just install Mysql! makes me laugh... :)
 
 Jeff-- I suggest you check:
 
 1) http://www.hotscripts.com/
 2) http://www.zend.com/
 3) http://www.sourceforge.com/
 4) http://www.mysql.com/ (Just kidding!)
 
 Any shopping cart that uses ODBC should work just fine--  and moreso,
 it shouldn't be hard (if you absolutely needed to) to modify a Mysql
 cart to use odbc calls instead.
 
 Best of luck!
 
 
 Jeff @ HookedOnThe.Net wrote:
  
   Can anyone direct me to a shopping cart package (preferrably in PHP,

   although PERL would possibly work) which utilizes either an MS
   Access database or flat files?  I've found several shopping carts,
   but they all seem to require MySQL which I do not have access to on
   my server. My server is Windows NT 4 with PHP 4 and PERL 5.
  
   I sure hope someone can help.  Thanks in advance.
  
   Regards,
   Jeff [EMAIL PROTECTED]  -  ICQ UIN:  736807
   Training, Web Hosting and Design
   http://www.HookedOnThe.Net
  
   --
   PHP Database Mailing List (http://www.php.net/)
   To unsubscribe, e-mail: [EMAIL PROTECTED] For
   additional commands, e-mail: [EMAIL PROTECTED] To contact
   the list administrators, e-mail: [EMAIL PROTECTED]
 
 
 --
 PHP Database Mailing List (http://www.php.net/)
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 To contact the list administrators, e-mail:
 [EMAIL PROTECTED]





-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DB] how to get ERROR message

2001-07-05 Thread support



   echo mysql_error();


Allen Lee
http://MissoulaWeb.com
$10/month PHP4 and MySQL hosting

On Thu, 5 Jul 2001, jong jong wrote:

 Hi,

 How can I see the error message from browser? My code
 is like this:
 htmlbody
 ?
 $conn=mssql_connect(xxx,,);
 mssql_select_db(xxx,$conn);
 $result=mssql_query(exec x) or die(query
 failed);
 mssql_free_result($result);
 ?
 /body/html

 I got query failed on the browser screen and nothing
 else. Here is some value I got from phpinfo():
   Configuration
 PHP Core
Directive  Local value  Master value
 display_errors   On On
 display_startup_errors
   Off   Off
 doc_root   no value  no value
 enable_dlOn On
 error_append_string  Off   Off
 error_log no value   no value
 error_prepend_string
  OffOff
 error_reporting  2039   2039

 Are they enough to display the error messages?
 Please help! I really do need to trace the errors.

 Thanks,
 jongjong

 __
 Do You Yahoo!?
 Get personalized email addresses from Yahoo! Mail
 http://personal.mail.yahoo.com/




-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP-DB] delay script

2001-06-30 Thread support


Or you could do:

?
 sleep(10); // do nothing for 10 seconds
 header(Location: $url);
?

Then you don't have to hope that the client's browser supports an html
meta tag for refresh.

-- 
Allen Lee
http://MissoulaWeb.com
Hosting, Programming and Design




On Fri, 29 Jun 2001, Michael Rudel wrote:

 Hi Jennifer,

 use my function:

 ?php
// Redirects to another Page using HTTP-META Tag
function redirect( $url, $delay = 0, $message =  )
{
   /* redirects to a new URL using meta tags */
   echo meta http-equiv='Refresh' content='.$delay.; url=.$url.';
   die( div style='font-family: Arial, Sans-serif; font-size: 12pt;' 
align=center .$message. /div );
}
 ?

 ... in your case this will be:

 ?php redirect( login.php, 5, Blogging out/B ); ?

 Hope this helps.

 Greetinx,
   Mike

 Michael Rudel
 - Web-Development, Systemadministration -

 Besuchen Sie uns am 20. und 21. August 2001 auf der
 online-marketing-düsseldorf in Halle 1 Stand E 16
 ___

 Suchtreffer AG
 Bleicherstraße 20
 D-78467 Konstanz
 Germany
 fon: +49-(0)7531-89207-17
 fax: +49-(0)7531-89207-13
 e-mail: mailto:[EMAIL PROTECTED]
 internet: http://www.suchtreffer.de
 ___



  -Original Message-
  From: Jennifer Arcino Demeterio [mailto:[EMAIL PROTECTED]]
  Sent: Thursday, June 28, 2001 11:31 AM
  To: [EMAIL PROTECTED]
  Subject: [PHP-DB] delay script
 
 
  hello!
 
  does anyone knows how to delay a display of a certain page
  ... for example,
  if i will click on logout button, it will show a page which will say
  logging out then after 5 seconds it will redirect to the login page.
 
 
  thanks =)
 
 





-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]