php-general Digest 14 Nov 2005 09:43:42 - Issue 3793
Topics (messages 225698 through 225724):
Re: Printing to a buffer
225698 by: Todd Cary
225699 by: Jasper Bryant-Greene
225700 by: Marcus Bointon
225703 by: Todd Cary
225704 by: Todd Cary
Hello,
I have been usng the file_get_contents function to insert a (repeating)
part of my code
$lines = file_get_contents('../shared/acessibility_box.htm');
echo $lines;
In this file I have the a self submitting link
a href=? $_SERVER['PHP_SELF']; ??text_size=small class=size1A/a
Ok...got it now.
Thanks for the tip max. It was that there was no parsing with the
file_get_contents function. Had another minor error but helped that I knew
include() was the way to go.
R.
Ross [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Hello,
I have been usng the
Thanks Richard,
the server app was in another box from the database and we thought there may
be security issues behind the router etc.
we have now put the server app in the same box as the database and will use
php UDP to notify the app.
thanks for your help
Tony
Richard Lynch [EMAIL
Hi Ross,
Monday, November 14, 2005, 9:44:45 AM, you wrote:
$lines = file_get_contents('../shared/acessibility_box.htm');
In this file I have the a self submitting link
a href=? $_SERVER['PHP_SELF']; ??text_size=small class=size1A/a
The problem I think is this code is inserted after the
Ross wrote:
Hello,
I have been usng the file_get_contents function to insert a (repeating)
part of my code
$lines = file_get_contents('../shared/acessibility_box.htm');
echo $lines;
In this file I have the a self submitting link
a href=? $_SERVER['PHP_SELF']; ??text_size=small
Can anyone point me to a good User Authentication class written in PHP
(Version 5 preferably) that uses MySQL as the backend. If the output is
valid XHTML then even better. There are lots of hits on Google but I
need some help sorting the wheat from the chaff.
It's for a hobbyist site so I'm
Hello,
Was upgrading PHP-5.0.3 = 5.0.5
Apache version : httpd-2.0.46-54.ent
Distro : RHEL3 U2
configure switches :
./configure --with-zlib --without-gd --without-gdbm
--with-oracle=/opt/oracle/app/oracle/product/9.2.0/ --enable-sigchild
--enable-force-cgi-redirect --enable-memory-limit
I have a large data tree that I wanted to display in an outline
format. I used a textbook tree recursion function to go through the
data and display it as nested unordered lists:
function outputTree($id) {
if (checkChildObjectExists($id)) {
print ul;
$child =
Hi Folks,
I'm attempting to diagnose an apparent problem with my Apache/PHP
server setup. The platform is SPARC Solaris 9. I'm running Apache httpd
2.0.55 and PHP 4.4.1, built from NetBSD pkgsrc.
I have a user who has .shtml (server side include) pages which include
PHP fragments using
On 11 November 2005 20:52, Jay Blanchard wrote:
$theFile = fopen(docs/InstallationInstructionMaster.txt, r) ||
die;
You need or not || here. The operator priorities are such that the above
means
$theFile = (fopen(docs/InstallationInstructionMaster.txt, r) || die);
which assigns TRUE to
On 11 November 2005 21:21, Nathan Tobik wrote:
I've always used:
fopen(C:\\dir\\dir\\file.txt);
on windows, I'm not sure how PHP interprets the slashes internally
though...
On Windows, / in filenames is internally translated by PHP to \ -- which
means you can write code that works on
[snip]
You need or not || here. The operator priorities are such that the above
means
...
which assigns the result of fopen() to $theFile, and then executes die if
it's false -- which is much more satisfactory. ;)
[/snip]
Originally I did not have any '||' or 'or' in the conditional check, with
On 11 November 2005 18:47, sunaram patir wrote:
array(1) { [PHPSESSID]= string(32)
337a44c0d6c9ed3cf4ba4e97d707589e } is returned by firefox on calling
var_dump($_COOKIE). NULL in ie.
If the very same piece of PHP produces different results in different browsers,
this *MUST* be due to
Hello,
I would like to split or explode strings in a way that
quoted strings inside the strings should remain.
e.g.:
first second \third third\ fourth \fifth fifth fifth\
after the split I need:
first
second
third third
fourth
fifth fifth fifth
Is there a simple way to achieve this in PHP?
Ördögh László wrote:
I would like to split or explode strings in a way that
quoted strings inside the strings should remain.
e.g.:
first second \third third\ fourth \fifth fifth fifth\
after the split I need:
first
second
third third
fourth
fifth fifth fifth
I love explode(), too, but this
On 11/14/05, Ördögh László [EMAIL PROTECTED] wrote:
Hello,
I would like to split or explode strings in a way that
quoted strings inside the strings should remain.
e.g.:
first second \third third\ fourth \fifth fifth fifth\
after the split I need:
first
second
third third
fourth
I've finally narrow-it down and found a solution.
After much, much googeling, trying and error on my test machine and my
xserve running mac os x 10.4, I've found out that apache2 was shipped with
mac os X 10.4 server (server only).
I decided to compile my own php (as allways) againts this
I have got it done.
Below is the code:
-
form name=from_service method=post
FONT style=FONT-SIZE:12pt color=#8B
face=Courier NewBService/B/FONT
/DIV
select name=D1 size=1
style=position:absolute;left:230px;top:68px;z-index:7
onChange=form_service.submit();
?php
Trying to get apache2, php5 and mysql running. get the following error when
opening phpMyAdmin. Can someone explain what it means. There is an include
path in php.ini.
--
Russ
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
Alan Milnes wrote:
Can anyone point me to a good User Authentication class written in PHP
(Version 5 preferably) that uses MySQL as the backend. If the output is
valid XHTML then even better. There are lots of hits on Google but I
need some help sorting the wheat from the chaff.
it might
On Mon, November 14, 2005 7:46 am, Greg Schnippel wrote:
I have a large data tree that I wanted to display in an outline
format. I used a textbook tree recursion function to go through the
data and display it as nested unordered lists:
function outputTree($id) {
if
On Sun, November 13, 2005 7:59 pm, Guy Brom wrote:
Anyone familiar with a good user-comment system for PHP, preferably
one that
works with adodb and has thread-like design (where users can answer
each
other).
It's not threaded, but the User Contributed notes system on
http://php.net should
On Sun, November 13, 2005 4:39 pm, Todd Cary wrote:
My client has switched to a shared server, so direct access to the
php.ini is not availble. Our calendar program expects to have
output_buffering set to On (1).
Currently, I get the expected error of
Warning: Cannot modify header
On Mon, Nov 14, 2005 at 10:06:17AM -0800, russbucket wrote:
Trying to get apache2, php5 and mysql running. get the following error when
opening phpMyAdmin. Can someone explain what it means. There is an include
path in php.ini.
I think you forgot to include the error message.
curt.
--
--
Does anyone know if there's a handy way to create a numeric hash from
a text string? I'm trying to generate an integer as a sort of quick
dirty checksum for text strings. Needs to be a decimal integer, not
hex or otherwise. Any clever ideas appreciated. :)
--
PHP General Mailing List
On Sun, November 13, 2005 4:05 pm, Marcus Bointon wrote:
This seems like a simple problem...
Maybe there should be a simple solution... :-)
I have a rewrite like this:
RewriteRule ^x/([0-9]+) x.php?x=$1 [PT,L]
This maps a url like http://www.example.com/x/123 to http://
On Mon, Nov 14, 2005 at 10:41:53AM -0800, Brian Dunning wrote:
Does anyone know if there's a handy way to create a numeric hash from
a text string? I'm trying to generate an integer as a sort of quick
dirty checksum for text strings. Needs to be a decimal integer, not
hex or otherwise.
Quick-n-easy:
int crc32 ( string str ) -- make sure to read the manual about the
unsigned/signed issue.
DanB
Brian Dunning [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Does anyone know if there's a handy way to create a numeric hash from a
text string? I'm trying to generate
On Sun, November 13, 2005 8:20 am, Marcus Bointon wrote:
On 13 Nov 2005, at 00:17, Jasper Bryant-Greene wrote:
seem to do that. I just tried application/text since I use
application/pdf for other applications.
Whatever it's giving the user the ability to do, it's probably
because the
Dan Rossi wrote:
Personally, i am trying to avoid all these frameworks until
everyones ideas are collabroated into one as i think they only work for
some or for the developers purposes only.
What features do you need from a framework?
--
PHP General Mailing List (http://www.php.net/)
To
Greetings all,
I have a question.
I want to display a group of records pulled form a MySQL db in the following
fashion.
16
27
38
49
510
Now I can easily figure out how to display the records as
12
34
56
78
910
But
On Sun, November 13, 2005 1:53 pm, Marcus Bointon wrote:
On 13 Nov 2005, at 19:27, Jasper Bryant-Greene wrote:
Many thanks! I did not know that MIME-Type. Change duly made!
You're not suggesting that you actually set the MIME-Type to
application/force-download, are you?
I think he
Richard -
Thanks for the helpful suggestion but that won't resolve my problem
the way I currently have it written because I'm creating a new, nested
ul each time I loop through:
print ul;
foreach ($parent as $key = $value) {
...
}
print /ul;
So when I tried this, the output was still inverted
On Sun, November 13, 2005 4:55 pm, Todd Cary wrote:
Because this was just a test of what will be many print lines. The
original application used a file to hold the data and upon request by
the user, it was emailed. But with my client's shared server, files
cannot be opened...a pain.
If you
How about good ol' phpbb?
http://www.phpbb.com/
DanB
Guy Brom [EMAIL PROTECTED] wrote in message
news:[EMAIL PROTECTED]
Hi all,
Anyone familiar with a good user-comment system for PHP, preferably one
that works with adodb and has thread-like design (where users can answer
each other).
On Sat, November 12, 2005 2:33 pm, bruce wrote:
anybody know of any php/linux/apache user groups in the east bay
(dublin/pleasanton/san ramon/etc...) area?
need to join one to find other like minded php/linux guys who are into
developing..
You have to do some weeding, but this is pretty
On Monday 14 November 2005 10:47, Curt Zirzow wrote:
On Mon, Nov 14, 2005 at 10:06:17AM -0800, russbucket wrote:
Trying to get apache2, php5 and mysql running. get the following error
when opening phpMyAdmin. Can someone explain what it means. There is an
include path in php.ini.
I think
On Sat, November 12, 2005 10:29 am, Gustavo Narea wrote:
- AFAIK, there are 3 versions of the Standard SQL (1993, 1999 and
2003), but, Which one am I going to need for this test?
I think it would be best to focus on SQL 92 because:
A) It's unlikely that a significant number of Zend Cert
Perfect - thanks guys! :)
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
I have a question.
I want to display a group of records pulled form a MySQL db
in the following
fashion.
16
27
38
49
510
Now I can easily figure out how to display the records as
12
34
56
78
910
russbucket said the following on 11/14/2005 11:15 AM:
Clicking on the config.inc.php gives following error.
Warning: Unknown: failed to open stream: Permission denied in Unknown on line
0
Warning: Unknown: Failed opening '/srv/www/htdocs/phpMyAdmin/config.inc.php'
for inclusion
On Fri, November 11, 2005 9:33 pm, Bruce Gilbert wrote:
$headers = From: $sender;
$headers .= Reply-To: $reply_to;
$headers .= Return-Path: $return_path;
$headers .= X-Sender: $x_sender;
$headers .= X-Mailer: PHP4\n; //mailer
These two may trip some spam
If you're looking for a light-weight, threaded discussion script, I
can recommend this class from xhawk.net
http://www.xhawk.net/projects/discussion/
I like it because I can quickly integrate this into blogs or galleries
by just instantiating a new board instance for each object id or
article.
On Mon, November 14, 2005 1:15 pm, russbucket wrote:
On Monday 14 November 2005 10:47, Curt Zirzow wrote:
On Mon, Nov 14, 2005 at 10:06:17AM -0800, russbucket wrote:
Trying to get apache2, php5 and mysql running. get the following
error
when opening phpMyAdmin. Can someone explain what it
Depending on how strict your requirements are for the table layout, you could
always do something like this:
tr
td
Item 1br
Item 2br
Item 3br
Item 4br
Item 5
/td
td
Item 6br
Item 7br
Item 8br
Item 9br
Item 10
/td
/tr
Each item isn't in it's own
On Mon, November 14, 2005 1:03 pm, Phillip S. Baker wrote:
Greetings all,
I have a question.
I want to display a group of records pulled form a MySQL db in the
following
fashion.
16
27
38
49
510
Now I can easily figure out how to display the
On Mon, November 14, 2005 12:41 pm, Brian Dunning wrote:
Does anyone know if there's a handy way to create a numeric hash from
a text string? I'm trying to generate an integer as a sort of quick
dirty checksum for text strings. Needs to be a decimal integer, not
hex or otherwise. Any clever
On Fri, November 11, 2005 9:12 pm, Imroz wrote:
Hi PHP Gurus
Am new to the php world, I need help to do something. PlZz help
I have this link HYPERLINK
http://www.taximauritius.mu/link1.phphttp://www.taximauritius.mu/link1
..php.
What I want to do :
When clicking on the link above,
On Fri, November 11, 2005 7:09 pm, Bagus Nugroho wrote:
I have session code which written WindowsXP and It wotk properly as
expected, but when I'm used in Windows 2K, it got error as;
Notice: Undefined index: loginMessage in
C:\CentralData\forms\mainForm.php on line 65
I'am used Apache 2.0
On Fri, November 11, 2005 6:59 pm, Jasper Bryant-Greene wrote:
GamblerZG wrote:
What is the purpose of sessions extension?
The reason I ask is because learning to deal with all its functions,
ini
options and quirks took me _much_ more time than writing pure-php
replacement. (That is,
Hi, Richard.
Richard Lynch wrote:
On Sat, November 12, 2005 10:29 am, Gustavo Narea wrote:
- AFAIK, there are 3 versions of the Standard SQL (1993, 1999 and
2003), but, Which one am I going to need for this test?
I think it would be best to focus on SQL 92 because:
A) It's unlikely that
On Fri, November 11, 2005 5:18 pm, Chris Shiflett wrote:
Richard Lynch wrote:
Suppose PHP had a superglobal $_CLEAN which was an empty array.
This seems like a decent idea, for two reasons:
1. Developers don't have to remember to initialize their array, which
offers some protection. PHP can
According to the php docs, the method DomDocument-getElementById() will
not work unless the document is validated using a DTD (not schema):
According to the DOM standard this requires a DTD which defines the
attribute ID to be of type ID. You need to validate your document with
On Fri, November 11, 2005 2:51 pm, Jay Blanchard wrote:
$theFile = fopen(docs/InstallationInstructionMaster.txt, r) ||
die;
Don't use || when you mean 'or' :-)
Nor sure it really matters here, but better to follow the crowd and
use 'or' here.
while(!feof($theFile)){
$theLine =
On Fri, November 11, 2005 3:23 pm, Jay Blanchard wrote:
// Left off the b because it ain't binary :)
I think you will find this is the crucial difference if you go back to
your original and take it out.
Your file is text.
It's not binary.
On Windowz, that matters, for some odd reason.
--
I have run into this behavior on several sites:
$dom-validate('books.dtd');
But according to the docs, the method it is defined
class DOMDocument {
bool validate ( void )
}
Is the dtd (file?) parameter deprecated?
/Erik
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe,
On Fri, November 11, 2005 2:27 pm, Daevid Vincent wrote:
I have a feature request (and I'm a bit disappointed that this isn't
already
in the DOMDocument, when there are nearly useless methods like
normalize())... Ruby has this built in. xmllint has the --format
parameter. But yet PHP's
In my office we found it to be quite quick and easy to write a library
which uses PHP session extensions to store all session data into a
database (we work in a load balanced environment). We found this to be
the best method of dealing with this because we did not need to deal
with generating
[snip]
On Fri, November 11, 2005 2:51 pm, Jay Blanchard wrote:
$theFile = fopen(docs/InstallationInstructionMaster.txt, r) ||
die;
Don't use || when you mean 'or' :-)
Nor sure it really matters here, but better to follow the crowd and
use 'or' here.
[/snip]
Okie dokie. Found there to be no
I have run into this behavior on several sites:
$dom-validate('books.dtd');
But according to the docs, the method it is defined
class DOMDocument {
bool validate ( void )
}
Is the dtd (file?) parameter deprecated?
/Erik
Just tested, $dom-validate('books.dtd') generates the warning
First of all - remember results display in a web browser, and if you want
to print these you will get results that are not like a normal printed page.
Second - here's an approach. Dump all records into an array, you'll have
the record count, then selectively fetch elements according to how
Yeah Jim - that's better than mine.
Miles
At 03:28 PM 11/14/2005, Jim Moseby wrote:
I have a question.
I want to display a group of records pulled form a MySQL db
in the following
fashion.
16
27
38
49
510
Now I can easily figure out how to
Can someone get rid of him?
Every time I post, which I admit is not often, I get a bounce.
Cheers - Miles
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
On 11/14/05 3:38 PM, Richard Lynch wrote:
Perhaps one should use:
$_ICLEAN
$_OCLEAN
for Input and Output.
$kosher = '/[^A-Za-z0-9\\',\\.-]/';
$_ICLEAN['first_name'] = preg_replace($kosher, '', $_GET['first_name'];
/* more code */
$_OCLEAN['first_name'] = htmlentities($_ICLEAN['first_name']);
Richard Lynch wrote:
But it ain't easy the first time.
If you're using DB to store session data, and trying to improve session
security, than it ain't easy even the second time. Or the third. In
fact, I gave up on that extension before it became easy. After that my
session-related code
Miles Thompson wrote:
Can someone get rid of him?
Every time I post, which I admit is not often, I get a bounce.
Yeah, same. I think there was some discussion recently regarding it but
I don't know what happened.
I even tried to go to www.xasamail.com and register an account ale0952
just
[I've had this posted in the php.windows group for a few days, but I got no
replies there.]
I have been plugging away at this for some time now and I can not figure out
how to get https and ftps as registered streams in my Windows installation of
Php (4.4.0). My direct need is to use fopen
Richard Lynch wrote:
If you had anything other than $_OCLEAN in an echo and friends, then
you would know you were screwing up.
Personally, if I pull something info from the database, then I do not
usually sanitize it. Yes, I know it's less secure, but I'm willing to
take such (negligible)
On 14 Nov 2005, at 18:51, Richard Lynch wrote:
include_path(/full/path/to/DocumentRoot: . include_path());
This may not be the right syntax/function to set include_path, but it
is a dynamic way to set the include path, from within PHP.
Yup, I tried this and it kind-of works, but still leads
On 14 Nov 2005, at 19:01, Richard Lynch wrote:
It may not be my final choice whether they download or not, but if a
browser doesn't treat:
application/octet-stream
as a download, and only as a download, then that browser is pretty
broken.
Letting the user configure their browser for that MIME
GamblerZG wrote:
If you had anything other than $_OCLEAN in an echo and friends, then
you would know you were screwing up.
Personally, if I pull something info from the database, then I do not
usually sanitize it. Yes, I know it's less secure, but I'm willing to
take such (negligible) risk
Dan Rossi wrote:
Personally, i am trying to avoid all these frameworks until
everyones ideas are collabroated into one as i think they only work for
some or for the developers purposes only.
What features do you need from a framework?
--
PHP General Mailing List (http://www.php.net/)
To
Dan Rossi wrote:
Just found this article via phpeclipse.de stating Zend will be including
Eclipse framework in their development schedules :)
http://www.zend.com/news/zendpr.php?id=109
Id like to know more about this standardized application framework.
Me too, considering the fact that I
_http://andigutmans.blogspot.com/_ (http://andigutmans.blogspot.com/)
Andi talks about the Framework on his Blog.
- Clint
Could use the xampp package or just the openssl php from it,
http://www.apachefriends.org/en/xampp.html
Chuck Anderson wrote:
[I've had this posted in the php.windows group for a few days, but I got
no replies there.]
I have been plugging away at this for some time now and I can not
Sorry for the newbie question...
I did a search on php.net but didn't find my answer.
what does \r\n do as opposed to just \n?
and yes, I know what \n does.
On 11/14/05, Richard Lynch [EMAIL PROTECTED] wrote:
On Fri, November 11, 2005 9:33 pm, Bruce Gilbert wrote:
$headers = From:
Bruce Gilbert wrote:
Sorry for the newbie question...
I did a search on php.net but didn't find my answer.
what does \r\n do as opposed to just \n?
and yes, I know what \n does.
Different platforms have different line-break conventions. \n is a line
feed, while \r is a carriage return
On Mon, 2005-11-14 at 03:55 -0500, Roman Ivanov wrote:
What features do you need from a framework?
Convention over configuration. (Yaml, not XML. ActiveRecord not
Propel/Phing.)
A persist-able domain model where logic and data are presented in one
wrapping. (I don't want to re-assign my data
James Benson wrote:
Could use the xampp package or just the openssl php from it,
http://www.apachefriends.org/en/xampp.html
Hey thanks. I may give that a try, but I already have two full apache
servers loaded on my PC. What I can't figure out is why these secure
streams are not
HI All,
In your template parsing classes do you put the code for tags in
seperate files or do you have some kind of array or other method of
assigning the action associated with the tag?
I have been putting the code for the tags in a dat/tag.dat file and
then including the file wherever the tag
On Mon, 2005-11-14 at 23:42, Leonard Burton wrote:
HI All,
In your template parsing classes do you put the code for tags in
seperate files or do you have some kind of array or other method of
assigning the action associated with the tag?
I have been putting the code for the tags in a
On Mon, Nov 14, 2005 at 02:08:08PM -0600, Richard Lynch wrote:
On Mon, November 14, 2005 12:41 pm, Brian Dunning wrote:
Does anyone know if there's a handy way to create a numeric hash from
a text string? I'm trying to generate an integer as a sort of quick
dirty checksum for text strings.
83 matches
Mail list logo