Re: [PHP] Exception handling in PHP

2008-02-07 Thread Paul Scott
On Wed, 2008-02-06 at 23:37 -0800, Prabath Kumarasinghe wrote: Does that mean for every exception do we have to write our custom exception and describe it from our own message No, it means that when you want to throw a meaningful exception, you need to type in a message. I mentioned custom

Re: [PHP] Exception handling in PHP

2008-02-07 Thread Paul Scott
On Thu, 2008-02-07 at 00:20 -0800, Prabath Kumarasinghe wrote: Understood, Thanks Paul Pleasure, but please don't top post, it makes it really hard to follow a thread easily. Most people on this list take time out from their really busy day jobs to help out, and the more time that everyone

Re: [PHP] Re: Multiple MySQL INSERT into loop

2008-02-07 Thread Paul Scott
On Thu, 2008-02-07 at 10:55 +, Colin Guthrie wrote: Simplest way would be to define your data in an array instead: e.g. $data = array(1 = array('id' = x, 'entry' = y, 'name' = z), ...). And of course to tie it all into a transaction that can be rolled back in case of problems. --Paul

Re: [PHP] Directory

2008-02-07 Thread Paul Scott
On Thu, 2008-02-07 at 12:30 -0600, Steve Marquez wrote: Could someone please point me in the right direction? I am trying to have PHP find out if a directory has files in it and then if it does, display and include, if it does not, then not display the include. oooh, goodie! You get to play

RE: [PHP] Re: Profiling with register_tick_function / declare

