Re: [PHP] Does PHP support multi-thread ?

2010-04-18 Thread Nathan Rixham
yup, check out forking though for related Phpster wrote: > Not all libraries are thread safe, so no. 2 seconds with a google search > would have given you the same answer. > > Bastien > > Sent from my iPod > > On Apr 18, 2010, at 9:17 AM, "ttplayer" wrote: > >> Hello, everyone, please answer

Re: [PHP] Class constants

2010-04-20 Thread Nathan Rixham
Gary . wrote: > On Mon, Apr 19, 2010 at 3:12 PM, Ashley Sheridan wrote: >> On 19 April 2010 14:24, Gary wrote: > >>> Okay. Why not? > ... >> Class constants must be defined with static values, not variables. They are >> constants after all! If they relied on the value of a variable, surely that

[PHP] Re: Directory permissions question

2010-04-20 Thread Nathan Rixham
missions and owner of the directory containing the files, if it's nobody then anybody could have written to it. All in, ask the ISP to check logs and history, ensure all your permissions on directories are tight, and that you don't have any scripts on there that can be abused and

Re: [PHP] Structured PHP studying

2010-04-24 Thread Nathan Rixham
pretty critical i mean it's entirely critical, the more you understand REST and the more familiar you are with HTTP then the better your websites, web apps, api's etc will be! HTTP: http://www.w3.org/Protocols/rfc2616/rfc2616.html HTTPbis (the updated version, work in progress, probably be

[PHP] Re: What's your game? (X-PHP)

2010-04-25 Thread Nathan Rixham
tedd wrote: > Hi gang: > > Considering we recently had several people mention what games they play, > it might be interesting to see what everyone plays. > > As for me, I currently play "Modern Warfare 2" on XBOX. It's the most > recent in a long line of war games (i.e., Call of Duty, Ghost Recon

Re: [PHP] Structured PHP studying

2010-04-25 Thread Nathan Rixham
David McGlone wrote: > On Saturday 24 April 2010 10:46:33 Nathan Rixham wrote: >> Aside: in every project i do, and at all times i have a test.php where I >> literally just try out ways of doing things and snippets of code, once >> I'm done i stick an exit; before it then

Re: [PHP] creating a PHP wrapper script?

2010-04-25 Thread Nathan Rixham
Peter Lind wrote: > php.net/curl should be able to do what you want. +1 > file_get_contents with a proper stream context should also work (have > a look at functions like http://dk.php.net/manual/en/context.http.php > ) very important to note that file_get_contents uses HTTP 1.0 not 1.1 by defau

Re: [PHP] What's your game? (X-PHP)

2010-04-25 Thread Nathan Rixham
Robert Cummings wrote: > tedd wrote: >> Hi gang: >> >> Considering we recently had several people mention what games they >> play, it might be interesting to see what everyone plays. >> >> As for me, I currently play "Modern Warfare 2" on XBOX. It's the most >> recent in a long line of war games (i

[PHP] Re: getting content exceprts from the database

2010-04-26 Thread Nathan Rixham
true, 'drop-proprietary-attributes' => true, 'output-xhtml' => true, 'show-body-only' => true, 'word-2000' => true, 'wrap' => '0' ); $tidy = new tidy(); $tidy->parseString($html, $config, 'utf

Re: [PHP] Error handling strategies (db related)

2010-04-27 Thread Nathan Rixham
Peter Lind wrote: > On 27 April 2010 16:24, Paul M Foster wrote: >> On Tue, Apr 27, 2010 at 04:13:20PM +0200, Peter Lind wrote: >> >>> On 27 April 2010 16:07, Paul M Foster wrote: On Tue, Apr 27, 2010 at 03:41:04PM +0200, Peter Lind wrote: > On 27 April 2010 15:36, Paul M Foster wr

[PHP] Re: finding out datasets in a certain distance of a zip code

2010-04-27 Thread Nathan Rixham
= round(($row->e*1.4),2); > echo 'cl: '.$row->cl_id.' '.$entfernung_km.''; > } > $num_results = db_numrows($result); > ### > > } // end if results > > Thank you for

Re: [PHP] Error handling strategies (db related)

