[PHP] jpg to pdf using fpdf

2006-07-26 Thread nicolas figaro
Hi, I'd like to convert a jpg image to a pdf document using the fpdf class. (www.fpdf.org). here is the code : ?php require(fpdf.php); $image=/pat/to/image.jpg; $pdf = new FPDF(); $pdf-open(); $pdf-image($image,0,0); $pdf-Output(/path/to/image.pdf,'F'); ? but I only get a blank a4 pdf

Re: [PHP] jpg to pdf using fpdf

2006-07-26 Thread nicolas figaro
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

Re: [PHP] jpg to pdf using fpdf

2006-07-26 Thread nicolas figaro
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 question

[PHP] captcha and blacklist

2006-07-25 Thread nicolas figaro
Hi, I'd like to set a captcha on my web server(s). The code works quite fine, but I'd like to blacklist (for an amount of time) the ips that failed with the captcha x times. The web server works with an SQL server, but I cannot ask the page to check for each IP with a request to the

Re: [PHP] Return XML using PHP and Content-Type with UTF-8 breaks the UTF-8

2006-07-20 Thread nicolas figaro
Mathijs a écrit : Hello there, I Have an problem with UTF-8 and XML. I Output perfect XML (according to IE, Opera and Firefox). I use the Content-Type header with text/xml; charset=utf-8. For some reason this breaks UTF-8 output. When i remove it it works. But i need the text/xml header. Hi,

Re: [PHP] Difference between 2 time entries

2006-07-20 Thread nicolas figaro
$timeDiff=$lastTime-$firstTime; // return the difference return $timeDiff; } //Usage : echo timeDiff($start,$finish); Thanks Chris Nicolas Figaro http://www.sdv.fr [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] SDV plurimédia -- PHP General Mailing List (http://www.php.net

Re: [PHP] Name in HTML input

2006-07-18 Thread nicolas figaro
weetat a écrit : Hi , Thanks for your info. I am new in PHP , how to remove the the space and '(',')' ? hi, $newstring = str_replace( ,_,$string); $newstring = str_replace(,,_,$newstring) hope this'll help N F Thanks Sameer N Ingole wrote: Sameer N Ingole wrote: weetat wrote:

Re: [PHP] printing special characters in PHP

2006-07-11 Thread nicolas figaro
Antonio Bassinger a écrit : Dear ALL, I've an binary file with special (non-printable) characters including '' '/' ''. I retrieve this file from the database, into a variable $binaryFILE. $binaryMS = explode(,$binaryMMS); foreach ($binaryFILE as $ii) { echo $ii; try this : echo

[PHP] Re: [Full-disclosure] Postfix configuration

2006-07-10 Thread nicolas figaro
Bartlomiej Szymanski a écrit : Hello, Hi I have a problem with message delivery via Postfix. I build a network, using VMware, consisting of three standalone FreeBSD machines. I named them: FREEBSD1, FREEBSD2 and FREEBSD3. do you know postfix has also a very good mailing list ? On each of

[PHP] sorry for the previous mail, mixed mailing list

2006-07-10 Thread nicolas figaro
/me really need some sleep ... N F -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Web service in PHP

2006-07-07 Thread nicolas figaro
Pham Huu Le Quoc Phuc a écrit : Hi! Hi, I want to build a Web Service in PHP. cool ! Could you give me some explain about this problem. Have any framework of Web service in PHP? could you give us some infos about the web service you'd like to build ? Please help me! N F --

Re: [PHP] uploading and extracting zip files

2006-07-05 Thread nicolas figaro
Chris a écrit : Schalk wrote: Greetings All, Can someone please point me to a tutorial or open source 'library' that will explain how one can upload a .zip file and then extract it's contents and store this on the server and/or database using PHP. This will unzip a file:

Re: [PHP] [JS question] : I want to block onChange event in Firefox...

2006-06-30 Thread nicolas figaro
Hi, did you try to open the javascript console in firefox to see if there is any error ? (in the tools or outils menu). hope this'll help / bon courage N F David BERCOT a écrit : Hi, I am blocked on this problem since so a long time that I prefer asking here my question... I'd like, if

Re: [PHP] Downloading page

2006-06-30 Thread nicolas figaro
BBC a écrit : Hi all... I'm interesting in a page (using PHP script) in internet, and I'd like to download that page with the complete script. the question is: Can I..? Hi, you can't directly. you have to ask the webmaster of the site. but the source code won't be helpfull if the script

Re: [PHP] FTP Problems

2006-06-27 Thread nicolas figaro
I had many troubles with ftp_nlist since I discovered the -a option. try this : $buff = ftp_nlist($conn_id,-a); N F James Nunnerley a écrit : I'm trying to create some functionality which requires FTPing onto another server, using the php functions. Doing the following comes up with a

Re: [PHP] FTP Problems

