php-general Digest 9 Jun 2008 21:32:45 -0000 Issue 5505

Topics (messages 275131 through 275162):

imap_open() error. (Can't open mailbox)
        275131 by: Mathijs van Veluw
        275132 by: Thijs Lensselink
        275133 by: Mathijs van Veluw
        275134 by: Thijs Lensselink
        275135 by: Mathijs van Veluw
        275138 by: Michael Kubler
        275140 by: Edward Kay
        275150 by: Mathijs van Veluw

PHP with C++
        275136 by: R B
        275137 by: Wolf
        275139 by: Stut
        275145 by: Daniel Brown
        275146 by: Павел aka [R-K]

Re: PHP with C++[Zend Engine?]
        275141 by: Павел aka [R-K]
        275142 by: Павел aka [R-K]
        275143 by: Павел aka [R-K]
        275144 by: Павел aka [R-K]

Re: spaces - not sure if this is a preg_match issue or a regexp issue
        275147 by: DeadTOm

PHP compile
        275148 by: Hélio Rocha
        275149 by: Daniel Brown
        275151 by: Wolf
        275152 by: Bastien Koert
        275157 by: zerof

Re: Choosing PHP or ? for building an automatic photo web.
        275153 by: Peter Sorensen

Retrive a ID or Class value from a form input field
        275154 by: Joe Harman
        275155 by: Jim Lucas
        275156 by: Jim Lucas
        275158 by: Robert Cummings
        275159 by: Jim Lucas
        275160 by: Joe Harman
        275162 by: Benjamin Hawkes-Lewis

mssql extension
        275161 by: Mathieu Pelletier

Administrivia:

To subscribe to the digest, e-mail:
        [EMAIL PROTECTED]

To unsubscribe from the digest, e-mail:
        [EMAIL PROTECTED]

To post to the list, e-mail:
        [EMAIL PROTECTED]


----------------------------------------------------------------------
--- Begin Message ---
Hello there,

i use imap to read incoming mail from the the SMTP server.
On the live server everythings works as it should.
I can use imap_open('/path/to/file', '', ''), to read just one raw-mail.
On my test env i can't get this to work.

I get the error message: "Can't open mailbox".
While on the live server it works and i get the correct resource "resource(42) of 
type (imap)".

I realy don't know what the problem is.
Can someone help me with this?

Thanks in advance.
Mathijs.

--- End Message ---
--- Begin Message ---
Quoting Mathijs van Veluw <[EMAIL PROTECTED]>:

Hello there,

i use imap to read incoming mail from the the SMTP server.
On the live server everythings works as it should.
I can use imap_open('/path/to/file', '', ''), to read just one raw-mail.
On my test env i can't get this to work.

I get the error message: "Can't open mailbox".
While on the live server it works and i get the correct resource
"resource(42) of type (imap)".

I realy don't know what the problem is.
Can someone help me with this?

Thanks in advance.
Mathijs.


I didn't work with IMAP much. So one suggestion could be to check if your dev box is behind a proxy server. If you're using SSL check if it's enabled on your dev box.



--- End Message ---
--- Begin Message ---
Thijs Lensselink wrote:
Quoting Mathijs van Veluw <[EMAIL PROTECTED]>:

Hello there,

i use imap to read incoming mail from the the SMTP server.
On the live server everythings works as it should.
I can use imap_open('/path/to/file', '', ''), to read just one raw-mail.
On my test env i can't get this to work.

I get the error message: "Can't open mailbox".
While on the live server it works and i get the correct resource
"resource(42) of type (imap)".

I realy don't know what the problem is.
Can someone help me with this?

Thanks in advance.
Mathijs.


I didn't work with IMAP much. So one suggestion could be to check if your dev box is behind a proxy server. If you're using SSL check if it's enabled on your dev box.


the imap_open() only gets a file location.
This file containts a raw-mail, so no need for ssl or proxy stuff etc..

--- End Message ---
--- Begin Message ---
Quoting Mathijs van Veluw <[EMAIL PROTECTED]>:

Thijs Lensselink wrote:
Quoting Mathijs van Veluw <[EMAIL PROTECTED]>:

Hello there,

i use imap to read incoming mail from the the SMTP server.
On the live server everythings works as it should.
I can use imap_open('/path/to/file', '', ''), to read just one raw-mail.
On my test env i can't get this to work.

I get the error message: "Can't open mailbox".
While on the live server it works and i get the correct resource
"resource(42) of type (imap)".

I realy don't know what the problem is.
Can someone help me with this?

Thanks in advance.
Mathijs.


I didn't work with IMAP much. So one suggestion could be to check if your dev box is behind a proxy server. If you're using SSL check if it's enabled on your dev box.


the imap_open() only gets a file location.
This file containts a raw-mail, so no need for ssl or proxy stuff etc..


It doesn't give a file location. it creates a resource. This resource you can use to retrieve the data.

SSL is no option like you said. I would at least check the proxy. I'm behind a proxy here also. And for remote communication i use a proxy class.

Maybe somebody else on the list can point you in the right direction.





--- End Message ---
--- Begin Message ---
Thijs Lensselink wrote:
Quoting Mathijs van Veluw <[EMAIL PROTECTED]>:

Thijs Lensselink wrote:
Quoting Mathijs van Veluw <[EMAIL PROTECTED]>:

Hello there,

i use imap to read incoming mail from the the SMTP server.
On the live server everythings works as it should.
I can use imap_open('/path/to/file', '', ''), to read just one raw-mail.
On my test env i can't get this to work.

I get the error message: "Can't open mailbox".
While on the live server it works and i get the correct resource
"resource(42) of type (imap)".

I realy don't know what the problem is.
Can someone help me with this?

Thanks in advance.
Mathijs.


I didn't work with IMAP much. So one suggestion could be to check if your dev box is behind a proxy server. If you're using SSL check if it's enabled on your dev box.


the imap_open() only gets a file location.
This file containts a raw-mail, so no need for ssl or proxy stuff etc..


It doesn't give a file location. it creates a resource. This resource you can use to retrieve the data.

SSL is no option like you said. I would at least check the proxy. I'm behind a proxy here also. And for remote communication i use a proxy class.

Maybe somebody else on the list can point you in the right direction.





Ill explain it a bit more better.
I have a file with something like the contents at the bottom (without the --).
Now on my live server i can use: <?php $imapResource = 
imap_open('/path/to/file-with-contents-at-bottom', '', ''); ?>.
This works like a charm, and i can use that resource to extract the information 
of that contents of that file.

Now if i use that same script on my test server, it doesn't work anymore.
And i get the following error: "Warning: imap_open() [function.imap-open]: Couldn't 
open stream /path/to/file-with-contents-at-bottom in ...".
This file is located (for example) in the document_root of the web server.
While on the live server the $imapResource is an 'resource(42) of type (imap)'.

So i wonder how i can fix this imap_open() problem.

Im sorry if i don't understand your response very well if that could be the 
solution.

Thx in advanced.

-------------------------------------------------------
        Delivered-To: [EMAIL PROTECTED]
        Received: by 10.0.0.1 with SMTP id xxxxxxxxxxxxx;
                Sun, 8 Jun 2008 02:00:12 -0700 (PDT)
        Received: by 10.0.0.1 with SMTP id xxxxxxxxxxxxxxx.1111111111111111;
                Sun, 08 Jun 2008 02:00:11 -0700 (PDT)
        Return-Path: <[EMAIL PROTECTED]>
        Received: from smtp.mail.com (smtp.mail.com [10.0.0.1])
                by mx.mail.com with ESMTP id 
xxxxxxxxxxxxxxx.222222222222222222222;
                Sun, 08 Jun 2008 02:00:11 -0700 (PDT)
        Received: from 10.0.0.1 (smtp.mail.com [10.0.0.1])
                by smtp.mail.com (8.13.1/8.13.1) with SMTP id xxxxxxxxxxxxxx
                for [EMAIL PROTECTED]; Sun, 8 Jun 2008 11:00:05 +0200
        Date: Sun, 8 Jun 2008 11:00:05 +0200
        Message-Id: <[EMAIL PROTECTED]>
        Reply-To: name <[EMAIL PROTECTED]>
        From: from <[EMAIL PROTECTED]>
        To: to <[EMAIL PROTECTED]>
        Subject: Subject
        Content-Type: text/plain; charset=utf-8
        Content-Transfer-Encoding: 8bit
        MIME-Version: 1.0
        
        This is my mail blah blah blah
        Blah blah blah blah foobar etc.. etc...
        
        
-------------------------------------------------------

--- End Message ---
--- Begin Message ---
File Permissions? PHP safe mode?
Mail server locking the file?

Can you >/tail /path/to/file-with-contents-at-bottom /  ??

Michael Kubler
*G*rey *P*hoenix *P*roductions <http://www.greyphoenix.biz>



Mathijs van Veluw wrote:

I get the error message: "Can't open mailbox".
While on the live server it works and i get the correct resource
"resource(42) of type (imap)".

I realy don't know what the problem is.
Can someone help me with this?

Thanks in advance.
Mathijs.

--- End Message ---
--- Begin Message ---

> -----Original Message-----
> From: Thijs Lensselink [mailto:[EMAIL PROTECTED]
> Sent: 09 June 2008 13:43
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP] imap_open() error. (Can't open mailbox)
>
>
> Quoting Mathijs van Veluw <[EMAIL PROTECTED]>:
>
> > Thijs Lensselink wrote:
> >> Quoting Mathijs van Veluw <[EMAIL PROTECTED]>:
> >>
> >>> Hello there,
> >>>
> >>> i use imap to read incoming mail from the the SMTP server.
> >>> On the live server everythings works as it should.
> >>> I can use imap_open('/path/to/file', '', ''), to read just
> one raw-mail.
> >>> On my test env i can't get this to work.
> >>>
> >>> I get the error message: "Can't open mailbox".
> >>> While on the live server it works and i get the correct resource
> >>> "resource(42) of type (imap)".
> >>>
> >>> I realy don't know what the problem is.
> >>> Can someone help me with this?
> >>>
> >>> Thanks in advance.
> >>> Mathijs.
> >>>
> >>
> >> I didn't work with IMAP much. So one suggestion could be to check
> >> if your dev box is behind a proxy server. If you're using SSL check
> >>  if it's enabled on your dev box.
> >>
> >>
> > the imap_open() only gets a file location.
> > This file containts a raw-mail, so no need for ssl or proxy stuff etc..
> >
>

Have you checked the permissions on the mail file? Are your dev and live
boxes both running PHP in the same manner (Apache module vs CGI)? Can you
open the same file with fopen?

Edward


--- End Message ---
--- Begin Message ---
Edward Kay wrote:

-----Original Message-----
From: Thijs Lensselink [mailto:[EMAIL PROTECTED]
Sent: 09 June 2008 13:43
To: [EMAIL PROTECTED]
Subject: Re: [PHP] imap_open() error. (Can't open mailbox)


Quoting Mathijs van Veluw <[EMAIL PROTECTED]>:

Thijs Lensselink wrote:
Quoting Mathijs van Veluw <[EMAIL PROTECTED]>:

Hello there,

i use imap to read incoming mail from the the SMTP server.
On the live server everythings works as it should.
I can use imap_open('/path/to/file', '', ''), to read just
one raw-mail.
On my test env i can't get this to work.

I get the error message: "Can't open mailbox".
While on the live server it works and i get the correct resource
"resource(42) of type (imap)".

I realy don't know what the problem is.
Can someone help me with this?

Thanks in advance.
Mathijs.

I didn't work with IMAP much. So one suggestion could be to check
if your dev box is behind a proxy server. If you're using SSL check
 if it's enabled on your dev box.


the imap_open() only gets a file location.
This file containts a raw-mail, so no need for ssl or proxy stuff etc..


Have you checked the permissions on the mail file? Are your dev and live
boxes both running PHP in the same manner (Apache module vs CGI)? Can you
open the same file with fopen?

Edward


The file is accessable, and they both run using the apache2 module etc..
Both have the same version PHP and same IMAP version.

So i find it strange.

For the output see my last post.

--- End Message ---
--- Begin Message ---
Hi,
I have a C++ script containing the function hello(x, y, z)

I want to access this C++ function from PHP, and output with PHP the return
information.

How can i do this?

Thank you.

--- End Message ---
--- Begin Message ---
---- R B <[EMAIL PROTECTED]> wrote: 
> Hi,
> I have a C++ script containing the function hello(x, y, z)
> 
> I want to access this C++ function from PHP, and output with PHP the return
> information.
> 
> How can i do this?

Where's your failing code?

STFW: 
http://www.google.com/search?q=PHP%3A+C%2B%2B&ie=utf-8&oe=utf-8&aq=t&rls=com.ubuntu:en-US:unofficial&client=firefox-a

When you have code that is failing, post it here and we'll see if we can help 
you get the bugs out.

Wolf

--- End Message ---
--- Begin Message ---
On 9 Jun 2008, at 14:11, R B wrote:
I have a C++ script containing the function hello(x, y, z)

I want to access this C++ function from PHP, and output with PHP the return
information.

How can i do this?

1) Buy this book...

http://www.amazon.com/dp/067232704X?tag=libssh2projec-20&camp=14573&creative=327641&linkCode=as1&creativeASIN=067232704X&adid=0RDRTQB9KQ7ATE0MAY5R&;

2) Read it carefully.

3) Try writing an extension to wrap your function.

4) Post questions here if you have problems but be sure you show that you've done 1-3 or we'll ignore you.

