RE: [PHP-DB] PHP form to search MySQL DB

2001-10-23 Thread Peter Lovatt
Hi echo $query; echo mysql_error( $mysql_db_link); is useful for finding query errors (it echos the query itself, and any error message) but the problem here I think is that you are using 'date' as a field name and/or variable name. Try using a name which is not a reserved word. HTH Peter

RE: [PHP-DB] SSL and IE

2001-10-26 Thread Peter Lovatt
it, but this is less than ideal. The only other answer I had was a 'Telephone us with your card details if you can't connect to the secure server' message. This is still relevant to me too, so if anybody else has any answers . Peter Lovatt -Original Message- From: Jonathan

RE: [PHP-DB] Nothing returned

2001-11-03 Thread Peter Lovatt
$sql = SELECT * FROM users WHERE (name='$name') if you are not getting an error, it is usually worth echoing the query SQL echo $sql ; and perhaps trying it manually. Is it possible the quotes around the $name are giving SELECT * FROM users WHERE (name='$name') and not evaluating $name

RE: [PHP-DB] Nothing returned

2001-11-04 Thread Peter Lovatt
To: [EMAIL PROTECTED] Subject: RE: [PHP-DB] Nothing returned Peter Lovatt wrote: $sql = SELECT * FROM users WHERE (name='$name') if you are not getting an error, it is usually worth echoing the query SQL echo $sql ; and perhaps trying it manually. Is it possible the quotes

RE: [PHP-DB] How do i search my database...

2001-11-11 Thread Peter Lovatt
SELECT * from tablename where FIELD_3 = search text will find exact matches SELECT * from tablename where FIELD_3 LIKE search text will find close matches Using % as a wild card will broaden the search SELECT * from tablename where FIELD_3 LIKE search text% will find close matches where the

RE: [PHP-DB] Login Script please?

2001-11-11 Thread Peter Lovatt
If they don't allow external connections then you won't be able to connect directly from UltraDev, only from uploaded scripts. Learn php, write them and run them! Alternatively switch to a host which allows external connections? No quick answers. Peter -Original Message- From:

RE: [PHP-DB] Problem with include()

2001-11-13 Thread Peter Lovatt
Could it be windows doesn't like the '/' in the path. OK on a webpage, but not directly into the filesystem? Peter -Original Message- From: TorrentUK [mailto:[EMAIL PROTECTED]] Sent: 13 November 2001 12:47 To: [EMAIL PROTECTED] Subject: [PHP-DB] Problem with include() Can anyone

RE: [PHP-DB] passing variable through an html email

2002-01-15 Thread Peter Lovatt
Hi Could it be that your message block starts with ' (single quote) so the variables are not evaluated. Variables are only evaluated when using (double quotes) which does not mix well with HTML. try using $message='text and HTMLtag name=zapit'.$variable.' more text and HTML'; Peter

RE: [PHP-DB] tracking users...

2002-01-21 Thread Peter Lovatt
Hi I use $sessionID = md5(uniqid(rand())); setcookie (sessionID , $sessionID ,0 , , ,0); which works hth Peter -Original Message- From: jas [mailto:[EMAIL PROTECTED]] Sent: 22 January 2002 06:51 To: [EMAIL PROTECTED] Subject: [PHP-DB] tracking users... I am fairly new to

RE: [PHP-DB] Ensuring users don't overwrite each other (NOT a newbie question)

2002-02-01 Thread Peter Lovatt
Hi Interesting problem! Systems would be so much easier to build if we didn't have to allow for users :) Two suggestions, depending on how you want the data dealt with. A table of rows in use, with a time stamp and an owner. When user1 opens the record, stamp it with owner and time. If user2

RE: [PHP-DB] Ensuring users don't overwrite each other (NOT a newbie question)

2002-02-01 Thread Peter Lovatt
without this!! Cheers Ollie -Original Message- From: Peter Lovatt [mailto:[EMAIL PROTECTED]] Sent: 01 February 2002 08:10 To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: [PHP-DB] Ensuring users don't overwrite each other (NOT a newbie question) Hi Interesting problem

RE: [PHP-DB] MySQL

2002-02-04 Thread Peter Lovatt
--- Excellence in internet and open source software --- Sunmaia www.sunmaia.net [EMAIL PROTECTED] tel. 0121-242-1473 --- -Original Message- From: Peter

