Suppose I have a variable $i = 0 or 1 or 2
and I have variables $item0, $item1 and $item2
how do I print the variable $item0 using a combination of variable $item and
variable $i?
or with this code it gives me an error:
$i = 0;
$item0 = test;
echo $item$i; #how do I properly use this variable
- Original Message
From: Grega Leskovšek legr...@gmail.com
To: php-general@lists.php.net
Sent: Thursday, September 24, 2009 10:10:33 AM
Subject: [PHP] variable
Suppose I have a variable $i = 0 or 1 or 2
and I have variables $item0, $item1 and $item2
how do I print the variable
- Original Message
From: Tommy Pham tommy...@yahoo.com
To: Grega Leskovšek legr...@gmail.com; php-general@lists.php.net
Sent: Thursday, September 24, 2009 10:16:44 AM
Subject: Re: [PHP] variable
- Original Message
From: Grega Leskovšek
To: php-general
Suppose I have a variable $i = 0 or 1 or 2
and I have variables $item0, $item1 and $item2
how do I print the variable $item0 using a combination of variable $item and
variable $i?
or with this code it gives me an error:
$i = 0;
$item0 = test;
echo $item$i; #how do I properly use this
Hi Grega
I think you might want to have a look at the array's section of the php
manual.
http://www.php.net/array
regards Lars
tor, 24 09 2009 kl. 19:10 +0200, skrev Grega Leskovšek:
Suppose I have a variable $i = 0 or 1 or 2
and I have variables $item0, $item1 and $item2
how do I print the
At 2:16 AM +0700 9/18/09, saeed ahmed wrote:
hello guys,
i'm new here in this list. guys i need a help. i can't assign a js variable
value to a php variable. how can i do this?
saeed:
Considering that js is client-side and php is server-side, you need
to pass the value via a communication
. i can't assign a js variable
value to a php variable. how can i do this?
--
Regards,
Saeed Ahmed
Rajshahi, Bangladesh
Blog: http://saeed05.wordpress.com
--
Follow Me Linkedin
http://www.linkedin.com/in/sas05Twitterhttp://twitter.com/saeed05
--
PHP General Mailing List (http
with the server
side code that is your php :).
Regards,
Gautam Bhatia
Punjab,India
mail2gautambha...@gmail.com
On Fri, 2009-09-18 at 02:16 +0700, saeed ahmed wrote:
hello guys,
i'm new here in this list. guys i need a help. i can't assign a js
variable
value to a php variable. how can i
basicly is use hidden inputs as a container for php variables, and transform
through js.
really? I though the other way round was extremely simple:
echo 'script type=text/javascriptvar
myPHPvar=eval(('.addslashes(json_encode($myPHPvar)).'));/script';
why would you use hidden input, plus
@lists.php.net
Date: Fri, 18 Sep 2009 13:01:28 +0200
Subject: RE: [PHP] how i assign a js variable to a php variable
basicly is use hidden inputs as a container for php variables, and transform
through js.
really? I though the other way round was extremely simple:
echo 'script type=text
i assign a js variable to a php variable
basicly is use hidden inputs as a container for php variables, and
transform
through js.
really? I though the other way round was extremely simple:
echo 'script type=text/javascriptvar
myPHPvar=eval(('.addslashes(json_encode($myPHPvar
-general@lists.php.net
Date: Fri, 18 Sep 2009 13:01:28 +0200
Subject: RE: [PHP] how i assign a js variable to a php variable
basicly is use hidden inputs as a container for php variables, and
transform
through js.
really? I though the other way round was extremely simple:
echo
You can not pass this myPHPvar javascript var as an input in a form. if you
want to change its value and maintein it, must to use an static var, and
only can access to this values via javascript functions where an event is
invoked (in case you want to read or write values)
with all due
hello guys,
i'm new here in this list. guys i need a help. i can't assign a js variable
value to a php variable. how can i do this?
--
Regards,
Saeed Ahmed
Rajshahi, Bangladesh
Blog: http://saeed05.wordpress.com
--
Follow Me Linkedin
http://www.linkedin.com/in/sas05Twitterhttp://twitter.com
On Fri, 2009-09-18 at 02:16 +0700, saeed ahmed wrote:
hello guys,
i'm new here in this list. guys i need a help. i can't assign a js variable
value to a php variable. how can i do this?
--
Regards,
Saeed Ahmed
Rajshahi, Bangladesh
Blog: http://saeed05.wordpress.com
--
Follow Me
I have to disagree Ash, you can pass js variable values to PHP but only
through a page load. Then you could use $_REQUEST, $_POST, $_GET to retrieve
it. I have done this before.
And I am sure Ash does it on daily basis, the problem is the used therm: I want
to *assign* ... not pass, assign!
-Original Message-
From: Ashley Sheridan [mailto:a...@ashleysheridan.co.uk]
Sent: Thursday, September 17, 2009 3:19 PM
To: saeed ahmed
Cc: php-general@lists.php.net
Subject: Re: [PHP] how i assign a js variable to a php variable
On Fri, 2009-09-18 at 02:16 +0700, saeed ahmed wrote
On Sep 17, 2009, at 2:43 PM, Andrea Giammarchi wrote:
I have to disagree Ash, you can pass js variable values to PHP but
only
through a page load. Then you could use $_REQUEST, $_POST, $_GET to
retrieve
it. I have done this before.
And I am sure Ash does it on daily basis, the problem
for that. You were absolutely correct in your statement about not
being able to directly assign the value of a javascript variable to a PHP
variable. I just felt that your response would leave the reader to believe
that that wasn't any way to pass the value at all. In my attempt to throw my
two cents
Hello, all.
I have a working app that runs in PHP 4.4.9 on the server. I develop
the app on my local environment, which runs PHP 5.2.6.
The setup is thus:
From my index, I have
require_once('config.php');
require_once('dbstuff.php');
config.php looks like this:
?php
$db_host =
I'm using an OnClick routine to set a session variable before I go
to another page.
onClick=?php $_SESSION['local_part']= 'rick'; ? works fine but I
need a variable where rick is
I've tried
onClick=?php $_SESSION['local_part']= $local_part; ?
and other variations but it doesn't work.
Can
Rick Duval wrote:
I'm using an OnClick routine to set a session variable before I go
to another page.
onClick=?php $_SESSION['local_part']= 'rick'; ? works fine but I
need a variable where rick is
I've tried
onClick=?php $_SESSION['local_part']= $local_part; ?
and other variations but it
I posted this once before, and then tried to use it multiple times in a
script. As you can guess I got a bunch of func already defined errors.
Here is a revision incase anyone decided to use it that will work multiple
times in the same script for variable watching.
---Code follows---
On Mon, 2009-01-12 at 16:11 -0500, Frank Stanovcak wrote:
I posted this once before, and then tried to use it multiple times in a
script. As you can guess I got a bunch of func already defined errors.
Here is a revision incase anyone decided to use it that will work multiple
times in the
Ashley Sheridan a...@ashleysheridan.co.uk wrote in message
news:1231796437.3558.62.ca...@localhost.localdomain...
On Mon, 2009-01-12 at 16:11 -0500, Frank Stanovcak wrote:
I posted this once before, and then tried to use it multiple times in a
script. As you can guess I got a bunch of func
Frank Stanovcak wrote:
I posted this once before, and then tried to use it multiple times in a
script. As you can guess I got a bunch of func already defined errors.
Here is a revision incase anyone decided to use it that will work multiple
times in the same script for variable watching.
Chris dmag...@gmail.com wrote in message
news:496bbd52.2080...@gmail.com...
Frank Stanovcak wrote:
I posted this once before, and then tried to use it multiple times in a
script. As you can guess I got a bunch of func already defined errors.
Here is a revision incase anyone decided to use
At 11:06 AM +1100 12/24/08, Clancy wrote:
On Tue, 23 Dec 2008 10:25:13 -0500, tedd.sperl...@gmail.com (tedd) wrote:
Two things:
1. One statement, one line.
2. The code between the two examples is different; produces different
results; and thus is rather pointless in making a definitive
oops, yes of course lol
Tim-Hinnerk Heuer
http://www.ihostnz.com
On Tue, Dec 23, 2008 at 7:43 PM, Lars Torben Wilson larstor...@gmail.comwrote:
2008/12/22 German Geek geek...@gmail.com:
agree, ++$i wont save u nething, it just means that the variable is
incremented after it is used:
You
On Mon, 22 Dec 2008 22:40:58 -0800, larstor...@gmail.com (Lars Torben Wilson)
wrote:
Well, in all fairness, it *is* faster--but you'll only notice the
difference in extremely tight and long-running loops (try it ;) ). As
long as you know why you're using it and what the side effects are, it
At 9:10 AM +1100 12/23/08, Clancy wrote:
Schlossnagle (in Advanced PHP Programming) advises:
$i = 0; while ($i $j)
{
++$i;
}
rather than:
$i = 0; while ($i $j)
{
...
$i++;
}
as the former apparently uses less
On Tue, 23 Dec 2008 10:25:13 -0500, tedd.sperl...@gmail.com (tedd) wrote:
At 9:10 AM +1100 12/23/08, Clancy wrote:
Schlossnagle (in Advanced PHP Programming) advises:
$i = 0; while ($i $j)
{
++$i;
}
rather than:
$i = 0; while ($i $j)
{
...
MikeP schreef:
Hello,
I am trying to output the value of the following:($x is an int incremented
by a for statement.
echo tr
td width='110' bgcolor='$row_color' nowrap
'$users[$x][U]'/td
/tr;
I have tried putting the quotes all over and all I get is:
'Array[U]'.
What
On Mon, 22 Dec 2008 10:20:09 +1100, dmag...@gmail.com (Chris) wrote:
I'd call this a micro-optimization. If changing this causes that much of
a difference in your script, wow - you're way ahead of the rest of us.
Schlossnagle (in Advanced PHP Programming) advises:
$i = 0; while ($i
On Mon, Dec 22, 2008 at 3:10 PM, Clancy clanc...@cybec.com.au wrote:
On Mon, 22 Dec 2008 10:20:09 +1100, dmag...@gmail.com (Chris) wrote:
I'd call this a micro-optimization. If changing this causes that much of
a difference in your script, wow - you're way ahead of the rest of
agree, ++$i wont save u nething, it just means that the variable is
incremented after it is used:
$i = 0;
while ($i 4) echo $i++;
will output
0123
while
$i = 0;
while ($i 4) echo ++$i;
will output
1234
Tim-Hinnerk Heuer
http://www.ihostnz.com
On Tue, Dec 23, 2008 at 7:25 PM, Nathan
2008/12/22 Nathan Nobbe quickshif...@gmail.com:
On Mon, Dec 22, 2008 at 3:10 PM, Clancy clanc...@cybec.com.au wrote:
On Mon, 22 Dec 2008 10:20:09 +1100, dmag...@gmail.com (Chris) wrote:
I'd call this a micro-optimization. If changing this causes that much of
a difference in your
2008/12/22 German Geek geek...@gmail.com:
agree, ++$i wont save u nething, it just means that the variable is
incremented after it is used:
You meant . . .before it is used:, right?
Torben
$i = 0;
while ($i 4) echo $i++;
will output
0123
while
$i = 0;
while ($i 4) echo ++$i;
On Mon, Dec 22, 2008 at 11:43 PM, Lars Torben Wilson
larstor...@gmail.comwrote:
2008/12/22 German Geek geek...@gmail.com:
agree, ++$i wont save u nething, it just means that the variable is
incremented after it is used:
You meant . . .before it is used:, right?
i hope so, coming from an
Hello,
I am trying to output the value of the following:($x is an int incremented
by a for statement.
echo tr
td width='110' bgcolor='$row_color' nowrap
'$users[$x][U]'/td
/tr;
I have tried putting the quotes all over and all I get is:
'Array[U]'.
What am I doing wrong.
Thanks
MikeP schrieb:
I have tried putting the quotes all over and all I get is:
'Array[U]'.
Try to avoid accessing the two-dimensional array $users inside a string.
Use echo's ability to accept multiple parameters:
echo 'trtd.', $users[$x]['U'], '/td';
Or by concating the string with
$users is an array and you are trying to simply put it in a string. $x seems
to be undefined ergo it's not printing anything. If 'U' is the index in the
array for your variable, use the '.' operator to concatenate strings:
echo tr
td width='110' bgcolor='$row_color' nowrap
' .
OK. I would think it uses more memory then, but doubt it would be slower.
Isnt the output buffered in memory anyway though in PHP? Surely the buffer
is bigger than 100 bytes (which is about the length of this string). So one
way or the other, the memory is used.
Tim-Hinnerk Heuer
Why is the first method faster and uses less memory?
Tim-Hinnerk Heuer
http://www.ihostnz.com
On Mon, Dec 22, 2008 at 10:59 AM, Marc Steinert li...@bithub.net wrote:
MikeP schrieb:
I have tried putting the quotes all over and all I get is:
'Array[U]'.
Try to avoid accessing the
German Geek schrieb:
Why is the first method faster and uses less memory?
Because the concatenation operator first reassembles a new string,
stores it in memory then passes this newly created string to the echo
function, if I'm not misstaken.
--
http://bithub.net/
Synchronize and share
for e.g.
$var = 'world';
echo hello $var;
vs
echo 'hello '.$var;
The first uses twice as many opcodes as compared to the second. The first is
init a string and adding to it the first part(string) and then the second
part (var); once completed it can echo it out. The second is simply two
opcodes,
True, it might mean the very slightest in milliseconds...depending on what
you're doing/hardware. However, no harm in understanding the difference/how
it works.
Many will code echo Hello World and echo 'Hello World'; and never know the
difference, I just happen to think being aware of the details
Anthony Gentile wrote:
True, it might mean the very slightest in milliseconds...depending on
what you're doing/hardware.
Connecting to a db will (probably) take longer than most of those
differences, let alone running a query processing the results.
Ternaries that make a lot of people feel
Anthony Gentile wrote:
for e.g.
$var = 'world';
echo hello $var;
vs
echo 'hello '.$var;
The first uses twice as many opcodes as compared to the second. The first is
init a string and adding to it the first part(string) and then the second
part (var); once completed it can echo it out. The
Yes, i agree with this. Even if it takes a few nano seconds more to write
out more understandable code, it's worth doing it because code management is
more important than sqeezing out the last nano second. And then also an
$var = Hello;
echo $val World;
has less characters than and is more
2008/12/21 German Geek geek...@gmail.com:
Yes, i agree with this. Even if it takes a few nano seconds more to write
out more understandable code, it's worth doing it because code management is
more important than sqeezing out the last nano second. And then also an
$var = Hello;
echo $val
I'm new to PHP 5 and classes, but I've done a lot of ActionScript.
I'm trying to use PHPMailer inside my own class (a service for AMFPHP).
I'm having problems getting the data that'spassed into my class's send()
method to the instance of the PHPMailer.
Basically, I have this:
class EmailAMF
Jim McIntyre wrote:
I'm new to PHP 5 and classes, but I've done a lot of ActionScript.
I'm trying to use PHPMailer inside my own class (a service for
AMFPHP). I'm having problems getting the data that'spassed into my
class's send() method to the instance of the PHPMailer.
Basically, I have
metastable wrote:
Jim McIntyre wrote:
$phpMail = new PHPMailer();
$phpMail-From = $from;
$phpMail-AddAddress($this-to);
$phpMail-Subject = $subject;
$phpMail-Body = $body;
return $phpMail-Send();
$this - to
it has no meaning in the scope of your class.
Apparently,
Jim McIntyre wrote:
metastable wrote:
Jim McIntyre wrote:
$phpMail = new PHPMailer();
$phpMail-From = $from;
$phpMail-AddAddress($this-to);
$phpMail-Subject = $subject;
$phpMail-Body = $body;
return $phpMail-Send();
Never mind - I found the problem. It was a lowly
I've been experimenting with having a varaible constant name, but failed
miserably... Can I please have a pointer?
What I'm trying to do is something like this:
$name = home;
Then read the constant IMG_HOME, like IMG_$name, I'm not sure I make myself
understood, but I hope so..
Anders.
--
Anders Norrbring wrote:
I've been experimenting with having a varaible constant name, but failed
miserably... Can I please have a pointer?
What I'm trying to do is something like this:
$name = home;
Then read the constant IMG_HOME, like IMG_$name, I'm not sure I make myself
understood, but I
I dont think you can do that with a constant, but you can do this a
normal variable:
I stand under correction form my previous email, it can be done:
define('TEST', 'the value of constant TEST');
$var= 'TEST';
echo constant($var);
--
PHP General Mailing List (http://www.php.net/)
To
, 2008 9:18 AM
Subject: Re: [PHP] Variable name for constants?
I dont think you can do that with a constant, but you can do this a
normal variable:
I stand under correction form my previous email, it can be done:
define('TEST', 'the value of constant TEST');
$var= 'TEST';
echo constant
I dont think you can do that with a constant, but you can do this a
normal variable:
I stand under correction form my previous email, it can be done:
define('TEST', 'the value of constant TEST');
$var= 'TEST';
echo constant($var);
This may be too early in the morning for me,
, December 11, 2008 9:18 AM
Subject: Re: [PHP] Variable name for constants?
I dont think you can do that with a constant, but you can do this a
normal variable:
I stand under correction form my previous email, it can be done:
define('TEST', 'the value of constant TEST');
$var
Richard Heyes wrote:
...
And you might also be interested in func_get_args(), which returns an
array of args passed to the function (don't know what it does if used
outside a function. Probably get an error).
yup..
bWarning/b: func_get_args(): Called from the global scope - no
function
On Fri, Nov 14, 2008 at 8:13 PM, Daniel Kolbo [EMAIL PROTECTED] wrote:
Hello,
I am trying to do something like the following:
?php
function hello($var1 = 'default1', $var2 = 'default2') {
echo $var1:$var2;
}
$func= hello;
$args = 'yo','bob';
$func($args);
?
I understand why this
yup..
bWarning/b: func_get_args(): Called from the global scope - no
function context
Doesn't the name of the function give you a clue as to its use? You
need to call it inside a function.
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and Safari:
http://www.rgraph.org (Updated
On Mon, 2008-11-17 at 11:54 -0500, Shiplu wrote:
On Fri, Nov 14, 2008 at 8:13 PM, Daniel Kolbo [EMAIL PROTECTED] wrote:
Hello,
I am trying to do something like the following:
?php
function hello($var1 = 'default1', $var2 = 'default2') {
echo $var1:$var2;
}
$func= hello;
Richard Heyes wrote:
yup..
bWarning/b: func_get_args(): Called from the global scope - no
function context
Doesn't the name of the function give you a clue as to its use? You
need to call it inside a function.
He was answering Nathan's question regarding what would happen IF you
...
And you might also be interested in func_get_args(), which returns an
array of args passed to the function (don't know what it does if used
outside a function. Probably get an error).
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and Safari:
http://www.rgraph.org (Updated November
Hello,
I am trying to do something like the following:
?php
function hello($var1 = 'default1', $var2 = 'default2') {
echo $var1:$var2;
}
$func= hello;
$args = 'yo','bob';
$func($args);
?
I understand why this outputs:
'yo','bob':default2
However, I want it to output:
yo:bob
Is this
Daniel Kolbo wrote:
Hello,
I am trying to do something like the following:
?php
function hello($var1 = 'default1', $var2 = 'default2') {
echo $var1:$var2;
}
$func= hello;
$args = 'yo','bob';
$func($args);
?
I understand why this outputs:
'yo','bob':default2
However, I want it to
$varname = \$_SERVER['REMOTE_ADDR'];
$varvalue = $$varname;
That's wrong. Offhand you'll end up printing a string. I tried this:
?php
$a = 365;
$b = 366;
$var = $_GET['var'];
echo $$var;
?
And it was fine.
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and
That's fine as a test, but you never want to get a variable name from a
URL in practice.
Thank you,
Micah Gersten
onShore Networks
Internal Developer
http://www.onshore.com
Richard Heyes wrote:
$varname = \$_SERVER['REMOTE_ADDR'];
$varvalue = $$varname;
That's wrong. Offhand you'll
That's fine as a test, but you never want to get a variable name from a
URL in practice.
Of course you can, as long as it's sanitized and checked.
--
Richard Heyes
HTML5 Graphing for FF, Chrome, Opera and Safari:
http://www.rgraph.org
--
PHP General Mailing List (http://www.php.net/)
To
I mean that it is open for hacking if you pass a variable name through a
URL.
Thank you,
Micah Gersten
onShore Networks
Internal Developer
http://www.onshore.com
daniel danon wrote:
What do you mean?
On Sun, Oct 12, 2008 at 5:40 PM, Micah Gersten [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
Hi, I was wondering,
By php.net manual, Please note that variable variables cannot be used with
PHP's Superglobal arrays within functions or class methods. Is there any
way to override this problem? Just the not nice eval(return $variable);?
and in simple words - is there any way to make the
Could someone tell me how to get the name of a variable as a string.
This would be useful in form submission with multiple check-boxes to
match against database records. At the moment I use ${var.$ID[$x]} or
someting like that to go through all the possible matches, but it would
be quicker
U could use an array to keep all of your fieldnames as keys and the values
would be the values of the form inputs.
That would be very easy and with no programagic.
On Wed, Aug 27, 2008 at 3:00 PM, ioannes [EMAIL PROTECTED] wrote:
Could someone tell me how to get the name of a variable as a
On Tue, Aug 5, 2008 at 1:40 AM, Philip Thompson [EMAIL PROTECTED] wrote:
Is it possible to grab a variable number of parameters and send the
appropriate amount to another function?
You can predefine function parameters:
?php
function example($line1,$line2=There is no line 2.) {
echo
On Aug 5, 2008, at 8:58 AM, Daniel Brown wrote:
On Tue, Aug 5, 2008 at 1:40 AM, Philip Thompson [EMAIL PROTECTED]
wrote:
Is it possible to grab a variable number of parameters and send the
appropriate amount to another function?
You can predefine function parameters:
?php
function
Philip Thompson wrote:
On Aug 5, 2008, at 8:58 AM, Daniel Brown wrote:
On Tue, Aug 5, 2008 at 1:40 AM, Philip Thompson
[EMAIL PROTECTED] wrote:
Is it possible to grab a variable number of parameters and send the
appropriate amount to another function?
You can predefine function
Philip Thompson wrote:
but more likely, you're looking for func_get_args().
http://php.net/func_get_args
Fortunately, I am quite familiar with your example. However, I am more
looking for something in which I could send any number of parameters
to my own function, grab each
On Aug 5, 2008, at 10:34 AM, Igor Kolodziejczyk wrote:
Philip Thompson wrote:
On Aug 5, 2008, at 8:58 AM, Daniel Brown wrote:
On Tue, Aug 5, 2008 at 1:40 AM, Philip Thompson [EMAIL PROTECTED]
wrote:
Is it possible to grab a variable number of parameters and send the
appropriate amount to
Philip Thompson wrote:
This isn't exactly what I'm wanting to achieve. I don't want to send
each parameter individually, I want to send them all at the same time.
Sounds like you want the standard varargs behaviour from C ? Where you
can gather up a list of arguments as a va_list and pass that
Philip Thompson wrote:
Is it possible to grab a variable number of parameters and send the
appropriate amount to another function?
?php
// Some class
$this-db-prepare(SELECT * FROM `table` WHERE (`id`=?));
$this-db-bind('ii', $id1);
$this-db-prepare(SELECT * FROM `table` WHERE (`id`=? AND
On Tue, Aug 5, 2008 at 6:07 PM, Jim Lucas [EMAIL PROTECTED] wrote:
# WARNING
# The following example uses eval() to do the execution.
# The following answer is a YMMV answer.
# Be careful with it. I could be a sleeping snake waiting to bite...
#
Errata for those of you
On Tuesday 05 August 2008 12:40:27 am Philip Thompson wrote:
Ok, is it possible to send any number of variables to db-bind() in
order to send those to statement-bind_param()?
Or, if someone else has a better db abstraction method, feel free to
educate...
Thanks,
~Phil
Unless I'm
Is it possible to grab a variable number of parameters and send the
appropriate amount to another function?
?php
// Some class
$this-db-prepare(SELECT * FROM `table` WHERE (`id`=?));
$this-db-bind('ii', $id1);
$this-db-prepare(SELECT * FROM `table` WHERE (`id`=? AND
`other_id`=?));
Greetings,
The following code works in every way except one. The variable,
$linkspage, in the link, will not replace with information from the
database for some reason. No matter what else I put in $id_num,
$filename or whatever it replaces, but not $linkspage. The variable
does work
Couple things, read in-line...
Steve Marquez wrote:
Greetings,
The following code works in every way except one. The variable,
$linkspage, in the link, will not replace with information from the
database for some reason. No matter what else I put in $id_num,
$filename or whatever it
Ok, I forgot to reply-all to the list. Here we go again.
On Wed, May 14, 2008 at 6:33 PM, Tyson Vanover [EMAIL PROTECTED] wrote:
I am trying to get a child class to pass an array of valid keys to it's
parent when the constructor is run, and the parent appends the data to one
of it's array of
I am trying to get a child class to pass an array of valid keys to it's
parent when the constructor is run, and the parent appends the data to
one of it's array of valid keys. Then it walks through an array pulling
out values that have valid keys, and putting them in an array for
processing
tyson
i never saw
self::$this-vkeys
doing this you actually are callig the var inside $this-vkeys
do self::$vkeys as static or $this-vkeys as object don't mix
regards
On Wed, May 14, 2008 at 7:33 PM, Tyson Vanover [EMAIL PROTECTED] wrote:
I am trying to get a child class to pass an array
I am trying to use variable variables in an array. ?The last line of code does
not work. ?More specifically the last variable in the last line of code does
not work in this setup. ?The array gets created with the appropriate indexes
however the values are blank. ?I can echo item_value and it
On Wed, Mar 5, 2008 at 4:58 AM, Pieter du Toit [EMAIL PROTECTED] wrote:
And unless you have your (Apache|IIS|etc.) web server set to
disable direct-access and/or web serving of *.inc files, you should
change these to *.php or *.inc.php files ASAP. Especially the first.
You're looking at a
On Feb 10, 2008 6:30 PM, Ron Piggott [EMAIL PROTECTED] wrote:
What is the command which shows the value of all the variables in
memory? Ron
get_defined_vars()
-nathan
What is the command which shows the value of all the variables in
memory? Ron
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
-- Forwarded message --
From: Nathan Nobbe [EMAIL PROTECTED]
Date: Jan 21, 2008 10:43 AM
Subject: Re: [PHP] change php variable depending on selection
To: stp [EMAIL PROTECTED]
On Jan 21, 2008 9:42 AM, stp [EMAIL PROTECTED] wrote:
I'm sorry…..I've got the conversion
I have stored. I can't seem to figure out how to, when you select
matt'sblog (for example), how to make it so that the php variable will be
populated with the rssfeed of matt's blog and then the feed will show. For
instance, selecting matt'sblog from the drop down list will make it so that
$url
the dropdown box so that it populates from my db the name
of
the blogs I have stored. I can't seem to figure out how to, when you
select
matt'sblog (for example), how to make it so that the php variable will be
populated with the rssfeed of matt's blog and then the feed will show. For
instance
of
the blogs I have stored. I can't seem to figure out how to, when you
select
matt'sblog (for example), how to make it so that the php variable will be
populated with the rssfeed of matt's blog and then the feed will show.
For
instance, selecting matt'sblog from the drop down list will make it so
that
$url
here is a complete, working example; hope it helps.
http://nathan.moxune.com/exampleDynamicSelect.php
-nathan
101 - 200 of 817 matches
Mail list logo