On Fri, 6 Jun 2003, Jay Blanchard wrote:
[snip]
I have a file named billed.crm.php and it fopen throws the error no
such file or directory. It seems to have something to do with the
multiple . in the file name. Does anyone know why?
It should make no difference. I hate to ask this
You guys should consider reading this:
http://www.php.net/manual/en/security.registerglobals.php
Most likely it's been updated since anyone here
read it, it covers everything discussed in this
thread.
Regards,
Philip
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
This is pretty straight forward. First, you really should
know where your data comes from, only you know that:
If it comes from GET, use $_GET
If it comes from POST,use $_POST
If it comes from COOKIE, use $_COOKIE
If it comes from SERVER, use $_SERVER
If it comes from ENV,
On Mon, 2 Jun 2003, Øystein Håland wrote:
What's the difference (and what's correct)?
With the use of error_reporting = E_ALL in php.ini I get an error as
mentioned above. In the code I use $_SERVER[PHP_SELF]. Changing this to
$_SERVER['PHP_SELF'] report no error but with error_reporting =
On Sat, 31 May 2003, Alberto Ferrer wrote:
Im compiling the last vercion of PHP 4.3.2 and says this after finish of
compile.
The system is a Redhat 7.3, Apache 1.3.27.
ext/mysql/libmysql/my_tempnam.lo: In function `my_tempnam':
/root/php-4.3.2/ext/mysql/libmysql/my_tempnam.c:115: the use
Me and a friend have been trying to make a php ftp client, it works fine on
*nix systems, but not on Windows. We looked at everything, until i finaly
noticed that php 4.2.3 is missing in the php.ini the extension=php_ftp.dll
line. The actualy file in the extensions dir is missing as well.
Read this:
http://www.php.net/variables.external
Be sure to note what register_globals means.
Regards,
Philip
On Thu, 29 May 2003, The Doctor wrote:
Questions, I have a
cusotmer using a basic username and password
verifier on a php Web Page.
This was working and suddenly with I
On Tue, 27 May 2003, Todd Barr wrote:
Morning
We recently moved out site to a new server, and scripts that use to work, no longer
do.
Like mysql_fetch_array worked fine, but now I am getting this error
mysql_fetch_array(): supplied argument is not a valid MySQL result resource
Any
When you found success in the loop you really should
end the loop otherwise it will keep checking and will
yield results as you describe. For example:
while (1) {
if (something) {
$foo = true;
break;
} else {
$foo = false;
}
}
When $foo = true, the loop
the exact problem
below.
Regards,
Philip
-Original Message-
From: Philip Olson [mailto:[EMAIL PROTECTED]
Sent: 27 May 2003 17:03
To: Jason Lange
Cc: [EMAIL PROTECTED]
Subject: Re: [PHP] Validation function doesn't work (sort of...)
When you found success in the loop you really
FWIW:
There is a proposal to add a runtime option to view
line numbers in the source, something like:
http://www.example.com/hi.phps?SHOW_LINENUMBERS
In fact, some even thought it was applied but alas
it never was. There is a little information on this
feature request here:
On Sun, 6 Apr 2003, Bobby Rahman wrote:
Hiya,
I have created a dynamic table within my form.
Above the table I want to insert a filter to order by:the column names
Here is the static list:
select name=select4
optionSeverity/option
optionCrash/option
If you really want to be optimal, use bitwise instead
of modulus :) And ++$i instead of $i++ :) And,
use single not double quotes :) Silly, but true.
http://www.faqts.com/knowledge_base/view.phtml/aid/783/fid/9
And, write less code, so:
$bgcolor = (++$i 1) ? '#ff' : '#ee';
On Wed, 2 Apr 2003, daniel wrote:
if u need it to work for both versions use $HTTP_POST_VARS instead
Keep in mind that the deprecated PHP directive
track_vars must be on for $HTTP_*_VARS type
variables to exist in PHP versions prior to
4.0.3
Regards,
Philip
--
PHP General Mailing List
On Thu, 3 Apr 2003, Justin French wrote:
Hi,
I can't believe I've never bothered to learn this stuff, so I apologise for
being totally dumb in advance :P
phpinfo() tells me my php.ini is being read from /usr/local/lib, however,
there's definitely NOT a php.ini file there.
That faq
On Thu, 3 Apr 2003, Justin French wrote:
Hi all,
Can I just have a quick head check on magic quotes runtime (gpc)?
I have them both set to Off currently, and my pages work fine. However,
when I set them to on, I end up with slashes throughout the mysql data.
This means you essentially
Read this:
http://www.php.net/features.commandline
PHP can run as a script indeed.
#!/usr/bin/php
Do that like you would perl and then make it executable. Should work.
Yes, assuming that's the name and location of the
CLI or CGI PHP (and one exists). Typing 'whereis php'
or 'which
This:
$word = 'test';
$len = strlen($word);
for ($a = 0; $a $len; $a++) {
print $word{$a} . \n;
}
Will print:
t
e
s
t
Regards,
Philip
On Thu, 27 Mar 2003, Oden Odenius wrote:
I have $word = test;
And i want to split it like
t
e
s
t
I want to make a loop.Like $a = 123; //$a
Regarding the location of php.ini, read this:
http://www.php.net/faq.installation.php#faq.installation.findphpini
Next, learn about using external variables in PHP:
http://www.php.net/variables.external
Now, regarding your example of: file.php?action=3 You'll notice
that you can use
/variables.scope
c) Constants must be scalar values in PHP4, (so
not arrays, objects, or resources).
d) Constants are cool, variables are cool too.
Regards,
Philip Olson
On Fri, 21 Feb 2003, Chris Corwin wrote:
Help, please -- I've just started looking at my first line of PHP code.
:)
A little
Read this faqt:
The PHP4TS.DLL file is linked to missing export
OLEAUT32.DLL:77 - Please help!!!
---
http://www.faqts.com/knowledge_base/view.phtml/aid/15670/fid/30
If you happen to be using Win95, don't, because PHP does
not
On 4 Feb 2003, Adam Voigt wrote:
I believe he meant the HTML source of an HTML page.
An example in the manual does exactly this:
http://www.php.net/file
Regards,
Philip
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
[snip]
How should I display the page ... the page has a lot of html code and
trying to write echoblah blah blah . ;
will not be a an option. Please suggest a way out .
Use includes:
http://www.php.net/include
And write HTML as HTML:
h3Greetings/h3
pHello b?php echo $username
I want to display an HTML page if PHP can't load an include
file or otherwise has an error or just doesn't work.
How do I do this?
include returns false on failure and here's a hack to
demonstrate. Once you implement your own error
handling, be sure to set error_reporting accordingly
or
On Tue, 4 Feb 2003, The New Source wrote:
How can I get a certain line from a file?
If I get a file in this way:
$f = fopen(http://www.url.com/index.htm,r;);
How can I get a certain line of the file index.htm?
I would need to get the line number 232, or lines from 232 to 238. How
On Tue, 4 Feb 2003, Bob Lockie wrote:
I don't appear to be able to use this variable in an include directive
because the variable is empty:
include $_SERVER['DOCUMENT_ROOT']
Do I have the syntax incorrect?
Please post the exact syntax as you did not as the
above will provide a serious
On Tue, 4 Feb 2003, Bob Lockie wrote:
On 02/04/03 13:16 Philip Olson spoke thusly
On Tue, 4 Feb 2003, Bob Lockie wrote:
I don't appear to be able to use this variable in an include directive
because the variable is empty:
include $_SERVER['DOCUMENT_ROOT']
Do I have the syntax
Read this:
http://www.php.net/features.http-auth
Regards,
Philip
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On Mon, 3 Feb 2003, Sunfire wrote:
do this:
run your php query to get the value of the text box and then do this:
?php
//connect to db here
$query=//put your query here
while($foo=mysql_fetch_array($query)){
//if you use mysql that is...
echo input type=text name=YourVarName value=\$foo\;
On Mon, 3 Feb 2003, Chris Shiflett wrote:
--- Philip Olson [EMAIL PROTECTED] wrote:
No offense Sunfire but I don't think you're ready to
be answering questions.
Please try to be a little more kind. While his answer does
have problems, his helpful attitude is a good thing.
Whenever
On Sat, 1 Feb 2003, Hugh Danaher wrote:
echo(| %s | %s | %s | %s | %s |br /, $array[id], $array[username],
$array[password], $array[status], $array[notes]);
try
echo | %s | %s | %s | %s | %s |br /.$array[id]. .$array[username].
.$array[password]. .$array[status]. .$array[notes];
dots
On Sun, 2 Feb 2003, Lon Lentz wrote:
Is there a PHP version of the ColdFusion tag CFParam?
Go here:
http://marc.theaimsgroup.com/?l=php-generals=cfparam
Regards,
Philip
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On Sun, 2 Feb 2003, Davy Obdam wrote:
Hi ppl,
I have a problem that probably very simple, but i cannot figure it out
right now
I need to get the field names of my database. I have a query like select
* from books and now i wanna have both the result and the field name. I
have been
On Sun, 2 Feb 2003, Sunfire wrote:
i have a listbox:
select name=users
?php
//connect to db and get query
mysql_connect(.);
mysql_select_db(...);
$query=mysql_query(select username from users);
/*finish the listbox*/
while($account=mysql_fetch_array($query)){
echo option
On Sun, 2 Feb 2003, Øystein Håland wrote:
Jason Sheets [EMAIL PROTECTED] skrev i meddelandet
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
Take a look at the getlastmod() function, an example of the usage would
be:
$last_mod = date (F d Y H:i:s., getlastmod());
Then you can print or
On Sat, 1 Feb 2003, Beauford.2002 wrote:
Hi,
Is there a way to pass a variable to a PHP script without using a form? I
want to put several links on my main page that when clicked on goes to a PHP
script - depending on what link was selected, will determine what part of
the PHP script gets
I am studying on php. And the book say, when the server see php extension it
is running php file and giving results to the visiting browser.
But as I see related directories are normal directory, doesn' t like cgi-bin
directories.
Is there any change to see php file source such as file
On Sat, 1 Feb 2003, CF High wrote:
Hey all.
In cold fusion I was able to define a default value with the cfparam name =
test default = myValue tag
When I passed the variable test via a form or query string, it would over
ride the parameter value.
How can I do this in PHP? I looked in
On Sat, 1 Feb 2003, Sunfire wrote:
if i do this:
/*all the mysql login stuff here*/
$query=mysql_query(select * from members);
while($new=mysql_fetch_array($query)){
echo $new['company'];
/*so on through the field list*/
}
on output all i get is the title with a submit button..
}
?
input type=submit value=send
/form
/html
/*end*/
any changes to make it work would be appreciated...tnx
- Original Message -
From: Philip Olson [EMAIL PROTECTED]
To: Sunfire [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Saturday, February 01, 2003 6:48 PM
On Sun, 2 Feb 2003, Pat Johnston wrote:
I've read that an include file in each of your pages with the lines below
should do the trick for you with register_globals OFF..
Not sure if this is a valid way to go though...
?php
extract($_SERVER);
extract($_ENV);
On Sat, 1 Feb 2003, Karl James wrote:
Hello guys and gals!!!
can you tell me why i can't get this script to print my
table
thanks Karl
please check out the code below
obviously i left my username and passwords blank :-)
On Sun, 2 Feb 2003, Michael Sims wrote:
On Sat, 1 Feb 2003 19:59:00 -0800, you wrote:
PHP keeps track of what line# is being executed, so that when there's an
error (say in pg_exec() ) it reports what line the error occured on.
[...]
Is there a function where I can access this
On Fri, 31 Jan 2003, Tracy Finifter Rotton wrote:
Change the name of your checkboxes in your HTML to something like:
name=DeleteIDs[]
This will make it an array, and you can access all the elements like
$_POST['DeleteIDs'][0]
etc.
(This should really be in a FAQ somewhere...)
On Fri, 31 Jan 2003, Weston Houghton wrote:
All,
I seem to be getting a silly error on Solaris when trying to do a PHP
4.3 make. I get an error that looks to me like the liner arguments are
just too long. to be honest, I'm a bit stupified as to why this is
happening or how to fix
On Thu, 30 Jan 2003, Chris Hayes wrote:
At 12:18 30-1-2003, you wrote:
sure this would work but it'd be VERY inefficient in my application. It's a
file browser application so i have hundreds of folder icons on a page .. the
'submit' element will pass back the name of the button clicked and
On Thu, 30 Jan 2003, Cesar Rodriguez wrote:
Hi there, my name is Cesar Rodriguez and I am trying to upgrade from Caldera
Linux Server 2.3 into RedHat Server 8.0. The problem I encounter is that
after testing different scripts, php is working, except when I make an MySQL
call like
One too many $'s in your code, use:
$_REQUEST['my_passed_variable']
This is how all arrays work, autoglobals are the same.
See also:
http://www.php.net/variables.external
http://www.php.net/variables.predefined
Regards,
Philip
On Wed, 29 Jan 2003, CF High wrote:
Hey all.
You never answered if this was in a function or class
method. Is it? Did you say whether it was Apache 1 or 2?
Also, to check what the register_globals setting really
is, make a call to phpinfo() as it will tell you the
true setting. Sometimes the wrong php.ini is edited
or the web server
[snip]
I assume i could use solution A above, and parse the _x out of the name
value .. but this seems pretty hoaky and it's my understanding soultion B is
[snip]
This is how it's done. If this is set, the button
was clicked. For example:
if (isset($_REQUEST['thebuttonname_x'])) {
Regarding keeping . as . and not _ in variables:
This isn't going to happen as it seriously breaks
BC. This also would affect functions such as
import_request_variables() and extract(). There
is no worthy benefit here, this will never happen.
Regards,
Philip
--
PHP General Mailing
On Mon, 27 Jan 2003, Wei Weng wrote:
Is there any environment/Global variable in PHP that indicates whether the
server port you connect to is SSL port?
$_SERVER['HTTPS']
Regards,
Philip
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On Mon, 27 Jan 2003, George E. Papadakis wrote:
Hello,
Has anyone noticed strange behaviour in strap_tags @ php 4.3?
We did upgrade to the latest snap yet the problem remains. For some reason
strip_tags acts weird..
Please be specific with a short self-contained example
that demonstrates
On Mon, 27 Jan 2003, Guru Geek wrote:
Hello,
I'm a recent convert from CGI/Perl and so am still getting my feet wet
in PHP.
Here's my code:
$filename = http://www.myserver.com/include/sometext.txt;;
$handle = fopen ($filename, rb);
$contents = fread ($handle, filesize ($filename));
On Mon, 27 Jan 2003, Guru Geek wrote:
Sorry, here is the code now ( I need a nap )
$filename
=/usr/local/plesk/apache/vhosts/myserver.com/httpdocs/include/text.txt;
$handle = fopen ($filename, r);
$contents = fread ($handle, filesize ($filename));
fclose ($handle);
echo $contents;
exit;
Read:
http://www.php.net/variables.scope
Also note that $_SERVER is an autoglobal.
Regards,
Philip
On Sun, 26 Jan 2003, @ Nilaab wrote:
Hello Everyone,
I am a little confused. Why do predefined variables like $PHP_SELF or
$DOCUMENT_ROOT not process within a class, in the methods
Whenever you get a segfault, try the latest
stable release and during compile be sure to
use --enable-debug
:
http://snaps.php.net/
If the segfault exists here, write a bug report
and include the backtrace:
http://bugs.php.net/how-to-report.php
http://bugs.php.net/
This will be of great
On Sun, 26 Jan 2003, Beogradjanin wrote:
Zdravo php-general,
Hi I have setup PHP Apache MySql.
I;m new in this stuff where can I learn hot to make web pages in
PHP...???
Go here:
Learn HTML
http://www.w3schools.com/html/
Learn SQL
http://www.w3schools.com/sql/
img src=?php $ps; ?
img src=?php echo $ps; ?
Regards,
Philip
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Everyone from this thread needs to reread this:
http://www.php.net/variables.external
Regards,
Philip
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
How do I access $DOCUMENT_ROOT when register_gobals is set off? I think
there's an array, something like $HTTP_ENV_VARS['DOCUMENT_ROOT'] but I can't
find it in the documentation.
http://www.php.net/variables.predefined
Regards,
Philip
--
PHP General Mailing List (http://www.php.net/)
To
Which part of $_whatever is the REQUEST_URI be found from?
It's a web server predefined variable so only lives
in $_SERVER.
http://www.php.net/variables.predefined
Regards,
Philip
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On Sun, 5 Jan 2003, thkiat wrote:
Do you kow how can I upgrade the PHP 4.1.1 in PHPTriad to PHP 4.3.0?
I need PHP 4.3.0. as it includes a version of gd (GD Library) as standard
equipment.
GD is not standard equipment, a special version
is just bundled in PHP source now. It sounds like
you
Another good one:
fudforum:
http://fud.prohost.org/
Regards,
Philip
On Tue, 24 Dec 2002, [windows-1254] Fatih Üstündað wrote:
do you know freeware forum in php I can easly use?
thanks.
fatih ustundag
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit:
I've heard that RH8 decided to disable short tags
in their default php.ini If this is true, the people
at RedHat deserve a good spanking. Talk about being
irresponsible!
Regards,
Philip
On Tue, 24 Dec 2002, Tom Woody wrote:
I have found this to be very true with RedHat 8 (includes
:
http://www.php.net/variables.external
Regards,
Philip Olson
On Sat, 21 Dec 2002, Beauford.2002 wrote:
Thanks for the info, but . is_numeric does not appear to accept
variables i.e. is_numeric($num) and ctype gives me the following.
Fatal error: Call to undefined function: ctype_digit
This tutorial lists many oop tutorials:
Know of any basic tutorials on PHP Classes and OOP?
---
http://www.faqts.com/knowledge_base/view.phtml/aid/7569
Regards,
Philip Olson
On Mon, 23 Dec 2002, Wee Keat wrote:
Hi Justin
Use is_numeric()
http://www.php.net/is_numeric
See also the ctype functions which can
be read about here:
http://www.php.net/ctype
And yes, regular expressions are another
option but aren't needed here.
Regards,
Philip Olson
On Sat, 21 Dec 2002, Beauford.2002 wrote:
Hi,
First off
, that would be ideal.
Regards,
Philip Olson
On Sun, 22 Dec 2002, Tony Earnshaw wrote:
I have a site hosted at JTL Networks, and I'm looking into setting up
a spell checker for my message boards. The problem is, JTL doesn't have
pspell compiled in with their php build, and it may
for the assistance!
Jamie Sullivan
Philip Olson wrote:
First, read this:
http://www.php.net/variables.external
Second, assuming you have a PHP version equal to
or greater than 4.1.0 and the method of the form
is POST, you'd do something like this:
$banlist = array('[EMAIL
No, but you can do this:
$arr2 = array_values($array);
print $arr2[0]; // VALUE1
Regards,
Philip Olson
On Fri, 20 Dec 2002, Alexander Guevara wrote:
How can i do for printing the value of an array given the numeric key for
example i have this code:
$array = array (
'VAL1
He is referring to a question that is answered here:
http://www.php.net/manual/en/faq.html.php#faq.html.encoding
Spoiler: htmlspecialchars() - http://www.php.net/htmlspecialchars
Regards,
Philip Olson
On Sat, 21 Dec 2002, Justin French wrote:
on 21/12/02 2:00 PM, Alexander Guevara
How about:
if (!$conn = mysql_connect($host, $user, $pass)) {
include 'static_html.inc';
exit;
}
print Welcome, yes the database is connected;
exit ends the script, nothing after its use is executed.
Regards,
Philip Olson
On Thu, 19 Dec 2002, Beauford.2002 wrote:
Hi
For the record, variables are case sensitive so it's
$_SESSION not $_session.
And if you're going to use $_SESSION (which you should),
do not use session_register().
Regards,
Philip
On Thu, 19 Dec 2002, Mike Hillyer wrote:
I have recieved a private response, it appears my system had
$_REQUEST['email']. Or,
import_request_variables() is another option. For
example:
import_request_variables('p', 'p_');
print $p_email;
See the manual for details, and have fun! It really
isn't that complicated and you'll be yelling out
Eureka! pretty soon now.
Regards,
Philip Olson
P.s
This faqt answers your question:
http://www.faqts.com/knowledge_base/view.phtml/aid/8583
Regards,
Philip Olson
On Fri, 20 Dec 2002, conbud wrote:
Hi.
Lets says I have 8 links stored in a database, extracting those links is
no problem. Now lets says I have 2 columns, how do I get link 1
Have another look here:
http://www.php.net/list
Note that the list construct only works
on numerical arrays and assumes 0-n. You
may want to use import_request_variables()
or extract() though.
Regards,
Philip Olson
On Wed, 18 Dec 2002, Ns_Andy wrote:
a.php
?php
list($a) = $_GET
You may want to provide more information like why
is this string being split at these seemingly
random points? Maybe there is a common separator
or could be? But anyway it sounds like you want
substr().
http://www.php.net/substr
Regards,
Philip Olson
On Wed, 18 Dec 2002, Alex Ciurea
the number or rows
returned before fetching is a form of error handling
as well as if it equals 0 than there is no data to
fetch. But if one ONLY wants a number of rows count,
doing SELECT count(*)... works great as suggested
below.
Regards,
Philip Olson
On Wed, 18 Dec 2002, liljim wrote:
Hi John
$total = 49; // result from count(*)
$total_pages = ceil($total/$num);
if($page $total_pages)
{
$page = $total_pages;
}
// Main query.
// select [whatever] from [table(s)] where [criteria] [whateverelse] limit
. (($page*$num)-$num) . ,$num;
James
Philip Olson [EMAIL PROTECTED
You want explode(), something like:
list($a, $b) = explode('|', $string);
Regards,
Philip Olson
On Wed, 18 Dec 2002, Jeff Bluemel wrote:
I have a string that will look like the following;
data1|data2
now - I need to put data1 in a variable, and data2 in another variable.
I've
) . and num_rows: $count\n;
print_r($rows);
Conclusion: mysql_num_rows seems to be returning one less row
than exists. Is this correct?
Nope.
Regards,
Philip Olson
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
example looks fine.
Regards,
Philip Olson
P.s: Essentially
numerical == numbered keys
associative == worded keys
On Mon, 16 Dec 2002, Andy Turegano wrote:
I see. Well, in that case I don't really know what to do. Sorry.
On Tue, 17 Dec 2002, Quentin Bennett wrote:
Hi
to all variables, even web server variables
such as PHP_SELF so you'd use: $_SERVER['PHP_SELF'], etc.
Regards,
Philip Olson
P.s. So you want your query to look more like this:
$sql = INSERT INTO $db_imgCat (catName, subCat)
VALUES ('{$_GET['nafn']}', 0);
P.s.s. Consider validating
No, GD is only bundled as of PHP 4.3.0.
Regards,
Philip
On Thu, 12 Dec 2002 [EMAIL PROTECTED] wrote:
Hello Phillip, hello Sean,
thank you very much, for answering the question of --with-gd - compiling.
I am not using 4.3 . I did it with php-4.2.3
Did I got it right - to use the
it. In production, you most likely won't want
to print it out but anyway...
For a more complete example, see:
http://www.php.net/mysql_fetch_assoc
Btw, being that there is a function named mysql_result
I wouldn't create a variable by that name, kinda confusing.
Regards,
Philip Olson
p.s. mysql_error
On Tue, 10 Dec 2002, Stefan Hoelzner wrote:
Hi folks,
surely this question has already been answered many times before in
this ng, but nevertheless: I want to pass variables from one .php to
another .php script. But I do not want to use either the
To use the bundled gd just do: --enable-gd
Note that 4.3.0 is the first distro that includes a
bundled GD. Also note that as of 4.3.0 just doing
--with-gd will also use the bundled GD. Before this,
--with-gd (no directory specified) would look for a
local copy. That seems odd yes but
include the output of that url into the
webpage. This is unrelated and remember that parse errors
are always due to syntax problems.
Regards,
Philip Olson
On Wed, 11 Dec 2002, Richard Creech wrote:
Hello List,
Is there a way to execute a cgi inside of php? This is what a customer wants to do
,
Philip Olson
On Wed, 11 Dec 2002, Jay (PHP List) wrote:
Okay, I need to retrieve the output of a php file with variables being
passed to it. Example:
$calendar_file = make_calendar.php3?month=$monthyear=$year;
$fp = $fp = fopen($calendar_file, r);
while (!feof ($fp)) {
$buffer = fgets
Remove the {braces}, those are only used when
inside a {$strin['g']}. Also, be sure to
'quote' your array indices.
unset($arr['foo'][$bar]);
Regards,
Philip Olson
On Wed, 11 Dec 2002, Richard Baskett wrote:
Ok I feel a little sheepish after that answer :) Still not working though
due
magic_quotes_gpc is simple, it essentially runs
addslashes on all GET, POST and COOKIE data.
That's it.
http://www.php.net/ref.info#ini.magic-quotes-gpc
http://www.php.net/addslashes
http://www.php.net/variables.external
Not sure about your problem, maybe someone else can
help.
Regards,
Reread the docs here (the table):
http://www.php.net/ini_set
You cannot set this directive at runtime. Using .htaccess
is as close as you'll get to that. I see no reason why
using auto_prepend_file here would be better than include()
as this is exactly what include() is for.
Regards,
Read the docs:
http://www.php.net/install.apache2.php
Apache 2 is EXPERIMENTAL in PHP right now, it may
or may not work. But, the following combination
is known to work:
PHP 4.2.3 along with Apache 2.0.39
But Apache 1.3.x is recommended and considered stable and
will work with any PHP
If you want to do relative includes, you must have a . in
your include_path. Maybe this is what you are meaning to
do. Please reread this:
http://www.php.net/configuration.directives.php#ini.include-path
And if you still have problems after adjusting it and restarting
the web server, tell
Please reread the documentation found here:
http://www.php.net/header
It has a pdf file as an example, modify according
to your needs.
Regards,
Philip
On Wed, 4 Dec 2002, Elkan wrote:
Couldn't you set the Mime-Type on the server for the correct extenstion?
Leif K-Brooks wrote:
Please make all replies to this ONLY go to php-general, thank you.
On Sun, 17 Nov 2002, John W. Holmes wrote:
callback should be the name of a function that determines what the
matched pattern will be replaced with.
Maybe you just need the regular preg_replace(), instead of the one
Hello,
Use an array:
input type=checkbox name=foo[] value=blah
Note:
Only checked checkboxes are passed.
Access:
print $_REQUEST['foo'][0]; // the first one
print $_REQUEST['foo'][1]; // the second
You can use named indices too:
input type=checkbox name=foo[bar] value=blah
A very important question indeed :)
form method='POST'...
input type=text name=interests[]
input type=text name=interests[]
print $_POST['interests'][0];
print $_POST['interests'][1];
input type=text name=interests[foo]
input type=text name=interests[bar]
print $_POST['interests']['foo'];
, $DOCUMENT_ROOT won't exist if it's off,
$_SERVER['DOCUMENT_ROOT']. Same for PHP_SELF, etc.
i) $_REQUEST can be useful, import_request_variables() too.
See also:
http://www.php.net/globals
http://www.php.net/variables.predefined
Regards,
Philip Olson
On Wed, 30 Oct 2002, Manuel Jenne
101 - 200 of 599 matches
Mail list logo