RE: [PHP-DB] If Statement that makes me cry

2002-02-10 Thread Peter Lovatt
hi A few thoughts Firstly wouldn't it be easier to store the resumes in the database? then 'SELECT * from table where cand_resume_text LIKE %keyword[1]% or cand_resume_text LIKE %keyword[2]% bit inefficient but it works, and opening lots of files is also inefficient. or SELECT * from table

[PHP-DB] How is NULL stored?

2002-02-11 Thread Peter Lovatt
Hi When I use phpMyAdmin to view data, where values are NULL it displays the word 'NULL'. Does this mean that the word 'NULL' is actually stored in the table, or is it defined by some other character? Is this any different from an empty value? I am using it to check to see whether a value has

RE: [PHP-DB] Drop Down Menus

2002-02-12 Thread Peter Lovatt
Hi the row index starts at 0 not 1 so you need $row[0], as you have only one field $row[1] will be empty. HTH Peter --- Excellence in internet and open source software --- Sunmaia www.sunmaia.net [EMAIL

[PHP-DB] Logging visits using a database

2002-02-13 Thread Peter Lovatt
Hi Excuse the cross post I am thinking about building a logging tool to do visit analysis using SQL, rather than doing log file analysis. The aim is to analyse requests for dynamic pages called via php as well as static pages. Static pages will use an include for logging. Php calls may have

[PHP-DB] RE: Logging visits using a database

2002-02-14 Thread Peter Lovatt
To: Peter Lovatt; [EMAIL PROTECTED] Subject: RE: Logging visits using a database Hi I have never used it but sounds like analog would fit your needs pretty well. Check them out at: http://analog.sourceforge.net/ Hope this helps.. Gurhan -Original Message- From: Peter Lovatt

RE: [PHP-DB] Logging visits using a database

2002-02-14 Thread Peter Lovatt
On Thursday 14 February 2002 07:29, Peter Lovatt wrote: Hi Excuse the cross post I am thinking about building a logging tool to do visit analysis using SQL, rather than doing log file analysis. The aim is to analyse requests for dynamic pages called via php as well as static

RE: [PHP-DB] Disable Right click w/ php?

2002-02-14 Thread Peter Lovatt
Hi I don't think it is possible without javascript, and it does not always work with javascript. Anybody with any real knowledge can bypass it anyway simply by saving the page and opening it in a text editor. So Javascript will stop casual right clickers, and the others will do it anyway, if

RE: [PHP-DB] Passing form values with quotes, to itself

2002-02-14 Thread Peter Lovatt
Hi I spent ages trying to get it to work. Echoing the always closes the text area in an input box, so any data after the quotes isn't displayed. Its fundamental to the HTML, so adding slashes is irrelevant. What I did in the end was to swap double quotes for two single quotes '' using

RE: [PHP-DB] PHP IDE

2002-02-24 Thread Peter Lovatt
Not an IDE as such but a good text editor Homesite has good php syntax colouring, which picks up missing quote marks. Its commercial, but good. http://www.macromedia.com/software/homesite/ HTH Peter --- Excellence in internet and open source

RE: [PHP-DB] The Debacle

2002-02-24 Thread Peter Lovatt
When you add the data //does it begin with 'The '? $name_start = substr($band_name, 0, 2) if ($name_start==The) { //remove the word 'The' and following space from the beginning of the string str_replace('The ', '', $band_name) ; //add ', The 'to the end of the name

RE: [PHP-DB] If else trouble

2002-02-24 Thread Peter Lovatt
Hi -Original Message- From: Jennifer Downey [mailto:[EMAIL PROTECTED]] Sent: 24 February 2002 22:28 To: [EMAIL PROTECTED] Subject: [PHP-DB] If else trouble Hi all, I have worked and re-worked this if else statement. I can't get it to work. It's suppose to work like this.

RE: [PHP-DB] Best way to store/retrieve content??

2002-03-07 Thread Peter Lovatt
Hi I have done a similar thing, and found that you can store just the text in the database. I added 'Short_content' which was a leader, and some other fields for management. I designed a few templates in Dreamweaver and embeded a function to display the content in the page eg trtd?php

RE: [PHP-DB] Best way to store/retrieve content??

2002-03-07 Thread Peter Lovatt
PROTECTED] (Peter Lovatt) Newsgroups: php.db Date: Thu, 7 Mar 2002 20:11:00 - To: Monty [EMAIL PROTECTED], [EMAIL PROTECTED] Subject: RE: [PHP-DB] Best way to store/retrieve content?? Hi I have done a similar thing, and found that you can store just the text in the database. I