2008-02-07 Thread McNaught, Scott
no difference. The problem is to do with the scope that the declare directive affects. Cheers anyway, Scott -Original Message- From: Shawn McKenzie [mailto:[EMAIL PROTECTED] Sent: Friday, February 08, 2008 5:43 AM To: php-general@lists.php.net Subject: [PHP] Re: Profiling

[PHP] Profiling with register_tick_function / declare

2008-02-07 Thread McNaught, Scott
); /** * Profiler * * @version SVN: $Id$ * @author Scott McNaught */ class Profiler { protected $m_arrProfileData = array(); protected $m_strCurrentFunction = null; protected $m_iLastTime = null; /** * Begins profiling */ public function start

RE: [PHP] Re: Profiling with register_tick_function / declare

2008-02-07 Thread McNaught, Scott
. They aren't invoked on ticks. I don't think these ticks can be relied upon - a neat idea but they don't seem to be implemented right yet. Scott -Original Message- From: Shawn McKenzie [mailto:[EMAIL PROTECTED] Sent: Friday, February 08, 2008 6:34 AM To: php-general@lists.php.net Subject

Re: [PHP] killing a process through php webservice

2008-02-07 Thread Paul Scott
On Fri, 2008-02-08 at 09:56 +0500, Fahad javed wrote: I still think the problem is access rights. question is how to solve it. Any help will be greatly appreciated. Yes it is access rights. You will probably have to add PHP to the root or wheel group as a user or something insane like

Re: [PHP] Recommendation for an XML class?

2008-02-06 Thread Paul Scott
On Wed, 2008-02-06 at 15:12 -0500, Nathan Nobbe wrote: SimpleXML, http://www.php.net/manual/en/ref.simplexml.php Dude, I thought you were playing with SPL! SimpleXML _then_ use the SimpleXMLIterator to work with it! http://www.php.net/spl --Paul All Email originating from UWC is covered

Re: [PHP] array problem with a zencart shipping module

2008-02-06 Thread Paul Scott
On Wed, 2008-02-06 at 23:42 -0500, Nathan Nobbe wrote: ouch, maybe you need to hire someone ? besides this has more to do than just arrays; there is the rest of the application and clearly anyone whos going to help out must understand at least some of it.. Yeah, I concur! You really should

Re: [PHP] Exception handling in PHP

2008-02-06 Thread Paul Scott
On Wed, 2008-02-06 at 22:52 -0800, Prabath Kumarasinghe wrote: Hi All I'm little bit confusing with PHP exception handling. Could you able to explain how to put try{} and catch(){} in a proper way in PHP. I had already read php exception manual but it didn't help me to get exact idea

Re: [PHP] Exception handling in PHP

2008-02-06 Thread Paul Scott
On Wed, 2008-02-06 at 23:10 -0800, Prabath Kumarasinghe wrote: Is this following code work in PHP if mysql_connect fails. try{ mysql_connect('localhost','user',''); }catch(Exception $e){ echo $e-getMessage(); Probably not. I don't think that the mysql functions throw exceptions on

Re: [PHP] Anyone else doing PHP on Symbian?

2008-02-05 Thread Paul Scott
On Tue, 2008-02-05 at 14:44 +, George Pitcher wrote: I've recently installed PAMP (PHP, Apache, MySQL Python) on my Nokia N95. I can do my development in Dreamweaver and move across to the phone and it all works. Sounds intruiging! Care to share some resources/links as to how to set

Re: [PHP] how dod you get to do multiple mysql queries concurrently?

2008-02-05 Thread Paul Scott
On Tue, 2008-02-05 at 11:53 -0600, Richard Lynch wrote: This is actually pretty OT for the PHP list itself, really, unless you want to try to implement GIS in PHP, which would be a particularly Bad Idea (tm) due to the scale, scope, and calculations involved. Err, sorry, but I must correct

Re: [PHP] how dod you get to do multiple mysql queries concurrently?

2008-02-05 Thread Paul Scott
On Mon, 2008-02-04 at 01:08 +0100, Jochem Maas wrote: the column spec. what kind of geomtery column is it? and A geographical geometry i.e. a projected data set of Geo data. are you using it as a primary key? or some else No, the integer gid is usually a primary key still. The geo data is

Re: [PHP] Anyone else doing PHP on Symbian?

2008-02-05 Thread Paul Scott
On Tue, 2008-02-05 at 13:29 -0500, Daniel Brown wrote: Still debating what device I'll get next, but I want to use it as a mobile server myself. I had been working on a bound-for-trash PDA doing the same a while back, but with what we'll refer to as limited results. I think that the key

Re: [PHP] Fileinfo

2008-02-05 Thread Paul Scott
On Tue, 2008-02-05 at 22:49 -0800, Mad Unix wrote: I did what you recommended i get the same erorr Depending on your distro, you may have 2 php.ini files. On debian based systems there certainly are. One for Apache to use and another for cli. Check that this is not the case first, you may

Re: [PHP] Fileinfo

2008-02-05 Thread Paul Scott
On Tue, 2008-02-05 at 23:13 -0800, Mad Unix wrote: thanks it works now Libraries have been installed in: /usr/local/src/Fileinfo-1.0.3/modules Be sure to remember to add the extension to your php.ini now as well with an extension= line and restart your server for the changes to

Re: [PHP] Schedule tasks from server

2008-02-04 Thread Paul Scott
On Mon, 2008-02-04 at 16:30 +0200, Pieter du Toit wrote: Is there a way that i can schedule tasks on my webserver that will automatically fire on a certain time and date, without anyone visiting the website? This domain is hosted by a ISP and not by me. Ask your ISP if they support cron

Re: [PHP] Schedule tasks from server

2008-02-04 Thread Paul Scott
On Mon, 2008-02-04 at 16:46 +0200, Pieter du Toit wrote: I am using paradigmsolutions.co.za. I read about cronjobs, but aparently it is only available on unix or linux hosting, is this true? Well, why not just host on *nix then? I see your site is a MS Frontpage one, but most linux based

Re: [PHP] php competion

2008-02-03 Thread Paul Scott
On Sun, 2008-02-03 at 20:10 +1100, doc wrote: come on people try you skills at http://www.rhwebhosting.com/comp/index.php Reworded as: Redesign our complete web presence and give us a couple of apps that we can flog to our clients, and we *may* give you a consolation prize. Yeah right.

Re: [PHP] Resetting a session variable

2008-02-03 Thread Paul Scott
On Sun, 2008-02-03 at 13:14 -0500, Ron Piggott wrote: What is the command to reset a session variable --- essentially deleting all of the values it contains? Ron Assign the session to an empty array() and then use session_destroy() All Email originating from UWC is covered by disclaimer

Re: [PHP] about preg_replace, please help !

2008-02-03 Thread Paul Scott
On Sun, 2008-02-03 at 21:06 -0800, Casey wrote: Why do you need preg_replace? Else he fails a homework assignment? --Paul -- . | Chisimba PHP5 Framework - http://avoir.uwc.ac.za |

Re: [PHP] how dod you get to do multiple mysql queries concurrently?

2008-02-01 Thread Paul Scott
Did anyone actually get this mail? More concrete example? What would you like to see? I suspect that some of my mail is getting dropped :( --Paul On Fri, 2008-02-01 at 06:33 +0200, Paul Scott wrote: On Fri, 2008-02-01 at 03:40 +0100, Jochem Maas wrote: I for one would really like to see

Re: [PHP] Re: [Slightly OT] Apple MacBook MAMP and Logic

2008-02-01 Thread Paul Scott
On Fri, 2008-02-01 at 10:58 +, Colin Guthrie wrote: That's just how sudo works tho' right? You can configure sudo to not require a password for certain commands run by certain users. Not sure how it works on the mac as there may be some kind of wrapper but I'm sure there would be a way to

Re: [PHP] array iteration vs. ArrayIterator

2008-02-01 Thread Paul Scott
On Fri, 2008-02-01 at 11:11 -0600, Greg Donald wrote: Thanks for the benchmark. Yes, thanks! It has just confirmed what I have been experiencing as well. I am busy converting a static site to a Chisimba CMS based site at the moment with 43 000 odd static, frontpage generated HTML pages. I

Re: [PHP] Calling All Opinionated ******** ....

2008-02-01 Thread Paul Scott
On Fri, 2008-02-01 at 22:18 +0100, Jochem Maas wrote: I'd like to hear from people who have or are using ZF with regard to their experiences, dislikes, likes, problems, new found fame and fortune, etc ... but only if it concerns ZF. I have integrated a few ZF components into the Chisimba

Re: [PHP] how dod you get to do multiple mysql queries concurrently?

2008-01-31 Thread Paul Scott
On Fri, 2008-02-01 at 03:40 +0100, Jochem Maas wrote: I for one would really like to see a concrete example of this kind of use of geometry columns and spacial indexes as an alternative to the stand integer based primary keys. On one of my local postGIS tables: CREATE INDEX k1 ON

[PHP] Release candidate: Chisimba-2.0.0RC1

2008-01-31 Thread Paul Scott
The next major release of the Chisimba PHP5 framework is now available. Major enhancements included in this release are: - Remote downloads of modules through web interface - Upgrades of modules via package server in modulecatalogue - Skin downloads via remote package server - Updates to

Re: [PHP] how to display photos of the day?

2008-01-29 Thread Paul Scott
On Tue, 2008-01-29 at 18:33 +0800, jeffry s wrote: i have a mysql table contain data about 1000 rows. i want to display any of the photos randomly and it is fixed for one day. MySQL has a rand() function, so you could bomb that off as a select once a day on cron or something, or you could

Re: [PHP] How can I do this -- method chaining

2008-01-29 Thread Paul Scott
On Tue, 2008-01-29 at 14:17 -0500, Eric Butera wrote: http://www.travisswicegood.com/index.php/2007/10/26/fluent_api_here_i_come Looks like a repurpose of one of my posts: http://fsiu.uwc.ac.za/index.php?module=blogaction=viewsinglepostid=gen9Srv59Nme5_7092_1182404204 --Paul All Email

Re: [PHP] Getting nuequiz pro wo to work in php5

2008-01-28 Thread Paul Scott
On Mon, 2008-01-28 at 11:49 -0500, Nathan Nobbe wrote: ive always thought about trying moodle for this purpose. Not to rag Moodle or anything, but trying to customize that thing is a nightmare. Besides, if you are willing to try out Chisimba, you can always ask me :) There is a test install at

Re: [PHP] Posting Summary for Week Ending 25 January, 2008: php-general@lists.php.net

2008-01-28 Thread Paul Scott
On Mon, 2008-01-28 at 16:43 +0100, Zoltán Németh wrote: where is the stats for last week? the experiment is over or what? ;) Jochem already did it for this week, so I think Dan is taking the week off. --Paul All Email originating from UWC is covered by disclaimer

Re: [PHP] how dod you get to do multiple mysql queries concurrently?

2008-01-28 Thread Paul Scott
On Mon, 2008-01-28 at 12:29 -0600, Richard Lynch wrote: Back on the mysql side of things, try using geometry columns rather than numerical primary keys, with spatial indexes.. it's a MASSIVE performance upgrade (I've cut 5 second queries down to 0.005 by using geo columns) Uh, could you

