Re: [PHP] Wierd error

2005-11-17 Thread Chris Boget
We were using unset() for the longest time but found it doesn't seem to free up the memory. interesting - you are suggesting that settype does free the memory directly? Yes. Moreso than unset(), at least according to my observations and tests. I have seen a number of posts to internals regar

Re: [PHP] Wierd error

2005-11-17 Thread Chris Boget
why not just do: unset($dbObject); We were using unset() for the longest time but found it doesn't seem to free up the memory. $dbObject &= new IPI_OfficeDetailsInterface(); so you want to do a bitwise AND on a non-existant variable and a newly creately object?? maybe you meant to do: $dbObj

Re: [PHP] Re: Wierd error

2005-11-17 Thread Chris Boget
There is nothing weird when this function takes a variable as the argument and your using an object, read the manual http://php.net/settype I'm not sure what you mean here. Nowhere on the doc page for settype() (at least, not that I saw) does it say you can't pass an object as the first argu

Re: [PHP] Wierd error

2005-11-17 Thread Chris Boget
I'm seeing the following line showing up in my logs: 08:08:30 [warning] [Unknown][0]: Unknown(): Unable to call () - function does not exist and I've narrowed it down to this line of code: Update, it turns out it's not the settype(). Here's a larger context of the offending area of code

[PHP] Wierd error

2005-11-17 Thread Chris Boget
I'm seeing the following line showing up in my logs: 08:08:30 [warning] [Unknown][0]: Unknown(): Unable to call () - function does not exist and I've narrowed it down to this line of code: settype( &$dbObject, "null" ); When I comment out the above line, the error goes away. When I uncomm

[PHP] mssql_*() functions and stored procedures

2005-10-11 Thread Chris Boget
Looking through the documentation, I see that I can use mssql_init() mssql_bind() mssql_execute() to execute those stored procedures that have parameters. But what about those SPs which just return a value? If I have the following SP CREATE PROCEDURE MySP AS DECLARE @resultCode int SELECT @r

Re: [PHP] Testing a String for 'most' Capitalised

2005-10-10 Thread Chris Boget
Image that there could be a string fred Fred FRED First of all I need to know that these are same which I can do with strtolower, but how could I tell that 'FRED' is 'most captilised? Iterate through the string and count the number of capitalised letters. You can do something like this (untest

Re: [PHP] Problems with new PHP install

2005-09-29 Thread Chris Boget
Step 15 of the php installation (as listed in the link in my OP) has you add the following to the httpd.conf: Ok, color me retarded. Pretty please. :) It turns out I modified the wrong httpd.conf file. duh. Sorry about that. Everyone can move along. Nothing to see here but some blathering

Re: [PHP] Problems with new PHP install

2005-09-29 Thread Chris Boget
And that is exactly what is getting output by the browser. The isn't even getting interpreted as a break...? Is there a line like this in your httpd.conf...? AddType application/x-httpd-php .php [snip] Yeah, looks like you need the AddType entry. Apache doesn't know what *.php is, so it'

Re: [PHP] Problems with new PHP install

2005-09-29 Thread Chris Boget
[snip] Then I modify the httpd.conf file as instructed at the above page by adding the LoadModule and AddType and then create a 'hello world' php script to make sure php is working. [/snip] Did you restart the Apache server after making the changes to httpd.conf ? I know it is basic, I just have

[PHP] Problems with new PHP install

2005-09-29 Thread Chris Boget
Since I was having so much difficulty getting PHP (with libxml2) installed on RH9, I decided to take the advice given by several people and use Fedora Core 4 instead, which I get installed w/o difficulty. So next is Apache/PHP and I download Apache version 2.0.54 and PHP version 5.0.5. Followi

Re: [PHP] Trying to install PHP

2005-09-27 Thread Chris Boget
So I'm trying to install PHP with XML support. During configuration, I get an error saying I need a newer version of libxml2. So I download libxml2-2.6.22-1.i386.rpm and try to upgrade. No go as I get failed dependancies. I then also download libxml2-devel-2.6.22-1.i386.rpm and libxml2-python

