On Wednesday 26 July 2006 21:41, Robert Cummings wrote:
> > I'm working on some code that would be called to generate a cell in a
> > possibly large table and therefore a small difference in performance
> > may have a significant impact.
>
> PHP uses copy-on-write and so copies are essentially sha
On Wed, 2006-07-26 at 22:29, Michael B Allen wrote:
> Is a function return value copied? If the value is an integer I suppose
> it is but what about a string or an array? If you pass by reference is
> the return value still copied?
>
> For example, is this:
>
> function foo(&$arr) {
> $ar
Is a function return value copied? If the value is an integer I suppose
it is but what about a string or an array? If you pass by reference is
the return value still copied?
For example, is this:
function foo(&$arr) {
$arr[] = "bar";
}
faster than this?
function foo(&$arr) {
$
Yes you can...
$pdf->Output("thelocation/filename.pdf", "F");
Just make sure that thelocation has permission to write for the web server.
/Peter
-Original Message-
From: João Cândido de Souza Neto [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 27, 2006 7:05 AM
To: php-general@lists.php
Thanks man... it turns out that I really was redeclaring the class, but
it didn't throw an error until I added APC.
Kinda weird, yeah? Anyway... it's all good now.
-- jon
Jochem Maas wrote:
jon wrote:
So... I've got some code that works just fine without APC, but dies when
I add it.
jon wrote:
> So... I've got some code that works just fine without APC, but dies when
> I add it.
>
> Here's the error:
> Fatal error: Cannot redeclare class
that error doesn't tell us much more than you in the context you give...
but I'm gonna put money on the fact that your doing something like
Le mercredi 26 juillet 2006 à 12:27 +0200, Jochem Maas a écrit :
> Yannick Warnier wrote:
> > Hi there,
> >
> > I'm trying to deal with big files (over 4GB) with PHP4.3.9 ans PHP4.4
> > but obviously it's not really possible.
>
> no, we're not quite at the 4GB-flash-header-files-for-webpages stag
[snip]
Do you mean a magnetic stripe reader?
Information is scattered all over business cards.
[/snip]
Most states do not allow access to their mag stripes, and one company
that I have found so far uses what is essentially an OCR scanner and a
software called IDScan to parse the data. They even cl
At 04:31 PM 7/26/2006, Jay Blanchard wrote:
For our retail application (written in PHP) we are looking for a class
that will work with a scanner to scan a driver's license or business
card and populate the forms properly with that data. I have found a
product (IDScan) that may work with PHP, but
>
> For our retail application (written in PHP) we are looking for a class
> that will work with a scanner to scan a driver's license or business
> card and populate the forms properly with that data. I have found a
> product (IDScan) that may work with PHP, but I was hoping to
> find others
> to
For our retail application (written in PHP) we are looking for a class
that will work with a scanner to scan a driver's license or business
card and populate the forms properly with that data. I have found a
product (IDScan) that may work with PHP, but I was hoping to find others
to compare it to.
So... I've got some code that works just fine without APC, but dies when
I add it.
Here's the error:
Fatal error: Cannot redeclare class
php -v =
PHP 5.1.2 (cli) (built: Jul 18 2006 23:21:00)
... any ideas what's up? Obviously, there are other ways I can improve
performance on that box, but I
Angelo Zanetti wrote:
> Hi all,
>
> I need some recommendations for books:
> are there any good books on PHP and WAP/WML? Also (OT) a recommendation
> regarding books for CSS2 and XHTML.
http://www.hudzilla.org/phpbook/
Regards,
Austin.
signature.asc
Description: OpenPGP digital signature
http://www.w3schools.com/wap/default.asp
That is a good start...
-Original Message-
From: Angelo Zanetti [mailto:[EMAIL PROTECTED]
Sent: Wednesday, July 26, 2006 10:54 PM
To: PHP List
Subject: [PHP] Books: PHP and WAP
Hi all,
I need some recommendations for books:
are there any good b
Angelo,
On Wed, 2006-07-26 at 17:53 +0200, Angelo Zanetti wrote:
> I need some recommendations for books:
> are there any good books on PHP and WAP/WML? Also (OT) a recommendation
> regarding books for CSS2 and XHTML.
>
Not sure about books, but if you are interested in this area, I would
reco
Hi all,
I need some recommendations for books:
are there any good books on PHP and WAP/WML? Also (OT) a recommendation
regarding books for CSS2 and XHTML.
Thanks in advance
--
Angelo Zanetti
Systems developer
On Wed, 26 Jul 2006 17:01:51 +0200, Jochem Maas <[EMAIL PROTECTED]> wrote:
>> I sure wont.
>> On the topic of my array, what would be an efficient way of checking my
> username/passwordd pairs match the user input form my login form.
>> The text file contains username and passwords in the foll
At 3:23 PM +0200 7/26/06, nicolas figaro wrote:
Hi,
I'd like to convert a jpg image to a pdf document using the fpdf
class. (www.fpdf.org).
here is the code :
open();
$pdf->image($image,0,0);
$pdf->Output("/path/to/image.pdf",'F');
?>
but I only get a blank a4 pdf document when I open imag
[EMAIL PROTECTED] wrote:
>
>
> On Wed, 26 Jul 2006 14:53:34 +0200, Jochem Maas <[EMAIL PROTECTED]> wrote:
>> [EMAIL PROTECTED] wrote:
>>> On Wed, 26 Jul 2006 13:54:15 +0200, Jochem Maas <[EMAIL PROTECTED]>
>> wrote:
var_dump($out, $u, $p, (" user " == "user"));
>>> Jochem
>>> Thank you, var_
On Wed, 26 Jul 2006 14:53:34 +0200, Jochem Maas <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
>>
>> On Wed, 26 Jul 2006 13:54:15 +0200, Jochem Maas <[EMAIL PROTECTED]>
> wrote:
>>> var_dump($out, $u, $p, (" user " == "user"));
>>
>> Jochem
>> Thank you, var_dump showed me i had
hi guys,
thanks for the replies! yes Melanie, you were correct the last example
(i had an old version of the manual). seemed to do the trick =)
Thanks to john as well for the reply.
Angelo
Melanie Maddix wrote:
[snip]
So they way I want to sort these rows is by total, totalPaid,
totalUnpa
out of frustration of needing and not having strptime() on certain machines
[read: windows]
and on certain versions of php [read: pre5.1] I wrote a crude userland 'compat'
function.
it works in so far as I have tested it... but it feels like a crap
implementation,
my attempt is below, the quest
On 7/26/06, Angelo Zanetti <[EMAIL PROTECTED]> wrote:
Hi all,
So they way I want to sort these rows is by total, totalPaid,
totalUnpaid all descending.
Hi Angelo,
So the first question the list will ask is if the array of data is
coming from a database. Because then you'd be urged to perform
Check the FPDF function in the manual http://www.fpdf.org/en/doc/fpdf.htm, I
think you can set custom size of the PDF. You have to figure out how to get
the image size first, hint: getImageSize();), and then convert it to the
units you use for the pdf.
-Original Message-
From: nicolas figa
Peter Lauri a écrit :
This is code how it works for me:
$pdf =& new FPDF('p','pt','a4');
$pdf->AddPage();
$pdf->Image("pdf/profilechart.png",145,$pdf->GetY());
$pdf->Output("pdf/temp/thepdf.pdf",'F');
Add the $pdf->AddPage(); and it might work :)
addpage did the trick.
thanks peter.
next
tedd wrote:
>> [EMAIL PROTECTED] wrote:
>>>
>>> On Wed, 26 Jul 2006 13:54:15 +0200, Jochem Maas
>>> <[EMAIL PROTECTED]> wrote:
var_dump($out, $u, $p, (" user " == "user"));
>>>
>>> Jochem
>>> Thank you, var_dump showed me i had an extra space at the end of the
>>> password. I trimmed the v
This is code how it works for me:
$pdf =& new FPDF('p','pt','a4');
$pdf->AddPage();
$pdf->Image("pdf/profilechart.png",145,$pdf->GetY());
$pdf->Output("pdf/temp/thepdf.pdf",'F');
Add the $pdf->AddPage(); and it might work :)
-Original Message-
From: nicolas figaro [mailto:[EMAIL PROTECT
So then it was the opposite of what I had in memory :)
-Original Message-
From: nicolas figaro [mailto:[EMAIL PROTECTED]
Sent: Wednesday, July 26, 2006 8:30 PM
To: 'PHP List'
Subject: Re: [PHP] jpg to pdf using fpdf
Peter Lauri a écrit :
> Correct me if I am wrong, but do fpdf allow jpg?
Peter Lauri a écrit :
Correct me if I am wrong, but do fpdf allow jpg? I think you must convert to
PNG or GIF and then use that image.
I correct you.
FPDF allow jpg.
take a look at ttp://www.fpdf.org/en/doc/image.htm
" Supported formats are JPEG and PNG. "
N F
--
PHP General Mailing List
On Wed, 26 Jul 2006 14:59:46 +0200, Jochem Maas wrote:
>
> I wonder if anyone can given a solid answer to this?
If I remember correctly, htmlspecialchars does what its name indicate:
konvert any character with special meaning according to the HTML
specification. htmlentities converts any characte
Correct me if I am wrong, but do fpdf allow jpg? I think you must convert to
PNG or GIF and then use that image.
-Original Message-
From: nicolas figaro [mailto:[EMAIL PROTECTED]
Sent: Wednesday, July 26, 2006 8:24 PM
To: PHP List
Subject: [PHP] jpg to pdf using fpdf
Hi,
I'd like to
Hi,
I'd like to convert a jpg image to a pdf document using the fpdf class.
(www.fpdf.org).
here is the code :
open();
$pdf->image($image,0,0);
$pdf->Output("/path/to/image.pdf",'F');
?>
but I only get a blank a4 pdf document when I open image.pdf using
acroread.
does anyone have an idea
Hi all,
Need some advice as to how to sort a array:
Structure:
partnerID
partnerName
total
totalPaid
totalUnpaid
So basically there will be many entries for the following:
eg:
partnerID | partnerName | total | totalPaid | totalUnpaid
1 marc 12 5
Dave Goodchild wrote:
> Hi all. I know htmlspecialchars converts the smallest set of entities
> possible to generate valid HTML, and that htmlentities goes much
> further, so
> what is the difference? Is it not better to use htmlentities in every case,
> making htmlspecialchars somewhat redundant,
[EMAIL PROTECTED] wrote:
>
> On Wed, 26 Jul 2006 13:54:15 +0200, Jochem Maas <[EMAIL PROTECTED]> wrote:
>> var_dump($out, $u, $p, (" user " == "user"));
>
> Jochem
> Thank you, var_dump showed me i had an extra space at the end of the
> password. I trimmed the vales from the file and it works fi
Hi all. I know htmlspecialchars converts the smallest set of entities
possible to generate valid HTML, and that htmlentities goes much further, so
what is the difference? Is it not better to use htmlentities in every case,
making htmlspecialchars somewhat redundant, or is there a performance
trade
On Wed, 26 Jul 2006 13:54:15 +0200, Jochem Maas <[EMAIL PROTECTED]> wrote:
> var_dump($out, $u, $p, (" user " == "user"));
Jochem
Thank you, var_dump showed me i had an extra space at the end of the password.
I trimmed the vales from the file and it works fine now.
Eoghan
--
PHP General
On Wed, 26 Jul 2006 13:54:15 +0200, Jochem Maas <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
>>
>>
>> On Wed, 26 Jul 2006 13:22:02 +0200, Jochem Maas <[EMAIL PROTECTED]>
> wrote:
>>> [EMAIL PROTECTED] wrote:
Hi
I am reading a username and password from a file. For the mo
This is only an example and threat it as example. Take care about
security too. So don't copy and paste :)
You could do like this:
weetat wrote:
> Hi all,
>
> I have code below which save MYSQL to csv file. I am using ADODB
> library to do this.
>
> The saving MYSQL to csv file is ok .
> Ho
Dear Eoghan,
May be you should'n just hit "Reply"/"Reply All" button.
--
Sameer N. Ingole
http://weblogic.noroot.org/gallery2/v/travel/lonar/
---
Better to light one candle than to curse the darkness.
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net
[snip]
I have code below which save MYSQL to csv file. I am using ADODB
library to do this.
The saving MYSQL to csv file is ok .
However i need to allow the the user to enter file name for csv file.
Anybody have any ideas how to do this? Thanks
[/snip]
If you want a true pop-up you will
[EMAIL PROTECTED] wrote:
>
>
> On Wed, 26 Jul 2006 13:22:02 +0200, Jochem Maas <[EMAIL PROTECTED]> wrote:
>> [EMAIL PROTECTED] wrote:
>>> Hi
>>> I am reading a username and password from a file. For the moment I am
>> trying to test if the username and password are the same as user inputted
>> us
[EMAIL PROTECTED] wrote:
if( $out[0][0] == $u && $out[0][1] == $p ) {
$error = "Login successful!";
}
else {
$error = "Invalid username/password. Try again";
}
If I just test if( $out[0][1] == $u ) it wo
[EMAIL PROTECTED] wrote:
> Hi
> I am reading a username and password from a file. For the moment I am trying
> to test if the username and password are the same as user inputted
> username/password.
> My code snippet is as follows:
> if( $out[0][0] == $u && $out[0][1] == $p ) {
>
Hi
I am reading a username and password from a file. For the moment I am trying to
test if the username and password are the same as user inputted
username/password.
My code snippet is as follows:
if( $out[0][0] == $u && $out[0][1] == $p ) {
$error = "Login successful
Yannick Warnier wrote:
> Hi there,
>
> I'm trying to deal with big files (over 4GB) with PHP4.3.9 ans PHP4.4
> but obviously it's not really possible.
no, we're not quite at the 4GB-flash-header-files-for-webpages stage of
internet evolution ;-)
>
> Is there a library somewhere that allows elem
Paul Scott wrote:
> I have googled around a bit, but not really found anything useful...
>
> Which is more efficient? A case switch or a $$method style method?
>
both examples are just boilerplate 'frontcontroller' code that do pretty much
nothing
of themselves.
- in terms of speed you will no
Hi there,
I'm trying to deal with big files (over 4GB) with PHP4.3.9 ans PHP4.4
but obviously it's not really possible.
Is there a library somewhere that allows elementary operations on these
kinds of files by, for example, using the operating systems commands
(Linux in this case)?
Or any other
For something like that that, unless you are doing it inside a loop, I
wouldn't really worry about efficiency as much as I would about security
On 7/26/06, Paul Scott <[EMAIL PROTECTED]> wrote:
I have googled around a bit, but not really found anything useful...
Which is more efficient? A cas
Hi all,
I have code below which save MYSQL to csv file. I am using ADODB
library to do this.
The saving MYSQL to csv file is ok .
However i need to allow the the user to enter file name for csv file.
Anybody have any ideas how to do this? Thanks
$sql = $_SESSION['CSV_SQL'];
$_logger = n
markw@mohawksoft.com wrote:
>> markw@mohawksoft.com wrote:
>>> [snip]
seems the perceived problem is being caused by something else?
>>> Sorry, I have to respectfully disagree.
>> ok :-).
>
> Men of integrity must be able to disgree peacefully. :-)
>
:-)
>
> Well, the point I was try
51 matches
Mail list logo