Re: [PHP] Getting nuequiz pro wo to work in php5

2008-01-28 Thread Paul Scott
On Mon, 2008-01-28 at 08:35 -0800, Jim Lucas wrote: Well, since this quiz app doesn't work. Does anybody have suggestions on a good tool to use for in-house/office training? Sort of like an employee initial training or evaluation quiz application. Guess it doesn't have to be just for

Re: [PHP] Getting part of string matched with regular expressions

2008-01-27 Thread Paul Scott
On Mon, 2008-01-28 at 14:28 +0900, Teck wrote: I was using preg_replace for this, and try to delete (i.e., replace the non-matched part with an empty string) the second part, but I can't make it work. Rather use preg_match_all() as that will produce an array of values, with the first

Re: [PHP] Posting Summary for Week Ending 25 January, 2008: php-general@lists.php.net

2008-01-23 Thread Paul Scott
On Thu, 2008-01-24 at 01:13 +0100, Jochem Maas wrote: stats while I'm at it ... I've been busy wracking my brain trying to figure out the setup for a load-balanced configuration for one of my major clients ... at least a system capable of migrating to loadbalancing ... global file system,

Re: [PHP] performance/load testing ...

2008-01-21 Thread Paul Scott
On Mon, 2008-01-21 at 10:50 +0100, Jochem Maas wrote: Does anyone have any tips, urls, advice as to how to start going about creating something like a 'test suite' for testing high load performance of a website? I went through a similar headache recently, and looked at a whole whack of