2010-04-27 Thread Nathan Rixham
Teus Benschop wrote: >> I'm still shocked you guys are still writing code that has errors in it, >> what's worse is you know about the errors, and instead of fixing them >> you're just telling the user about it! >> > > The point here is that we, programmers, know that we write code with > bugs in

Re: [PHP] Two color rows in table inside while iteration

2010-05-02 Thread Nathan Rixham
o me. Oh, as for "governments" if you want a copy of >> anything please contact me directly, I have a few forms for you to >> fill out. > > If you think about it, that's pretty hilarious. Normally, doing anything > with the government requires *you* to fill out

[PHP] Re: Need login suggestions

2010-05-02 Thread Nathan Rixham
d find a single bit of information that both a student and you know about that student, possibilities are: student id class teacher year and so forth.. if the person signing up has any of these things then they must be a student. Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Need login suggestions

2010-05-02 Thread Nathan Rixham
udents to anybody unless they are 100% verified and allowed the info - that's one thing I would not want to screw up on myself, could be a nasty lawsuit. best, nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Need login suggestions

2010-05-02 Thread Nathan Rixham
I think in that scenario you'd really appreciate the gentle nudge - and we, many of us parents, wouldn't want the possibility of a hurt (or worse) child due to not speaking up ;) Regards, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] In need of CVS/SVN checkout script for Production servers [solved]

2010-05-04 Thread Nathan Rixham
rome 5.0.375.29 beta - what advanced features am I (and chrome) missing? sounds like I'm being negative, but I'm not :) tip though; degrade gracefully mate, don't break the net for non-required features. best, nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Inserting rows with missing IDs

2010-05-04 Thread Nathan Rixham
rs (unless it's a number table!) best, nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Really impressive work

2010-05-05 Thread Nathan Rixham
; together in such a user pleasing and useful way, is definately something to applaud :) Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] how to check for bandwidth limitations when uploading files?

2010-05-05 Thread Nathan Rixham
you're testing and then another server with a good connection - that way you'll get solid numbers and be able to pinpoint the bottleneck in a snap. [1] http://httpd.apache.org/docs/2.0/programs/ab.html Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] In need of CVS/SVN checkout script for Production servers [solved]

2010-05-05 Thread Nathan Rixham
are sending out to associates, friends and clients alike (both current and potential). I won't say anything specific about your website, other than lol (you know it's really bad) - just take it on the chin, if possible heed the good (honest) advice you've been given, and get back on with what you're doing - we all make mistakes and go down incorrect tech paths from time to time :) Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Connection error expected but ...

2010-05-06 Thread Nathan Rixham
Al Mangkok wrote: Code below from the manual. I changed $ldaphost to some fictitious name. When I ran the script, I always get the message "Connection was successful !" Why didn't the script bomb and give the could not connect message? http://php.net/ldap_connect "ldap_connect() will always r

Re: [PHP] simplexml choking on apparently valid XML