2006-06-27 Thread nicolas figaro
James Nunnerley a écrit : Nope - unfortunately, no change, still the same problems, logging in but no ftp_nlist or indeed ftp_rawlist even with a pathname ? ftp_nlist($conn_id, -a /) do you have any log on the server ? ( you can also sniff the network to watch what php sends). NF Cheers

[PHP] how can I decode such a string ?

2006-06-27 Thread nicolas figaro
Hi, I'd like to convert a string generated by a mail client like the following one : test nf =?ISO-8859-15?Q?=E9_123456789012?= back to the original one test nf é 123456789012. Is there a (simple) way to do this ? thanks N F -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] Equivelant to mysql_fetch_row for normal array

2006-06-22 Thread nicolas figaro
Dave M G a écrit : PHP List, Pretty standard. But what do I do when I want to do the same kind of while loop not with a MySQL result, but with just a regular array? while (variable = ($array)){ echo $variable[text1]; echo $variable[text2]; } did you try something like this ? foreach

Re: [PHP] Upgrade to PHP5 on Fedora Core

2006-06-15 Thread nicolas figaro
Dave M G a écrit : PHP List, My hosting service allows me enough access to do things like handle my own upgrades and full administrative access. Usually, because I am more of a web designer than an server administrator, I get their support staff to manage upgrades and installations.

Re: [PHP] basic php problem