RE: [PHP-DB] Storing sesssions in a db bad for the performance?

2002-03-11 Thread Peter Lovatt
Hi I do this and have no problems. I don't have two similar sites to compare , but performance seems fine. HTH Peter --- Excellence in internet and open source software --- Sunmaia www.sunmaia.net [EMAIL

RE: [PHP-DB] A text file include ?

2002-03-25 Thread Peter Lovatt
hi try nl2br hth Peter --- Excellence in internet and open source software --- Sunmaia www.sunmaia.net [EMAIL PROTECTED] tel. 0121-242-1473 --- -Original

RE: [PHP-DB] Re - Direct a User after a completed Form

2002-03-31 Thread Peter Lovatt
?php {do submit data routine} include(thanks.htm) ? should do the trick HTH Peter --- Excellence in internet and open source software --- Sunmaia www.sunmaia.net [EMAIL PROTECTED] tel. 0121-242-1473

FW: [PHP-DB] need some help...

2002-04-02 Thread Peter Lovatt
hi Alex basically you load a variable with the contents of the page, and then write the contents of the variable to the file hope this helps Peter ?php //load page contents into a variable then write to file $retval.=' div align=left table border=0 cellpadding=0

RE: [PHP-DB] How to avoid: Warning: Page has Expired

2002-04-09 Thread Peter Lovatt
If you change the form action to 'get' instead of 'post' this avoids the message. form action=script.php3 method=get 'Get' data is displayed on the address line eg http://domain.com/script.php3?photoID=123viewtype=full so it should be avoided for sensistive data like passwords or credit card

RE: [PHP-DB] Re: security/setup question: php3 script contains db password, but scriptmust be readable by nobody: any solution?

2002-04-11 Thread Peter Lovatt
The only answer I know is in the php config, which you may not have acces to. php can be configured to run as the owner of the script that calls it. This means only your scripts can read your files. This is not the default option, and most ISPs just run the default, so your password is available

RE: [PHP-DB] Definitive answer for large scale registration/authentication

2002-04-16 Thread Peter Lovatt
hi Depends a little on what you are doing next. I am not an htaccess expert so this is written as a 'sessions' user, but if you use a database/session system you have a lot of flexibility, and can log what users are up to. If it is well programmed, with security in mind you can make it very

RE: [PHP-DB] Import/Export data

2002-04-18 Thread Peter Lovatt
Hi The most universal way would be to export the table to CSV format. You can then use LOAD DATA INFILE phpMyAdmin to load it into the database. http://www.mysql.com/doc/L/O/LOAD_DATA.html HTH Peter --- Excellence in internet and open source

RE: [PHP-DB] page expires

2002-04-18 Thread Peter Lovatt
Add META HTTP-EQUIV=expires CONTENT=0 META HTTP-EQUIV=Pragma CONTENT=no-cache to your header, which will tell the browser not to cache the page, and use the POST method form action=script.php name=entryform method=post HTH Peter --- Excellence in

RE: [PHP-DB] Updating Many Records

2002-04-18 Thread Peter Lovatt
IF there is a formula for the value of quantity eg Quantity = Quantity -1 (UPDATE table SET Quantity = Quantity-1 ) you need to do an update statement for each row EG UPDATE table SET Quantity = 9 WHERE Field = Book3 HTH Peter --- Excellence in

RE: [PHP-DB] Updating Many Records oops

2002-04-18 Thread Peter Lovatt
--- Sunmaia www.sunmaia.net [EMAIL PROTECTED] tel. 0121-242-1473 --- -Original Message- From: Peter Lovatt [mailto:[EMAIL PROTECTED]] Sent: 18 April 2002 23:30 To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: [PHP-DB] Updating Many Records

RE: [PHP-DB] Passwords