Extensions aren't rocket science, but there are many gotcha's and that book helped me a lot when I was starting out. Don't feel like shelling out for the book? Check out the many extensions included in the PHP source, but be aware that it's not overly simple.

-Stut

--
http://stut.net/

--- End Message ---
--- Begin Message ---
On Mon, Jun 9, 2008 at 9:11 AM, R B <[EMAIL PROTECTED]> wrote:
> Hi,
> I have a C++ script containing the function hello(x, y, z)
>
> I want to access this C++ function from PHP, and output with PHP the return
> information.
>
> How can i do this?

    The cheating, quickest, easiest way, would be to write the
function into a portable C++ script, compile it to binary form, and
pass `x`, `y`, and `z` as argv[]'s via PHP's exec() function, like so:

<?php
$ret = null;
// In the exec() call below, note the quotes around special characters
and spaces.
exec('./cpp-binary argument1 argument2 "argument three?"',$ret,$err);
if(count($ret) > 1) {
    foreach($ret as $r) {
        echo $r."<br />\n";
    }
} elseif(count($ret) == 1) {
    echo $ret[0]."<br />\n";
} else {
    echo "Nothing returned by exec()!  Error Level: ".$err."<br />\n";
}
?>

-- 
</Daniel P. Brown>
Dedicated Servers - Intel 2.4GHz w/2TB bandwidth/mo. starting at just
$59.99/mo. with no contract!
Dedicated servers, VPS, and hosting from $2.50/mo.