2006-06-15 Thread nicolas figaro
Ross a écrit : I want to set a page number of a page if(!isset($_REQUEST['page'])) { $page =$_REQUEST['page'] + 1; echo page is .$page; // this echos out page is 1 } The problem is when I try and use $page further down in the body $page is 0 Question ?=$page; ? BR / ? echo page is.$page; ?

Re: [PHP] basic php problem

2006-06-15 Thread nicolas figaro
nicolas figaro a écrit : Ross a écrit : I want to set a page number of a page if(!isset($_REQUEST['page'])) { $page =$_REQUEST['page'] + 1; echo page is .$page; // this echos out page is 1 } The problem is when I try and use $page further down in the body $page is 0 Question ?=$page

Re: [PHP] references for beginner...

2006-06-14 Thread nicolas figaro
BBC a écrit : Hii all I just joined this forum, I'm beginner of PHP programming. welcome. I didn't understand almost all the syntax you're talking about (ups too honest, right?), so please... Does anyone have a kinds of references like soft books or something, which talk about all the

Re: [PHP] parsing out quoted text

2006-06-09 Thread nicolas figaro
sam a écrit : $str='bass electric organ bagpipes'; $parser($str); $query=SELECT * FROM table WHERE tb_instr = bass AND tb_instr = electric organ //quoted phrase AND tb_instr = bagpipes; Anybody know where I can just copy code that will do the above? you wish to split $str and

Re: [PHP] What would cause this?

2006-06-01 Thread nicolas figaro
tedd a écrit : Hi gang: Hi I have a question regarding php and security. My apologies beforehand if this is common knowledge to everyone except me. I have a php application sitting at root level on one of my servers who's sole function is to send me an email whenever it's run. So,

Re: [PHP] Array name out of field value with data

2006-05-22 Thread nicolas figaro
Jonas Rosling a écrit : Not so sure if I've tried to work this out before in this list. I'm trying to make an array name by a field/row value and assigning values to it. But I'm having some problems getting it to work. Is it possible to do this? And if, what am I doing wrong? Or is there any

Re: [PHP] 404 After Setting session.save_path to /tmp

2006-05-16 Thread nicolas figaro
Mark Sargent a écrit : Hi All, I get this, Not Found The requested URL /movie1.php was not found on this server. Apache/2.2.0 (Fedora) Server at localhost Port 80 when setting session.save_path to /tmp in

Re: [PHP] PHP stdout stream

2006-05-15 Thread nicolas figaro
[EMAIL PROTECTED] a écrit : Hello, I've a quite simple question : one of my PHP script executes a Perl script which outputs a lot of text. My wish is to redirect PHP stdout stream to NULL, executing the perl script, and after this make the stdout stream back to normal. I've not found a solution

Re: [PHP] Re: PHP output stream

2006-05-15 Thread nicolas figaro
[EMAIL PROTECTED] a écrit : Thanks for your answer. I already have thought about your solution. The problem is I have to use the Perl module for PHP. An example : $perl = new Perl(); $perl-require('mct.pl'); $perl-MCT_polling(); where MCT_polling() is a function of my script mct.pl. I would

Re: [PHP] Sessions - session_start()

2006-05-15 Thread nicolas figaro
Jonas Rosling a écrit : Hi, I've been building a site with PHP 5 on my develop machine. I've been woring alot with session handling. For example I've been using session_start() now and then depending on where the user/vistor are or are doing. But now I've moved the site to a host server with PHP

Re: [PHP] Web app for betting on soccer WorldCup 2006

2006-05-03 Thread nicolas figaro
FAURE, Bruno (PCO TECHNOLOGIES) a écrit : Hi all, Hi, I am looking for a web application that could be used for organizing informal intranet bets on soccer worldcup 2006. If it's informal, why can't you use a simple password protected spreadsheet (excel, openoffice, or the format you

Re: [PHP] A error with PHP and CakePHP

2006-05-03 Thread nicolas figaro
Pham Huu Le Quoc Phuc a écrit : Hi! hi, you don't need to send the mail to me + copy to the list. I have a error, please see attach image file I use php 5.0, CakePHP and IIS, Windows XP, IE 6.0 Please help me. 1st : read the html source of your page. 2nd : find in the source the code

Re: [PHP] Slow mail()

2006-05-02 Thread nicolas figaro
Tony Aldrich a écrit : Hello! What are the reasons of slow mail() (about 30-40 seconds)? Hi, many reasons, but nothing related to php IMHO. mail relay load, slow reverse dns interrogations for spam, etc. If your mail runs only on a local or corporate network, ask the mail admin, otherwise,

Re: [PHP] How to execute multiples querys

2006-04-26 Thread nicolas figaro
Mauricio Pellegrini a écrit : Hi all I'm trying to execute two querys and they execute perfectly in fact, but after the execution of the first query there suposed to be some variable setted to a certain value. The problem is this variable is not available at the time the second query runs.

Re: [PHP] How to execute multiples querys

2006-04-26 Thread nicolas figaro
Mauricio Pellegrini a écrit : $quer1 = SET @var1=3 ; SELECt * from table1 Where [EMAIL PROTECTED] ; This gave a syntax error from MySQL inmmediately before the ; (semicolon), did you try to run the query above ( SET @var1=3 ; SELECt * from table1 Where [EMAIL PROTECTED] )

Re: [PHP] strange php url

2006-04-24 Thread nicolas figaro
. (I'll check the code to be sure). If I can make sure the PATH_INFO isn't used anywhere in the code, is there a way to change the config in order to generate a 404 for each url with a not null PATH_INFO ? Nicolas Figaro Joe Wollard a écrit : I believe Kevin is on the right track there. To expand

[PHP] strange php url

2006-04-21 Thread nicolas figaro
because my own site does the same and I wanted to be sure it didn't come from my config. thanks Nicolas Figaro -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Best way to start a CRON

2006-04-20 Thread nicolas figaro
Barry a écrit : Hello Everyone! What would be the best way to start a PHP Script via CRONJOB? Should i use the 'php' command or use curl or lynx or something to open that URL? Hi, unless you need to be sure the http server is up and running, it's a better way to run your script via a

Re: [PHP] POST arrays?

2006-04-20 Thread nicolas figaro
William Stokes a écrit : Can someone help me to get started with serializing? I think I did'nt quite understand the manual here... serialize and unserialize don't modify your variable, but the return value is a string or a mixed (which means it can be a very complicated structure, or a

Re: [PHP] preventing duplicate rows?

2006-04-13 Thread nicolas figaro
William Stokes a écrit : Hello, I'm updating a table with following SQL statement $sql = INSERT INTO x_ikaluokat (ryhma, ikaluokka) VALUES ('$ryhma','$ikaluokka'); What would be the best way to test that similar rows doesn't get created to the table? I can't make both columns unique.

Re: [PHP] Is it a bug of CakePHP?

2006-04-07 Thread nicolas figaro
Pham Huu Le Quoc Phuc a écrit : I catch an error, could you tell me if you have some ideas? class Dsptraining extends AppModel { function GetDsptrainings() { return $this-findBySql(select max(start_date) start_date from tbl_dsptrainings); } } did you try your sql

Re: [PHP] Outputting text ? how to?

2006-03-30 Thread nicolas figaro
Merlin a écrit : Hi there, I would like to output following text with php: ?xml version=1.0 encoding=ISO-8859-1 ? How can I do that? I tried to escape the ? with \? but this did not help. htmlentities perhaps ? N F Any ideas? Thank you for any hint, Merlin -- PHP General Mailing List

[PHP] call a php script in a php script

2006-03-28 Thread nicolas figaro
be a returning code with a message. (but it hasn't been fixed yet). Thanks a lot. Nicolas Figaro -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] mysql query/$post problem

2006-03-27 Thread nicolas figaro
Mark a écrit : I havnt even tried this query but i know its wrong can anyone help! *** ?php include(header.php); include(connect.php); don't you need a session_start() somewhere ? (or it's in the header.php or connect.php perhaps ?) $comp_id =

Re: [PHP] opening .Z archive with gzopen

2006-03-26 Thread nicolas figaro
Chris a écrit : nicolas figaro wrote: Hi I'm using php 4.3.11 on linux RH9. I'd like to open a .Z archive with gzopen. I looked at the options of gzopen, but I'm not sure there is a way to specify the compression used by compress/uncompress. Has anyone ever tried and done this yet

[PHP] opening .Z archive with gzopen

2006-03-24 Thread nicolas figaro
Nicolas Figaro -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] opening .Z compressed file with php

2006-03-24 Thread nicolas figaro
Nicolas Figaro -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php