Re: [PHP] Re: Posting Summary for Week Ending 18 January, 2008: php-general@lists.php.net

2008-01-20 Thread Paul Scott
On Sun, 2008-01-20 at 10:04 -0500, Daniel Brown wrote: That would actually be pretty interesting. Since we've all been known to beat a thread to death, it certainly wouldn't be difficult to collect the data. FWIW, I would like to continue to see these postings, as mailing list metrics

Re: [PHP] Digital Downloads and Scale

2008-01-20 Thread Paul Scott
On Mon, 2008-01-21 at 02:43 +0100, Jochem Maas wrote: use simple code, optimize your db and go and read up on everything you can find about optimizing [download] connections on your webserver ... these spring to mind In addition to optimizing code and db (I presume that includes using

Re: [PHP] Re: Match anything between two that is not a except if it is escaped...

2008-01-18 Thread Paul Scott
On Fri, 2008-01-18 at 12:28 +0200, Nikolay Ananiev wrote: This is for double quotes: '/[^]*(?:.[^]*)*/' this is for single: '/\'[^\']*(?:.[^\']*)*\'/' i took these from the smarty compiler class. Has anyone started a commonly used PCRE Regexp library? It could be

Re: [PHP] XAdES in PHP

2008-01-14 Thread Paul Scott
On Mon, 2008-01-14 at 10:59 -0600, Richard Lynch wrote: After a quick Google to find out what the Hades is XAdES, I'd suggest you look for a C implementation and link it in as an extension. There are a couple of implementations of XMLDSIG in PHP that I have seen, although none really up to

Re: [PHP] Posting Summary for Week Ending 11 January, 2008: php-general@lists.php.net

2008-01-12 Thread Scott Wilcox
well thats just no good is it :P Thats pretty funky, congrats on the concept and implementation :) Daniel Brown wrote: On Jan 11, 2008 4:11 PM, Jason Pruim [EMAIL PROTECTED] wrote: Hate to shot a hole in your script Dan... But my posts aren't listed :P and I had a few on Jan 8 :) Where

Re: [PHP] SMTP vs mail()

2008-01-12 Thread Scott Wilcox
Per Jessen wrote: Richard Heyes wrote: Bearing in mind I haven't yet done any benchmarks, which do you think is faster - SMTP with multiple RCPT commands or the PHP mail() function (with it launching a separate sendmail process for each mail() function call)? I've done some rough

[PHP] PHP Jpeg Uploads Corrupting

2008-01-09 Thread Scott Wilcox
?type=full Any help would be appreciated greatly, I just can't seem to figure this one out. Scott. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] PHP Jpeg Uploads Corrupting

2008-01-09 Thread Scott Wilcox
Jim Lucas wrote: Scott Wilcox wrote: Greetings folks, I'm having a few issues with PHP this evening. I'm uploading various jpg images, doing a resize via GD, and then storing the image in a database. Usually this works fine, but for some unknown reason I'm getting corrupted uploads

Re: [PHP] PHP Jpeg Uploads Corrupting

2008-01-09 Thread Scott Wilcox
Ah, ignore. Problem seems to be solved. Some piping seems to have caused corrupting. All working now. Thanks anyway folks! :) Scott Wilcox wrote: Jim Lucas wrote: Scott Wilcox wrote: Greetings folks, I'm having a few issues with PHP this evening. I'm uploading various jpg images, doing

Re: [PHP] First stupid post of the year.

2008-01-02 Thread Scott Wilcox
Add it inline, and it'll override everything else. input type=submit style=width: 200px; name=bob / tedd wrote: At 1:46 PM -0500 1/2/08, Nathan Nobbe wrote: On Jan 2, 2008 1:34 PM, tedd mailto:[EMAIL PROTECTED][EMAIL PROTECTED] wrote: nbsp; nbsp; nbsp; nbsp;Anbsp; nbsp; nbsp; nbsp; (it's

[PHP] Using PHP to remove certain number of bytes from file

2007-12-30 Thread Scott Wilcox
Is it possible with PHP to remove a certain number of bytes from a file, purely within PHP? If so, does someone have an example of doing this, removing the first 230 bytes from a file. Thanks, Scott. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http

[PHP] Chisimba Release