2002-04-23 Thread Peter Lovatt
Basically you need first to authorise the user. Check the username and password against an entry in a user table in the database. If you are using sessions set a variable that makes the session authorised, you are not using sessions then you need some sort of session management. (I have the

RE: [PHP-DB] Weird Windows SQL

2002-04-24 Thread Peter Lovatt
have you set up permissions for the user you are connecting as? see GRANT in the MySql manual. The test bit is a default setting for users with no privileges (from my slightly rusty memory) HTH Peter --- Excellence in internet and open source

[PHP-DB] UK based php/mysql programmers

2002-04-29 Thread Peter Lovatt
Hi I am bidding for a big project scheduled for the end of May. If it comes off I will need an extra pair of hands, or perhaps two. Some UK specific knowledge/content which is why UK based matters, no offence to anyone else :) Anybody interested in working for/with me? Rates and URLs to

FW: [PHP-DB] Using functions in SELECT statements

2002-05-02 Thread Peter Lovatt
Could it be the second $ in the lower('%$SearchBox$%') ? Peter --- Excellence in internet and open source software --- Sunmaia www.sunmaia.net [EMAIL PROTECTED] tel. 0121-242-1473

RE: [PHP-DB] Easy one for you guru's :-)

2002-05-11 Thread Peter Lovatt
I have one that uses a database, is that any use, or do you specifically want a php session based bit of coding?? Peter --- Excellence in internet and open source software --- Sunmaia www.sunmaia.net [EMAIL

RE: [PHP-DB] Open file dialog box to save static file

2002-05-12 Thread Peter Lovatt
Hi you can use php to write the html to a file, rather than having to do it all manually. Look at fopen() Not sure if this is exactly what's needed, but it might be. HTH Peter --- Excellence in internet and open source software

RE: [PHP-DB] mssql_fetch_array not working?

2002-05-13 Thread Peter Lovatt
well spotted :) --- Excellence in internet and open source software --- Sunmaia www.sunmaia.net [EMAIL PROTECTED] tel. 0121-242-1473 --- -Original

RE: [PHP-DB] Fames Included?

2002-05-25 Thread Peter Lovatt
Hi just use a frameset with php pages in FRAMESET ROWS=210,* FRAMESPACING=0 FRAMEBORDER=0 border=0 FRAME SRC=top.php3 NORESIZE=NORESIZE NAME=top scrolling=no FRAMESET COLS=130,* FRAMESPACING=0 FRAMEBORDER=0 BORDER=0 FRAME SRC=left.php3 NORESIZE=NORESIZE NAME=s_main FRAME SRC=main.php3

RE: [PHP-DB] HUGE problem here

2002-06-08 Thread Peter Lovatt
DELETE FROM auth WHERE name=$deletename LIMIT 1; needs quotes DELETE FROM auth WHERE name='$deletename' LIMIT 1; This may be the problem. HTH Peter --- Excellence in internet and open source software

RE: [PHP-DB] Re: password()... is it possible?

2002-06-22 Thread Peter Lovatt
Hi PASSWORD() is not reversible, but ENCRYPT() might be worth a look. Are you sure you want unencrypted passwords on view? If you have a security breach, which can include a sacked or unhappy sys admin, who wants to hit back, then you could have a very uncomfortable situation! Better to go with

RE: [PHP-DB] Question

2002-06-23 Thread Peter Lovatt
Hi The correct way, IMHO, would be to consider the situation. The hard drives are a sub component of the computer. In which case the hard drive table should be a 'child' of the computer table. However the hard drives could be an item in their own right too. So if you want to consider the hard

RE: [PHP-DB] PHP and msql Error

2002-06-26 Thread Peter Lovatt
Hi With MySql that means that there is no result returned. Usually SQL error, but could be a setup problem if you have not run any queries succesfuly. Not sure if the same applies to MSql, but try echoing the error, echo msql_error($conn) (if it is the same as MySql) HTH Peter

[PHP-DB] XML

2002-06-27 Thread Peter Lovatt
Hi I am looking at a project using XML to import and export data into MySql directly or using php. The datasets are quite large (40-50 million records) I haven't used XML before. Does it take long to work out how to use php/XML? Are there any problems working with large datasets? Thanks

RE: [PHP-DB] encryption of critical data

2002-06-27 Thread Peter Lovatt
HI If you are using MySql look at ENCODE() on mysql.com http://www.mysql.com/doc/M/i/Miscellaneous_functions.html Most databases support some sort of encryption. Encrypting by php is probably more secure - somebody might be able to sniff data going to the database if it still plain text, but

RE: [PHP-DB] Excel to MySQL??