--- End Message ---
--- Begin Message ---
You wrote:

> 4) Post questions here if you have problems but be sure you show that
> you've done 1-3 or we'll ignore you.
I read this book and some else,but nothing book helped me in writing Zend - 
Extension...
I'd like to wrote some similar but simplier them Zend Encoder... If you can, 
help me please.

PS.Sorry for my English.

-- 
===============
С уважением, Манылов Павел aka [R-k]
icq: 949-388-0
mailto:[EMAIL PROTECTED]
===============
А ещё говорят так:
PS Документация zsh - просто нечеловеческая.
                -- vyt in community@
[fortune]

--- End Message ---
--- Begin Message ---
You wrote:

> 4) Post questions here if you have problems but be sure you show that
> you've done 1-3 or we'll ignore you.
I read this book and some else,but nothing book helped me in writing Zend - 
Extension...
I'd like to wrote some similar but simplier them Zend Encoder... If you can, 
help me please.

PS.Sorry for my English.

-- 
===============
С уважением, Манылов Павел aka [R-k]
icq: 949-388-0
mailto:[EMAIL PROTECTED]
===============
А ещё говорят так:
A kid'll eat the middle of an Oreo, eventually.
[fortune]

--- End Message ---
--- Begin Message ---
You wrote:

> 4) Post questions here if you have problems but be sure you show that
> you've done 1-3 or we'll ignore you.
I read this book and some else,but nothing book helped me in writing Zend - 
Extension...
I'd like to wrote some similar but simplier them Zend Encoder... If you can, 
help me please.

