RE: [PHP] true type fonts again
I included the error_reporting (E_ALL); ini_set('display_errors', 1); and commented out the header information, and I got the cannot open/find font So I copied the font to the correct places where I thought the font should go, and tried the web page again. The image is displayed but no text, I will be looking through the web pages for a way to output the image to harddrive directly. would running php script.php filename.gif be suitable, or is there another method. I do appreciate your help Thanks CJ -Original Message- From: Jason Wong [mailto:[EMAIL PROTECTED] Sent: Monday, 15 December 2003 7:22 PM To: [EMAIL PROTECTED] Subject: Re: [PHP] true type fonts again On Monday 15 December 2003 13:26, cj wrote: I have been able to the the image to display, which is a gif image of a rectange. But the text doesn't get displayed on the image. There are no error messages on the screen The other messages entitled true type fonts is a thread I started as well, but the image was not being displayed on the screen at all. So now I have the image but no text on the image. What could be causing this, and what should I have a look at? If you had read and followed the advice given in response to your earlier posts I'm sure you would've solved your problem by now. Again: 1) Enable FULL error reporting by including these lines at the top of your code: error_reporting (E_ALL); ini_set('display_errors', 1); 2) Output the image to file. Remember to comment out the header() for the time being. 3) And someone else suggested that you may have specified the name of your font file incorrectly. In my experience you *have* to specify a path to your font file. So if the font file was in the same directory as your script then use './name_of_font_file'. So if you had followed the above steps (at the least step 1) you would have seen the following error: PHP Warning: imagettftext(): Could not find/open font in ... and would have clued you into what the problem was. -- Jason Wong - Gremlins Associates - www.gremlins.biz Open Source Software Systems Integrators * Web Design Hosting * Internet Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* Alone, adj.: In bad company. -- Ambrose Bierce, The Devil's Dictionary */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] treu type fonts
sorry for the late delay. How would I output the image to a file on the hard drive Thanks -Original Message- From: Jason Wong [mailto:[EMAIL PROTECTED] Sent: Thursday, 11 December 2003 11:19 AM To: [EMAIL PROTECTED] Subject: Re: [PHP] treu type fonts On Thursday 11 December 2003 06:06, cj wrote: I tried the png like you suggested and the same thing happens. I get nothing on the screen but if I do a right click and properties on the spot where the image should be the image type is a png image. 1) Enable FULL error reporting. 2) For debugging purposes, instead outputting the image directly, write it to disk first. -- Jason Wong - Gremlins Associates - www.gremlins.biz Open Source Software Systems Integrators * Web Design Hosting * Internet Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* We are on the verge: Today our program proved Fermat's next-to-last theorem. -- Epigrams in Programming, ACM SIGPLAN Sept. 1982 */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] true type fonts again
G'day all I have been able to the the image to display, which is a gif image of a rectange. But the text doesn't get displayed on the image. There are no error messages on the screen The other messages entitled true type fonts is a thread I started as well, but the image was not being displayed on the screen at all. So now I have the image but no text on the image. What could be causing this, and what should I have a look at? Thanks P.S: the code I use is below ?php header(Content-type: image/gif); $im = imagecreate(400,30); $white = imagecolorallocate($im, 202,112,112); $black = imagecolorallocate($im, 255,255,255); // Replace path by your own font path imagettftext($im, 20, 0, 10, 20, $black, arial, Testing... Omega: amp;#937;); imagegif($im); imagedestroy($im); ? The Glennies Group P.O. Box 5136 Studfield Post Office WANTIRNA SOUTH VIC 3152 Ph: 61 3 9800 3906 E-mail: [EMAIL PROTECTED] Website: glennies.com.au -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] treu type fonts
Thanks Tom I tried the png like you suggested and the same thing happens. I get nothing on the screen but if I do a right click and properties on the spot where the image should be the image type is a png image. -Original Message- From: Tom Rogers [mailto:[EMAIL PROTECTED] Sent: Wednesday, 10 December 2003 1:10 PM To: cj Cc: [EMAIL PROTECTED] Subject: Re: [PHP] treu type fonts Hi, Wednesday, December 10, 2003, 11:53:27 AM, you wrote: c G'day all c I was wandering I have php installed with GD with freetype fonts compiled in c I ran this php script c ?php c header(Content-type: image/gif); c $im = imagecreate(400,30); c $white = imagecolorallocate($im, 255,255,255); c $black = imagecolorallocate($im, 0,0,0); c // Replace path by your own font path c imagettftext($im, 20, 0, 10, 20, $black, ./arial, Testing... Omega: c amp;#937;); c imagegif($im); c imagedestroy($im); ? c and nothing gets displayed on the screen. c Also if i right click in the top right hand corner and click properties the c type is gif image. c Can any one tell me what I should double check and what to look for. c As I am getting no errors messages, I guess that means that free type fonts c support is installed correctly? or please correct me if im wrong. Depending on where gd came from you may not be able to create gif files only read them. Try generating a png or jpeg -- regards, Tom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] treu type fonts
G'day all I was wandering I have php installed with GD with freetype fonts compiled in I ran this php script ?php header(Content-type: image/gif); $im = imagecreate(400,30); $white = imagecolorallocate($im, 255,255,255); $black = imagecolorallocate($im, 0,0,0); // Replace path by your own font path imagettftext($im, 20, 0, 10, 20, $black, ./arial, Testing... Omega: amp;#937;); imagegif($im); imagedestroy($im); ? and nothing gets displayed on the screen. Also if i right click in the top right hand corner and click properties the type is gif image. Can any one tell me what I should double check and what to look for. As I am getting no errors messages, I guess that means that free type fonts support is installed correctly? or please correct me if im wrong. Thanks CJ The Glennies Group P.O. Box 5136 Studfield Post Office WANTIRNA SOUTH VIC 3152 Ph: 61 3 9800 3906 E-mail: [EMAIL PROTECTED] Website: glennies.com.au -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] numbers
G'day all I have a calculation which gives me a number ie 6976587.4169922 This number is works outed by dividing a variable with 1024 Is there any way to strip anything after the . so I just want the number 6976587 and not anything after the . Thanks CJ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] numbers
I just found the answer -Original Message- From: cj [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 22 January 2003 11:07 AM To: Php-List (E-mail) Subject: [PHP] numbers G'day all I have a calculation which gives me a number ie 6976587.4169922 This number is works outed by dividing a variable with 1024 Is there any way to strip anything after the . so I just want the number 6976587 and not anything after the . Thanks CJ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] numbers
I used the floor() function -Original Message- From: Brian T. Allen [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 22 January 2003 11:49 AM To: [EMAIL PROTECTED]; 'Php-List (E-mail)' Subject: RE: [PHP] numbers Which, for the list, can be number_format(), among other things. Brian -Original Message- From: cj [mailto:[EMAIL PROTECTED]] Sent: Tuesday, January 21, 2003 5:18 PM To: Php-List (E-mail) Subject: RE: [PHP] numbers I just found the answer -Original Message- From: cj [mailto:[EMAIL PROTECTED]] Sent: Wednesday, 22 January 2003 11:07 AM To: Php-List (E-mail) Subject: [PHP] numbers G'day all I have a calculation which gives me a number ie 6976587.4169922 This number is works outed by dividing a variable with 1024 Is there any way to strip anything after the . so I just want the number 6976587 and not anything after the . Thanks CJ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] forms
G'day All Just a quick question This is really a html more than a php question. Is it possible to have two buttons and have different actions for each button in the same form? Thanks CJ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] forms
Would you know of any tutorial web sites which would explain how to do this? As I have not done any java programing before. -Original Message- From: Cal Evans [mailto:[EMAIL PROTECTED]] Sent: Tuesday, 14 January 2003 12:43 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: [PHP] forms yes but it's more of an HTML/JavaScript thing. use INPUT Type='BUTTON' to put a second button on your form. Then use the onClick method to assign an action to it. If you want it to submit your form then call document.formName.submit(); =C= * * Cal Evans * The Virtual CIO * http://www.calevans.com * -Original Message- From: cj [mailto:[EMAIL PROTECTED]] Sent: Monday, January 13, 2003 7:32 PM To: [EMAIL PROTECTED] Subject: [PHP] forms G'day All Just a quick question This is really a html more than a php question. Is it possible to have two buttons and have different actions for each button in the same form? Thanks CJ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] forms
So, if I am understanding correctly The page that processes the form will have to work out which button got pressed? That should be easy enough to work out, I hope :-) -Original Message- From: Chris Shiflett [mailto:[EMAIL PROTECTED]] Sent: Tuesday, 14 January 2003 2:21 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: [PHP] forms --- cj [EMAIL PROTECTED] wrote: Is it possible to have two buttons and have different actions for each button in the same form? No, because the action belongs to the form, not the submit buttons (which is why action is an attribute of form). However, you can use different names and values for the submit buttons, so that you can tell which was pressed on your receiving page. This way you can act accordingly, which is probably what you wanted to know. Hope that helps. Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] forms
Thanks everyone for your help. I got it to work yay -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Advice
G'day all I have a web page were users can upload and downloads files. When they go to download a file A list of files they can download is displayed and a check box next to each file name and a button, with which the users can click to download the selected file. What I would like to know what would be the best method of doing this? Would it be best to imbed the whole thing in a form, or is there another way that php can get the file information from the check box. The code I am working on is below, I am not very effient and a newbie at php so please excuse the mess Thanks Heaps cj //This gets the information of the owner and location of the file from the db $result = mysql_query(SELECT * FROM binary_files WHERE owner='$owner' and location='$location', $db); //this displays a table with Name, Size, and info. echo trtd/tdtdName/tdtdSize/tdtdInfo/td/tr\n; $myfile=0; //This fetchs the file information from the above mysql_query while ($myrow = mysql_fetch_array($result, MYSQL_ASSOC)) { //this displays a table with a checkbox, I would like the file_id to be the value for the checkbox (not //working) the check box gets no value echo trtdinput TYPE=checkbox NAME=filetodownload VALUE=$myrow[id_files] UNCHECKED/td; echo br; echo File To Download: ; echo $filetodownload; echo br; //This displays a link to the file download.php with the url varieble filedownload which equels the file_id obtained from the db echo tda href=download.php?filedownload=$myrow[id_files]$myrow[filename]/a/td; //This displays the filesize echo td$myrow[filesize]/td; //this display a info link (not yet implemented echo tda href=info.php?fileinfo=$myrow[id_files]img src=/Images/Info.png hspace=0 vspace=0 border= 0/a/td; echo //This displays a image, with a link to download.php with the url variable filedownload which contains the //file_id from the check box above (not working) a href=/upload/download.php?filedownload=$filetodownload target=mainimg src=/Images/icons.php?text=Downloadcolor=red border=0 border=0/a ; } echo /table\n; -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] php+gd 2.0.7 problems take 2
Hi would any one know what the following error's are for/mean I am using gd 2.0.7 with gif support built in and php4.2.3 I am using the exact same gd version and php version as I used on another machine and it compiled with only minor problems, but these errors are different to the errors I got on the other machine. Thanks gcc -I. -I/usr/local/src/php-4.2.3/ext/gd -I/usr/local/src/php-4.2.3/main -I /usr/local/src/php-4.2.3 -I/usr/local/src/apache_1.3.26/src/include -I/usr/l ocal/src/apache_1.3.26/src/os/unix -I/usr/local/src/php-4.2.3/Zend -I/usr/lo cal/include -I/usr/local/src/gd-2.0.7gif/ -I/usr/local/src/php-4.2.3/ext/mys ql/libmysql -I/usr/local/pgsql/include -I/usr/local/src/php-4.2.3/ext/xml/ex pat -I/usr/local/src/php-4.2.3/TSRM -g -O2 -c gd.c touch gd.lo gd.c: In function `zm_startup_gd': gd.c:303: `gdArc' undeclared (first use in this function) gd.c:303: (Each undeclared identifier is reported only once gd.c:303: for each function it appears in.) gd.c:304: `gdPie' undeclared (first use in this function) gd.c:305: `gdChord' undeclared (first use in this function) gd.c:306: `gdNoFill' undeclared (first use in this function) gd.c:307: `gdEdged' undeclared (first use in this function) gd.c: In function `zif_imagecreatetruecolor': gd.c:588: warning: assignment makes pointer from integer without a cast gd.c: In function `zif_imagecreatefromstring': gd.c:1093: `gdImageCreateFromGifCtx' undeclared (first use in this function) gd.c: In function `zif_imagecreatefromgif': gd.c:1235: `gdImageCreateFromGif' undeclared (first use in this function) gd.c:1235: `gdImageCreateFromGifCtx' undeclared (first use in this function) gd.c: In function `zif_imagegif': gd.c:1462: `gdImageGifCtx' undeclared (first use in this function) gd.c: In function `zif_imagecolorat': gd.c:1626: structure has no member named `tpixels' gd.c: In function `_php_image_convert': gd.c:3521: `gdImageCreateFromGif' used prior to declaration gd.c:3521: warning: assignment makes pointer from integer without a cast make[3]: *** [gd.lo] Error 1 make[3]: Leaving directory `/usr/local/src/php-4.2.3/ext/gd' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/usr/local/src/php-4.2.3/ext/gd' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/usr/local/src/php-4.2.3/ext' make: *** [all-recursive] Error 1 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] php+gif problems take 2
Hi would any one know what the following error's are for/mean I am using gd 2.0.7 with gif support and php4.2.3. I am using the exact same gd version and php version as I used on another machine and it compiled with only minor problems, but these errors are different to the errors I got on the other machine. Thanks gcc -I. -I/usr/local/src/php-4.2.3/ext/gd -I/usr/local/src/php-4.2.3/main -I /usr/local/src/php-4.2.3 -I/usr/local/src/apache_1.3.26/src/include -I/usr/l ocal/src/apache_1.3.26/src/os/unix -I/usr/local/src/php-4.2.3/Zend -I/usr/lo cal/include -I/usr/local/src/gd-2.0.7gif/ -I/usr/local/src/php-4.2.3/ext/mys ql/libmysql -I/usr/local/pgsql/include -I/usr/local/src/php-4.2.3/ext/xml/ex pat -I/usr/local/src/php-4.2.3/TSRM -g -O2 -c gd.c touch gd.lo gd.c: In function `zm_startup_gd': gd.c:303: `gdArc' undeclared (first use in this function) gd.c:303: (Each undeclared identifier is reported only once gd.c:303: for each function it appears in.) gd.c:304: `gdPie' undeclared (first use in this function) gd.c:305: `gdChord' undeclared (first use in this function) gd.c:306: `gdNoFill' undeclared (first use in this function) gd.c:307: `gdEdged' undeclared (first use in this function) gd.c: In function `zif_imagecreatetruecolor': gd.c:588: warning: assignment makes pointer from integer without a cast gd.c: In function `zif_imagecreatefromstring': gd.c:1093: `gdImageCreateFromGifCtx' undeclared (first use in this function) gd.c: In function `zif_imagecreatefromgif': gd.c:1235: `gdImageCreateFromGif' undeclared (first use in this function) gd.c:1235: `gdImageCreateFromGifCtx' undeclared (first use in this function) gd.c: In function `zif_imagegif': gd.c:1462: `gdImageGifCtx' undeclared (first use in this function) gd.c: In function `zif_imagecolorat': gd.c:1626: structure has no member named `tpixels' gd.c: In function `_php_image_convert': gd.c:3521: `gdImageCreateFromGif' used prior to declaration gd.c:3521: warning: assignment makes pointer from integer without a cast make[3]: *** [gd.lo] Error 1 make[3]: Leaving directory `/usr/local/src/php-4.2.3/ext/gd' make[2]: *** [all-recursive] Error 1 make[2]: Leaving directory `/usr/local/src/php-4.2.3/ext/gd' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/usr/local/src/php-4.2.3/ext' make: *** [all-recursive] Error 1 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] passing multiple variables in a url
I have a contact us php script on my site that allows users to email direct from the webiste. I want to be able to pass the to address and subject line to the script so I can call teh web page from elsewhere on the site and have it automatically choose the correct email address and subject line. EG instad of using a href=mailto:joe;bloggs.mail.com which requires them to have an email client set up on the machine I want to link to a href=contactus.php?email=director subject=job enquiry The script already handles the email=director by setting a default entry in a drop down form but I can't get it to separate the first and second variables in the URL. Also is this a big security risk as I will be echoing the 2nd variable as the contents of a form field. Would it be possible for someone to type in the URL with HTML/php in it that would make a mess of everything? How can I protect against this? Would it be sufficient to just pase the 2nd variable for non alphabetic characters and remove them? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] passing multiple variables in a url
that works fine thanks. Now for what to do with the variables (new post scanning for non alpha characters) Bigdog [EMAIL PROTECTED] wrote in message news:1037262239.10847.17.camel;pclnxrhunter.digitalglobe.com... Does this not work... a href=contactus.php?email=directorsubject=job enquiry On Thu, 2002-11-14 at 14:11, CJ wrote: I have a contact us php script on my site that allows users to email direct from the webiste. I want to be able to pass the to address and subject line to the script so I can call teh web page from elsewhere on the site and have it automatically choose the correct email address and subject line. EG instad of using a href=mailto:joe;bloggs.mail.com which requires them to have an email client set up on the machine I want to link to a href=contactus.php?email=director subject=job enquiry The script already handles the email=director by setting a default entry in a drop down form but I can't get it to separate the first and second variables in the URL. Also is this a big security risk as I will be echoing the 2nd variable as the contents of a form field. Would it be possible for someone to type in the URL with HTML/php in it that would make a mess of everything? How can I protect against this? Would it be sufficient to just pase the 2nd variable for non alphabetic characters and remove them? -- .: B i g D o g :. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] scanning for non alpha characters
I want to scan the variables passed from teh url of my script for non alpha characters. The variables should only consist of a-z A-Z 0-9 and spaces, full stops and commas (Basically I don't want scripts to be passed via the variable to the server) I've used perl a long time ago and its regular expressions seemed ideal for this kind of thing. Can enybody suggest a scrip to remove unwanted characters from my variable? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Swear word substitution
I've got a mysql based website with a php scripted fromt end. I want to parse the output the php scripts get from the database before printing it as html for swear words and substitute these for more acceptable words (on a word for word basis). I need to do it this way as I want to keep the original posts in their rude form in case I need evidence for misuse of the site. I need to be able to check for words separated by non alpha characters in case people get clever and write obscenities separated w i t h s p a c e s or with o_t_h_e_r characters or even new l i n e s or wordsruntogetherintoonelongword. I also want a list of permitted words that contain swearwords such as Scunthorpe which won't get changed. Has anybody done this? I have a feeling that there is a 1 line regular expression out there that will do this nicely. Any help appreciated Feeling rusty at coding... CJ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: scanning for non alpha characters
Did check them, it suggested that it was an optional library! I'll look into ereg_replace. Thanks CJ Coert Metz [EMAIL PROTECTED] wrote in message news:3DD3C27A.9070504;metzonline.nl... PHP also supports regular expressions Check the manual at php.net for more information (ereg_replace a.s.o) Coert Cj wrote: I want to scan the variables passed from teh url of my script for non alpha characters. The variables should only consist of a-z A-Z 0-9 and spaces, full stops and commas (Basically I don't want scripts to be passed via the variable to the server) I've used perl a long time ago and its regular expressions seemed ideal for this kind of thing. Can enybody suggest a scrip to remove unwanted characters from my variable? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Swear word substitution
I'm posting this again as i got a mail saying Trend SMEX Content Filter has detected sensitive content. Place = [EMAIL PROTECTED]; ; Sender = CJ Subject = [PHP] Swear word substitution Delivery Time = November 14, 2002 (Thursday) 23:40:23 Policy = Dirty Words Action on this mail = Delete message Warning message from administrator: Sender, Content filter has detected a sensitive e-mail. There was not a swear word in my original post but there was a word that contained a swear word but is itself not a swear word. The word is Scu n thorpe and I need a script to allow wordslike this but remove proper swearwords. I've got a mysql based website with a php scripted fromt end. I want to parse the output the php scripts get from the database before printing it as html for swear words and substitute these for more acceptable words (on a word for word basis). I need to do it this way as I want to keep the original posts in their rude form in case I need evidence for misuse of the site. I need to be able to check for words separated by non alpha characters in case people get clever and write obscenities separated w i t h s p a c e s or with o_t_h_e_r characters or even new l i n e s or wordsruntogetherintoonelongword. I also want a list of permitted words that contain swearwords such as Sc%%thorpe which won't get changed. Has anybody done this? I have a feeling that there is a 1 line regular expression out there that will do this nicely. Any help appreciated Feeling rusty at coding... CJ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Variable over url
Read the docs first plz, or search for it thank you... Manuel jenne wrote: Hi, I've just installed php 4.2.3 and wonder why I can't submit an variable over url. Example: My Script: Test.php My URL: www.some.domain/test.php?tmp=5 My result: NOTHING !!! Where is the error? P.S. phpmyadmin run ok. Thanx Manuel -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: $html_code .= include (filetoinclude.txt);
$html_code = $html_code.include(filetoinclude.txt); Research And Development wrote: Should this work? $html_code .= include (filetoinclude.txt); I am populating a variable with html to be printred later as usual: $html_code .= html. But I have some static html files that I want included in the html that I am storing in the variable. The HTML is in text files. The above code obviously does not work. I want to know if there is another way. Thanks. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] configuring sever to send mail (Win2k)
i have a problem using the mail function on my server. win2000 Pro IIS 5.0 PHP Version 4.0.6 i'm not sure if it's a configuration problem with IIS or i'm missing something in the php.ini file. thanks CJ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] configuring sever to send mail (Win2k)
thanks for the reply but i still need some help: PHP Version 4.0.6 [mail function] ; For Win32 only. SMTP = localhost ; For Win32 only. sendmail_from = [EMAIL PROTECTED] --- I get this error when i use the mail function on my local server (IIS 5.0, windows 2000 Pro). Maybe it's an IIS configuration problem. i'm really not sure. Error Warning: Server Error in F:\Inetpub\wwwroot\stowe\scripts\mail.php on line 42 Code ?php $to = '[EMAIL PROTECTED]'; $from = '[EMAIL PROTECTED]'; //Check if we have something POSTed by the form. if (isset($HTTP_POST_VARS)){ //Start with an empty body for the mail message $body = ''; //Iterate through all the POSTed variables, and add them to the message body. while (list($key, $value) = each($HTTP_POST_VARS)){ $body .= $key . ' = ' . $value . \r\n; } //Build up some nice From/Reply Headers $headers = From: $from\r\n; $headers .= Reply-To: $from\r\n; //Mail the message out. //Requires setting php3.ini sendmail path as per instructions $success = mail($to, Posted . date(m/d/Y), $body, $headers); //LINE 42 //Always check return codes from functions. if ($success){ echo BCENTERThank you for your input/CENTER/B\n; } else{ echo CENTERBInternal Error/B: Your input was unprocessed.BRContact $from/CENTER\n; } } ? Dl Neil [EMAIL PROTECTED] wrote in message 06f601c1962f$e3841cc0$7b16100a@jrbrown">news:06f601c1962f$e3841cc0$7b16100a@jrbrown... CJ, i have a problem using the mail function on my server. win2000 Pro IIS 5.0 PHP Version 4.0.6 i'm not sure if it's a configuration problem with IIS or i'm missing something in the php.ini file. The pre-requisite is that the php.ini file points to a visible SMTP server. Please review the [mail function] section of that file. If you have further questions please include that section, plus PHP version number in your reply. Regards, =dn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] configuring sever to send mail (Win2k)
thanks for the reply but i still need some help: PHP Version 4.0.6 [mail function] ; For Win32 only. SMTP = localhost ; For Win32 only. sendmail_from = [EMAIL PROTECTED] --- I get this error when i use the mail function on my local server (IIS 5.0, windows 2000 Pro). Maybe it's an IIS configuration problem. i'm really not sure. Error Warning: Server Error in F:\Inetpub\wwwroot\stowe\scripts\mail.php on line 42 Code ?php $to = '[EMAIL PROTECTED]'; $from = '[EMAIL PROTECTED]'; //Check if we have something POSTed by the form. if (isset($HTTP_POST_VARS)){ //Start with an empty body for the mail message $body = ''; //Iterate through all the POSTed variables, and add them to the message body. while (list($key, $value) = each($HTTP_POST_VARS)){ $body .= $key . ' = ' . $value . \r\n; } //Build up some nice From/Reply Headers $headers = From: $from\r\n; $headers .= Reply-To: $from\r\n; //Mail the message out. //Requires setting php3.ini sendmail path as per instructions $success = mail($to, Posted . date(m/d/Y), $body, $headers); //LINE 42 //Always check return codes from functions. if ($success){ echo BCENTERThank you for your input/CENTER/B\n; } else{ echo CENTERBInternal Error/B: Your input was unprocessed.BRContact $from/CENTER\n; } } ? Dl Neil [EMAIL PROTECTED] wrote in message 06f601c1962f$e3841cc0$7b16100a@jrbrown">news:06f601c1962f$e3841cc0$7b16100a@jrbrown... CJ, i have a problem using the mail function on my server. win2000 Pro IIS 5.0 PHP Version 4.0.6 i'm not sure if it's a configuration problem with IIS or i'm missing something in the php.ini file. The pre-requisite is that the php.ini file points to a visible SMTP server. Please review the [mail function] section of that file. If you have further questions please include that section, plus PHP version number in your reply. Regards, =dn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]