2002-06-29 Thread Peter Lovatt
Hi from Excel export to csv use phpMyAdmin to load it into mysql (recent versions of phpMyAdmin has an Excel import function) HTH Peter --- Excellence in internet and open source software --- Sunmaia

RE: [PHP-DB] Storing passwords in a database

2002-06-30 Thread Peter Lovatt
Hi Retrieving lost passwords is a lot less hassle than a setting up a new one, for the user. IMHO a job site would be better with more convenience and less security. So I would go for option 1 - encrypt / decrypt If you were storing very sensitive information then go for option 2. Peter

RE: [PHP-DB] MySQL test database creation...

2002-07-05 Thread Peter Lovatt
hi If the database is not too much data you can export using phpMyAdmin and select 'complete inserts' which generates complete queries. you could also do INSERT INTO db_2.tablename SELECT * FROM db_1.tablename if both databases are on the same server. There may be better answers, but these

RE: [PHP-DB] Newbie Reminder on HTML Variable Passing - quick fix

2002-07-07 Thread Peter Lovatt
# # # # # #This module copyright SunMaia.net 1999-2002# # author Peter Lovatt [EMAIL PROTECTED] # # # #http://www.sunmaia.net for full licence terms

RE: [PHP-DB] disable backbutton

2002-07-07 Thread Peter Lovatt
Hi if you add META HTTP-EQUIV=expires CONTENT=0 META HTTP-EQUIV=Pragma CONTENT=no-cache to your header that should stop the browser caching and if you do all your links using a form with the method set to 'post' that should stop people using the back button HTH Peter

RE: [PHP-DB] catch warnings?

2002-07-10 Thread Peter Lovatt
look at http://www.php.net/manual/en/function.mssql-get-last-message.php Peter --- Excellence in internet and open source software --- Sunmaia www.sunmaia.net [EMAIL PROTECTED] tel. 0121-242-1473

RE: [PHP-DB] Good mysql abstraction layer class?

2002-08-16 Thread Peter Lovatt
Hi If you want power take a look at Metabase, it covers most major DBs with a single interface. If you want simple, but functional, contact me offlist and I will send you mine, which works well. Peter --- Excellence in internet and open source

FW: [PHP-DB] how to hide source code??

2002-08-29 Thread Peter Lovatt
hi Basically the answer is no. However Zend (www.zend.com) produce commercial software which compiles the php, making it run faster and the source unreadable, but it is not cheap so you need a good enough reason to spend the money. On the other hand it is the commercial arm of php so you are

RE: [PHP-DB] Help with code

2002-08-29 Thread Peter Lovatt
Hi try echoing the actual query, after the variables have been converted to values $qtrans = insert into $tbltrans values('0', 'daily', '$building', '$itemchoice', '0', '$count', '0', '$ddate', '$cat'); echo $qtrans ; and see if a comma or quote mark is in

RE: [PHP-DB] Kudos

2002-08-30 Thread Peter Lovatt
Hi I will second that and add MySql to the list. I love the power and stability and the confidence these two give. I started building sites at a time when the costs of M$ software were beyond my means and perl was beyond my abilities :) Now I feed my kids and keep a roof over our heads using

RE: [PHP-DB] not a valid MySQL result

2002-09-06 Thread Peter Lovatt
Hi Couple of points, you probably have an SQL error, I use echo $query; echo 'br'.mysql_error(); which shows the query and the error you use 'author-cat' in the table name and 'author_cat' and 'author-cat' in the where clause which will throw an error. HTH Peter

RE: [PHP-DB] Can't see the results

2002-09-07 Thread Peter Lovatt
Hi you are using mysql_fetch_array which returns an array indexed by field name eg $row = mysql_fetch_array($result) $row[Author] will be 'fred bloggs' you are indexing using a number which needs mysql_fetch_row suggested simplified code is I have named the resulting field as

RE: [PHP-DB] Problem with SQL

2002-09-08 Thread Peter Lovatt
hi It is trying to insert the value '127' into a key field (or indexed field) when it already has a record with '127' in that field. You may know it as a key violation It means you are trying to insert a record with a duplicate primary key HTH Peter

RE: [PHP-DB] Form response

2002-09-21 Thread Peter Lovatt
Missed most of the thread, so hope this hits the mark! If one form works and one doesn't are they both called .php ? If one is .php3 and one .php and the webserver is only configured to parse onr then the other will show as plain text. just a thought Peter