PS.Sorry for my English.

-- 
===============
С уважением, Манылов Павел aka [R-k]
icq: 949-388-0
mailto:[EMAIL PROTECTED]
===============
А ещё говорят так:
A kid'll eat the middle of an Oreo, eventually.
[fortune]

--- End Message ---
--- Begin Message ---
You wrote:

> 4) Post questions here if you have problems but be sure you show that
> you've done 1-3 or we'll ignore you.
I read this book and some else,but nothing book helped me in writing Zend - 
Extension...
I'd like to wrote some similar but simplier them Zend Encoder... If you can, 
help me please.

PS.Sorry for my English.

-- 
===============
С уважением, Манылов Павел aka [R-k]
icq: 949-388-0
mailto:[EMAIL PROTECTED]
===============
А ещё говорят так:
A kid'll eat the middle of an Oreo, eventually.
[fortune]

--- End Message ---
--- Begin Message ---
You wrote:

> 4) Post questions here if you have problems but be sure you show that
> you've done 1-3 or we'll ignore you.
I read this book and some else,but nothing book helped me in writing Zend - 
Extension...
I'd like to wrote some similar but simplier them Zend Encoder... If you can, 
help me please.

PS.Sorry for my English.

-- 
===============
С уважением, Манылов Павел aka [R-k]
icq: 949-388-0
mailto:[EMAIL PROTECTED]
===============
А ещё говорят так:
PS Документация zsh - просто нечеловеческая.
                -- vyt in community@