2007-12-20 Thread Paul Scott
The next release of the Chisimba PHP5 framework is now available. Major enhancements included in this release are: - Better APC support - Improved database performance - Bug fixes - Better code documentation - XML-RPC API for Video conversions module - XML-RPC API for the Active Dynamic

Re: [PHP] Profiling PHP App

2007-12-19 Thread Paul Scott
On Thu, 2007-12-20 at 11:21 +0700, php mail wrote: Is there any tool to profiling PHP app ? Yes, there are a few. The best that I have found anyway, is Xdebug 2 (http://pecl.php.net/xdebug). It can also integrate nicely with PHPUnit as well to do code coverage as well as make your life

Re: [PHP] Professional inquiry for you freelancers

2007-12-05 Thread Paul Scott
On Wed, 2007-12-05 at 23:33 -0500, Steve Finkelstein wrote: Basically what I'm asking is, am I going to be end up being a jack of all trades, master of none, if I continue pursuing design AND development? Is there plenty of work out there for folks who just stick to development? It all

Re: [PHP] Software Help

2007-12-03 Thread Paul Scott
On Mon, 2007-12-03 at 14:55 -0500, Mike Roberts wrote: My name is Mike Roberts, and I am a recruiter with Corporate Staffing Services in Bala Cynwyd, Pennsylvania. I need help finding qualified candidates who have experience with PHP ( whole lamp environment). Out of respect, I am not

Re: [PHP] Structured Code vs. Performance

2007-11-29 Thread Paul Scott
On Thu, 2007-11-29 at 13:51 +0100, Jochem Maas wrote: okay, but I was just paraphrasing the man Rasmus, although I admit I may have misinterpreted (or misundersstood the 'why') - thought I pretty sure he has written on a number of occasions that code like the following sucks for op-code

Re: [PHP] PHP RFC # 0001 --- List Etiquette [SOLVED]

2007-11-28 Thread Paul Scott
On Thu, 2007-11-29 at 09:24 +0800, Crayon Shin Chan wrote: This has been the expected behavior (adding [SOLVED]) for a long time though it does not occur as often as it should. It has been in the NEWBIE GUIDE for a long time and has been a de-facto standard on IT or computer related

[PHP] PHP + Amazon to retrieve book data

2007-11-21 Thread Scott Wilcox
Hey folks, Does anyone have any resources or links to resources concerning obtaining book data via Amazons web services? Any help/pointers appreciated. Scott. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Cannot send a hyperlink (resent)

2007-11-16 Thread Scott Wilcox
. I'd personally not use that header. That is of course just my two cents though! Scott. tedd wrote: At 7:29 PM +0100 11/15/07, Per Jessen wrote: Brad wrote: Why is php refusing to parse as html? Here your code cut down to what you need: $headers = From: \.$fromname.\ .$fromaddress

Re: [PHP] [NEWBIE GUIDE] For the benefit of new members

2007-11-15 Thread Paul Scott
On Thu, 2007-11-15 at 16:45 -0500, Daniel Brown wrote: 3. There is a searchable archive of the mailing list discussion at http://phparch.com/mailinglists. or at http://fsiu.uwc.ac.za/index.php?module=blogaction=randbloguserid=9914070612 if the above is down, as it is for me right now.

[PHP] Segfault strangeness

2007-11-14 Thread Paul Scott
All of a sudden, I am getting a bunch of segfaults in PHP. The Apache2 error log simply says: [Wed Nov 14 11:43:36 2007] [notice] child pid 10982 exit signal Segmentation fault (11) and if I run the script through PHP-CLI it outputs the expected HTML, but with a Segmentation Fault notice at

Re: [PHP] Segfault strangeness

2007-11-14 Thread Paul Scott
On Wed, 2007-11-14 at 13:32 +0100, Per Jessen wrote: Backtrace? backtrace #0 0xb691f310 in ?? () #1 0xb7874705 in CRYPTO_lock () from /usr/lib/i686/cmov/libcrypto.so.0.9.8 #2 0xb78e057d in ?? () from /usr/lib/i686/cmov/libcrypto.so.0.9.8 #3 0x0009 in ?? () #4 0x0001 in ?? () #5

Re: [PHP] Segfault strangeness

2007-11-14 Thread Paul Scott
On Wed, 2007-11-14 at 14:17 +0100, Per Jessen wrote: OK, so quite a few things could have changed - in PHP or in apache. However, you said you reproduced the problem using CLI, so we're talking PHP or something underlying. It looks as though libcrypto has gotten itself into a knot. I did a

Re: [PHP] PHP 5.1 memory leak?

2007-11-07 Thread Paul Scott
On Wed, 2007-11-07 at 15:21 -0200, Egon Hilgenstieler wrote: I have a really complex report which uses a tree-like structure of data base objects. Usually it consumes a lot of memory but that it is not really an issue because it is an intranet application with few users and a dedicated server

[PHP] Strange warning: preg_match compilation warning

2007-11-05 Thread Paul Scott
Does anyone have any idea as to why the following line is generating a warning? } else if (preg_match('/^([0-9]{4})-([0-9]{4})? (AVOIR \)$/', $content) === 0) { The warning text is as follows: Warning: preg_match(): Compilation failed: missing ) at offset 34 in ... Offset 34 seems to be the