[PHP] Trying to install PHP

2005-09-27 Thread Chris Boget
So I'm trying to install PHP with XML support. During configuration, I get an error saying I need a newer version of libxml2. So I download libxml2-2.6.22-1.i386.rpm and try to upgrade. No go as I get failed dependancies. I then also download libxml2-devel-2.6.22-1.i386.rpm and libxml2-python-

Re: [PHP] Bitwise operators

2005-09-26 Thread Chris Boget
I tested; I don't want to waste peoples time. Rewriting the question: this outputs: c = 32 d = 0 The question is why? First row is the bit's number and the second row is the bit's value: #8 | #7 | #6 | #5 | #4 | #3 | #2 | #1 --- 128 | 64 | 32 | 16 | 8 |

[PHP] phppatterns.com

2005-08-25 Thread Chris Boget
Has the above site gone down? Does anyone know? I've not been able to access it for quite a while... thnx, Chris

[PHP] PHP developer in the UK

2005-08-23 Thread Chris Boget
My company wants to relocate to the UK (London, specifically) from the US and I've been looking at various resources to try find out what my current salary would translate to. Most of the job listings I've seen are for junior or not very experienced developers. So I'm wondering if there are any

[PHP] Load testing

2005-08-22 Thread Chris Boget
What do you guys use for load testing forms? I've just been opening seperate windows, navigating to the form, filling out the form on all windows and hitting the submit button at the same time. After about 15 or so windows, it starts to become a bit cumbersom. Do you guys load test? What do you

[PHP] Resource id #X

2005-08-18 Thread Chris Boget
I just want to make sure of my understanding on something. I was pretty sure I had this down but now I'm beginning to question myself and I'm hoping someone could confirm. * User A accesses page X, which makes a connection to the database. Echoing out the result of the mssql_pconnect() function

[PHP] PEAR and MSSQL

2005-08-17 Thread Chris Boget
We are using PEAR as our database abstraction layer for connectivity to MSSQL. It seems that, for some inexplicable reason, that our code is losing it's connection to the sql server. We have a section of our site where users can come in and fill out a form to get an insurance quote. Once th

[PHP] Windows, DLLs and php.ini

2005-08-16 Thread Chris Boget
I've looked at the documentation but was able to find this. If anyone can point me to the right page, it would be much appreciated. In any case, where do you define where PHP looks for the appropriate DLLs? For example, if a DLL (say, ntwdblib.dll) is in both the "\PHP\dll" directory and the "\w

Re: [PHP] skip a row in foreach loop