[fortune]

--- End Message ---
--- Begin Message ---
> what about just writing a utility to manipulate the files names to remove
> spaces?
>
> --
>
> Bastien
>
> Cat, the other other white meat
>

Because it's not a separate file. The attachment is encoded as plain text
into the nntp message.

--

DeadTOm
http://www.mtlaners.org
[EMAIL PROTECTED]
A Linux user since 1999.


--- End Message ---
--- Begin Message ---
Hi there,

How can i compile or encrypt a PHP project without changing any thing on the
server? [Fast-]CGI it's a possibility.

Thanks in advance.
Hélio

--- End Message ---
--- Begin Message ---
On Mon, Jun 9, 2008 at 10:36 AM, Hélio Rocha <[EMAIL PROTECTED]> wrote:
> Hi there,
>
> How can i compile or encrypt a PHP project without changing any thing on the
> server? [Fast-]CGI it's a possibility.

    STFW: http://www.google.com/search?q=php+encoders

    Generally, there will have to be something installed on the server
that will give instructions on how to decrypt the files, but they
don't always require root access or intervention.

-- 
</Daniel P. Brown>
Dedicated Servers - Intel 2.4GHz w/2TB bandwidth/mo. starting at just
$59.99/mo. with no contract!
Dedicated servers, VPS, and hosting from $2.50/mo.

--- End Message ---
--- Begin Message ---
---- "Hélio Rocha" <[EMAIL PROTECTED]> wrote: 
> Hi there,
> 
> How can i compile or encrypt a PHP project without changing any thing on the
> server? [Fast-]CGI it's a possibility.
> 
> Thanks in advance.
> Hélio

STFW:

http://www.google.com/search?q=PHP%3A+encrypt&ie=utf-8&oe=utf-8&aq=t&rls=com.ubuntu:en-US:unofficial&client=firefox-a

http://www.google.com/search?hl=en&client=firefox-a&rls=com.ubuntu%3Aen-US%3Aunofficial&hs=Tfi&q=PHP%3A+compile&btnG=Search



--- End Message ---
--- Begin Message ---
On Mon, Jun 9, 2008 at 10:43 AM, Wolf <[EMAIL PROTECTED]> wrote:

> ---- "Hélio Rocha" <[EMAIL PROTECTED]> wrote:
> > Hi there,
> >
> > How can i compile or encrypt a PHP project without changing any thing on
> the
> > server? [Fast-]CGI it's a possibility.
> >
> > Thanks in advance.
> > Hélio
>
> STFW:
>
>
> http://www.google.com/search?q=PHP%3A+encrypt&ie=utf-8&oe=utf-8&aq=t&rls=com.ubuntu:en-US:unofficial&client=firefox-a
>
>
> http://www.google.com/search?hl=en&client=firefox-a&rls=com.ubuntu%3Aen-US%3Aunofficial&hs=Tfi&q=PHP%3A+compile&btnG=Search
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>
might want to look at roadsend as well

http://www.roadsend.com/home/index.php?SMC=1&pageID=compiler

-- 

Bastien

Cat, the other other white meat

--- End Message ---
--- Begin Message ---
Hélio Rocha escreveu:
Hi there,

How can i compile or encrypt a PHP project without changing any thing on the
server? [Fast-]CGI it's a possibility.

Thanks in advance.
Hélio

http://www.roadsend.com/home/index.php

