Re: [PHP] Spam using email on website
Pieter du Toit wrote: Hi guys I have a website that is being crawled or whatever and i have a submission form for an event. I keep on getting random mail from this form. I have even disabled the submit button on the form, but keep on getting it. What can i do? you could use a CAPTCHA image (although not entirely spam proof) you could have a random variable in a hidden input field, perhaps the session id and check this variable when the form is submitted. also form validation is important and having certain fields that are required makes it a little harder for spammers. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Re: Frameworks
Radicore is built using PHP, so if PHP can run under IIS then so can Radicore. If you already have a working PHP installation running under IIS then Radicore should work. I'm not sure about the .htaccess settings though, so you will have to consult the IIS manual. Tony Marston http://www.tonymarston.net http://www.radicore.org Bruce Cowin [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Hi Tony, On the installation instructions for Radicore, I see a lot of mention of Apache but no mention of IIS set up. Does Radicore work on IIS? Thanks. Regards, Bruce Tony Marston [EMAIL PROTECTED] 3/11/2006 11:10:12 p.m. It totally depends on what type of application you are writing, and what features you want out of the box so that you don't have to design and write them yourself. For example, if you are writing an administrative web application and you want user authentication, dynamic menus, role based access control, audit logging without database triggers, built-in workflow, and internationalisation facilities then you might want to take a look at Radicore (http://www.radicore.org/) As well as having all the above features it has a custom built Data Dictionary which can generate all the basic code for you. This enables you to start with nothing more than a database schema which you then import into the Data Dictionary, and from there you can press buttons to generate the database table classes and also buttons to generate the scripts to view and maintain those tables. All this without having to write a single line of code. It uses a catalog of transaction patterns which deal with single tables, one-to-many relationships and even many-to-many relationships. There is a massive amount of documentation and sample code, and a tutorial is available at http://www.tonymarston.net/php-mysql/radicore-tutorial.html -- Tony Marston http://www.tonymarston.net http://www.radicore.org [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I know this subject has been covered in the past, but my question is why use them? I'm hoping to not create a religious war... I see that frameworks would probably help you develop some things faster, but most of the time they don't do the things the way I would want them to work. If I did use one, it almost seems like I would use it to get through something until I had time to do things the way I wanted/needed to do them. There's a lot of talk about frameworks lately, and especially the Zend Framework, so I'd like to look into what it's all about. I think I might be missing out the framework issue, so I'd like to hear other people's opinions. I do like the mail, pdf, and a few other parts of the Zend Framework. I also like that it's more like a set of tools than a monolithic beast that would take a lot of memory just to load up into your application. Your thoughts? Thanks, Ray -- 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] Re: Sorting MySQL queries
Richard Lynch wrote: Actually, super-recent MySQL has user-defined functions, I think, so the previous solution by another post may be better in that case. MySQL since way back has allowd UDF's but you need to write them in C and compile them up as .so's and then call the create function syntax to register them in the func table. It's very handy and we've written a few UDFs and Aggregate UDFs to make our lives easier. Newer versions of MySQL can maybe create simpler UDFs from built in commands like the Postgres example earlier in the thread?? Sounds interesting and handy. Unf. unlike in Postgres, I don't think you can create functional indexes atlhough that too sounds mega handy! Given me food for SQL thought :) Col. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] WAP?
Richard Lynch wrote: So far, in my limited reading, it seems like more than a few people are saying the 1.x-only handsets are still out there yes true, just remember the 80/20 principle, how many of those older handset user will be using this wap site, actually depending on what you want to do you may want to have a look at USSD (way older than wap), this will work on all GSM phones even ones that don't have wap support. It pretty much has to just work for any user in the United States. Or Canada. maybe you can gets stats on the most common handsets I'm just happy to have Hello World working. cool -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] PHP Zip Question
Richard, Thank you for your post and the link to your rant. Indeed I am a PHP newbie and have fallen into the advice I have been given through google. . . I have added an exit and probably owe you a donut as I had to remove a couple of echo's from my code! However, the good news after all of this is that my code is now working and I can finish off my tests. Thanks again Matt -Original Message- From: Richard Lynch [mailto:[EMAIL PROTECTED] Sent: 06 November 2006 21:02 To: Matt Street Cc: 'php-general@lists.php.net' Subject: RE: [PHP] PHP Zip Question On Mon, November 6, 2006 6:28 am, Matt Street wrote: Thanks for the response, I decided that it was easier to unpack the zip during the upload process and then delete the zip. I can then indicate which files I want to zip up and this works (opening the zip on the server), but, and it's a big but, when the zip is downloaded to the users machine it is being corrupted! To force the download I use: header('Content-type: application/zip'); header('Content-Disposition: attachment; filename='.$tutorzipfile); readfile($filename); Which correctly gives me: Content-Type: application/zip Content-disposition: attachment; filename=tutorzipfile.zip when viewing the LiveHTTPHeaders extension in firefox. Rant #37 http://richardlynch.blogspot.com/ However, when I view the zip file that is downloaded to my machine, in Textpad, php has appended the directory information of the files I'm zipping up onto the front of the zip file, so it no longer starts PK!!! PHP didn't do it. Your zip routines may have done it. Your code may have done it. But PHP is not, no its own, just outputting the directory info for no real reason. Put an exit right before you readfile() and the headers. You may need to move the headers down below all the code that calculates what's getting zipped up and all that... Dollars to donuts says you've left behind a debugging: echo pwd(); or something similar. -- Some people have a gift link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] 'View as HTML' Conversions
Hi, We are trying to create a script which (the same as google search and gmail) allows for PDF's, Doc's, Excel etc to be converted to HTML documents dynamically, this is just in case users want to view documents but don't have the necessary software. The HTML needs to keep as much of the styling as possible. Does anyone know how google have done this? or does anyone know any PHP equivalents, we are using the Windows IIS server. Thanks Kevin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: 'View as HTML' Conversions
Kevin [EMAIL PROTECTED] ???/ ? ?: news:[EMAIL PROTECTED] Hi, We are trying to create a script which (the same as google search and gmail) allows for PDF's, Doc's, Excel etc to be converted to HTML documents dynamically, this is just in case users want to view documents but don't have the necessary software. The HTML needs to keep as much of the styling as possible. Does anyone know how google have done this? or does anyone know any PHP equivalents, we are using the Windows IIS server. You may try to use COM to convert MS Office files to HTML, something like $doc = new COM('somewordfile.doc'); $doc-saveAs('somewordfile.html', 10); $doc-close(); -- Sincerely, Rosty Kerei -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] 'View as HTML' Conversions
Kevin wrote: Does anyone know how google have done this? or does anyone know any PHP equivalents, we are using the Windows IIS server. They employ some very clever people :) your best bet is to find a command line tool that can do what you need, then simply call this from php. Thanks Kevin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] problems with SOAP-PHP5 and heritage
Hi, I'm making a webservice using SOAP-PHP5. It working fine. But when I use a method in a class that use a heritage, it fails. The class wrok fine out of the webservice, but dont work on webservice. Look SoapFault exception: [Client] looks like we got no XML document in /var/www/bruno/xtemplate/ControlerClasses/Personnel/Personnel.php:125 Stack trace: #0 [internal function]: SoapClient-__call('listPersonnel', Array) #1 /var/www/bruno/xtemplate/ControlerClasses/Personnel/Personnel.php(125): SoapClient-listPersonnel() #2 /var/www/bruno/xtemplate/ControlerClasses/Personnel/Personnel.php(97): PersonnelTemplate-generatePersonnels() #3 /var/www/bruno/xtemplate/ControlerClasses/BiomaTemplate.php(241): PersonnelTemplate-generate() #4 /var/www/bruno/xtemplate/ControlerClasses/BiomaTemplate.php(159): BiomaTemplate-generatePersonnel() #5 /var/www/bruno/xtemplate/index.php(54): BiomaTemplate-generate() #6 {main} Both, Personnel.php and BiomaTemplate.php is a extended class Look the file Personnel attach and the main class Common. What is the problem? SOAP dont support heritage? -- Prof. Ronaldo Reis Júnior | .''`. UNIMONTES/Depto. Biologia Geral/Lab. Ecologia Evolutiva | : :' : Campus Universitário Prof. Darcy Ribeiro, Vila Mauricéia | `. `'` CP: 126, CEP: 39401-089, Montes Claros - MG - Brasil | `- Fone: (38) 3229-8190 | [EMAIL PROTECTED] | ICQ#: 5692561 | LinuxUser#: 205366 Personnel.php Description: application/php Common.php Description: application/php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: 'View as HTML' Conversions
Kevin wrote: Hi, We are trying to create a script which (the same as google search and gmail) allows for PDF's, Doc's, Excel etc to be converted to HTML documents dynamically, this is just in case users want to view documents but don't have the necessary software. The HTML needs to keep as much of the styling as possible. Does anyone know how google have done this? or does anyone know any PHP equivalents, we are using the Windows IIS server. Have a look at the *nix command line utility: pdf2html it may give you some guidence but seeing as you are using Windows I don't know. I'm pretty sure Google will used *nix and perhaps even the pdf2html tool itself?? As for word documents I know there are *nix command line tools to extract text out of them for indexing but not sure about format conversions, certainly it should be easy enough to produce a PDF form Word/Excel then use whatever technique you choose to get the PDF2HTML. If your webserver has Word/Excel installed (not recommended for security etc.) then I presume there is some sort of method you can call to interact with it Tho' guessing that word will not take command line args like any sensible program can and do automated conversion for you... ;) Not much help here I know, but hopefully some food for thought. Col -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] 'View as HTML' Conversions
Check out Alfresco. It's basicly a (E)CMS, which you upload word / excel / etc. It may do everything you want, or you may be able to extract the parts you want and leave the rest, or it may be of no use to you whatsoever. It basicly sets up an OOo daemon, and connects to it to do its conversions. Downside ( unless you're also a java dev ) is that the connector is written in Java, and may be difficult to port to PHP. Unless it's a clean java class that you can initialise with www.php.net/java -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Authentification and LDAP (SSO / Single Sign-On)
Hi, I'm currently developing a PHP application as intranet tool for our company. I would like to make users connect to this tool with an authentification window where they can enter their domain login and password. via LDAP and Apache module mod_auth_ldap, i would like to check this user login and password. Only if it's correct, they can enter in my tool. I tried to find some example of PHP code but without success. Could you help me ? thanks, Al.
Re: [PHP] Authentification and LDAP (SSO / Single Sign-On)
On Tuesday 07 November 2006 12:13, Alain Roger wrote: I'm currently developing a PHP application as intranet tool for our company. I would like to make users connect to this tool with an authentification window where they can enter their domain login and password. via LDAP and Apache module mod_auth_ldap, i would like to check this user login and password. Only if it's correct, they can enter in my tool. I tried to find some example of PHP code but without success. If you are using Apache's mod_auth_ldap to implement authentication and access control, your Apache configuration (in .htaccess file or server configuration file) will have to specify how this is to work. Apache will present a standard HTTP challenge for username and password and deny access if these are invalid for the requested URL. Your PHP appliction will be able to see the username of the authenticated user (as the server variable AUTH_USER). Using mod_auth_ldap means that you don't need to code anything in PHP - all access control is done by Apache. HTH - Nick - Mae'r e bost hwn ac unrhyw atodiad iddo yn gyfrinachol ac fe'i bwriedir ar gyfer y sawl a enwir arno yn unig. Gall gynnwys gwybodaeth freintiedig. Os yw wedi eich cyrraedd trwy gamgymeriad ni ellwch ei gopio, ei ddosbarthu na'i ddangos i unrhyw un arall a dylech gysylltu gyda Cyngor Sir Powys ar unwaith. Mae unrhyw gynnwys nad yw'n ymwneud gyda busnes swyddogol Cyngor Sir Powys yn bersonol i'r awdur ac nid yw'n awdurdodedig gan y Cyngor. This e mail and any attachments are confidential and intended for the named recipient only. The content may contain privileged information. If it has reached you by mistake, you should not copy, distribute or show the content to anyone but should contact Powys County Council at once. Any content that is not pertinent to Powys County Council business is personal to the author, and is not necessarily the view of the Council. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: 'View as HTML' Conversions
Rosty Kerei wrote: Kevin [EMAIL PROTECTED] ???/ ? ?: news:[EMAIL PROTECTED] Hi, We are trying to create a script which (the same as google search and gmail) allows for PDF's, Doc's, Excel etc to be converted to HTML documents dynamically, this is just in case users want to view documents but don't have the necessary software. The HTML needs to keep as much of the styling as possible. Does anyone know how google have done this? or does anyone know any PHP equivalents, we are using the Windows IIS server. You may try to use COM to convert MS Office files to HTML, something like $doc = new COM('somewordfile.doc'); $doc-saveAs('somewordfile.html', 10); $doc-close(); Hi Thanks for that, the com library seems the way to do it, just a bit unsure what I would need to do, I take it I would need to install the office suite on the server, would I also need to install all converters on the server too? for example would i need to install the adobe acrobat printer, so that I can call the print function and print it to that printer, then move the output file to where i want??! Could you provide just one example of how to open a word doc, print it to a printer (say an adobe printer) and move it to a folder on the system?! What security holes would this leave open and is there any other information regarding security I could up on? Thanks for your help Kevin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PHP and dynamic DHTML menus - suggestions
Hi All, We are looking for a solution for visually displaying parent and child nodes in a tree like component. It must work with PHP and mySQL as we are going to be populating the tree with dynamic data. We have found this: http://scbr.com/docs/products/dhtmlxTree/index.shtml but the demo of the PHP + mySQL things doesnt work. If anyone has any comments, experiences and advices please shoot away! Thanks in advance. Angelo -- Angelo Zanetti Systems developer *Telephone:* +27 (021) 469 1052 *Mobile:* +27 (0) 72 441 3355 *Fax:*+27 (0) 86 681 5885 * Web:* http://www.zlogic.co.za *E-Mail:* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Authentification and LDAP (SSO / Single Sign-On)
On Tuesday 07 November 2006 12:37, you wrote: So how can i implement a SSO via PHP only ? To use LDAP from within PHP you need to have a version of PHP with LDAP support available. Check the PHP online docs for how to do this. Assuming you know how to use PHP to create a standard looking login box then what you then need to do to check a username and password is to attempt to bind to the LDAP server using these credentials. If this fails, something is wrong with the credentials and you can decide how to handle it in your code. The main thing you'll need to know is how to construct the dn from just the username. If you know about the LDAP directory you want to use then you'll probably know how to do this. If not, talk with your directory admin. The code you would write would be along these lines, assuming you've just collected $username and $password from the login box... $dn = uid=$username,ou=Accounts,o=Your Company,c=US; $ds=ldap_connect(your.ldap.server); $r=ldap_bind($ds, $dn, $password); If ldap_bind() succeeds you have an authenticated user. There are sometimes a few extra things you may need to do, depending on your directory server setup. For example, you may need to explicitly set the LDAP protocol to use, or you may need to first do an anonymous bind to the directory and run a query to get the correct dn for the user if you can't construct the dn as in the above example. There are lots of code snippets in the online PHP docs that cover these things. HTH - Nick - Mae'r e bost hwn ac unrhyw atodiad iddo yn gyfrinachol ac fe'i bwriedir ar gyfer y sawl a enwir arno yn unig. Gall gynnwys gwybodaeth freintiedig. Os yw wedi eich cyrraedd trwy gamgymeriad ni ellwch ei gopio, ei ddosbarthu na'i ddangos i unrhyw un arall a dylech gysylltu gyda Cyngor Sir Powys ar unwaith. Mae unrhyw gynnwys nad yw'n ymwneud gyda busnes swyddogol Cyngor Sir Powys yn bersonol i'r awdur ac nid yw'n awdurdodedig gan y Cyngor. This e mail and any attachments are confidential and intended for the named recipient only. The content may contain privileged information. If it has reached you by mistake, you should not copy, distribute or show the content to anyone but should contact Powys County Council at once. Any content that is not pertinent to Powys County Council business is personal to the author, and is not necessarily the view of the Council. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] OpenLDAP
Hi, where can i find OpenLDAPftp://ftp.openldap.org/pub/OpenLDAP/openldap-stable/files already compiled ? i've downloaded the tar file, but i do not have a compiler with me... :-*( thx, Alain
Re: [PHP] PHP and dynamic DHTML TREE (not menu) - suggestions
Angelo Zanetti wrote: Hi All, We are looking for a solution for visually displaying parent and child nodes in a tree like component. It must work with PHP and mySQL as we are going to be populating the tree with dynamic data. We have found this: http://scbr.com/docs/products/dhtmlxTree/index.shtml but the demo of the PHP + mySQL things doesnt work. If anyone has any comments, experiences and advices please shoot away! Thanks in advance. Angelo -- Angelo Zanetti Systems developer *Telephone:* +27 (021) 469 1052 *Mobile:* +27 (0) 72 441 3355 *Fax:*+27 (0) 86 681 5885 * Web:* http://www.zlogic.co.za *E-Mail:* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] PHP and dynamic DHTML TREE (not menu) - suggestions
How about http://developer.yahoo.com/yui/treeview/ ? I've been using Yahoo's UI components for a few weeks now and am seriously impressed by them. Edward Angelo Zanetti wrote: Hi All, We are looking for a solution for visually displaying parent and child nodes in a tree like component. It must work with PHP and mySQL as we are going to be populating the tree with dynamic data. We have found this: http://scbr.com/docs/products/dhtmlxTree/index.shtml but the demo of the PHP + mySQL things doesnt work. If anyone has any comments, experiences and advices please shoot away! Thanks in advance. Angelo -- Angelo Zanetti Systems developer *Telephone:* +27 (021) 469 1052 *Mobile:* +27 (0) 72 441 3355 *Fax:*+27 (0) 86 681 5885 * Web:* http://www.zlogic.co.za *E-Mail:* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] -- 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] Re: Spam using email on website
On Tue, 07 Nov 2006 08:42:57 +0200, Pieter du Toit wrote: Hi guys I have a website that is being crawled or whatever and i have a submission form for an event. I keep on getting random mail from this form. I have even disabled the submit button on the form, but keep on getting it. What can i do? I usually find these bastards to enter lots of information in some fields. If I find too much info (or an \r\n) in a regular INPUT type=text field, I either stop processing or throw an error. Either way: no mail-sending. Ivo -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Spam using email on website
Pieter du Toit wrote: Hi guys I have a website that is being crawled or whatever and i have a submission form for an event. I keep on getting random mail from this form. I have even disabled the submit button on the form, but keep on getting it. What can i do? Did you write the mail sender script yourself? A spammer can simply submit your form using there own server or any other server with your fields, so you need to stop the processing on your server side if you simply want to disable it. If you want it work however then that you could use the GD library to create an image on the fly showing 5 numbers, which the user needs to fill in in order to send, this would stop the bots from being automate your form. Kevin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PHP-based content and document management
I am looking for a PHP based content management system to integrate into my existing website. I am not interested in the community-type systems. All I need is to query the content management system for content or documents based on some search criteria. The interface to the system could be a PHP method or a web service call. I would appreciate any suggestions. Thanks in advance. Regards. -- Anas Mughal
[PHP] Parse Errors with 5.2 on Linux
Hi there, I just installed PHP 5.2 on a linux server (compiled from source), and am having some strange problems with a script that is reporting a fatal parse error: Parse error: syntax error, unexpected $end in /xxx/xxx/xxx/functions.php on line 1213 This very script parses just a-okay under PHP 5.1.6 (linux), and, mysteriously, 5.2 on windows. I'm sure that the file is identical across all three servers. The file is pulled from a subversion repository, so it should be identical. Any ideas? Thanks, Mike
Re: [PHP] Parse Errors with 5.2 on Linux
On Tue, November 7, 2006 11:30 am, Michael Caplan wrote: I just installed PHP 5.2 on a linux server (compiled from source), and am having some strange problems with a script that is reporting a fatal parse error: Parse error: syntax error, unexpected $end in /xxx/xxx/xxx/functions.php on line 1213 This very script parses just a-okay under PHP 5.1.6 (linux), and, mysteriously, 5.2 on windows. I'm sure that the file is identical across all three servers. The file is pulled from a subversion repository, so it should be identical. Any ideas? That usually means an unmatched { or ( or or ' etc... So, basically, I'd suggesting copying the files over by hand with FTP or something and doing a 'diff' to be 100% sure you have the whole file. It's also remotely possible that something changed in 5.2... I never have understood why it was kosher to leave the final ? off, for example, so maybe that changed. :-) [I doubt it] At any rate, you have to confirm that the file *IS* complete first. After that, post the file if you can, or we've got nothing to say about it, really... -- Some people have a gift link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] list of countries
Does anyone have a list of countries in a handy format for importing into MySQL? I just really need a list. Wikipedia has a nice list, but it's muddled by HTML tags. If you also have them in Chinese and Arabic that would be even better. -James -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Parse Errors with 5.2 on Linux
Hi Richard, Thanks for the reply. I tracked the problem down to short tags being turned off in the php.ini (I know, short tags, bad, bad). That fixed it. Thanks, Mike -Original Message- From: Richard Lynch [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 07, 2006 1:39 PM To: Michael Caplan Cc: php-general@lists.php.net Subject: Re: [PHP] Parse Errors with 5.2 on Linux On Tue, November 7, 2006 11:30 am, Michael Caplan wrote: I just installed PHP 5.2 on a linux server (compiled from source), and am having some strange problems with a script that is reporting a fatal parse error: Parse error: syntax error, unexpected $end in /xxx/xxx/xxx/functions.php on line 1213 This very script parses just a-okay under PHP 5.1.6 (linux), and, mysteriously, 5.2 on windows. I'm sure that the file is identical across all three servers. The file is pulled from a subversion repository, so it should be identical. Any ideas? That usually means an unmatched { or ( or or ' etc... So, basically, I'd suggesting copying the files over by hand with FTP or something and doing a 'diff' to be 100% sure you have the whole file. It's also remotely possible that something changed in 5.2... I never have understood why it was kosher to leave the final ? off, for example, so maybe that changed. :-) [I doubt it] At any rate, you have to confirm that the file *IS* complete first. After that, post the file if you can, or we've got nothing to say about it, really... -- Some people have a gift link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] problems with SOAP-PHP5 and heritage
if you want sombody using nabble.com having a look into the attached .php files, you should zip them before upload(i got them without any linefeeds). -- View this message in context: http://www.nabble.com/problems-with-SOAP-PHP5-and-heritage-tf2588326.html#a7223514 Sent from the PHP - General mailing list archive at Nabble.com. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] list of countries
On Tue, 2006-11-07 at 12:40 -0500, James Tu wrote: Does anyone have a list of countries in a handy format for importing into MySQL? I just really need a list. Wikipedia has a nice list, but it's muddled by HTML tags. Don't be lazy. And it's called marked up not muddled. Cheers, Rob. -- .. | InterJinn Application Framework - http://www.interjinn.com | :: | An application and templating framework for PHP. Boasting | | a powerful, scalable system for accessing system services | | such as forms, properties, sessions, and caches. InterJinn | | also provides an extremely flexible architecture for | | creating re-usable components quickly and easily. | `' -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] OpenLDAP
# [EMAIL PROTECTED] / 2006-11-07 15:57:17 +0100: Hi, where can i find OpenLDAPftp://ftp.openldap.org/pub/OpenLDAP/openldap-stable/files already compiled ? i've downloaded the tar file, but i do not have a compiler with me... :-*( Ignoring for a while that this is *utterly* off topic... There are free compilers for windows. Try MingW, or try to find the MSVC 7.1 Express installer: Microsoft gives (or gave) that away. -- How many Vietnam vets does it take to screw in a light bulb? You don't know, man. You don't KNOW. Cause you weren't THERE. http://bash.org/?255991 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] problems with SOAP-PHP5 and heritage
Jürgen Wind wrote: if you want sombody using nabble.com having a look into the attached .php files, you should zip them before upload(i got them without any linefeeds). but it may be a nabble.com bug, i filed a bugreport anyhow. -- View this message in context: http://www.nabble.com/problems-with-SOAP-PHP5-and-heritage-tf2588326.html#a7224125 Sent from the PHP - General mailing list archive at Nabble.com. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Spam using email on website
-Original Message- From: Pieter du Toit [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 07, 2006 1:43 AM To: php-general@lists.php.net Subject: [PHP] Spam using email on website Hi guys I have a website that is being crawled or whatever and i have a submission form for an event. I keep on getting random mail from this form. I have even disabled the submit button on the form, but keep on getting it. What can i do? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php You could put a security image on the page. http://www.devshed.com/c/a/PHP/Security-Images-in-PHP/ The security image sets a session variable that is not accessible by the client. The user must enter the code shown into a form field. When the form is submitted, the submit page checks that the security code entered matches the session variable. If not, no mail is sent and an optional error message is displayed. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] list of countries
On Tuesday 07 November 2006 19:58, Robert Cummings wrote: On Tue, 2006-11-07 at 12:40 -0500, James Tu wrote: Does anyone have a list of countries in a handy format for importing into MySQL? I just really need a list. Wikipedia has a nice list, but it's muddled by HTML tags. Goto: http://27.org/isocountrylist/ -Stathis Don't be lazy. And it's called marked up not muddled. Cheers, Rob. -- .. | InterJinn Application Framework - http://www.interjinn.com | | :: : | An application and templating framework for PHP. Boasting | | a powerful, scalable system for accessing system services | | such as forms, properties, sessions, and caches. InterJinn | | also provides an extremely flexible architecture for | | creating re-usable components quickly and easily. | `' -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Spam using email on website
-Original Message- From: Pieter du Toit [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 07, 2006 1:43 AM To: php-general@lists.php.net Subject: [PHP] Spam using email on website Hi guys I have a website that is being crawled or whatever and i have a submission form for an event. I keep on getting random mail from this form. I have even disabled the submit button on the form, but keep on getting it. What can i do? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php You could put a security image on the page. http://www.devshed.com/c/a/PHP/Security-Images-in-PHP/ The security image sets a session variable that is not accessible by the client. The user must enter the code shown into a form field. When the form is submitted, the submit page checks that the security code entered matches the session variable. If not, no mail is sent and an optional error message is displayed. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] list of countries
On Tue, November 7, 2006 11:40 am, James Tu wrote: Does anyone have a list of countries in a handy format for importing into MySQL? I just really need a list. Wikipedia has a nice list, but it's muddled by HTML tags. If you also have them in Chinese and Arabic that would be even better. If you Google for ISO Country Names Codes you'll find the standard list of countries and their 2-character codes. I suck that down every few months in a cron job and reset my country list in MySQL from it. I figure nobody can expect much better than that, given how seldom a country name changes or countries spring up out of nowhere or disappear. [tongue firmly planted in cheek, folks!] I'm sure somebody somewhere living in some country that does not make the ISO list will be mad at me someday, but I dunno what else I could do... I'm open to suggestions, however! And the Wikipedia list plus http://php.net/strip_tags might be better. -- Some people have a gift link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] 'View as HTML' Conversions
Google for pdf2html, doc2html, excel2html and see what comes up... On Tue, November 7, 2006 5:16 am, Kevin wrote: Hi, We are trying to create a script which (the same as google search and gmail) allows for PDF's, Doc's, Excel etc to be converted to HTML documents dynamically, this is just in case users want to view documents but don't have the necessary software. The HTML needs to keep as much of the styling as possible. Does anyone know how google have done this? or does anyone know any PHP equivalents, we are using the Windows IIS server. Thanks Kevin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Some people have a gift link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: list of countries
James Tu wrote: Does anyone have a list of countries in a handy format for importing into MySQL? I just really need a list. Wikipedia has a nice list, but it's muddled by HTML tags. If you also have them in Chinese and Arabic that would be even better. See attached. Dunno how old it is (a few years at least) but should get you started Col. -- MySQL dump 10.9 -- -- Host: localhostDatabase: amoza -- -- -- Server version 4.1.12 /*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */; /*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */; /*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */; /*!40101 SET NAMES utf8 */; /*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */; /*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */; /*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */; /*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */; -- -- Table structure for table `countries` -- DROP TABLE IF EXISTS `countries`; CREATE TABLE `countries` ( `id` int(10) unsigned NOT NULL auto_increment, `name` char(70) default NULL, `iso3166` char(2) default NULL, `dialcode` char(20) default NULL, PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1; -- -- Dumping data for table `countries` -- /*!4 ALTER TABLE `countries` DISABLE KEYS */; LOCK TABLES `countries` WRITE; INSERT INTO `countries` VALUES (1,'Afghanistan','AF','93'),(2,'Albania','AL','355'),(3,'Algeria','DZ','213'),(4,'American Samoa','AS','684'),(5,'Andorra','AD','376'),(6,'Angola','AO','244'),(7,'Anguilla','AI','1-264'),(8,'Antarctica','AQ','672'),(9,'Antigua And Barbuda','AG','1-268'),(10,'Argentina','AR','54'),(11,'Armenia','AM','374'),(12,'Aruba','AW','297'),(13,'Australia','AU','61'),(14,'Austria','AT','43'),(15,'Azerbaijan','AZ','994'),(16,'Bahamas','BS','1-242'),(17,'Bahrain','BH','973'),(18,'Bangladesh','BD',NULL),(19,'Barbados','BB',NULL),(20,'Belarus','BY',NULL),(21,'Belgium','BE','32'),(22,'Belize','BZ',NULL),(23,'Benin','BJ',NULL),(24,'Bermuda','BM',NULL),(25,'Bhutan','BT',NULL),(26,'Bolivia','BO',NULL),(27,'Bosnia And Herzegovina','BA',NULL),(28,'Botswana','BW',NULL),(29,'Bouvet Island','BV',NULL),(30,'Brazil','BR','55'),(31,'British Indian Ocean Territory','IO',NULL),(32,'Brunei Darussalam','BN',NULL),(33,'Bulgaria','BG',NULL),(34,'Burkina Faso','BF',NULL),(35,'Burundi','BI',NULL),(36,'Cambodia','KH',NULL),(37,'Cameroon','CM',NULL),(38,'Canada','CA',NULL),(39,'Cape Verde','CV',NULL),(40,'Cayman Islands','KY',NULL),(41,'Central African Republic','CF',NULL),(42,'Chad','TD',NULL),(43,'Chile','CL',NULL),(44,'China','CN',NULL),(45,'Christmas Island','CX',NULL),(46,'Cocos (Keeling) Islands','CC',NULL),(47,'Colombia','CO',NULL),(48,'Comoros','KM',NULL),(49,'Congo','CG',NULL),(50,'Congo, The Democratic Republic Of The','CD',NULL),(51,'Cook Islands','CK',NULL),(52,'Costa Rica','CR',NULL),(53,'Cote D\'ivoire','CI',NULL),(54,'Croatia','HR',NULL),(55,'Cuba','CU',NULL),(56,'Cyprus','CY',NULL),(57,'Czech Republic','CZ',NULL),(58,'Denmark','DK',NULL),(59,'Djibouti','DJ',NULL),(60,'Dominica','DM',NULL),(61,'Dominican Republic','DO',NULL),(62,'East Timor','TP',NULL),(63,'Ecuador','EC',NULL),(64,'Egypt','EG',NULL),(65,'El Salvador','SV',NULL),(66,'Equatorial Guinea','GQ',NULL),(67,'Eritrea','ER',NULL),(68,'Estonia','EE',NULL),(69,'Ethiopia','ET',NULL),(70,'Falkland Islands (malvinas)','FK',NULL),(71,'Faroe Islands','FO',NULL),(72,'Fiji','FJ',NULL),(73,'Finland','FI',NULL),(74,'France','FR','33'),(75,'French Guiana','GF',NULL),(76,'French Polynesia','PF',NULL),(77,'French Southern Territories','TF',NULL),(78,'Gabon','GA',NULL),(79,'Gambia','GM',NULL),(80,'Georgia','GE',NULL),(81,'Germany','DE','49'),(82,'Ghana','GH',NULL),(83,'Gibraltar','GI',NULL),(84,'Greece','GR',NULL),(85,'Greenland','GL',NULL),(86,'Grenada','GD',NULL),(87,'Guadeloupe','GP',NULL),(88,'Guam','GU',NULL),(89,'Guatemala','GT',NULL),(90,'Guinea','GN',NULL),(91,'Guinea-bissau','GW',NULL),(92,'Guyana','GY',NULL),(93,'Haiti','HT',NULL),(94,'Heard Island And Mcdonald Islands','HM',NULL),(95,'Holy See (Vatican City State)','VA',NULL),(96,'Honduras','HN',NULL),(97,'Hong Kong','HK',NULL),(98,'Hungary','HU',NULL),(99,'Iceland','IS',NULL),(100,'India','IN',NULL),(101,'Indonesia','ID',NULL),(102,'Iran, Islamic Republic Of','IR',NULL),(103,'Iraq','IQ',NULL),(104,'Ireland','IE',NULL),(105,'Israel','IL',NULL),(106,'Italy','IT','39'),(107,'Jamaica','JM',NULL),(108,'Japan','JP','81'),(109,'Jordan','JO',NULL),(110,'Kazakstan','KZ',NULL),(111,'Kenya','KE',NULL),(112,'Kiribati','KI',NULL),(113,'Korea, Democratic People\'s Republic Of','KP','82'),(114,'Korea, Republic Of','KR','850'),(115,'Kuwait','KW',NULL),(116,'Kyrgyzstan','KG',NULL),(117,'Lao People\'s Democratic Republic','LA',NULL),(118,'Latvia','LV',NULL),(119,'Lebanon','LB',NULL),(120,'Lesotho','LS',NULL),(121,'Liberia','LR',NULL),(122,'Libyan Arab
Re: [PHP] PHP and dynamic DHTML TREE (not menu) - suggestions
Edward Kay wrote: How about http://developer.yahoo.com/yui/treeview/ ? I made an ajaxy tree using this and other bits of YUI, using data from a mysql db that is then output as JSON data. getting it together was all rather painless, I can very much recommend using YUI's treeview. :-) I use the tree to display a explorer like view of all the 'pages' defined in a CMS' database and generate icons alongside each node for deleting, moving, editing, etc when the tree is rendered using the data retrieved via 'ajax' - each list of children is retrieved as/when a node is expanded. it is possible to define custom Node 'subclasses' (sub-prototypes?) [in javascript] that allow you completely customize the functionality/display/etc of each (type of) node. the Dojo toolkit will also do what you want but the learning curve is steeper. I've used both and while I like dojo for the insane ammount of functionality I prefer to use YUI for smaller solutions. (i.e. not full blown 'ajax/dhtml applications') rgds, I've been using Yahoo's UI components for a few weeks now and am seriously impressed by them. Edward Angelo Zanetti wrote: Hi All, We are looking for a solution for visually displaying parent and child nodes in a tree like component. It must work with PHP and mySQL as we are going to be populating the tree with dynamic data. We have found this: http://scbr.com/docs/products/dhtmlxTree/index.shtml but the demo of the PHP + mySQL things doesnt work. If anyone has any comments, experiences and advices please shoot away! Thanks in advance. Angelo -- Angelo Zanetti Systems developer *Telephone:* +27 (021) 469 1052 *Mobile:* +27 (0) 72 441 3355 *Fax:*+27 (0) 86 681 5885 * Web:* http://www.zlogic.co.za *E-Mail:* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] -- 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] Spam using email on website
On Tue, November 7, 2006 12:42 am, Pieter du Toit wrote: I have a website that is being crawled or whatever and i have a submission form for an event. I keep on getting random mail from this form. I have even disabled the submit button on the form, but keep on getting it. What can i do? Disable the mail() function bit in your code that processes the FORM submission. The Bad Guys are probably cramming your $subject and $from data with an ENTIRE eamil, so your mail() function is, in effect, and Open Relay. (That's very very very bad.) Example: Normal Input $subject = Hi!; Bad Guy Input $subject = Hi!\r\nCc: [EMAIL PROTECTED]@example.com; If you do: mail($to, $subject, $body); then you are letting THEM control the headers of your email, which lets them splice in 1000 recipients to their junk. Plus then can also splice in MIME headers and a new body to send virus-laden emails, and the $body you thought you were sending is just tacked on to the end of their body. Or not, if they splice in something to convince SMTP to end the email at the end of their body (which you've crammed into $subject in your mail() function call). -- Some people have a gift link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] list of countries
Thanks everyone for the helpful links and suggestions! Any people here with access to a country list in Arabic or Chinese? -James -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] postgreSQl and images
On Mon, November 6, 2006 5:17 pm, Børge Holen wrote: aaight... I get yer point there, BUT you see, what do you do when an artists changes it name... forget it, that was a bad choice... Oh no, it's a GREAT choice. First of all, if they really really changed their name, then I create a new record for them, and they have 2 Artist Profiles, so I can maintain historical accuracy. E.g., if Prince had played our venue every year, I'd want the shows in 1993-- to be 'Prince' and then from 1993 to 2000 to be 'tafkap' and then I'd be using the same pre-1993 record again from 2000 onwards. (Assuming his name does not change again.) I have done this many many many times for artist who marry, rename their bands, have side projects or perform solo as well as with their band, or suffer some other identity crisis. If you've worked with musicians, you would know that all of the above are not uncommon experiences. :-) If it's just a typo in an artist name, I just fix it. But the artist name is the ONE field we simply do not let the artist have access to. They'd end up destroying the historical accuracy of our web calendar listing their gigs back to 2003 (and earlier, if I ever get the owner to drag in his dead-tree bookings calendars so I can input them...) And since the ID3 tag comes from the DB in real-time, pre-pended to the mp3 stream with the static audio portion of the mp3 following, the actual output MP3 stream is corrected for the artist name as soon as I fix the typo. PHP ID3 rocks. :-) Actually, if you download the same MP3 file 2 successive times from my server, and if the artist has multiple images, you could trivially prove that I change the stream on the fly, as I choose the image at random. I think Rachel Sage has the most images in there, so that would be a good choice, if she has turned on downloads in her account. That's why only a tiny fraction of the 65000 mp3s are available. Artists have to login, choose the tracks and their usage parameters (streaming, download, radio, hifi, lofi, cafe speaker system) and they have to sign a release form. [aside] The release form is the worst possible non-contract I could manage to draft, on purpose, to avoid locking the artist into anything, while keeping the cafe lawyer happy -- Dang thing doesn't even have a DATE on it, much less read as an enforcable contract. So your version of the MP3 and mine will not match on our browser, wrt the ID3 meta-data being different images. The static audio portion will remain the same, of course. anyway... you see, in one of my fields of interests, you got dogs... see, dogs can change name, not just the calling name, but I mean completely change it all. second, they change apperance with growth. So to keep track on stuff you need to make a system work for you, not the other way around... Hence, all in the db... but no way someone would be * enought to put ... you know what.. In that case, I'd suggest a series of related records for each dog tied back to some unique ID. If there is an industry-standard ID for a dog that never changes throughout the course of its life, tie that into the central ID, or just make one up and convince users to tie their records together correctly through the business logic. I don't even attempt to map out which artists are really the same as which other artists, as the can of worms and social issues this would open up are legion. Prince/tafka looks a mere piker in this regard compared to some of the data I'd have to deal with... I'll pick a funny story of an artist, just as an example... Ken Vandermark was interviewed a couple years ago, after winning the McArthur Foundation genius grant (sic) and they got to talking about all the bands he was in. He's a free/improv jazz artist, plays mostly saxophone. Anyway, the interviewer asked him just how many bands he was in. Ken's answer was something not unlike this: I don't know. You'd have to track down all the bands I ever played in, and ask them [shrug]. If we played together every 2 or 3 years for awhile, but it's been 5 years now since we've been together, are we still a band? I dunno. I guess it just depends on whether we make plans to play together again or not. Call it about 500 bands, give or take. Now Ken's an extreme example, but these and similar issues turn out to be pretty non-trivial, once you start digging into it. NOone would EVER put a single mp3 file in a db ;) lol. There we agree. I don't know that nobody would ever put a single MP3 in a db. They might have a zillion teeny tiny MP3 files that they can more efficiently serve up from the DB, and have the research and stats to prove that it's better on their system. But if you have to ask the question about this matter, I'd say putting the data in your file-system is the Right Answer. :-) -- Some people have a gift link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I
RE: [PHP] list of countries
ummm... i must be missing something how is asking for the list lazy??? -Original Message- From: Robert Cummings [mailto:[EMAIL PROTECTED] Sent: Tuesday, November 07, 2006 9:59 AM To: James Tu Cc: PHP Subject: Re: [PHP] list of countries On Tue, 2006-11-07 at 12:40 -0500, James Tu wrote: Does anyone have a list of countries in a handy format for importing into MySQL? I just really need a list. Wikipedia has a nice list, but it's muddled by HTML tags. Don't be lazy. And it's called marked up not muddled. Cheers, Rob. -- .. | InterJinn Application Framework - http://www.interjinn.com | :: | An application and templating framework for PHP. Boasting | | a powerful, scalable system for accessing system services | | such as forms, properties, sessions, and caches. InterJinn | | also provides an extremely flexible architecture for | | creating re-usable components quickly and easily. | `' -- 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] list of countries
On Tue, 2006-11-07 at 12:12 -0800, bruce wrote: ummm... i must be missing something You're missing a capitalized 'i' at the beginning of your sentence :/ how is asking for the list lazy??? Because he saw a list, and then decided not to use it because it was muddled by HTML tags. That part is being lazy. At any rate, he asked for something unrelated to PHP. I'm sorry but PHP General isn't a data warehouse. Thank you for your concern, Rob. -- .. | InterJinn Application Framework - http://www.interjinn.com | :: | An application and templating framework for PHP. Boasting | | a powerful, scalable system for accessing system services | | such as forms, properties, sessions, and caches. InterJinn | | also provides an extremely flexible architecture for | | creating re-usable components quickly and easily. | `' -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PHP Consultant / Contractor
Hi all, I apologize in advance for a commercially orientated posting in this discussion list - I did not see a business focused list to use instead. I am looking for a good reliable PHP developer that can help with some one off projects that I have (10-20 hours a month perhaps) - geographic location is not a concern (aka I am open to persons outside of the US), the requirement of reliable communication and timely delivery is absolute. If you are interested in something like this please email me off list with your Resume/CV, any sample projects that would be good to look at, and of course your contact information. Thanks, Max max [at] clarksys [dot] com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Parse Errors with 5.2 on Linux
Richard Lynch wrote: I never have understood why it was kosher to leave the final ? off, for example, so maybe that changed. :-) [I doubt it] Certainly hasn't changed, and I hope it never does. Having to find an errant space or carriage return at the end of an include file that is one of nearly 100 that get included in a script has taught me that there is no greater feature in PHP!! I never use a closing ? if PHP script is the last thing in a file - less headaches all around. -Stut -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Parse Errors with 5.2 on Linux
On Tue, 2006-11-07 at 21:18 +, Stut wrote: Richard Lynch wrote: I never have understood why it was kosher to leave the final ? off, for example, so maybe that changed. :-) [I doubt it] Certainly hasn't changed, and I hope it never does. Having to find an errant space or carriage return at the end of an include file that is one of nearly 100 that get included in a script has taught me that there is no greater feature in PHP!! I never use a closing ? if PHP script is the last thing in a file - less headaches all around. Hear, hear! And the word from internals a few years ago was that it was an intended feature for exactly that reason. Cheers, Rob. -- .. | InterJinn Application Framework - http://www.interjinn.com | :: | An application and templating framework for PHP. Boasting | | a powerful, scalable system for accessing system services | | such as forms, properties, sessions, and caches. InterJinn | | also provides an extremely flexible architecture for | | creating re-usable components quickly and easily. | `' -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] list of countries
A MySQL list would have been a better place for this. Then again Most people on the MySQL list would have known about http://dev.mysql.com/doc/world-setup/en/world-setup.html where as people on this are less likely to. On 11/7/06, James Tu [EMAIL PROTECTED] wrote: Does anyone have a list of countries in a handy format for importing into MySQL? I just really need a list. Wikipedia has a nice list, but it's muddled by HTML tags. If you also have them in Chinese and Arabic that would be even better. -James -- 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] Spam using email on website
Yikes, so besides disabling the mail() function, how do you check for all that? Regards, Bruce Richard Lynch [EMAIL PROTECTED] 8/11/2006 8:14 a.m. On Tue, November 7, 2006 12:42 am, Pieter du Toit wrote: I have a website that is being crawled or whatever and i have a submission form for an event. I keep on getting random mail from this form. I have even disabled the submit button on the form, but keep on getting it. What can i do? Disable the mail() function bit in your code that processes the FORM submission. The Bad Guys are probably cramming your $subject and $from data with an ENTIRE eamil, so your mail() function is, in effect, and Open Relay. (That's very very very bad.) Example: Normal Input $subject = Hi!; Bad Guy Input $subject = Hi!\r\nCc: [EMAIL PROTECTED]@example.com; If you do: mail($to, $subject, $body); then you are letting THEM control the headers of your email, which lets them splice in 1000 recipients to their junk. Plus then can also splice in MIME headers and a new body to send virus-laden emails, and the $body you thought you were sending is just tacked on to the end of their body. Or not, if they splice in something to convince SMTP to end the email at the end of their body (which you've crammed into $subject in your mail() function call). -- Some people have a gift link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So? -- 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] list of countries
Sorry, maybe I should have posted on that list. My post was about the list rather than about using MySQL. My initial thought was that country lists would have been something that people in this forum would have encountered and was also hoping that some people here would have multi-language experience for country lists in other languages. Thanks to all that have pointed me in the right direction. -James On Nov 7, 2006, at 4:41 PM, Rory Browne wrote: A MySQL list would have been a better place for this. Then again Most people on the MySQL list would have known about http://dev.mysql.com/doc/world-setup/en/world-setup.html where as people on this are less likely to. On 11/7/06, James Tu [EMAIL PROTECTED] wrote: Does anyone have a list of countries in a handy format for importing into MySQL? I just really need a list. Wikipedia has a nice list, but it's muddled by HTML tags. If you also have them in Chinese and Arabic that would be even better. -James -- 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] pass value to next page
Hi , Newbie question, I have a form, form acttion=search.php3 method=post input . input... ... /form The search.php3 goes to query mysql database to see if the infomation is new or existed, if new, will promt two radio buttons ( Yes or No) to confirm if you like to enter the info inot DB .The form will action=result.php My question is how we can passwd the values which are entered in first page to result.php page. Thank you for your help
Re: [PHP] pass value to next page
Hi, In search.php3, you'd need to save the values into inputs of type hidden. You can then query them in result.php as per usual. I hope that helps. Regards, Bruce Wang Chen [EMAIL PROTECTED] 8/11/2006 11:57 a.m. Hi , Newbie question, I have a form, form acttion=search.php3 method=post input . input... ... /form The search.php3 goes to query mysql database to see if the infomation is new or existed, if new, will promt two radio buttons ( Yes or No) to confirm if you like to enter the info inot DB .The form will action=result.php My question is how we can passwd the values which are entered in first page to result.php page. Thank you for your help -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] pass value to next page
you could also do this all on one page... with different if statments to direct which part of the process your actually in. if (processone) { blah... blah... } if (processtwo) { blah... blah... } this is how all of my pages work, to an extent, and it make things much easier not having to pass variables from page to page. hope it helps. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Sorting MySQL queries
On 07/11/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: you really need to deal with this issue at the database design/data entry level. doing things on the sort to exclude (otherwise undefined) initial articles (as some have suggested) is very maintenance heavy as you have to update the sort portion for every language your data are entered in. additionally, an initial word that's an initial article in one language may not be in another. at the database design/data entry level the common approaches include: - a separate field for initial articles - separate sort and print fields - an initial article offset indicator that is used for sorting the first of these is probably the easiest and most portable. the last is easy, but probably the least portable. i consider the separate print/sort fields to be the least desirable since it's a lot of redundant data that has to be managed and maintained. in my experience, if you encounter a setup that doesn't support the proper handling of initial articles it's best to fix things at the database/data entry level as soon as possible -- otherwise the resolution just gets more expensive (however you define that). Although I wouldn't have known to define it as such, I also don't like the idea of redundant data littering the DB. But it does seems to be the easiest method to implement as far as coding, and the fastest way to retrieve the data. Dotan Cohen http://what-is-what.com/what_is/xml.html http://essentialinux.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] pass value to next page
Wang Chen wrote: Hi , Newbie question, I have a form, form acttion=search.php3 method=post input . input... ... /form The search.php3 goes to query mysql database to see if the infomation is .php3 extension is, I would say, discouraged. just use .php new or existed, if new, will promt two radio buttons ( Yes or No) to confirm if you like to enter the info inot DB .The form will action=result.php 2 options: 1. php solution, put the data in $_SESSION and retrieve it again when you have the 'insert' confirmation - (search the manual for session usage) 2. html solution, in the second form put the inputs from the first form, set all their type attributes to hidden and set the value accodingly: input type=hidden value=?php echo $data['foo']; ? name=foo / My question is how we can passwd the values which are entered in first page looks like you mean pass not passwd :-) to result.php page. Thank you for your help -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] pass value to next page
Thanks much, y'all. Forgive to my typo on the original email. On 11/7/06, Jochem Maas [EMAIL PROTECTED] wrote: Wang Chen wrote: Hi , Newbie question, I have a form, form acttion=search.php3 method=post input . input... ... /form The search.php3 goes to query mysql database to see if the infomation is .php3 extension is, I would say, discouraged. just use .php new or existed, if new, will promt two radio buttons ( Yes or No) to confirm if you like to enter the info inot DB .The form will action=result.php 2 options: 1. php solution, put the data in $_SESSION and retrieve it again when you have the 'insert' confirmation - (search the manual for session usage) 2. html solution, in the second form put the inputs from the first form, set all their type attributes to hidden and set the value accodingly: input type=hidden value=?php echo $data['foo']; ? name=foo / My question is how we can passwd the values which are entered in first page looks like you mean pass not passwd :-) to result.php page. Thank you for your help
[PHP] Nested includes - Relative paths?
Hi All, I'm relatively new to PHP but I've had some training and feel quite confortable programming it... Anyway, I'm having a problem in understanding the correct behaviour of the include statement/function. Imagine that I have an INDEX.PHP file in my root directory and I want to include the file INCLUDE\SESSION.PHP. I would use the statement: ?php include 'include/session.php'; ? What if, inside the file INCLUDE\SESSION.PHP I want to include the file INCLUDE\DATABASE.PHP? Should I use the statement: ?php include 'database.php'; ? because DATABASE.PHP and SESSION.PHP are in the same directory or should I use the statement: ?php include 'include/database.php'; ? because INCLUDE\SESSION.PHP is going to be included in INDEX.PHP witch is NOT in the same directory of DATABASE.PHP? In other words... When PHP processes an include statement does it include the file where the include statement is and then process its contents (eventualy including other files) or does PHP processes the file to be included and only includes it after that? Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Time-Zone juggling
I have a PostgreSQL database chockful of datatype: time without time zone The times I chucked in there are, like, '7:00 PM' and they all seem fine... Until I start trying to generate an RFC 882 datetime stamp. :-( At that point, the fact that the server lives in Portland OR, and my times are all based in Chicago means that my output is: Mon, 03 Apr 2006 17:00:00 PDT even though the actual date/time in question is REALLY at 20:00 in Chicago. I'm just doing the naive: select whatdate, whattime from ... list($y, $m, $d) = explode('-', $whatdate); list($h, $i, $s) = explode(':', $whattime); $datetime_882 = date(DATE_RFC882, mktime($h, $i, $s, $m, $d, $y)); This is PHP4, and I've done an if(!defined()) define() to get the DATE_RFC882 constant. What is the least-stupid way to fix this, and get 20:00 in the Portland OR server to turn into: Mon, 03 Apr 2006 20:00:00 CDT which is what time it really was. E. Without changing the schema which means having to re-do everything else in the application. That's probably the RIGHT way to fix it, but that ain't happening. I've been dinking with gmmktime() and reading about setlocale() but none of them seem to be the Right Answer. I got a couple stupid ways I think I could fix it, and I'd rather not do those, cuz they're stupid. :-) E.g., str_replace(array('PDT', 'PST'), array('CDT', 'CST'), $datetime); This time zone stuff always gets me head all spun around, I admit freely. -- Some people have a gift link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Time-Zone juggling
Richard Lynch wrote: What is the least-stupid way to fix this, and get 20:00 in the Portland OR server to turn into: Mon, 03 Apr 2006 20:00:00 CDT which is what time it really was. E. Without changing the schema which means having to re-do everything else in the application. That's probably the RIGHT way to fix it, but that ain't happening. Yeah... I ran into the same stuff a few weeks ago with the DST change. The quickest solution that is *almost* OK is using putenv(tz=america/montreal) or putenv(tz=america/san_diego) etc.. (should really be the date_default_timezone_get/set functions) Datetime fields do not have timezone stored (mysql too.) The only real solution to this problem is to always store datetimes in GMT/UTC. That is the correct thing to do, and until that is done our workaround still has one problem (that isn't big enough to warrant reworking the ticketing code that inserts to the db...) The remaining problem is that until we store in UTC we will never know which 01:30:00 a timestamp refers to, EDT or EST (Eastern Daylight, or Eastern Standard.) In UTC this doesn't happen. Of course there is no problem for spring, only in the fall time change. This can be a big problem to some apps, and others might be fine with the workaround like we've done where you loose a tiny bit of data (It's 08:00 on the day after the timechange, is this ticket from 01:30:00 6.5 or 7.5 hours old? who cares.. just reply.) Travis Doherty -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] OpenLDAP
Hi, I want to authenticate user by checking with our LDAP their login and password. For that, i need before to : 1- download LDAP client librairies OpenLDAP or Bind9 2- compile those librairies 3- Compile PHP with option == --with-ldap 4- Setup php.ini by removing semi-colon in front of == extension=php_ldap.dll 5- copy libeay32.dll and ssleay32.dll to my SYSTEM folder C:\windows\system32 Did i miss something ? Moreover, an regarding point 2 : which librairies concretly should i compile ? Because OpenLDAP tar has several folders and files. thanks a lot, Alain
Re: [PHP] Nested includes - Relative paths?
On Tuesday 07 November 2006 21:50, Nuno Vaz Oliveira wrote: because INCLUDE\SESSION.PHP is going to be included in INDEX.PHP witch is NOT in the same directory of DATABASE.PHP? In other words... When PHP processes an include statement does it include the file where the include statement is and then process its contents (eventualy including other files) or does PHP processes the file to be included and only includes it after that? When PHP hits an include() (or require(), or include_once(), etc.), it copies the contents of the included file into the running context and executes it. That process is recursive. All include statements are parsed based on the defined include path, where . is interpreted relative to the active context, vis, the script that the web server itself is running. That means that if the include path contains ., and apache executes a.php, and a.php includes foo/b.php, and b.php includes c.php, then c.php is looked up on the file system as ./c.php, relative to a.php, since that's what apache is actually running. Got that? :-) -- Larry Garfield AIM: LOLG42 [EMAIL PROTECTED] ICQ: 6817012 If nature has made any one thing less susceptible than all others of exclusive property, it is the action of the thinking power called an idea, which an individual may exclusively possess as long as he keeps it to himself; but the moment it is divulged, it forces itself into the possession of every one, and the receiver cannot dispossess himself of it. -- Thomas Jefferson -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php