RE: [PHP-DB] Variables coming from forms

2002-09-22 Thread Peter Lovatt
could be a register globals issue? Peter --- Excellence in internet and open source software --- Sunmaia www.sunmaia.net tel. 0121-242-1473 --- -Original

RE: [PHP-DB] export to csv file

2002-09-28 Thread Peter Lovatt
If you are using *nix set the file, or directory permissions recursively, to 777. If you want to let the users download the file it may be simpler to generate the content and send it directly to them when they click on a link. http://www.phpbuilder.com/mail/phplib-list/2001062/0017.php

RE: [PHP-DB] Security

2002-10-23 Thread Peter Lovatt
check http://www.mysql.com/doc/en/Miscellaneous_functions.html it covers a number of options Peter --- Excellence in internet and open source software --- Sunmaia www.sunmaia.net tel. 0121-242-1473

RE: [PHP-DB] database synchronization

2002-10-29 Thread Peter Lovatt
Hi Take a look at replication http://www.mysql.com/doc/en/Replication.html HTH Peter --- Excellence in internet and open source software --- Sunmaia www.sunmaia.net tel. 0121-242-1473

RE: Re[2]: [PHP-DB] database synchronization

2002-10-29 Thread Peter Lovatt
--- Sunmaia www.sunmaia.net tel. 0121-242-1473 --- -Original Message- From: Martin Hudec [mailto:corwin;corwin.sk] Sent: 29 October 2002 08:44 To: Peter Lovatt Cc: [EMAIL PROTECTED] Subject: Re[2]: [PHP-DB

RE: Re[4]: [PHP-DB] database synchronization

2002-10-29 Thread Peter Lovatt
--- -Original Message- From: Martin Hudec [mailto:corwin;corwin.sk] Sent: 29 October 2002 09:18 To: Peter Lovatt Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re[4]: [PHP-DB] database synchronization Hello Peter, okay :)))so far I understand...buthmmm let me

RE: [PHP-DB] Connecting to DB on separate server?

2002-11-04 Thread Peter Lovatt
Hi You need to pinpoint where the break in communication is. Does php connect ok to a database on the local machine? no - php or local MySql config problem? yes - can you ping the database server from the php server? no - network problem yes -MySql problem -is MySql running

RE: [PHP-DB] Connecting to DB on separate server?

2002-11-04 Thread Peter Lovatt
Also the following might give a more useful error message $link=mysql_connect($hostname, $user, $pass) echo mysql_errno() . : . mysql_error(). \n; Peter --- Excellence in internet and open source software

[PHP-DB] FW: php J2EE .NET

2002-11-06 Thread Peter Lovatt
Hi There is an article on sitepoint.com about benchmarking J2EE and .NET and some controversy over the result http://www.sitepoint.com/newsletters/viewissue.php?fid=3id=3issue=52 Does anybody have experience of php/MySql in comparison with either of the above in terms of efficiency or ultimate

RE: [PHP-DB] ROugh idea of speed

2002-11-09 Thread Peter Lovatt
Hi I have been following the thread and I am interested in the limits of MySql. I have a site which is growing. The biggest tables are currently about 750K but this will grow to the 3-10M record mark over the next 6 months. The databases are well designed and are currently running smoothly on

[PHP-DB] MySql limits - WAS [PHP-DB] ROugh idea of speed

2002-11-11 Thread Peter Lovatt
Hi I am interested in the limits of MySql. I have a site which is growing. The biggest tables are currently about 750K but this will grow to the 3-10M record mark over the next 6 months. The databases are well designed and are currently running smoothly on 2x1GHz PIII and 512MB RAM. I am

RE: [PHP-DB] Pull Word Docs

2002-11-13 Thread Peter Lovatt
Hi If the webserver is delivering the doc you need the path relative to the document, not the server file system. If the word doc is off the web root I think a href=get_doc.php?doc=proc1.docProcedure/a and get_doc.php is (assuming linux file system) ?php include

RE: [PHP-DB] Fastest, easiest Flatfile DB with PHP

2002-11-18 Thread Peter Lovatt
Hi If you have a lot of queries then use a database. If 'the frequency and number of queries are really massive so ' is a typo I am still not sure it's worth the hassle Peter --- Excellence in internet and open source software