--
zerof
http://www.educar.pro.br/
Apache - PHP - MySQL - Boolean Logics - Project Management
----------------------------------------------------------
Você deve, sempre, consultar uma segunda opinião!
----------------------------------------------------------
Deixe todos saberem se esta informação foi-lhe útil.
----------------------------------------------------------      
You must hear, always, one second opinion! In all cases.
----------------------------------------------------------
Let the people know if this info was useful for you!
----------------------------------------------------------

--- End Message ---
--- Begin Message ---
Sorry wrong button on the mail program.


"Stut" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED]
Please copy replies to the list.

On 8 Jun 2008, at 22:47, Nordstjernealle 10 wrote:
Thanks Stut

I have looked at Gallery and I think your are right, just what I need.
Onfortunately I have found that Gallery musthave PHP safe mode off, which Surftown does not allow. Using Gallery means write of my Surftown account and get another web hotel.
Any other ideers?

Use a better web host. Any system that can do what you're after will want to do things like generate thumbnails and other different sizes. This can get difficult with safe mode enabled.

I try not to recommend web hosts because they all suck, but I do know a few people on this list provide hosting services and I'm sure they'll get in contact if they can help.

-Stut

--
http://stut.net/

----- Original Message ----- From: "Stut" <[EMAIL PROTECTED]>
Newsgroups: php.general
To: "Peter Sorensen" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Sunday, June 08, 2008 11:27 PM
Subject: Re: [PHP] Choosing PHP or ? for building an automatic photo web.


On 8 Jun 2008, at 21:44, Peter Sorensen wrote:
I want to make my own web with my familie photos.
At the same time I get a remote backup for our photos.
I am new to web prgramming including HTML, but as an electronic engineer I have some fundamental understanding of programming. I use windows XP or Vista but that properly does not matter in web design? I have invested in a web service on surftown (only starter) for 5 years. So before I spend a lot time learning webprogramming, I would like some experience web programmers to tell me if my project is doable within a reasonable effort.

I want 2 thinks that are a little uncommon:
1. User login protected by password (don't won't free access to all my photos). I have found some PHP code that does this and seems readable to me, so I guess this is trivial and on to the main problem.

2. I want the web source to automatic create a new tab or link or ?, when ever I upload a new set of photo's via FTP. I want the photos arranged in subfolders when I upload (preferreable two levels of subfolders). If I upload more photos in an existing folder with photos, they must appear automatickly.

So the question is: is this doable for a newbie within a limited amount of hours?
Is PHP the choice?
Do I need to use mySQL for this?
What features must the webhotel suport and do you know if Surftown does? Is there anywhere I get template source code for this, free or at a low price?

This wheel has been invented a hundred times already.

I would suggest http://gallery.menalto.com/ which I think does everything you're after.

-Stut

--
http://stut.net/




--- End Message ---
--- Begin Message ---
Hello,

is there any way to get more field information other than just the
value of a field when a form is submitted???

ex:
 <input name="email" type="text" id="email" size="30" maxlength="120"
class="theClass" value="" />

type, size, class, etc.

Thanks
Joe

--- End Message ---
--- Begin Message ---
Joe Harman wrote:
Hello,

is there any way to get more field information other than just the
value of a field when a form is submitted???

ex:
 <input name="email" type="text" id="email" size="30" maxlength="120"
class="theClass" value="" />

type, size, class, etc.

Thanks
Joe


Yes, but that would be a Javascript question.

Google for a javascript method called getAttribute()

--
Jim Lucas

   "Some men are born to greatness, some achieve greatness,
       and some have greatness thrust upon them."

Twelfth Night, Act II, Scene V
    by William Shakespeare


--- End Message ---
--- Begin Message ---
Jim Lucas wrote:
Joe Harman wrote:
Hello,

is there any way to get more field information other than just the
value of a field when a form is submitted???

ex:
 <input name="email" type="text" id="email" size="30" maxlength="120"
class="theClass" value="" />

type, size, class, etc.

Thanks
Joe


Yes, but that would be a Javascript question.

Google for a javascript method called getAttribute()


Man, what a day.

I should have said it like this.

No, but in javascript, before the form is submitted, you can.

then....

--
Jim Lucas

   "Some men are born to greatness, some achieve greatness,
       and some have greatness thrust upon them."

Twelfth Night, Act II, Scene V
    by William Shakespeare