2005-08-03 Thread Chris Boget
but there is a tons of code lines inside the loop and was thingking is there any part in foreach function that can do that? something like: foraech($results as $key => $value, skip(empty($value))) { // } 'continue' is your friend. http://us3.php.net/manual/en/control-structures.continue.php

[PHP] Regex help

2005-08-02 Thread Chris Boget
I'm trying to validate an email address and for the life of me I cannot figure out why the following regex is not working: $email = "[EMAIL PROTECTED]"; $regex = "^([a-zA-Z0-9_\.\-\']+)@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.)|(([a-zA-Z0-9\-\']+\.)+))([a-zA-Z]{2,4}|[0-9]{

Re: [PHP] Timezone date/time conversion

I'm sure something like this has already been written and I'd hate to redesign the wheel. I've searched google but came up empty and am wondering if any of you guys have what I am looking for. I ended up writing my own. Hopefully to help anyone else out trying to do the same thing, I've includ

[PHP] Timezone date/time conversion

I'm sure something like this has already been written and I'd hate to redesign the wheel. I've searched google but came up empty and am wondering if any of you guys have what I am looking for. Basically I need a function that will convert a time from one time zone to another. Such that if I p

[PHP] PEAR DB issue

I'm using PEAR::DB to connect to a MS SQL Server 2000. I'm attempting to run the following query: SELECT * FROM myTable FOR XML AUTO, ELEMENTS When I run the above query using the Query Analyzer, I get back the results as expected. However, when I try to run the same query using PEAR, I get the

Re: [PHP] Rasmus' 30 second AJAX Tutorial - [was Re: [PHP] AJAX & PHP]

> function sndReq(action) { > http.open('get', 'rpc.php?action='+action); > http.onreadystatechange = handleResponse; > http.send(null); > } So with AJAX, the data gets sent back to the browser using GET? Is there any way you can do it using POST? thnx, Chris -- PHP General Mailing

Re: [PHP] Ok, why is this happening...

> Chris Boget wrote: > > > echo "if( $originalNet != $calculatedNet ) = " . ( (int)$originalNet !== > > (int)$calculatedNet ) . "\n"; > > Change this to echo out what you're comparing... > echo "if( ". (int)$originalNet ."

[PHP] Ok, why is this happening...

Consider the following test script: set_time_limit( 0 ); echo ''; echo 'Test Rounding Net Premium'; echo ''; echo 'Running test...
'; flush(); echo ''; echo ''; echo ''; echo '
Original NetCommission %<

Re: [PHP] HTML -> PDF PHP Package

> I am looking for a PHP based packaged (though it doesn't necesarily have to > be) that will convert HTML files to their PDF representations; on the fly of > course. Anyone know or have any experience w/this? Thanks in advance, We use htmldoc. http://www.easysw.com/htmldoc/ thnx, Chris -- PHP

[PHP] PEAR and stored procedures

I've tried google and also the PEAR documentation but I can't figure out how to run a stored procedure that uses an OUTPUT parameter. I keep getting an error saying that the variable used as the OUTPUT parameter must be declared. But how can I declare it using PEAR? Has anyone run across this? I

Re: [PHP] domxml_load_mem()/_file()

> If it's because of memory issues then it will indicated by an error > message saying that your script has tried to allocate more than the > allowed memory limit (and it's easy to fix by adjusting this limit in > php.ini) Actually, I'm not getting any error at all. The script just halts. I am o

[PHP] domxml_load_mem()/_file()

Is there a hard limit to the size of the file you can load into the DOM using either of the above functions? I ask because I have a 5mb XML file I'm trying to load and both functions die when used. I've whittled the size down to about 1.5mb and both functions then work. It's not as if it's dying

Re: [PHP] Amy's Site question

> On a site I'm listing measurements in both inches and cm; in the db > they're stored as inches. To convert them to cm I'm doing: > x ($cartoon['art_height'] * 2.54); ?> cm > How can I limit the result of that math to one decimal place, ie, 9.5 > cm, not 9.523 cm? ummm, round()? thnx, Chris

Re: [PHP] linux php editor

> On windows platform I use HomeSite 5.5 and I'm more then happy. I was a big proponent of HS for the longest time until I played around with Visual Slickedit. I very quickly switched and never looked back. VS is infinitely more feature rich than is HS. thnx, Chris -- PHP General Mailing List

Re: [PHP] linux php editor

Slickedit has a linux flavor and is an exceptional IDE (in general; at least, on Windows). http://www.slickedit.com thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] This is happening why?

Run this code: "; } else { echo "'NULL' != 0"; } ?> Is this just a case of PHP converting variable types for comparison? thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Check class definition

> > You can use defined() to check to see if a constant has been > > defined. You can use function_exists() to see if a function > > has been defined. But what can you use to check to see if > > a class has been defined? > class_exists() I found that after it dawned on me to search for the phra

[PHP] Check class definition

You can use defined() to check to see if a constant has been defined. You can use function_exists() to see if a function has been defined. But what can you use to check to see if a class has been defined? thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: htt

Re: [PHP] Delay?

> > Has anyone else noticed significant delays in messages getting posted? > No, no delay on my end. At least 4hrs on my end... thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Questionary Development - Continued

> That being the case, you may want to consider ajax, so that users > answers are recorded as soon as they make them. What's 'ajax'? Link please? thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] DOM: copying from one document to another

> Is there any way I can copy an element from one DOM document to another > without having to dissect the original node/element and create a new > node/element from scratch using the new DOM document and append to it? Never mind. Apparently I can use clone_node(). When I tried that before I was

[PHP] domxml_open_mem()

Consider the following test script: $doc = domxml_new_doc( '1.0' ); $domNode = $doc->create_element( 'Node' ); $node = $doc->create_element( 'NodeChild' ); $textNode = $doc->create_text_node( 'this' ); $node->append_child( $textNode ); $domNode->append_child( $node ); $doc->

Re: [PHP] if(($mydata->address

> This should be easy, but refuses to work: > if( > ($mydata->address != "") > and > ($mydata->addresspublic == "yes") > ) > { > } Are you getting any errors? If so, what are they? Also, shouldn't the code look like this: if( ($mydata->address != "") && ($mydata->addresspublic == "yes") ) { }

[PHP] DOM: copying from one document to another

Consider the following test code: $doc = domxml_new_doc( '1.0' ); $baseDocument = domxml_new_doc( '1.0' ); $domNode = $doc->create_element( 'Node' ); $node = $doc->create_element( 'NodeChild' ); $textNode = $doc->create_text_node( 'this' ); $node->append_child( $textNode );

Re: [PHP] searching tables

> I'd like to know if it is possible to perform a search across multiple > mysql tables within a single query. Look into UNION. thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Same sessions / different domains

> I need to access a website (written in php) using two different > domains (www.foo.com and www.bar.com). I must see the same content. > Since the site uses session and cookie variables I was wondering if > (and how) it's possible to create a session id that is valid for the > domains I'll be usin

Re: [PHP] php resultset restart??

> i've checked the PHP manual but can't find a function for this, perhaps I'm > missing something. > I get a resultset and loop through it but this is in a loop so it only executes > the first time. is this because the resultset is at the end? is there a way to > tell PHP to start at the beginning

Re: [PHP] Round to the nearest X - SOLVED

Thank you for everyone's suggestions. Using them (and a few other things I've found elsewhere), I've come up with the following function: function roundToNearest( $number, $toNearest = 5 ) { $retval = 0; $mod = $number % $toNearest; if( $mod >= 0 ) { $retval = ( $mod > ( $toNearest /

[PHP] Round to the nearest X

I realize this is a dumb question but I just can't come up with an equation that will do this and I don't see an internal PHP function (for version 4.3) that will do this... Basically I need to come up with an equation/algorithm that will round any number up/down to the nearest X. I tried using y

[PHP] MSSqlServer table/field information

Is there a way to programatically get information about a specific table and/or field? And also any constraints that a field has? thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] MSSqlServer table/field information (Solved, kinda)

> Look into the INFORMATION SCHEMA views in SQL Books Online for a > starting point. Excellent tip! Thanks. With the help provided by everyone who replied, I came up with the following: Query to get the primary key(s) for a table sp_pkeys @table_name='' Query to get the column names for a t

Re: [PHP] Sorting table columns dynamically on normalized MySQL tables

> R> Just build a JOIN query and do one query. > Doing a join on four tables is ok? (serious question, not being > facetious). Yes. I've built a query before (for reporting purposes) that join 15 tables... Just make sure the tables are indexed properly. thnx, Chris -- PHP General Mailing List

Re: [PHP] Sorting table columns dynamically on normalized MySQL tables [LONG]

> The actual SELECT statement is as follows: > $sqlCourses="SELECT * FROM " . $tbl_courses . " WHERE courseDate > '" . date("Y-m-d") . "' ORDER BY " . $orderBy . " ASC"; > the $orderBy variable is set via $_GET['orderBy'] which is sent by the > table headers as below: I'm curious why you aren't jo

Re: [PHP] Sorting table columns dynamically on normalized MySQL tables

> I can do that, but is there a better way? How do you all handle > dynamic sorting of normalized DBs? Firstly, what DB are you using? Secondly, just select and sort on the columns. An example query would be: SELECT course.name, location.name, instructor.name FROM course INNER JOIN locat

Re: [PHP] Streaming video BLOBs from MySQL

> If I make one pass and get 1mb of the blob...the > browser is simply going to load that 1mb only, right? > How do I keep looping and refreshing the users > browser, or in this case, flash player? > Thanks for any ideas! Look into flush(); thnx, Chris -- PHP General Mailing List (http://www.p

Re: [PHP] Storing password in cookie

> Please refrain from such speculation, because it does nothing to improve > the state of security within our community. This idea of storing > passwords in cookies is absurd. Is the above sentiment true even if you store the password as some sort of hash (md5 or otherwise)? thnx, Chris -- PH

Re: [PHP] parsing values from a form post

> I can't figure out how to separate these variables and values so that I > can do what I need to do. > I've got > foreach($_POST as $var=>$value) { > } > but can't seem to figure out what to do inside. > Ideas?? What you could do is rename the form field names. Instead of naming the field 'tax0

Re: [PHP] How do I get the first element's key of an array of objects?

>> I don't see a graceful way of finding the first element's key ID. >> Array >> ( >> [3] => fooObject Object >> ( >> [id:protected] => 3 >> [model:protected] => ABC >> [read:protected] => public >> [write:protected] => private >>

[PHP] mySQL outputting XML

If you use the mysql command line tool, you can pass the -X parameter so that all results will be returned in XML format. Is there an easy way to do that in PHP using the native mysql_*() functions w/o having to manually generate the XML using the result set? Or does anyone know if this is possib

Re: [PHP] mail() Alternative?

> I've had a production system moved to a new server. Our geniuses here > have refused to allow sendmail on the server and all my e-mail > functions are now gone. Is there a way around this? I have already > checked the manual, I don't see anything You can always look into utilizing PEAR::M

Re: [PHP] HTML - to - PDF

> Hi All, I have some reports I need converted from HTML to PDF, I'm on a > LAMP box, so does anyone have any free suggestions? Google htmldoc thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] How can i calculate total process time?

> Hi, i wanna ask if anybody knows how to calculate the total process > time of a script. I guess there exists a > function to perform but i dont know which one it is. I mean if u c any > PHP Nuke site, it says this page is produced in seconds. I made > some codes it calculates but i dont beli

[PHP] Class/object storing itself in a database

I have the following Class: class MyClass { function store_myself() { $query = 'INSERT INTO mytable ( myfield ) VALUES ( ' . $this . ')'; $result = mssql_query( $query ); } } which works. Kind of. What I expected was a serialized copy of the object to be stored in the column myfield

[PHP] Appending DOM doc as child in another DOM doc

Is there a way to take an already existing DomDocument object and appending it as a child node within a seperate DomDocument object? Or would I have to pull it apart first and generate new DomNode/DomElement objects using the data then append those DomNode/DomElement objects to the seperate DomDoc

Re: [PHP] DomElement oddness

> Consider the following: Never mind. I'm retarded. :p Sorry, folks. Nothing to see here but an empty brain cavity. Move along. :) thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] DomElement oddness

Consider the following: This function - function setAttribute( $nodeName, $attributeName, $attributeValue ) { $domElement = $this->DOMDocument->get_elements_by_tagname( $nodeName ); if( $domElement ) { echo 'ObjectData: ' . print_r( $domElement,

Re: [PHP] hackers?

> not sure if this is a stupid question, > but im looking for a person or a place that will check or try to "break" a > site. Check out Netcraft. They are very good though quite pricey, however. thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php

Re: [PHP] Replacing whole words only

> The case is what's stopping it from working > a str_replace(strtolower($exceptionphrase) , '' , > strtolower($stringtoparse)) would take the case out of the equation No, that didn't entire quite work, either. The result from this change is "or ldy lughed" and not the desired result of "lady la

[PHP] Replacing whole words only

Is there a way to replace/remove *whole* words from a phrase? For example: 0 ) { foreach( $exceptionsList as $exceptionPhrase ) { $stringToParse = str_replace( $exceptionPhrase, '', trim( $stringToParse )); } $retval = trim( $stringToParse ); } echo 'Retval: ' . $retval .

[PHP] Problem with loose typing

Consider the following: function test() { static $i = 0; $i++; $retval = ( $i <= 10 ) ? $i : ''; return $retval; } while( $bob = test()) { echo $bob . ''; } You would expect the while loop to go on forever just looking at the above code. However, what's happening

[PHP] Hostname

In earlier versions of PHP, you could use the $HOSTNAME global variable to get the server/machine name that is running Apache/PHP. However, that variable is no longer working and I can't seem to find a replacement in any of the super global variables. Is there one? How can you get the server/mac

Re: [PHP] PHP cross platform IDE

> A bit off topic, what are people out there using for PHP IDE's? Thought not specifically a PHP IDE, I use Visual Slick Edit (which is cross platform). It's probably the best IDE I've come across to date. thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: htt

Re: [PHP] Varible calling a define value

> Currently i have a Defiune setup of: > define("THS", "This is a test"); > I also have a string value of > $that='THS'; > When I echo out $that it get THS. > I want to echo out $that and get: > This is a test. > How can I do this? $that = THS You don't want the quotes. thnx, Chris -- PHP Gene

[PHP] Multiple Inheritance

What are some of the things you guys do to get around the fact that classes in php4 can't do multiple inheritance? thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] adding a symbol in front of each line

> Hi there, > I would like to add a > symbol infront of each line I pull out of a database. > Similar to the function seen in online e-mail clients when you click on reply. > Has anybody an idea on how to add a symbol in front of each line?` Should be simple enough using explode() followed by impl

[PHP] Regexp help

What would the regex look like to accept *any* character for a value but the total length of the value can be no greater than 50 characters. The regex I am trying to use is as follows ^[\d\D\w\W\s\S.]{0,50}$ but it doesn't appear to be working... Any ideas? thnx, Chris -- PHP General Mailing

Re: [PHP] add item to end of (multidimensional) array

> You mean like this... > $sub = array > ( > 'name' => 'Ahnold', > 'address' => '123 Someplace Nice', > ); > > $bigArray[] = $sub; Something else that will work is the following: $arrPt =& $Arr[]; $arrPt['name'] = 'bob'; $arrPt['address'] = 'wherever'; thnx,

[PHP] Interrupting instantiation

In PHP4, is there any way to interrupt instantiation of an object? For example, by returning NULL as the return value of the class constructor so that the variable you are assinging the object to is, instead, null? Here's what I'm trying to do: class MyClass { function MyClass() { return N

Re: [PHP] Referencing a "constant" class variable

> A work around I've used in the past has been to use a keyed array such as: > $MyEnums = array( > "is" => "This", > "at" => "That", > "er" => "Other" > ); Only problem is that the above doesn't address my need (which I included in a subsequent post and probably should have included in my initial

Re: [PHP] Referencing a "constant" class variable

> reference like MyClass::MyVar. Don't use PHP5 conventions in PHP4! I'm curious if you tested your code? Did it work? If so, what version of PHP are you using? I copied and pasted the code you provided and got the following error: Parse error: parse error, expecting `','' or `';'' in /usr/loc

Re: [PHP] Referencing a "constant" class variable

> I believe you can make the property static (at least in PHP5): > class MyClass > { > public static $myClassVar = "Bob"; > } > echo MyClass::$myClassVar; // Bob Unfortunately, in PHP4.3.2 that doesn't seem to be working... :( Does anyone know how I can access a class' variable w/o having to insta

[PHP] Referencing a "constant" class variable

If I have a class that looks like this: class MyClass { var $MyClassVar = "Bob"; } is there a way to reference that variable w/o instantiating MyClass? I've tried: MyClass::$MyClassVar MyClass->$MyClassVar MyClass.$MyClassVar nothing works. Is this even possible? I'm using PHP 4.3.2. thnx

Re: [PHP] A question of style....

> > Anything that doesn't use the word 'flava' :) > What if I name all my variables after Rocky characters? ;) Hey! You stole my method! Actually, mine are Rocky and Bullwinkle, but still! :p thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.n

Re: [PHP] shiflett-clock.gif

> Did anyone ever solve the shiflett-clock.gif puzzle? What's the puzzle? thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Best way to allow a user to indicate formatting to be displayed but stored.

> I am looking for the best way to have a user enter information and > format it ... i.e. Bold, Italics, etc... with out havng to use the > HTML commands... > Using PHP4. > Any suggestions... Take a look at the way phpBB does this. thnx, Chris -- PHP General Mailing List (http://www.php.net/) T

Re: [PHP] Split haystack at nth occurrence of needle?

> I've been RTFMing for about an hour and I can't find a string function > to split haystack 'onetwothreefourfive' at the nth > occurrence of needle ''. strpos gives me the position of the first > needle, and strrpos gives me the position of the last needle. But I'm > looking for the position o

[PHP] PHP Workflow Suite

Does anyone know if a workflow suite/engine written in PHP exists? thnx, Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Spammers

> > [snip] > > Hey everyone, don't know about you, but I'm sick of spam and so I've > reported the spammers > [/snip] > Which "spammers" are you referring too? I believe he made reference to them in his original post here: > so if you have a minute and are sick of the garbage from suisse bank a

[PHP] Regular Expression

Why isn't my regex working? From everything that I've read, it should be... $string = "[joebob]"; if( preg_match( '/\[(\s+)\]/i', $string, $aMatches )) { print_r( $aMatches ); } else { echo 'No match was found' . "\n\n"; } Chris -- PHP General Mailing List (http://www.php.net/) To u

Re: [PHP] dynamically building insert/update forms from db

> I believe there is a PEAR library package that does this. You might want to > do some research to see if it fits your needs. Take a look at the following: http://pear.php.net/package/DB_DataObject_FormBuilder Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: ht

Re: [PHP] dynamically building insert/update forms from db

> generate forms but I still have to create each input..i.e > $forms->inputBox(), etc. I want to be able to pass in a table name and have > a form returned to me. How do other's handle this? My first thought is to > have an xml file that maps the database columns to form elements such as > text,

Re: [PHP] HTTP_RAW_POST_DATA

> > same configuration. Where would I look to discover why one > > server would have data held in $HTTP_RAW_POST_DATA > > whereas the other server would not? > Check the value of "always_populate_raw_post_data" in php.ini > on both servers. That was it. Thank you so very much!! Chris -- PHP

[PHP] HTTP_RAW_POST_DATA

I was looking through the documentation and I could not figure out why the following is occuring: On our development server, I have a script that accesses the value of $HTTP_RAW_POST_DATA (upon form submission) and there is data there. However, on our production server, the same code shows no v

Re: [PHP] Include from another URL?

> Include a content from another URL into the current output. I have done > something like this: Look into the fopen() function. I also believe that the file() function can also take a URL, but I'm not sure. Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://

Re: [PHP] PHP editor

> i guess you didn't read the second part of my email that started after > the "ON THE OTHER HAND" line. Ok, yes, I am a retard. :) Chris -never mind me. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] PHP editor

> function cleanFinalOutput($html){ > $return = eregi_replace("\n", "", $html); > $return = eregi_replace("\r", "", $return); > return eregi_replace("\t", "", $return); > } Not to be too pedantic, but you could probably reduce the above to a single line function: function cleanFinalOutput($

Re: [PHP] PHP editor

> > Not exactly... I was not reffering to PHP files... The white spaces > > from a template file will make double the size of certain files when > > they are sent to the browser... So a page of 50 k might have 100 K > > because of those white spaces instead of tabs... For a dial up > > connection t

Re: [PHP] OOP variables

> [quote] > In PHP 4, only constant initializers for var variables are allowed. To > initialize variables with non-constant values, you need an > initialization function which is called automatically when an object > is being constructed from the class. Such a function is called a > constructor (se

Re: [PHP] PHP editor

> What I am looking for is something to work pretty fast, have code > autocompletion (even for functions defined in the included files like zend > does) and also code ident in a similar manner with zend studio Check out Visual Slick Edit. After using many of the more oft suggested editors, I foun

Re: [PHP] converting string to monetary format

> it is number_format http://www.php.net/number_format You can also use either of the following: http://us2.php.net/manual/en/function.sprintf.php http://us2.php.net/manual/en/function.printf.php echo sprintf( '%.02f', 59.9 ); Chris -- PHP General Mailing List (http://www.php.net/) To uns

<    1   2   3   4   5   >