RE: [PHP-DB] autoupload

2002-11-22 Thread Peter Lovatt
A little more detail Install MyODBC - you will need it on all machines In Access File - Get external data - Link tables -ODBC data sources - MyODBC data source You now have a direct link from Access to MySql and can run an Access query to load the data straight into MySql. I did this a while

RE: [PHP-DB] mysql problem

2002-11-28 Thread Peter Lovatt
Hi you need quotes around the values mysql_query(insert into tblquotehits (qoption,referer,browser,remoteaddr,dt) values ('$quotetype','$referer','$browser','$remoteaddress','$currentdtstring'),$d b); HTH Peter --- Excellence in internet and open

RE: [PHP-DB] Special URL Verification String...

2002-12-04 Thread Peter Lovatt
The %7 and similar are used in URL encoding to represent illegal characters such as spaces and others - these are translated when the user clicks to open the URL, giving the string you get back. I think Peter --- Excellence in internet and open

RE: [PHP-DB] Special URL Verification String... PS

2002-12-04 Thread Peter Lovatt
Hi PS I would use $verify_string = md5(uniqid(rand())); to generate a random identifier of the sort you are looking for Peter --- Excellence in internet and open source software --- Sunmaia Birmingham UK

RE: [PHP-DB] Users on line

2003-01-03 Thread Peter Lovatt
Hi My bank uses two processes. If a user is inactive for more than about 5 minutes it forces you to log in again. This is done server side and just does not allow you to do anything if your last activity was more than 5 minutes ago. It probably also marks the session as logged out. It also uses

RE: [PHP-DB] Users on line

2003-01-03 Thread Peter Lovatt
-242-1473 International +44-121-242-1473 --- -Original Message- From: Matthew Moldvan [mailto:[EMAIL PROTECTED]] Sent: 03 January 2003 22:24 To: 'Peter Lovatt'; Bernain, Fernando G.; 'Peter Beckman'; Hutchins, Richard Cc: [EMAIL PROTECTED] Subject

RE: [PHP-DB] PHP-DB - ot browser compatibility

2003-01-23 Thread Peter Lovatt
Hi I test on NS 4.75 and IE4 as a minimum browser spec. I test on the following IE 4, 5, 5.5, 6.0 NS 4.75, 7 (NS 6 has very low distribution and flaky table handling ) Opera 5.0 and 6.0 Mozilla 1.1 Presentation in IE5+ must be perfect. I tolerate minor layout problems in the other browsers,

RE: [PHP-DB] need help spotting this php parse error

2003-01-23 Thread Peter Lovatt
Hi Probably a missing ; ? option value=? echo $row[0]; ?? echo $row[1]; echo $row[2]; ?/option ? } ; - here ? /select /form -Original Message- From: Ignatius Reilly [mailto:[EMAIL PROTECTED]] Sent: 23 January 2003 22:00 To: David Rice;

RE: [PHP-DB] Cutting strings

2003-01-26 Thread Peter Lovatt
Hi from the manual http://www.mysql.com/doc/en/String_functions.html LEFT(str,len) Returns the leftmost len characters from the string str: mysql SELECT LEFT('foobarbar', 5); - 'fooba' HTH Peter -Original Message- From: Chezney [mailto:[EMAIL PROTECTED]] Sent: 26

RE: [PHP-DB] first 10 or so words

2003-02-13 Thread Peter Lovatt
try SUBSTRING http://www.mysql.com/doc/en/String_functions.html Peter -Original Message- From: Bruce Levick [mailto:[EMAIL PROTECTED]] Sent: 13 February 2003 22:23 To: [EMAIL PROTECTED] Subject: [PHP-DB] first 10 or so words Howdy, I have a SELECT query displaying the results in

RE: [PHP-DB] processing status page help

2003-02-15 Thread Peter Lovatt
htmlmeta http-equiv=refresh content=10;URL=http://www.mysite.com/newpage.php;body bgcolor=#ff please wait. bodyhtml should work - the 10 is the delay Peter -Original Message- From: Brendon [mailto:[EMAIL PROTECTED]] Sent: 15 February 2003 22:14 To: [EMAIL PROTECTED]

RE: [PHP-DB] processing status page help