--- End Message ---
--- Begin Message ---
On Mon, 2008-06-09 at 14:45 -0500, Joe Harman wrote:
> Hello,
> 
> is there any way to get more field information other than just the
> value of a field when a form is submitted???
> 
> ex:
>  <input name="email" type="text" id="email" size="30" maxlength="120"
> class="theClass" value="" />

<input type="hidden" name="email__config"
value="name=email,type=text,id=email,size=30,maxlength=120,class=theClass" />

Alternatively fill the value of the hidden field using JavaScript at
submission time. Of course... that only works when JavaScript is
enabled.

Cheers,
Rob.
-- 
http://www.interjinn.com
Application and Templating Framework for PHP


--- End Message ---
--- Begin Message ---
Jim Lucas wrote:
Jim Lucas wrote:
Joe Harman wrote:
Hello,

is there any way to get more field information other than just the
value of a field when a form is submitted???

ex:
 <input name="email" type="text" id="email" size="30" maxlength="120"
class="theClass" value="" />

type, size, class, etc.

Thanks
Joe


Yes, but that would be a Javascript question.

Google for a javascript method called getAttribute()


Man, what a day.

I should have said it like this.

No, but in javascript, before the form is submitted, you can.

then....


Let me ask this.  Why would you want to do this?

--
Jim Lucas

   "Some men are born to greatness, some achieve greatness,
       and some have greatness thrust upon them."

Twelfth Night, Act II, Scene V
    by William Shakespeare


--- End Message ---
--- Begin Message ---
I was just writing a form validation script... I know that there is
ton of them out there... and i know that there are some different
methods of doing it... but i want to assign class names to each field
like class="req:email"... not sure if that is the right way to do it,
but i thought it would make thing neat and tidy

Thanks for all your input
Joe

On Mon, Jun 9, 2008 at 3:09 PM, Jim Lucas <[EMAIL PROTECTED]> wrote:
> Jim Lucas wrote:
>>
>> Jim Lucas wrote:
>>>
>>> Joe Harman wrote:
>>>>
>>>> Hello,
>>>>
>>>> is there any way to get more field information other than just the
>>>> value of a field when a form is submitted???
>>>>
>>>> ex:
>>>>  <input name="email" type="text" id="email" size="30" maxlength="120"
>>>> class="theClass" value="" />
>>>>
>>>> type, size, class, etc.
>>>>
>>>> Thanks
>>>> Joe
>>>>
>>>
>>> Yes, but that would be a Javascript question.
>>>
>>> Google for a javascript method called getAttribute()
>>>
>>
>> Man, what a day.
>>
>> I should have said it like this.
>>
>> No, but in javascript, before the form is submitted, you can.
>>
>> then....
>>
>
> Let me ask this.  Why would you want to do this?
>
> --
> Jim Lucas
>
>   "Some men are born to greatness, some achieve greatness,
>       and some have greatness thrust upon them."
>
> Twelfth Night, Act II, Scene V
>    by William Shakespeare
>
>



-- 
Joe Harman

SCP Performance Parts Warehouse
3475 High Ridge Blvd
High Ridge, MO 63049
Office : (636) 677-1320
Cell : (269) 277-0717

http://www.scpracingparts.com

--- End Message ---
--- Begin Message ---
Joe Harman wrote:
I was just writing a form validation script... I know that there is
ton of them out there... and i know that there are some different
methods of doing it... but i want to assign class names to each field
like class="req:email"... not sure if that is the right way to do it,
but i thought it would make thing neat and tidy

And these class names could be used on the server for … what? Hopefully, you're not relying on GET and POST requests from (intrinsically untrustworthy) clients to know what data type input should be, as that would be intrinsically insecure.

--
Benjamin Hawkes-Lewis




--- End Message ---
--- Begin Message ---
Hello !
 
My Workstation/server:
Window XPApache 2.2.4 (win32) PHP/5.2.3SQl Server 2003
 
I have never been able to load mssql extension in my life...In my php .ini 
file, I removed the ; correctly :
 
extension=php_mssql.dll
 
Other extensions work fine, for example I use the PDF extension :
extension=libpdf_php.dll
 
When I call phpinfo(), I can see informations about PDF, but nothing about 
mssql.
I was wondering if I have the good version of the dll in my "ext" directory..Or 
is SQl server 2003 compatible with XP and the latest version of php?
By the way, SQLServer works fine on my computer.
 
Thank you very much
 
Mathieu
_________________________________________________________________


--- End Message ---

Reply via email to