2010-05-07 Thread Nathan Nobbe
ot; } php > var_dump(simplexml_load_string('Basketball Personalized Notebook - Jeff's')); object(SimpleXMLElement)#1 (1) { [0]=> string(41) "Basketball Personalized Notebook - Jeff's" } -nathan

Re: [PHP] __call and recursion

2010-05-09 Thread Nathan Nobbe
he methods youre trying to invoke via var_dump() or error_log() etc? eg .. var_dump($method); call_user_func_array(array($this,$method), $args); -nathan

Re: [PHP] Re: PHP Application Structre

2010-05-11 Thread Nathan Nobbe
anization, or maybe it's > because > I've been practicing a whole lot more. dunno. if theres one thing i tend to stay away from, or start deleting the second i inherit a new codebase, its smarty. ive never seen anything more bloated & ridiculous. hey, lets all learn *another* set of conventions & syntax on top of what we've already learned, drop *another* url in our bookmarks and slow down the entire universe in the process... imo smarty and most any 'template engine' on top of php can be summarized in one line of code: include($someScript); // :P i did gander at robs template system in interjinn once, but never got my head wrapped round it; honestly i only gave it a day or so. i prefer to go the typical route as per above, and omit the bloat that systems like smarty, savant etc bring to the table. nothing personal david, just an anti-smarty rant :) -nathan

[PHP] Re: -----json and php----help

2010-05-11 Thread Nathan Rixham
shahrzad khorrami wrote: hi dears, I have a json file. I want to access some fileds of this json file only and can add some fields to it also... I couldn't find any thing in www, json api ! is there any function to get specific data from json file or add function that can add something in somewh

Re: [PHP] Re: PHP Application Structre

2010-05-11 Thread Nathan Rixham
Nathan Nobbe wrote: On Mon, May 10, 2010 at 9:19 PM, David McGlone wrote: On Monday 10 May 2010 22:15:44 Paul M Foster wrote: On Mon, May 10, 2010 at 06:09:00PM -0400, David McGlone wrote: On Monday 10 May 2010 13:04:36 richard gray wrote: On 10/05/2010 18:17, Ashley Sheridan wrote: It

Re: [PHP] Append Dom Document

2010-05-13 Thread Nathan Nobbe
;"); > echo (""); > echo ($item_desc . ""); > } > you might have an easier time w/ SimpleXML for this task; have a look at the examples: http://us.php.net/manual/en/simplexml.examples-basic.php the other thing i find strange about this code is the xml parsing assumes a similar schema when the source urls are from seemingly totally disparate domains, and topic .. id guess it sheer coincidence they have overlapping schemas at all. -nathan

Re: [PHP] Append Dom Document

2010-05-13 Thread Nathan Nobbe
xisting one, you would use the appendChild() method. > Am I making sense here? no because youre not editing the DOMDocument in your code, youre just reading a document; what is getting overwritten here? im not entirely sure what youre trying to accomplish. -nathan

Re: [PHP] Append Dom Document

2010-05-14 Thread Nathan Nobbe
On Fri, May 14, 2010 at 7:20 AM, Andrew Ballard wrote: > On Fri, May 14, 2010 at 12:04 AM, Nathan Nobbe > wrote: > [snip] > > having said that if you wanted to append > > a new DOMNode to an existing one, you would use the appendChild() method. > > Usually, yes. In th

Re: [PHP] what's the point of _autoload?

2010-05-14 Thread Nathan Nobbe
could potentially be needed to fulfill a given request. > If _autoload can't figure out the correct path to the file which defines > the class, then what is the point from an oop pov? see above; its a speed boost, and typically folks prefer not to bother include/require files atop ever class the define; those are the 2 main benefits. -nathan

Re: [PHP] Multiple Login in a single PC should not be possible

2010-05-15 Thread Nathan Nobbe
rcumvent your 'security' anyway?) and the only way they >> can access both course materials and the test is with two sets of login >> credentials. >> > > Just to follow-up... even if one could identify the machine, someone out > there would open up a virtual machine :) or add a second nic .., or a virtual nic, which doesnt even require additional hardware ;) -nathan

Re: [PHP] Simplexml_load_file: 401 Authorization Required

2010-05-17 Thread Nathan Nobbe
le from the remote server. if you want to specify credentials for an http connection why dont you try curl. also you might try stream contexts, however, i dont think those are supported by the simplexml functions. short version - pull down the file w/ curl then feed it to simplexml locally. -nathan

[PHP] Re: How to prevent duplicate record insertion after refreshing php page

2010-05-19 Thread Nathan Rixham
en this will prevent duplicates at the table level (regardless of the scenario). to handle POST data, well no point me repeating it, see the spec: http://tools.ietf.org/html/draft-ietf-httpbis-p2-semantics-09#section-7.5 Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsu

Re: [PHP] Multiple Login in a single PC should not be possible

2010-05-23 Thread Nathan Rixham
hat @ each certain time. Good luck though :) Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Is there a good way to extract the / content in HTML with/without closing tag?

2010-05-23 Thread Nathan Rixham
esults is to run the document through HTML Tidy, then parse it in to a DOM and query it using xpath/xquery - basically mimic the base way in which the browsers do it (and the way recommended by the HTML specs) Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Multiple Login in a single PC should not be possible

