Hmmm, didn't think about that. Here's something simple that seems to
work in a couple of tests.
if(strlen($testValue-0) == strlen($testValue)) {
echo "Is a number";
} else {
echo "Is not a number";
}
Or, in one line:
(strlen($testValue-0) == strlen($testValue) ? 1 : 0)
Kind of a kludge, but it
OK. I'm suffering from brain gas...
I'm trying this, it doesn't work and I can't figure out why:
include_once $SYSTEM_URL . "/classes/category.php"; where $SYSTEM_URL =
"http://www.example.com"; is the url to the web site. and I get this error:
Fatal error: Cannot instantiate non-existent c
On Friday 13 June 2003 04:43, Philip Olson wrote:
> The manual over at phpbuilder is useless, and very old. Do
> not use that manual, use php.net/manual
Talking of manuals, what happened to the extremely useful index of functions
that used to be in the appendix?
--
Jason Wong -> Gremlins Asso
Hi all,
I have a self referring script that $_POST's two times at the beginning. The
problem is that the first time the script comes up those two $_POST vars
aren't being submitted and the webserver complains.
If I could detect if the vars were passed and if not then skip that would be
great. What
On Friday 13 June 2003 04:55, Sparky Kopetzky wrote:
> I'm trying this, it doesn't work and I can't figure out why:
>
> include_once $SYSTEM_URL . "/classes/category.php"; where $SYSTEM_URL =
> "http://www.example.com"; is the url to the web site. and I get this error:
>
> Fatal error: Cannot
On Friday 13 June 2003 05:08, Johnny Martinez wrote:
> I have a self referring script that $_POST's two times at the beginning.
> The problem is that the first time the script comes up those two $_POST
> vars aren't being submitted and the webserver complains.
>
> If I could detect if the vars wer
if ( isset($_POST['var_1']) and isset($_POST['var_2']) ) {
your code
}
- Original Message -
From: "Johnny Martinez" <[EMAIL PROTECTED]>
To: "PHP General" <[EMAIL PROTECTED]>
Sent: Thursday, June 12, 2003 5:08 PM
Subject: [PHP] POST detection
> Hi all,
> I have a self referring script t
Is there a way to make a variable not exist? There are several places
where I test (!$variable), and I want to be able to change the
variable to pass that test, even though it exists, under certain
circumstances.
Thanks.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
>
> Is there a way to make a variable not exist? There are several places
> where I test (!$variable), and I want to be able to change the
> variable to pass that test, even though it exists, under certain
> circumstances.
>
> Thanks.
>
You can unset the variable www.php.net/unset but also I wou
Woot! That worked! Thanks Jason and R'twick!
Johnny
-Original Message-
From: Jason Wong [mailto:[EMAIL PROTECTED]
Sent: Thursday, June 12, 2003 2:14 PM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] POST detection
On Friday 13 June 2003 05:08, Johnny Martinez wrote:
> I have a self referring
On Jun 12, 2003, "news" claimed that:
|Shouldn't the following work - or rather why doesn't it :
|
|
|ignore_user_abort(0);
|
|for( $i=100; $i; $i-- )
|{
|if ( connection_status() ) exit(0);
|print " blurp."; flush();
|sleep(1
Is this valid to iterate over a form variables.?
foreach ($_SESSION as $key=>$value)
and another question, do I need this in my form?
Im really struggling with $_SESSION. Im trying to program smarter and make friendlier
applications.
Ive submitted several emails dealing with this func
On Thu, 12 Jun 2003, Per Jessen wrote:
> Shouldn't the following work - or rather why doesn't it :
>
>
> ignore_user_abort(0);
>
> for( $i=100; $i; $i-- )
> {
> if ( connection_status() ) exit(0);
> print " blurp."; flush();
>
And won't generate a notice.
Alex Earl wrote:
You can unset the variable www.php.net/unset but also I would recommend
using if(!isset($variable)) instead of just if(!$variable) its a little
more clear as to what you are really trying to see I think.
Alex
--
The above message is encrypted with
The file get's parsed server side I guess... You would need to name it .txt
or something for that to work... :p
"Sparky Kopetzky" <[EMAIL PROTECTED]> skrev i meddelandet
news:[EMAIL PROTECTED]
OK. I'm suffering from brain gas...
I'm trying this, it doesn't work and I can't figure out why:
inc
I am writing a module that will allow a customer to process a credit card
refund thru a web interface that I am designing. The problem I am having is
that once the information is posted to the gateway, it returns a url encoded
string with the responce from the transaction. How can I capture that
re
Will this work for $_GET as well?
J
-Original Message-
From: Jason Wong [mailto:[EMAIL PROTECTED]
Sent: Thursday, June 12, 2003 2:14 PM
To: [EMAIL PROTECTED]
Subject: Re: [PHP] POST detection
On Friday 13 June 2003 05:08, Johnny Martinez wrote:
> I have a self referring script that $_P
Starting with a working site (FreeBSD 4.7, Apache 1.3.27) using PHP 4.3.0
and the latest Zend Optimizer, I upraded to PHP 4.3.2. Afterwards, phpinfo
() did not show the Optimizer as loaded. Reinstalling Optimizer did not
change this, nor did uninstalling and reinstalling Optimizer. There were
I'm trying to make a PHP script that automaticly makes a link on the side
menu to the id page that was just made, under certain catagories. But I
edited my code to cleen up soem errors and all of a sudden 3 errors came up,
and I haven't been able to fix them! They are:
Warning: mysql_fetch_array():
It has to do with you assuming everything will work 100%
of the time. It won't. mysql_query() returns false on
failure, check for that. Read this recent thread:
http://marc.theaimsgroup.com/?l=php-general&m=105517588819420
Also, this faq explains it:
http://www.php.net/manual/en/faq.data
Try using this
$_POST['var_name']
Jake Johnson
http://www.plutoid.com
On Thu, 12 Jun 2003, Joaco wrote:
> I am writing a module that will allow a customer to process a credit card
> refund thru a web interface that I am designing. The problem I am having is
> that once the information is p
Dear Walker,
After connecting to the LDAP using ldap_connect('localhost'); you should
use ldap_bind like the code given below.
Hope this should help.
Regards
Praveen
---SOFTPRO DISCLAIMER--
Information contained in this E-MAIL and any attachment
Is there a way to get PHP script/code out of a DB? Becasue, when I enter PHP
code into the textbox and hit submit, and go check the page it has nothing
there with and just shows the code, e.g.
include("menu.php"); without the tags, the code I'm using to import
the DB text is below:
} elsei
In article <[EMAIL PROTECTED]>,
[EMAIL PROTECTED] says...
> > Working kind of :)
> >
> > Get one line from it
>
> Kinda... I get it to return one line...
>
> The code:
>
> define('STDIN',fopen("php://stdin","r"));
> $str = fgets(STDIN);
> mail("[EMAIL PROTECTED]","Test","Test Test...\n\nOr
www.php.net/eval
Ben Houlton wrote:
Is there a way to get PHP script/code out of a DB? Becasue, when I enter PHP
code into the textbox and hit submit, and go check the page it has nothing
there with and just shows the code, e.g.
include("menu.php"); without the tags, the code I'm using to impor
php-general Digest 13 Jun 2003 05:38:05 - Issue 2114
Topics (messages 151282 through 151330):
Re: mail() function & exchange
151282 by: Diana
151283 by: Mark
151287 by: Diana
Re: How to find if a string is an integer?
151284 by: Felipe Desiderati
1512
- Original Message -
From: "Ben Houlton" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, June 13, 2003 2:49 PM
Subject: [PHP] Gettnig PHP code out of a DB?
Er...you need to eval() it to get it to parse/run.
> Is there a way to get PHP script/code out of a DB? Becasue, when I
e
I use
echo $msg;
eval("\$msg = \"$msg\";");
echo $msg;
and it comes up with
include("menu.php");
on the live page
"Leif K-Brooks" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> www.php.net/eval
>
> Ben Houlton wrote:
>
> >Is there a way to get PHP script
*sigh* Just do:
eval($msg);
Ben Houlton wrote:
I use
echo $msg;
eval("\$msg = \"$msg\";");
echo $msg;
and it comes up with
include("menu.php");
on the live page
"Leif K-Brooks" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
www.php.net/eval
Ben Houlton wrot
You have to use socket connection. Take a look at:
http://us4.php.net/fsockopen
In the User Contributed Notes look for a post by
info at agriya dot com
02-Feb-2003 12:38
there you will see a script that shows you how to do it.
Hope this helps.
-Original Message-
From: Joaco [mailto:
Daniel,
Rather than sending them to a new page to validate the form and then
sending them back if a field is invalid, do the error checking from the
same script.
Here's an example, a bit simple but just to give you an idea.
For a better explanation, you should read this article which elaborates
101 - 131 of 131 matches
Mail list logo