[PHP] Re: help avoid multiple login

2005-11-30 Thread Mark Rees
the normal way of doing session 'closing' is by way of 'garbage collection' - every now and then a script/process/function is run that 'closes' any sessions which are (according to your criteria) inactive. php has stuff built it that will do this for you to a degree. - Is there a way I

[PHP] Re: Autodeleting news when it has become yesterdays news

2005-11-23 Thread Mark Rees
I have a news-script on a webpage. Or an eventscript you might call it. This lists up events thats gonna happen on a given day. ie concerts and sportsevents. To get this deleted without having to log on to the adminpage when the event is over would have been a great relief. 1. Is it just as

[PHP] Re: undefined index and php

2005-11-10 Thread Mark Rees
I tried this to set the value... if (!isset($_POST['heading'])) { $_POST ['heading'] = ; } because the following line give the notice 'undefined index' BEFORE the submit button has been pressed.. ? $heading_insert= stripslashes($_POST['heading']);? What everyone else said, but also:

[PHP] Re: PHP and files Upload

2005-10-19 Thread Mark Rees
the script always says it was sucessful to upload the file, but the destination directory was always empty... even when checking the $_FILES global $_FILES['var_name']['tmp_name'] and $_FILES['var_name']['name'] and $_FILES['var_name']['size'], the vars alwyas return empty values... is

[PHP] Re: Help needed / failed to open stream: Permission denied

2005-10-19 Thread Mark Rees
This is line 57 $file_handle = fopen(./ . $file_name, r); It seems that the user your web server runs as may not have permission to open that file. Also, you might want to double check that ./$ile_name is a valid path. And if you're planning to write to the file, you need to specify that.

Re: [PHP] Uploaded CSV - database

2005-10-18 Thread Mark Rees
This discussion is starting to go over my head, but fgetscv works with uploaded files (in PHP5 anyway). Here's some sample code: if(isset($_FILES['userfile']['tmp_name'])){ $csvfile=fopen($_FILES['userfile']['tmp_name'],rb); if($csvfile==FALSE){die('error opening file');};

[PHP] Re: a couple of problems with PHP form