2010-05-23 Thread Nathan Rixham
n account which has sensitive data in it. I seem to have missed it; but why exactly don't you want a client 'logged in' multiple times (at the same time)? perhaps if you give us the root of the problem instead of how to do the solution you've chosen, we can be of more help :) B

Re: [PHP] Remove blank lines from a file

2010-05-23 Thread Nathan Rixham
Robert Cummings wrote: tedd wrote: At 1:02 PM -0400 5/22/10, Robert Cummings wrote: tedd wrote: If that is all (i.e., removing double linefeeds), then this will do it: $text_array = array(); $text_array = explode("\n\n", $input_text); $output_text = implode("\n",$text_array); Sorry tedd, this

Re: [PHP] Remove blank lines from a file

2010-05-23 Thread Nathan Rixham
Nathan Rixham wrote: Robert Cummings wrote: tedd wrote: At 1:02 PM -0400 5/22/10, Robert Cummings wrote: tedd wrote: If that is all (i.e., removing double linefeeds), then this will do it: $text_array = array(); $text_array = explode("\n\n", $input_text); $output_text = i

Re: [PHP] Remove blank lines from a file

2010-05-23 Thread Nathan Rixham
Robert Cummings wrote: Nathan Rixham wrote: Nathan Rixham wrote: Robert Cummings wrote: tedd wrote: At 1:02 PM -0400 5/22/10, Robert Cummings wrote: tedd wrote: If that is all (i.e., removing double linefeeds), then this will do it: $text_array = array(); $text_array = explode("

Re: [PHP] Multiple Login in a single PC should not be possible

2010-05-23 Thread Nathan Rixham
Karl DeSaulniers wrote: Hi Nathan, The problem is not mine to speak of necessarily. I was trying to help find a solution for another. But from what I understand, they have a online lesson that they dont want people to be able to log in as another user and get the answers to. Here is the

Re: [PHP] Remove blank lines from a file

2010-05-23 Thread Nathan Rixham
Robert Cummings wrote: Nathan Rixham wrote: Robert Cummings wrote: Nathan Rixham wrote: Nathan Rixham wrote: Robert Cummings wrote: tedd wrote: At 1:02 PM -0400 5/22/10, Robert Cummings wrote: tedd wrote: If that is all (i.e., removing double linefeeds), then this will do it

Re: [PHP] Remove blank lines from a file

2010-05-23 Thread Nathan Rixham
Robert Cummings wrote: Nathan Rixham wrote: Robert Cummings wrote: You may want to start testing your solutions. None have worked yet. Not even close :) filed under 'works for me' Doesn't appear to work on the following: $input = ' 1 2 3 4 5 6'; Additionall

Re: [PHP] Remove blank lines from a file

2010-05-23 Thread Nathan Rixham
Robert Cummings wrote: Nathan Rixham wrote: Yes it was client stripping out extra whitespace! thanks Rob, replicated your results: 1 2 3 4 5 6 and then 'fixed' to give what's needed: preg_replace( "/(((\r|)\n)(\h*|))+/im", '\\1' , $input ); the above

Re: [PHP] determining time difference between two timestamp fields.

2010-05-25 Thread Nathan Rixham
time ); echo "Completion Time:"; echo $formatted_completion_time; echo ""; Sure it's verbose, but it's also so much easier to debug, and you can always tidy / crunch it up afterwards. Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] authentication issue...

2010-05-28 Thread Nathan Nobbe
it logs me in properly, but I > have to click the login button twice.... Ideally I should just do it once, > so I'm wondering if anyone can spot my grievous misstep here? > it looks to me like you need to move the authentication() call if(isset($_POST['txtUser'])) { $authUser = $_POST['txtUser']; $authPass = $_POST['txtPass']; $auth = authentication($authUser, $authPass, $cfgtableAuth); } above the check to see if the user has logged in, right after the include("nav.php"); line. right now, when the user submits the form, your code is first finding that the user isnt logged in, spitting out the 'please log in' portion of the html then logging them in, so youre actually already logged in when the form shows itself the second time! -nathan

Re: [PHP] constant from variable