2003-02-15 Thread Peter Lovatt
or perhaps more comprehensively ?php print(' htmlmeta http-equiv=refresh content=10;URL=http://www.mysite.com/newpage.php;body bgcolor=#ff please wait. bodyhtml ') //start the processing here do this; do that; do the other ; ? should work but I am not absolutly sure - try it

RE: [PHP-DB] Parse Error

2003-02-26 Thread Peter Lovatt
if ($packages == 1){ if ($airporttransfer == car){ $airporttransfer2 = 12.00}; if ($airporttransfer == bus){ $airporttransfer2 = 10.00}; if ($airporttransfer == none){ $airporttransfer2 = 0.00}; }; () round brackets round the condition {} braces around the 'do it' bit :) HTH Peter

RE: [PHP-DB] Related to WAR - 1

2003-03-29 Thread Peter Lovatt
Hi There are many aspects to this complex political mess, most of us will have views on it, and there are plenty of places to discuss it. This is the wrong place. I would echo David's comments Keep it off php lists Thanks Peter -- PHP Database Mailing List (http://www.php.net/) To

RE: [PHP-DB] INSERT Question

2003-03-29 Thread Peter Lovatt
Hi you need to create 5 selects, all named investigator[] with index 1-5 (or 0-4), with the option set to empty for no selection. this will return an array investigator[1] = '1064618047' investigator_yesno[1] = 'Y' investigator[2] = '1649815377' investigator_yesno[2] = 'N' for example form

RE: [PHP-DB] MySql Help needed

2003-03-30 Thread Peter Lovatt
Hi Try running a grant query GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,DROP,ALTER ON database_name.* TO [EMAIL PROTECTED] IDENTIFIED BY 'mypassword'; which will probably fix it Peter -Original Message- From: Sparky Kopetzky [mailto:[EMAIL PROTECTED]

RE: [PHP-DB] Select Statement with output in different colors.

2003-06-17 Thread Peter Lovatt
Try this $query = 'SELECT * FROM table $mysql_result = mysql_query($query, $link); while($row = mysql_fetch_array($mysql_result)) { switch ($row[event] ) { case event_one: $bg = 'blue' break;

RE: [PHP-DB] Page Use

2003-06-23 Thread Peter Lovatt
use sessions and a database table enter page name and timestamp it for each page request Analyse from the timestamp order and the time difference. Let me know if you want more details HTH Peter -Original Message- From: Tim Winters [mailto:[EMAIL PROTECTED] Sent: 23 June 2003 13:06

RE: [PHP-DB] Query problem

2003-07-22 Thread Peter Lovatt
select * from ticket where Type = 'Line' and (Closeddate IS NULL OR Closeddate ='') or select * from ticket where Type = 'Line' and Closeddate IS NULL HTH Peter -Original Message- From: Ron Allen [mailto:[EMAIL PROTECTED] Sent: 22 July 2003 10:29 To: [EMAIL PROTECTED] Subject: [PHP-DB]

RE: [PHP-DB] write to word..

2003-07-23 Thread Peter Lovatt
Hi I did it like this ?php //create file here //then output it header (Content-type: application/msword); header (Content-Disposition: attachment; filename=letter.doc); include('letter.htm'); print('done it') ? I wrote the letter to file and then

RE: [PHP-DB] MySQL Session

2003-07-27 Thread Peter Lovatt
Hi welcome to php :) in general you can use an include at the beginning of each page ?php include('database_conn.php' ) ; $query = 'select * from table' $result = ($query, $link) ? -Original Message- From: Morten Twellmann [mailto:[EMAIL PROTECTED] Sent: 27 July 2003 13:01 To:

RE: [PHP-DB] un-encrypting passwords

2003-07-28 Thread Peter Lovatt
mysql has ENCRYPT() which will do the job Peter -Original Message- From: Sam Folk-Williams [mailto:[EMAIL PROTECTED] Sent: 28 July 2003 21:05 To: [EMAIL PROTECTED] Subject: [PHP-DB] un-encrypting passwords Hi, I've got a PHP/MySQL site that uses a simple user table to check for a

RE: [PHP-DB] mysql connect error

2003-08-14 Thread Peter Lovatt
Hi Check the database name is exactly the same case as you are using - not Soverign rather soverign for example. After that try the raw php functions for connecting to the database ?php //require_once 'DB.php'; $user = 'jbyrne'; $pass = ''; $host = 'localhost'; $db_name = 'sovereign'; if($dsn

  1   2   >