2005-10-17 Thread Mark Rees
- sorry, my editor has not indented again - also, I want the field to appear hilighted when there is no information so I am doing this: input class=? if($error_msg){ echo error; } ELSE { echo

Re: [PHP] Uploaded CSV - database

2005-10-17 Thread Mark Rees
-Original Message- From: Jim Moseby [mailto:[EMAIL PROTECTED] Sent: Monday, October 17, 2005 10:41 AM To: 'Brian Dunning'; php-general@lists.php.net Subject: RE: [PHP] Uploaded CSV - database -Original Message- From: Brian Dunning [mailto:[EMAIL PROTECTED]

[PHP] Re: Connecting to MySQL Sever using PHP5

2005-10-13 Thread Mark Rees
I have just installed PHP5. I am using Windows XP and have already installed MySQL. When I try and make a connection to a database on MySQL via Dreamweaver I get the following error message: An unidentified error has occurred. What could be wrong Have a look at this:

Fw: [PHP] Re: Connecting to MySQL Sever using PHP5

2005-10-13 Thread Mark Rees
Back to the list - please use reply-all - Original Message - From: Andreja Simovic [EMAIL PROTECTED] To: Mark Rees [EMAIL PROTECTED] Sent: Thursday, October 13, 2005 9:58 AM Subject: Re: [PHP] Re: Connecting to MySQL Sever using PHP5 Sometimes this error may ocure if you do not place

[PHP] Re: Userlogin system seems to override the if statement....

2005-10-12 Thread Mark Rees
- sorry my mail reader didn't indent. comments in -- I'm new to this. So I used a tutorial to write this. But it shows Login ok. Welcome at once when the page loads. Here is the tutorial:

Re: [PHP] How do I POST data with headers make the browser follow?

2005-10-10 Thread Mark Rees
basically what I am working on is integrating a step inbetween the checkout and the payment gateway processing. The cardholder information is checked for enrolment in the first step, if the cardholder is enrolled he will need to authenticate himself by password (this is where the 2nd page

Re: [PHP] Testing a String for 'most' Capitalised

2005-10-10 Thread Mark Rees
Image that there could be a string fred Fred FRED It isn't hard to do. First of all I need to know that these are same which I can do with strtolower Also note strcasecmp for this task - http://uk2.php.net/manual/en/function.strcasecmp.php -- PHP General Mailing List

Re: [PHP] How do I POST data with headers make the browser follow?

2005-10-07 Thread Mark Rees
The information that comes in from the first page is a creditcard form with the standard values (CCnumber, Expiry Date, Cardholder name etc). On page 2 an XMLrequest is done with a verification gateway (in this case to check for enrolment in 3D-Secure), the result for that I get back on the

[PHP] Re: mail() with port authentication

2005-10-06 Thread Mark Rees
Do I need to use Pear to specify port 587 and authentication when sending mail? I could not find any way to do it using mail(). Windows or Unix? On Windows you can set the port by setting smtp_port in php.ini. Unix doesn't appear to have a direct equivalent, but you might be able to do

Re: [PHP] How do I POST data with headers make the browser follow?

2005-10-06 Thread Mark Rees
1. Take POST data from a form (no problem) 2. Do whatever i need to on the target page (no problem) 3. Pass some other data on to a 3rd page as a POST request. 4. Get the browser to follow to said 3rd page. All this is happening via SSL. What the other people said about HTTP. It's

[PHP] Re: PHP and Active Directory

2005-10-03 Thread Mark Rees
How do I connect a php script running on linux with Active Directory on a windows machine? I would like to have my php script autmotatically read email addresses from the AD server. Can this be done? I've found a bunch of ldap functions for php but they seem to require ldap to be installed on

[PHP] Re: Array Select from database

2005-09-28 Thread Mark Rees
Array ( [count] = 1 [0] = Array ( [clientaccountmanager] = Array ( [count] = 2 [0] = 210 [1] = 149 ) I've got the following Query=select * from client WHERE clientaccountmanager='$value of array1' OR '$2nd value of array 1' So that the query loops through the whole array...

[PHP] is_dir paths

2005-09-26 Thread Mark Rees
Hello I am having trouble with is_dir I am trying to check whether /lists/admin/temp exists (which it does). However, I cannot get the function to work by specifying the path as above - it only works if I do it relative to the current working directory. So: var_dump (is_dir(getcwd()));

[PHP] is_dir paths

2005-09-26 Thread Mark Rees
Hello I am having trouble with is_dir I am trying to check whether /lists/admin/temp exists (which it does). However, I cannot get the function to work by specifying the path as above - it only works if I do it relative to the current working directory. So: -- www.itsagoodprice.com -

Re: [PHP] is_dir paths

2005-09-26 Thread Mark Rees
what does the following output: var_dump (getcwd()); This outputs a fully qualified path to the current working directory (/lists/admin) Not sure about the permissions. I'm using windows 2000, and the 'temp' directory has the same user permissions as the rest of the htdocs foler I have

Re: [PHP] is_dir paths

2005-09-26 Thread Mark Rees
what does the following output: var_dump (getcwd()); Sorry, this wasn't clear. I mean it outputs c:\...\htdocs\lists\admin Not sure about the permissions. I'm using windows 2000, and the 'temp' directory has the same user permissions as the rest of the htdocs folder what does the

Re: [PHP] is_dir paths

2005-09-26 Thread Mark Rees
var_dump (realpath('temp')); I am trying to check whether /lists/admin/temp exists (which it does). This dir doesn't exists. The '/' at the beginning of path means: path is from root (unix) or from e.g. c:\ (windows) Outputs from var_dump(realpath(../../lists/admin/temp))

Re: [PHP] is_dir paths

2005-09-26 Thread Mark Rees
echo 'pre', var_dump( $_SERVER ), '/pre'; for instance I cut/paste the following from an application of my, the code lives in a centrally included file: /* define a webroot basepath for the datasyncer module */ define('DS_WEBROOT', realpath(dirname(__FILE__).'/..')); dirname! That's the

[PHP] Re: curl version and PHP docs

2005-09-19 Thread Mark Rees
To put the question more simply, is there any way of finding out what versions of the PHP modules ship with each/the latest release, short of installing that version of PHP? Some release notes, for example? Thanks in advance -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

[PHP] Re: REGEX Help Please

2005-09-19 Thread Mark Rees
I am trying to implement a regular expression so that I have a number between 0.00 and 1.00. the following works except I can go up to 1.99 $regexp = /^[0-1]{1}.[0-9]{2}/; You could always do this, unless you are set on using a regular expression: if($num=0 $num=1.01){ echo

[PHP] Re: Problem with mysql_connect(...)

2005-09-19 Thread Mark Rees
I'm trying to connect to my MySQL server with mysql_connect(...). The server is up and running, and I'm running Apache with PHP properly installed. : --- But have you got the mysql extension? put this in a script ?php phpinfo(); ? and view the output to check

[PHP] curl version and PHP docs

2005-09-16 Thread Mark Rees
Hello I need version 7.14 of curl, as it contains a bug fix for my environment (behind an ISA proxy server). phpinfo tells me that my current version is 7.11.2, and I'm running PHP 5.0.4 As I am running Windows, and have neither the software nor the skills to compile my own dlls (the suggested

Re: [PHP] mysql query

2005-09-15 Thread Mark Rees
On Wednesday 14 September 2005 07:36 pm, Jesús Alain Rodríguez Santos wrote: I have a table colum in mysql with two fields: day and month. I would like to know if it's possible to make a query where I can determine if exist days before to a selected day, for example: if I have in my table:

Re: [PHP] Re: PHP 5, LDAP/Active Directory

2005-09-14 Thread Mark Rees
On my server I'm running: Fedora Core 4 Apache 2 PHP 5 compiled with OpenLDAP To shed more light on the topic, bug #30670 [ http://bugs.php.net/ bug.php?id=30670edit=0 ] seems to fit my situation perfectly. As some of the posts on that bug suggest, I've tried using

Re: [PHP] whats wrong in this program.

2005-09-14 Thread Mark Rees
I tried to use the final array values in a insert statement, but the values are not inserted. the code is foreach ($final as $subnum){ $res = $db-query(INSERT INTO substrate_protocoll(substrate_type,substrate_num,operator,location,solvent,u ltrasonic,duration,cdate,ctime,comment)

[PHP] Re: PHP 5, LDAP/Active Directory

2005-09-13 Thread Mark Rees
I've looked through php.net and scoured Google for a solution to an issue I'm having with PHP and LDAP but have so far found nothing. I'm trying to build an intranet site that uses the company LDAP (Active Directory really) service but I can't seem to get around the Operations error and other

[PHP] Re: Round with ONE-decimal... always...

2005-09-12 Thread Mark Rees
I want to adjust the round() -function a little... If I put round(6,0) there will be an output of 6 If I put round(6,32) there will be an output of 6,3 I want it to have 6,0 instead of just 6... I guess there is an easy solution to this? Suggestions? Have a look at this.

[PHP] Re: Best way to mass mail

2005-09-12 Thread Mark Rees
Ryan A [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi, My client has a dating site and now he wants to mail all his members, he does not want to use any of the already installed mailing lists but wants us to make one for him, he's on a dedicated server. Presently he does not

Re: [PHP] Inserting records question

2005-09-09 Thread Mark Rees
Still learning, so sorry if this sounds really simply noobish. But as I understand things currently this should work. But doesn't. I've been looking over tutorials but just don't see whatever the problem is. I created a simple table with the following fields (in order) tc_id (auto

Re: [PHP] regular expression for integer range

2005-09-08 Thread Mark Rees
Murray @ PlanetThoughtful [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi all, I want to write regular expression for checking the string format entered by user. the allowed formats are examples: 10 10, 10,12-10 12-10 that is the valid strings are: 1.

Re: [PHP] Sessions , expiry times and different time zones

2005-09-07 Thread Mark Rees
Dan Rossi [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] client cookie expires hence no more session ... On 07/09/2005, at 1:57 AM, Jordan Miller wrote: Hi Dan, Couldn't you store an expiration time directly in the $_SESSION variable, rather than relying on cookie

Re: [PHP] Re: calling PHP self with a text link

2005-09-02 Thread Mark Rees
Ross wrote: a href=? echo $PHP_SELF,'?','action=something' ?do somehthing/a this seems to work but can someone explain the syntax to me what does a '?' and a ',' do in PHP? I thought you joined strings with a full stop '.' (a period if you are from the US). There was a long

[PHP] Re: 400 error

2005-09-02 Thread Mark Rees
Seth Rainsdon [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] when I try to access anything.php it tells me HTTP 400 bad request I have no clue how to fix this Seth Nor do we, yet. Which OS? Which web server? What have you tried so far? Has it just broken, or did it never work? --

Re: [PHP] String format problem

2005-09-01 Thread Mark Rees
In fact, this is a poor example since the difference gets larger with longer string and more arguments. When you use dots, the interpreter has to actually concatenate the string, looking for memory to do so and freeing it up afterwards. This takes time. With commas, each argument is sent to

Re: [PHP] ID based on position?

2005-09-01 Thread Mark Rees
Auugh!! Why would you want to do this? You're flying in the face of relational database theory and practice. Position of a record in the table is, or should be irrelevant. Agreed - position is a notional concept. The data is stored physically in some sort of order, but what order that is is

[PHP] Re: (Yet another) I'm blind ... post

2005-08-31 Thread Mark Rees
Martin S [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] In this code, I'm not getting the value of $list passed to the Mailman page. I've checked this umpteen times by now, but fail to see the error. I've $list is not to be found in this code sample. $lista is though. beaten

[PHP] Re: upload file - clients path to file?

2005-08-30 Thread Mark Rees
Hi all. I havent found an answer after looking at the manual. I'm trying to find out if it possible to find the path of the file on the clients pc once a form has been submitted with the file upload form. No, this would be a security risk. If all your users are on an intranet, you may be

Re: [PHP] Re: upload file - clients path to file?

2005-08-30 Thread Mark Rees
. If that's the problem, you might find it easier to solve by going for two separate forms - one to enter all the details, and the second just to upload the file. Quoting Mark Rees [EMAIL PROTECTED]: Hi all. I havent found an answer after looking at the manual. I'm trying to find out

Re: [PHP] Re: php ldap

2005-08-26 Thread Mark Rees
Santosh Jambhlikar [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] then can i output the SMD5 of my password in php. Jeff Loiselle wrote: Santosh Jambhlikar wrote: Hi , I have a ldap server the user password are stored in that. my php ldasearch result says that the

[PHP] Re: Help Needed

2005-08-26 Thread Mark Rees
?php require(../passit.php); $stmt = OCIParse(select UPI, ORG from WEB_DS where REC_VALUE = 'uczmdsk1'); OCIExecute($stmt); According to the manual, this returns a boolean. I have never used oracle with php but you need to find a function which actually returns a result set

[PHP] Re: PHP open source newsletter software

2005-08-25 Thread Mark Rees
Angelo Zanetti [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi guys. Does anyone know of any open source software written in PHP to create HTML news letters (head, side and bottom graphics). as well as being able to send the newsletters. PHPlist from www.tincan.co.uk thanks

Re: [PHP] LDAP problem

2005-08-24 Thread Mark Rees
How long does it take to fail? I get the answer immidiatly (0-1sec.)... Are you sure you are connecting? As in, do you only try to bind if you have a successful connection? Have you checked ldap_error? Are you doing an anonymous bind, or using a username and password? Try each and see what

Re: [PHP] PHP vs. ColdFusion

2005-08-24 Thread Mark Rees
I'm betting you'll have the SAME ISSUE, and that the problem has NOTHING to do with PHP whatsoever. And you'd win that bet. I thought that would be the proof I'd need to show that it wasn't PHP, but management has some notion that PHP might have somehow tainted IIS. Gotta love a

Re: [PHP] php solution to html problem

2005-08-24 Thread Mark Rees
Jay Blanchard [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] [snip] doesn't work CSS acts the same way with a long unbroken string. [/snip] Well, you have no way of determining how many pixels wide something can be with PHP. You might have to use JavaScript to break up the string as

Re: [PHP] Catching all errors and redirecting

2005-08-19 Thread Mark Rees
Jay Blanchard [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] [snip] Is it possible to catch all parser errors (notices), and as that happens redirecting to a 'sorry-page-not-available-at-this-moment' page, whilst storing the error (or notice) message somewhere else (e.g. emailing it to

[PHP] Re: setting 'sendmail_from' on windows

2005-08-19 Thread Mark Rees
George Pitcher [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi, I am sending emails out from php using a variety of 'From addresses', depending on who is logged on. I would like bounced messages to go directly to the sender, but they are not. I suspect that this is because in

[PHP] Re: LDAP, PHP and MS Active Directory

2005-08-18 Thread Mark Rees
Hello I am using PHP v5 to write an intranet. The site is hosted on a windows 2000 server running Apache. I want to incorporate some form of Windows authentication to allow or deny access to given resources based on usernames and group membership. I am trying to accomplish this using LDAP.

[PHP] Re: edit $variable online?

2005-08-17 Thread Mark Rees
Jesús Alain Rodríguez Santos [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi, I have in a php page one ($variable = 85), I woud like to change the value from this variable online, without any data base, for example ussing a form where I can put the new value and it change the value

[PHP] Re: access multiple databases

2005-08-17 Thread Mark Rees
Bing Du [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi, I need to access both MySQL and SQL server 2000 in a PHP script on RHEL 3. In phpinfo(), I noticed 'supported databases' shows 'MySQL ODBC PostgreSQL Microsoft SQL Server FrontBase Oracle 8 (oci8)'. And 'Configure

[PHP] LDAP, PHP and MS Active Directory

2005-08-17 Thread Mark Rees
Apologies if this turns out to be a cross-post. I sent it to the list @ evolt, but have seen no traffic on that list for two days now. --- Hello I am using PHP v5 to write an intranet. The site is hosted on a windows 2000 server running Apache. I want to

Re: [PHP] Advice sought on PHP site maintenance

2005-08-16 Thread Mark Rees
George Pitcher [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] John, Thanks for the input. I just knew I hadn't covered everything. My server is currently set up as NT4/IIS. I suppose I could look to switching to Apache though. Far be it from me to discrouage you from switching to

[PHP] Re: The Naming of Directories

2005-08-04 Thread Mark Rees
Tom Chubb [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] This may be slightly OT, but I've modified a gallery script that I had written for me which reads directories and echos the dir name as a gallery. Unfortunately, it doesn't look very nice with say picsofsomething so I renamed the

[PHP] Re: Everything works...Unless they hit the back button...

2005-08-03 Thread Mark Rees
Jack Jackson [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi all. This has been an interesting week. Now the form works, and I am able to error check, if no errors look into user answer table and delete from that all q_ids matching the ones just picked, insert this page of

Re: [PHP] returning info. from a form selection

2005-08-02 Thread Mark Rees
can anyone give me an idea on how to return info. from a forl pulldown menu and return that to an email address. A most basic question begs a most basic answer: ? if (!$_POST['submit']){ // Display form ? html head titleDropdown Value to Email/title /head body form

[PHP] Re: dynamic two column table

2005-08-01 Thread Mark Rees
i know how to break up db results into two tables but im having a hard problem with this: db structure --- | id | cid | title --- | 1 | 2 | hardware | 2 | 3 | software | 3 | 3 | software | 4 | 2 | hardware how can i have hardware on column 1 and

Re: [PHP] Re: error checking a null array

2005-08-01 Thread Mark Rees
g.gill wrote: From what I understand the simplest solution here would be to check to see if you have $_POST['cb'] in the first place. That would indicate if checkbox was selected or not. After, you have posted the form just do the following test. $check_box_exits =

Re: [PHP] Re: error checking a null array

2005-08-01 Thread Mark Rees
On 8/1/05, Jack Jackson [EMAIL PROTECTED] wrote: Jochem Maas wrote: snip wtf are you smoking Jack? every checkbox that was checked will exist in the $_POST array set with the value you gave it (I alway set a chekcboxes value to 1 because the values mere existance in the submitted data

[PHP] Re: Has anybody used amfphp? (open flash remoting + php)

2005-07-28 Thread Mark Rees
Taksam [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Anybody used OpenAMF+PHP? ( http://www.amfphp.org/ ) It is an open-source Flash Remoting gateway. I already used it with Java and works OK. Just wanted to know if somebody here used it with PHP and would like to know if they

Re: [PHP] Multipage form redux

2005-07-28 Thread Mark Rees
Jack Jackson [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Somehow my intent has been turned around here and I apologise. I do not want to use *any* client side validation. I only want to do server side validation and server side storage. My intent was to remove the client from

Re: [PHP] Multipage form redux

2005-07-28 Thread Mark Rees
Jack Jackson [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Somehow my intent has been turned around here and I apologise. I do not want to use *any* client side validation. I only want to do server side validation and server side storage. My intent was to remove the client from

Re: [PHP] Multipage form redux

2005-07-28 Thread Mark Rees
Jack Jackson [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Somehow my intent has been turned around here and I apologise. I do not want to use *any* client side validation. I only want to do server side validation and server side storage. My intent was to remove the client from

Re: [PHP] Multipage form redux

2005-07-28 Thread Mark Rees
André Medeiros [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] The point of sessions is that when you close your browser, you loose it. I'm affraid that if you want sessions that last two weeks, you'll have to make your own session handler :) but yeah, it's possible, and it beats the

Re: [PHP] php mySql question

2005-07-27 Thread Mark Rees
Yes, it is quite possible that you have more than one php.ini file. Check this and delete as appropriate. Shaw, Chris - Accenture [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] ... Have you tried doing a search for the text php5 in the php.ini file that sits in your c:\windows folder?

Re: [PHP] Multipage form redux

2005-07-27 Thread Mark Rees
André Medeiros [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Wed, 2005-07-27 at 07:51 -0400, Jack Jackson wrote: Hi, I have searched the archives and seen links to tutorials at phpclasses (which seem to be down) and not found an answer to my question: I have a long form I

Re: [PHP] preg_match - help please

2005-07-27 Thread Mark Rees
André Medeiros [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Wed, 2005-07-27 at 15:27 +0100, Steve Turnbull wrote: Hi I want to see that a user is submiting a form field in the correct manner. So I decided to use preg_match to verify their input. The pattern I am trying

Re: [PHP] MySQL + PHP question

2005-07-26 Thread Mark Rees
Are you familiar with Joe Celko's tree theory? It might help you understand more about the problem. http://www.intelligententerprise.com/001020/celko.jhtml?_requestid=235427 -- Hello, Consider this: tbl_project(id, name, parent) 1 6 / \ / \ 2 3 7 8 /\ 4 5 if

Re: [PHP] MySQL + PHP question

2005-07-26 Thread Mark Rees
André Medeiros [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] One thing I didn't quite explain myself well... I'm building this to register objects on a permission system. The SQL weight is heavy as it is, and I want to save queries as much as possible. Making two queries to

[PHP] Re: function MAX with WHERE

2005-07-25 Thread Mark Rees
Jesús Alain Rodríguez Santos [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I have someting like this: $test = mysql_query(SELECT MAX(dato) AS datos FROM tabla WHERE campo_mes = '$mes'); $test_m = mysql_fetch_array($test); $test_mes = $test_m['datos']; print $test_mes where

[PHP] Re: still some problems with contact form

2005-07-21 Thread Mark Rees
Hello Mark An alternative (and more user-friendly) approach is to have the form's action as itself (i.e. the form on contact.php submits to contact.php). You can then identify which fields are incomplete and highlight them in the form. This will make it easier for users to see what they have done

[PHP] Re: still some problems with contact form

2005-07-20 Thread Mark Rees
An alternative (and more user-friendly) approach is to have the form's action as itself (i.e. the form on contact.php submits to contact.php). You can then identify which fields are incomplete and highlight them in the form. This will make it easier for users to see what they have done wrong and

Re: [PHP] problems with self referential sticky forms

2005-07-20 Thread Mark Rees
eoghan [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On 20 Jul 2005, at 02:22, Linda H wrote: fahreheit is here: ? $fahr = $_GET['fahrenheit']; if (is_null($fahr)){ echo 'fahr is null';} $ The error was on the line: $fahr = $_GET['fahrenheit']; try: input

[PHP] Re: checking for internet connection

2005-07-20 Thread Mark Rees
Steven [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi I am looking for a simple way to check if the server is connected to the Internet, they use a dialup to get Internet connection, and I need to email reports out, but want to check to see if the user remembered to connect to

Re: [PHP] sytax errors

2005-07-19 Thread Mark Rees
John Nichel [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] babu wrote: Hi, could someone please check where the sytax error is in these statements. $sqlstmt= EXEC sp_addlogin .$adduser. , .$addpass; $sqlstmt1= EXEC sp_adduser @loginame= .$adduser. , @name_in_db= .$adduser;

[PHP] Re: session data not recorded

2005-07-18 Thread Mark Rees
Alessandro Rosa [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I have a problem to record session data and I would you help me. I suppose there's something I missed in the general configurations during the last install, but I can't realize it. Review the settings in php.ini. In

Re: [PHP] Re: Need help with PHP / MySQL connect problem

2005-07-18 Thread Mark Rees
Linda H [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I added the following to the top of my script: ?php echo phpinfo(); ? Got all sorts of environment and path info. Not anything about MySQL, but I didn't see anything that looked obviously wrong, though I don't understand

[PHP] Re: Post URL ?

2005-07-18 Thread Mark Rees
Joey [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] OK I understand the difference between a get a post but if I just have a URL/link which is calling a function like so: abc.com/display_information?customer_number=$value It passes to the display_information the customer number

[PHP] Re: re-order a sql result

2005-07-18 Thread Mark Rees
Ross [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I have a query $query = SELECT * FROM sheet1 WHERE '$filter' LIKE '$search_field%' Simply requery the database for each search. For example, this orders the results by surname from a-z $query = SELECT * FROM sheet1 WHERE

Re: [PHP] Re: Need help with PHP / MySQL connect problem

2005-07-18 Thread Mark Rees
Linda H [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] For those who didn't join this thread at the beginning, I'm running MySQL 4.0.21, Apache 2.0.52 and PHP 5.0.2 on a Windows XP system. I installed in the sequence - MySQL, then Apache, then PHP. MySQL was running when the others

[PHP] Usability review - OT

2005-07-15 Thread Mark Rees
Hello Sorry for the OT request. Does anyone know of anywhere I can get my website picked apart from a usability point of view? I'm thinking of general first impressions rather than an in-depth review of functionality. Thanks Mark -- www.itsagoodprice.com - top-brand electronics for less. --

Re: [PHP] Refresh

2005-07-14 Thread Mark Rees
david forums [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] well I see two way. First is to make a php script without end, which will run continuously. I don't recommend this way at all. Why take up all that energy second way is to add refresh html tag, in your page, or a js

[PHP] Re: gettext best practice

2005-07-14 Thread Mark Rees
Skippy [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] How do you people best deal with text meant for i18n via gettext, which is either large or contains HTML tags, or both? The GNU gettext manual, in section 3.2, recommends to split long texts at paragraph level, or in the case

[PHP] Re: Win2000 easier than Win2003 ??

2005-07-14 Thread Mark Rees
Grosz, Steve (IPG IT) [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] .. Is setting up PHP easier on Windows 2000 server rather than Win2003? I'm having nothing but problems getting PHP files to show up in IE on the Win2003 server, I get nothing but 404 - file not found errors. Can you

[PHP] Re: Number of users

2005-07-12 Thread Mark Rees
[EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hello all, I have some questions and I hope someone could answer them 1. Is there a way to find out how many users currently browsing pages at my web site? 2. If I write down the IP of a user that log on my web site, can

[PHP] Re: Plz, help

2005-07-12 Thread Mark Rees
adolfas [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi, I have a line: $sql=select u.*, p.name_lt as pareiga from nese_users u left join nese_pareigos p on p.id=u.pareiga order by data desc; As I understand there are 2 tables: nese_users and nese_pareigos I need to know what

Re: [PHP] error when trying to delete a record

2005-07-11 Thread Mark Rees
Jay Blanchard [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] [snip] $query= DELETE FROM sheet1 WHERE id=$id; You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1 [/snip] try... $query=

Re: [PHP] Writing a PHP Web application

2005-07-01 Thread Mark Rees
Philip Hallstrom [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] What are the options to get code to run on the server (every XX minutes), without any user interaction, etc. If you are running on a unix like system (linux, freebsd, solaris, etc.) cron can do this for you. See

[PHP] cUrl and proxies

2005-06-30 Thread Mark Rees
Hello This code gives me a 407 Proxy Authentication Required message. Can anyone see what is missing? The username and password are definitely correct, as are the proxy IP and port. Win2k. php 5.0.4 $ch=curl_init(); curl_setopt ($ch, CURLOPT_URL, 'http://www.google.com/'); curl_setopt($ch,

[PHP] Re: cUrl and proxies

2005-06-30 Thread Mark Rees
in? The readme files in the package I did download don't really help either: http://curl.haxx.se/dlwiz/?type=*os=Win32flav=-ver=2000%2FXP Please help if you can Mark Mark Rees [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hello This code gives me a 407 Proxy Authentication Required

RE: [PHP] dynamic drop down

2005-06-02 Thread Mark Rees
The dropdown list is on the client (browser). Javascript runs on the client. PHP runs on the server. You have 2 options - one is to do as Richard says and use javascript to change the contents of one select box when an option is selected in another. - the other is to refresh the page when the

RE: [PHP] Php with mysql

2005-05-23 Thread Mark Rees
This is a beginner's guide to SQL syntax, please review it http://www.webdevelopersnotes.com/tutorials/sql/mysql_guide_querying_mys ql_tables.php3?PHPSESSID=fb6c7c7a548b6a271a75d623ce04cc9c The answer to your question (which someone has already given in a previous reply to you) is SELECT

RE: [PHP] Php with mysql

2005-05-23 Thread Mark Rees
(posted again with another syntax error corrected) This is a beginner's guide to SQL syntax, please review it http://www.webdevelopersnotes.com/tutorials/sql/mysql_guide_querying_mys ql_tables.php3?PHPSESSID=fb6c7c7a548b6a271a75d623ce04cc9c The answer to your question (which someone has already

RE: [PHP] OT - Table help needed~ PLEASE

2005-05-20 Thread Mark Rees
Something along these lines should get you started Tclothes (holds all the possible variations of size, colour and style) Id PK Styleid FK to Tstyle Sizeid FK to Tsize Colourid FK to Tcolour Tstyle Styleid PK StyleDescription VARCHAR Tsize Sizeid PK SizeDescription VARCHAR Tcolour Colourid PK

RE: [PHP] Class function calling another function in class

2005-05-19 Thread Mark Rees
You might find this interesting if you are working with hierarchies in SQL http://www.intelligententerprise.com/001020/celko.jhtml?_requestid=72430 3 -Original Message- From: Richard Lynch [mailto:[EMAIL PROTECTED] Sent: 19 May 2005 07:35 To: Charles Kline Cc: php-general@lists.php.net

RE: [PHP] Unknown column 'peterspeters' in 'where clause'

2005-05-18 Thread Mark Rees
I expect (indeed I sincerely hope) that customer_username AND customer_password columns are character datatypes. So it would be a good idea to put single quotes around the values you are trying to select from them. -Original Message- From: Mark Sargent [mailto:[EMAIL PROTECTED] Sent: 18

  1   2   >