2010-06-04 Thread Nathan Rixham
Tanel Tammik wrote: ""Tanel Tammik"" wrote in message news:31.a3.00596.0d759...@pb1.pair.com... "Ashley Sheridan" wrote in message news:1275678975.2217.83.ca...@localhost... On Fri, 2010-06-04 at 22:07 +0300, Tanel Tammik wrote: Hi, define('MYCONST', 'something'); $my = 'my'; $const = 'co

[PHP] Re: Script to add domain users to local groups on remote machines

2010-06-04 Thread Nathan Rixham
. regards, nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] constant from variable

2010-06-04 Thread Nathan Rixham
Tanel Tammik wrote: "Nathan Rixham" wrote in message news:4c097083.3080...@gmail.com... Tanel Tammik wrote: ""Tanel Tammik"" wrote in message news:31.a3.00596.0d759...@pb1.pair.com... "Ashley Sheridan" wrote in message news:1275678975.2217.83.ca...@l

Re: [PHP] finding the web root

2010-06-08 Thread Nathan Nobbe
; > $cwd = explode(DIRECTORY_SEPARATOR, __DIR__); > $web_root = '/' . implode('/', array_diff($cwd, $root)); > echo $web_root; > ?> $_SERVER['DOCUMENT_ROOT'] although a post on the manual mentions some variability between environments. -nathan

[PHP] Re: PHP app & Server Load

2010-06-10 Thread Nathan Rixham
no way for anybody to tell you how many servers of what spec you'll need, because the biggest factor here your PHP code and MySQL queries, if you were purely serving static files though then circa 2000 requests per second is a good guestimate. Best, Nathan -- PHP General Mailing List (ht

Re: [PHP] PHP & Active Directory?

2010-06-21 Thread Nathan Nobbe
adLDAP class - its the chronic http://adldap.sourceforge.net/ -nathan

Re: [PHP] PHP & Active Directory?

2010-06-21 Thread Nathan Nobbe
On Mon, Jun 21, 2010 at 9:42 AM, David Stoltz wrote: > Awesome – thanks – BTW, what does “it’s the chronic” mean? > listen to some dr. dre or come visit me in denver, co :) -nathan

Re: [PHP] Stripping Characters

2010-06-22 Thread Nathan Nobbe
lpha character and not a number value from 0 > to 9? > check the docs, the first parameter may be an array of multiple needles, e.g. $moditem = str_replace(array('-', '?', '!'), '_', $mystring); you could likely do something more elegant w/ preg_replace() tho. -nathan

Re: [PHP] call_user_func_array how to use on object php >= 5.3

2010-06-28 Thread Nathan Nobbe
he callback array is an object, not a string naming a class. 5.3.0 string(4) "A::b" -nathan

Re: [PHP] call_user_func_array how to use on object php >= 5.3

2010-06-28 Thread Nathan Nobbe
On Mon, Jun 28, 2010 at 12:51 PM, Nathan Nobbe wrote: > > > On Mon, Jun 28, 2010 at 12:39 PM, Shaun Morrow wrote: > >> I am working on code that implements a delegate design pattern, this makes >> use of the call_user_func_array function. >> >> I am having trou

Re: [PHP] adduser & php

2010-07-13 Thread Nathan Nobbe
d and w/e other superuser required commands you intend to run from it. -nathan

Re: [PHP] running out of memory processing result set on Linux, but not on Solaris

2010-07-13 Thread Nathan Nobbe
run it on the linux box 31.7M of memory is in use. another easy way to make the determination is to do as ashley suggested and write a script which does nothing other than execute the query. -nathan

Re: [PHP] Getting only attribute and not its values when doing LDAP calls to 2003 AD server

2010-07-18 Thread Nathan Nobbe
ute names and not the values stored in > attributes array. Can some one give me some tips to fix my issue. > Here is my configuration. give the adLdap class a shot; if it works you can reverse engineer how they accomplished it. http://adldap.sourceforge.net/ -nathan

Re: [PHP] What are the curly brackets around variables in SQL statements for?