Re: [PHP] Strange warning: preg_match compilation warning

2007-11-05 Thread Paul Scott
On Mon, 2007-11-05 at 12:08 -0500, Daniel Brown wrote: You canceled-out the final closing param with a backslash here: (AVOIR \) Oh geez, thanks! How embarrassing... I suppose that's what you get for coding on long haul flights... Thanks! --Paul All Email originating from

Re: [PHP] Can I make a process run in background?

2007-11-05 Thread Paul Scott
On Mon, 2007-11-05 at 19:20 +0100, Luca Paolella wrote: I want the bot to run a process in background (a periodic message, for example) while listening for events (like a user joining a channel or using a certain command) and consequentially executing the corresponding functions, is

Re: [PHP] Maximum function nesting level of '100' reached

2007-10-26 Thread Paul Scott
On Fri, 2007-10-26 at 12:52 +0200, Jochem Maas wrote: since when is there an arbitrary maximum recursion limit??? Since forever... ;) I thought that it was at 60 though... --Paul All Email originating from UWC is covered by disclaimer

Re: [PHP] Ant in php

2007-10-25 Thread Paul Scott
On Thu, 2007-10-25 at 02:25 -0700, DCVer wrote: is this a good idea to use Ant with PHP or is there some similar tool to Ant, that works fine with PHP? Thanks in advance. What you really want to look at is Phing, not Ant. It is very similar and I use it extensively for my project(s). --Paul

Re: [PHP] combining 2 arrays

2007-10-16 Thread Paul Scott
On Tue, 2007-10-16 at 16:42 +0200, Ladislav Andel wrote: arrayDB1 = array(array('8', 'SER'), array('5','Asterisk')) When finished then it starts reading from second DB where I would get arrayDB2 = array(array('6', 'XIP'), array('4','Asterisk')) Is there any function where I would

Re: [PHP] Please recommend blog script

2007-10-07 Thread Paul Scott
On Sun, 2007-10-07 at 09:35 +0200, Niels wrote: Basically I want to integrate articles into existing pages, something like ?php blog::getArticlesHTML($rule); ? ?php blog::getUserCommentEditHTML($article); ? What you want is a blog that exposes it's functionality as an API (MetaWebLog or

[PHP] evil script in server logs (Heads Up)