2010-07-21 Thread Nathan Nobbe
riable name unless the string expression is wrapped in double quotes (which probly also evaluates in heredocs & nowdocs). in this case, i would say you are right, the curly braces seem gratuitous; again as dan suggested, read the docs for clarification ... http://us.php.net/manual/en/language.types.string.php#language.types.string.parsing -nathan

Re: [PHP] What are the curly brackets around variables in SQL statements for?

2010-07-21 Thread Nathan Nobbe
On Wed, Jul 21, 2010 at 1:32 PM, Daniel Brown wrote: > On Wed, Jul 21, 2010 at 15:27, Nathan Nobbe > wrote: > > > [snip!] > > name unless the string expression is wrapped in double quotes (which > probly > > also evaluates in heredocs & nowdocs). > [snip!]

Re: [PHP] PHP database interface layer

2010-07-22 Thread Nathan Nobbe
t all clients joined to the company > $clients = $company->get_clients(); > > // Get all projects joined to the client > $projects = $clients->get_projects(); > > ? i recommend propel http://www.propelorm.org/ -nathan

Re: [PHP] PHP database interface layer

2010-07-22 Thread Nathan Nobbe
your schema; re-generate the base layer.., o yeah, and it preserves custom logic too (upon regeneration), since that resides in sub classes. i used to hand write db wrapper classes but found it tedious and tended to result in a lack of cohesion through the classes themselves, not to mention being error prone. -nathan

Re: [PHP] Retaining scroll position after asynchronous refresh NOT PHP

2010-07-23 Thread Nathan Nobbe
> googled for this, but everything I find is ASP or C# or Java. My stuff >> is straight php/html. How can I do this with that? >> > how are you doing the refresh? a location header or http meta tag? both of those are gross imo - try ajax and i bet your problem goes away. -nathan

[PHP] Re: Does class length slow down performance

2010-07-24 Thread Nathan Rixham
Sebastian Ewert wrote: Hi, I'm developing an joomla component and my helper an user classes are crowing bigger and bigger. The helper class is for static use only. Does class size decrease performance of my php scripts, even for static usage? Is there a general rule when to split a class to kee

[PHP] the state of the PHP community

2010-07-28 Thread Nathan Rixham
etting involved with)? ps: please *do not* flame anybodies answers, that really wouldn't be fair. Best & Regards, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: socket multithreading problem

2010-07-28 Thread Nathan Rixham
together without waiting each other ? 1: you can't multi thread PHP 2: you can 'fork' PHP processes using the pcntl_ functions to achieve what you are looking for by making a cli based php deamon. Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscri

Re: [PHP] the state of the PHP community

2010-07-29 Thread Nathan Rixham
Hi Josh, Thanks for taking the time - comments in-line from here :) Josh Kehn wrote: On Jul 29, 2010, at 1:36 AM, Nathan Rixham wrote: Hi All, I find myself wondering about the state of the PHP community (and related community with a PHP focus), so, here's a bunch of questions - feel

Re: [PHP] the state of the PHP community

2010-07-29 Thread Nathan Rixham
Larry Garfield wrote: On Thursday 29 July 2010 02:07:58 am you wrote: Hi Larry, Thanks for taking the time to reply, a solid insightful one at that - kudos +1 for your opensource drupal efforts! Good of you to mention, and indeed to see, Palinter grasping opensource with two hands, this is ce

Re: [PHP] the state of the PHP community

2010-07-29 Thread Nathan Rixham
Larry Garfield wrote: On Thursday 29 July 2010 12:36:13 am Nathan Rixham wrote: Hi All, I find myself wondering about the state of the PHP community (and related community with a PHP focus), so, here's a bunch of questions - feel free to answer none to all of them, on list or off, or add

Re: [PHP] the state of the PHP community

2010-07-29 Thread Nathan Rixham
Adam Richardson wrote: On Thu, Jul 29, 2010 at 1:36 AM, Nathan Rixham wrote: Hi All, I find myself wondering about the state of the PHP community (and related community with a PHP focus), so, here's a bunch of questions - feel free to answer none to all of them, on list or off, or add

Re: [PHP] the state of the PHP community

2010-07-29 Thread Nathan Rixham
zine/article.aspx?i=70379 -Original Message- From: Nathan Rixham [mailto:nrix...@gmail.com] Sent: Thursday, July 29, 2010 1:36 AM To: PHP-General Subject: [PHP] the state of the PHP community Hi All, I find myself wondering about the state of the PHP community (and related commun

Re: [PHP] the state of the PHP community

2010-07-29 Thread Nathan Rixham
Bastien Koert wrote: On Thu, Jul 29, 2010 at 1:36 AM, Nathan Rixham wrote: Hi All, I find myself wondering about the state of the PHP community (and related community with a PHP focus), so, here's a bunch of questions - feel free to answer none to all of them, on list or off, or add mo

[PHP] Re: PHP 5.3 as a requirement for a library?

2010-07-30 Thread Nathan Rixham
2 for some time. Are we average in that regard or the exception to the rule? Most people are on 5.2 afaik, certainly most shared hosts are either 5.1.x and 5.2.x, and most os's still have the 5.2.x when you install from the packages. Best, Nathan -- PHP General Mailing List (http://w

Re: [PHP] DirectoryIterator

2010-08-02 Thread Nathan Nobbe
termine if the entry is a link and if so, dereference it http://www.php.net/manual/en/splfileinfo.islink.php (note: $oFile is internally being populated via $oIt->current()) isLink()) { echo 'link found' . PHP_EOL; echo 'link points to: ' . $oFile->getRealPath() . PHP_EOL; } ?> -nathan

[PHP] Re: How safe is a .htaccess file?

2010-08-19 Thread Nathan Rixham
y which is only available to your application - this doesn't negate insecure code, but it at least ensures the raw files are encrypted securely enough to negate any of these worries. (just keep your private key safe, preferably in a pkcs12 w/a strong 64char+ pass) Best, Nathan --

[PHP] Re: How safe is a .htaccess file?

2010-08-19 Thread Nathan Rixham
ing a public key which is only available to your application - this doesn't negate insecure code, but it at least ensures the raw files are encrypted securely enough to negate any of these worries. (just keep your private key safe, preferably in a pkcs12 w/a strong 64char+ pass) Best

[PHP] Re: openssl_pkey_new question

2010-08-19 Thread Nathan Rixham
' => 2048 ) ); Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: cast changes value

2010-08-19 Thread Nathan Rixham
Martín Marqués wrote: I have values with 2 decimals that I multiple by 100 to make them integers, but to be sure I do a cast using (int). The thing is that (int) is changing the value of the integer. Here is a var_dump of the original value, the value * 100, and the value after casting to int.

[PHP] Re: [OUTPUT BUFFER] - problems with redirects

2010-08-19 Thread Nathan Rixham
ainly wouldn't just knock output buffering right up high to work around it if I was you. Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: [OUTPUT BUFFER] - problems with redirects

2010-08-19 Thread Nathan Rixham
ownloading a big zip would you? but yeah ob_** functions, this way you're catching the entire MessageBody (your html) before sending anything to the client, which then let's you send headers followed by body in your own time. Best, nathan Tristan wrote: A rewrite of the entire site w

[PHP] Re: [OUTPUT BUFFER] - problems with redirects

2010-08-20 Thread Nathan Rixham
Nisse Engström wrote: On Thu, 19 Aug 2010 17:47:01 -0600, Tristan wrote: A rewrite of the entire site would be needed in order to fix. So, I guess you are saying as best options for workaround are - use the ob_ functions to work around. - stick output buffer on or high so best case scenario u

[PHP] Re: Dear Lazy Web: Pseudo Randomisation Strategies on Listing Websites

2010-08-20 Thread Nathan Rixham
Thus, assign each user / session a simple random int, and use it in the query. on a semi related note, if you need real random data, then you'll be wanting random.org Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Web application architecture (subdomain vs. sub directory)

2010-08-25 Thread Nathan Nobbe
lots of large sites use subdomains to implement distribution. say you have a big image hosting site, all the images are stored on s3, so you might have images.blah.com in that case (note the images are hosted on separate infrastructure). just general guidelines, quite vague, but hopefully helpful. -nathan

Re: [PHP] Web application architecture (subdomain vs. sub directory)

2010-08-25 Thread Nathan Nobbe
simple site sub-directories is the obvious route for a contiguous single application. this really is a question of how large is the site, and what are the load / distribution requirements, IMO. -nathan

Re: [PHP] Question about news.php.net

2010-09-14 Thread Nathan Rixham
it as a "bug" (in either thunderbird or the mailing list software that PHP is running). Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Adjusting Session Times

2010-09-14 Thread Nathan Rixham
mand Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] php cli question