2007-10-05 Thread Paul Scott
I am taking a quick look through the access logs on our dev box, and came across this little nasty that was trying to execute itself as a XSS attack(?) ? $ker = @php_uname(); $osx = @PHP_OS; echo f7f32504cabcb48c21030c024c6e5c1abr; echo h2SysOSx:$ker/h2/br; echo h2SysOSx:$osx/h2/br; if ($osx ==

Re: [PHP] error messages

2007-10-05 Thread Paul Scott
On Fri, 2007-10-05 at 00:32 -0700, tbt wrote: I added the following lines to the top of my script but still no error messages show up on the browser. When a php error occurs the entire page is still shown blank. Is your script *supposed* to output something? --Paul All Email originating

Re: [PHP] evil script in server logs (Heads Up)

2007-10-05 Thread Paul Scott
On Fri, 2007-10-05 at 07:38 -0600, Ashley M. Kirchner wrote: Quarantine Messages: Message quarantined because of virus: PHP.Shell. Someone saw it somewhere and reported it... Don't you love Free Software? ;) --Paul All Email originating from UWC is covered by

Re: [PHP] evil script in server logs (Heads Up)

2007-10-05 Thread Paul Scott
On Fri, 2007-10-05 at 11:29 -0400, Daniel Brown wrote: Yeah, honestly I wasn't sure if it was an injection attack or if those URLs were referrers in the logs. OK sorry if I wasn't 100% clear here, but the logs showed up something like:

Re: [PHP] error messages

2007-10-04 Thread Paul Scott
On Thu, 2007-10-04 at 22:38 -0700, tbt wrote: I'm a newbie to php and i would like to know a way of viewing runtime errors on the browser. Currently when an error occurs nothing is displayed on the browser. Is there any way of viewing all error messages on the browser itself. You can up

Re: [PHP] languages and PHP

2007-09-27 Thread Paul Scott
On Thu, 2007-09-27 at 12:15 +0200, Angelo Zanetti wrote: What are the implications of having a site that has many different languages, including latin and non latin characters? Keep everything as universal (UTF-8) as possible, and make sure that you code for right-to-left languages as well.

Re: [PHP] SOAP in PHP on very restricted host?

2007-09-26 Thread Paul Scott
On Wed, 2007-09-26 at 13:26 +0900, David Christopher Zentgraf wrote: But I just found out about NuSOAP (http://dietrich.ganx4.com/ nusoap/), which seems to be what I'm looking for, a no-strings- attached SOAP implementation. I'm trying my luck with this one for now. :) If you are using

Re: [PHP] Re: Data request

2007-09-25 Thread Paul Scott
On Tue, 2007-09-25 at 09:17 -0400, Robert Cummings wrote: Oh sure, and now when I'm searching for shit I'll get all these Henry's cat references *bleh*. Well then why not tie in coprophilia as well? ugh. --Paul All Email originating from UWC is covered by disclaimer

Re: [PHP] Data request

2007-09-24 Thread Paul Scott
On Mon, 2007-09-24 at 14:14 +0100, Stut wrote: Have you tried Google? It knows a lot about most things and a little about the rest. Also try have a look at the models used in flightgear - http://www.flightgear.org --Paul All Email originating from UWC is covered by disclaimer

Re: [PHP] Very Large text file parsing

2007-09-21 Thread Paul Scott
On Fri, 2007-09-21 at 15:51 +1000, Chris wrote: (Personally I'd use perl over php for processing files that large but that may not be an option). Thanks for all of the suggestions, I seem to have it working quite well now, although the client has just contacted me and said that they had made

Re: [PHP] Very Large text file parsing

2007-09-21 Thread Paul Scott
On Fri, 2007-09-21 at 08:34 +0200, Paul Scott wrote: Thanks to all for the suggestions - I now have to figure out the best way to manipulate every single record in that table (now over 6.5 million rows) to add in a field (RDBMS function in C - so much easier)... Oh, and by the way, adding

Re: [PHP] Very Large text file parsing

2007-09-21 Thread Paul Scott
On Fri, 2007-09-21 at 08:42 +0200, Per Jessen wrote: Isn't that just an ALTER ? Its a little more complex than that, as I have to actually create WKB from the data, so no, not just an ALTER unfortunately. --Paul All Email originating from UWC is covered by disclaimer

[PHP] Very Large text file parsing

2007-09-20 Thread Paul Scott
I have a very large text file that gets dumped into a directoory every now and then. It is typically around 750MB long, at least, and my question is: What is the best method to parse this thing and insert the data into a postgres db? I have tried using file(), fget*() and some others, all with

RE: [PHP] Very Large text file parsing

2007-09-20 Thread Paul Scott
On Thu, 2007-09-20 at 12:50 +0100, Edward Kay wrote: In addition to Martin's good suggestions (and also assuming you're running php-cli via cron), you could use nice to stop it consuming too many resources: This is the current approach that I am taking, was just really wondering if there

RE: [PHP] Very Large text file parsing

2007-09-20 Thread Paul Scott
On Thu, 2007-09-20 at 08:03 -0400, Robert Cummings wrote: Post some samples of the data you are parsing and a sample of the code you've written to parse them. If you're parsing 750 megs of data then it's quite likely you could squeeze some performance out of the parse routines themselves.

Re: [PHP] Very Large text file parsing

2007-09-20 Thread Paul Scott
On Thu, 2007-09-20 at 09:54 -0300, Martin Marques wrote: If not, you should just use the COPY command of PostgreSQL (you are using PostgreSQL if I remember correctly) or simply do a bash script using psql and the \copy command. Unfortunately, this has to work on all supported RDBM's - so

[PHP] IE Not Following Header(Location: /path/to/file.php);

2007-09-06 Thread Scott Wilcox
hey folks. I have a strange problem with IE sometimes. It doesn't seem to accept and follow a header sent to the browser. The action occurs when a user logs in, then is sent this header. Any hints/ideas appreciated. Scott. -- PHP General Mailing List (http://www.php.net/) To unsubscribe

Re: [PHP] Using PHP to determine if user has Java installed

2007-09-05 Thread Paul Scott
On Wed, 2007-09-05 at 20:41 -0400, tedd wrote: Java Runtime Environment == Java JavaScript != Java How about something like: if ( navigator.javaEnabled() ) { alert('JRE is installed!'); window.location=page_with_a_JAVA_applet; } else { alert('JRE is not installed!');

[PHP] Chisimba Framework Release

2007-08-31 Thread Paul Scott
The next release of the Chisimba PHP5 framework is now available. Major enhancements included in this release are: - Memcache support - Better caching of language items - Improved database performance - Bug fixes - Better code documentation - API docs - First draft of the Chisimba Book

Re: [PHP] PHP and SOAP calls

2007-08-24 Thread Paul Scott
On Fri, 2007-08-24 at 07:55 +0200, Angelo Zanetti wrote: I have been using nusoap to development a client that makes SOAP calls to a server. I have however been stuck on a small issue but can't seem to solve it and therefore I need to relook at using another package to get a solution.

Re: [PHP] Web Service with PHP4 suggestions wanted.

2007-08-16 Thread Paul Scott
On Thu, 2007-08-16 at 09:55 +0200, Mattias Hakansson wrote: So I request some suggestions from any one that has experience with this on what web service library/extension you would chose with PHP 4 ? I read about nuSOAP but it seems they are not any longer maintaining the source ? since the

Re: [PHP] PHP Books - A poll of sorts

2007-08-12 Thread Paul Scott
On Sun, 2007-08-12 at 20:52 -0500, Jay Blanchard wrote: If there was a best practices book would you buy it? (I am showing complete disregard for the thread on copyright infringement v. theft.) Or do you rely on other sources like this list, articles, etc to derive your own set of practices?

Re: [PHP] php SHOW

2007-08-03 Thread Paul Scott
On Fri, 2007-08-03 at 11:56 +0100, Hulf wrote: Is there a way to output my data and tables using a php version of SHOW? Doesn't have to be pretty HTML just output to screen Well, not knowing what show does, my best guess would be that you are looking for __toString() --Paul All Email

Re: [PHP] Blooging Portal

2007-07-31 Thread Paul Scott
On Tue, 2007-07-31 at 10:27 +0200, Christian Hänsel wrote: Does any of you know a decent Blooging Portal software? Of course, it should be OpenSource ;o) What I wanna do is: I want to give people the ability to create their own blogs on my server under one domain name... so

Re: [PHP] session_start(): Cannot send session cache limiter...

2007-07-20 Thread Paul Scott
On Fri, 2007-07-20 at 16:01 +0800, Vanessa Vega wrote: I already put session_start() on topmost part of the file..but i saved the file as utf-8..and that seems to be the problem..can anyone share their knowledge on this? Set your error_reporting to at least E_ALL and check that there are

Re: [PHP] Unlink file older then 7 days

2007-07-18 Thread Paul Scott
On Wed, 2007-07-18 at 07:29 +0100, [EMAIL PROTECTED] wrote: I need to throw in a wildcard, how would I do that.. I have this so far. which dont work. foreach(glob(*.asc.txt) as $files) { unlink($files); } --Paul All Email originating from UWC is covered by disclaimer

Re: [PHP] Xdebug 2 released.

2007-07-18 Thread Paul Scott
On Wed, 2007-07-18 at 21:23 +0200, Derick Rethans wrote: Now head over to the Xdebug site [2] and try it out! I have been using the XDebug RC for a while now, and am really glad that it is now stable! Thanks very much, it is one of the most important bits in my toolbox.

[PHP] PHP-5.2.3 and Internal Server Error

2007-07-17 Thread Paul Scott
On one of our test boxen, we recently upgraded to PHP-5.2.3 and all of a sudden started getting Internal Server Errors. The Apache log file tells me that there is a premature end of script error on index.php, which is simply an entry point script to an MVC framework. I have checked that there is

Re: [PHP] PHP-5.2.3 and Internal Server Error

2007-07-17 Thread Paul Scott
On Tue, 2007-07-17 at 18:06 -0500, Richard Lynch wrote: Run the same script with php CLI and see what it outputs. Goes through without a problem. Open the script in various editors to be sure there's no stray un-printable character in the source. Checked. This is from one of our

[PHP] PHP 101 Podcasts

2007-07-16 Thread Paul Scott
I have decided to take a stab at lecturing, and have taken on a group of 2nd year computer science students at UWC to teach PHP to. I would like to make use of some podcasts and/or other CC licensed content to make it a little more enjoyable than Read the manual, write unit tests, code, ship

Re: [PHP] acerca de extensiones SQL Server

2007-07-14 Thread Paul Scott
On Sat, 2007-07-14 at 19:57 +0200, M. Sokolewicz wrote: That's assuming he wanted specifically MySQL. The OP's post did not actually state _which_ extension he wants to use, nor to which RDBMS he wants to connect (at all). To the OP: SQL is simply a language, what you want is a

<    1   2   3   4   5   6   7   8   9   10   >