2010-09-14 Thread Nathan Rixham
to clearing objects from memory quickly? Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] 1984 (Big Brother)

2010-09-14 Thread Nathan Rixham
ementation being an if(file_exists('boss_man_say_okay') ){ // let monkeys work } type solution. Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: libmcrypt usage

2010-09-16 Thread Nathan Rixham
Gary wrote: Can anyone tell me what the equivalent to the following command line usage of openssl is, in php using the mcrypt_* functions, please: , | openssl enc -e -aes-256-cbc -k ... ` TIA. I tried , | $iv = mcrypt_create_iv(mcrypt_get_block_size(MCRYPT_RIJNDAEL_256, |

[PHP] Re: Sending Encrypted Email

2010-09-16 Thread Nathan Rixham
ertificate. note: Each certificate has codes embedded which state for what you can use said certificate, although it's technically possible to use almost any certificate for anything, it's best to use one which has the correct flags set. Best, Nathan -- PHP General Mailing List (htt

[PHP] Re: libmcrypt usage

2010-09-16 Thread Nathan Rixham
Gary wrote: Nathan Rixham wrote: Gary wrote: Can anyone tell me what the equivalent to the following command line usage of openssl is, in php using the mcrypt_* functions, please: , | openssl enc -e -aes-256-cbc -k ... ` TIA. I tried , | $iv = mcrypt_create_iv

Re: [PHP] Copying an Object

2010-09-22 Thread Nathan Nobbe
t;care":"A":private]=> int(2) ["someObj":"A":private]=> object(stdClass)#2 (0) { } } [1]=> object(B)#5 (7) { ["what":protected]=> int(5) ["anotherObj":protected]=> object(stdClass)#7 (0) { } ["shallowObj":protected]=> object(stdClass)#4 (0) { } ["blah"]=> int(0) ["meh":protected]=> int(1) ["care":"A":private]=> int(2) ["someObj":"A":private]=> object(stdClass)#6 (0) { } } } hope it helps! -nathan

Re: [PHP] Copying an Object

2010-09-22 Thread Nathan Nobbe
), $args); } } $a = new A(); $b = new B($a); // some code .. $anotherA = new A(); // some more code $b->swapA($anotherA); -nathan

Re: [PHP] Copying an Object

2010-09-24 Thread Nathan Nobbe
e ways of modeling this problem in any of these languages (see above for 1 reasonable solution w/ single inheritance in php). one of the problems w/ the runtime class alteration model is how do you determine the class of an object after altering it at runtime? -nathan

Re: [PHP] SEO Experts?

2010-09-26 Thread Nathan Nobbe
as well, but don't forget internal links. if you have links pointing from several pages on your site to one important page, search engines can tell that. unique content is also great as it distinguishes your site from competitors. -nathan On Sep 26, 2010 6:10 AM, "David Mehler"

Re: [PHP] SimpleXML/array duality (like particles & waves)

2010-09-28 Thread Nathan Nobbe
On Tue, Sep 28, 2010 at 4:29 PM, Brian Dunning wrote: > I am kind of jacked here. I have a SimpleXML object that's been converted > to an array. how was the SimpleXMLElement converted to an array? -nathan

Re: [PHP] SimpleXML/array duality (like particles & waves)

2010-09-28 Thread Nathan Nobbe
in functionality, which is to say, why bother converting to an array in the first place? -nathan

[PHP] Re: Friday's Post

2010-10-01 Thread Nathan Rixham
ing/from microsoft, and also OData which is a nice RESTful protocol. Best, Nathan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] daemon

2010-10-06 Thread Nathan Nobbe
pdate add php-service default and the script will start when the box hits runlevel 3! -nathan

<    5   6   7   8   9   10   11   12   13   14   >