Re: [PHP] html area

2006-02-28 Thread Robert Cummings
On Tue, 2006-02-28 at 02:58, 2wsxdr5 wrote: I am looking for a simple html area text area type editor, similar to to what you find in the phpbbs and Joomla. I don't need a lot of features it is just to edit small snipits of html and I really want it to be very simple to implement. I have

[PHP] HOW update time and date-fields to mysql....

2006-02-28 Thread Gustav Wiberg
Hi there guys! I have used a date-field and a time-field in a mysql-database. How should I update these fields through php? This is my code now (it works fine locally with data on a win-machine, but not on Linux at my webhotel - Time doesn't work at all) function safeQuote($value) { //

Re: [PHP] HOW update time and date-fields to mysql....

2006-02-28 Thread Robin Vickery
On 28/02/06, Gustav Wiberg [EMAIL PROTECTED] wrote: Hi there guys! I have used a date-field and a time-field in a mysql-database. How should I update these fields through php? This is my code now (it works fine locally with data on a win-machine, but not on Linux at my webhotel - Time

Re: [PHP] Re: Strange slowdowns in PHP

2006-02-28 Thread William Lovaton
Ohhh I see now. Yes, it should be putting things into a buffer before sending the data to the client. I guess shutdown function executes after the content have been sent. My users are usually working on LAN connections but sometimes there are network problems and this could be one of the

Re: [PHP] HOW update time and date-fields to mysql....

2006-02-28 Thread matt stone
On 2/28/06, Gustav Wiberg [EMAIL PROTECTED] wrote: Hi there guys! I have used a date-field and a time-field in a mysql-database. $sql = UPDATE tbforum SET; $sql .= question= . safeQuote($frmQuestion); $sql .= , insertDate=' . $dat . '; $sql .= , insertTime=' . time() . '; $sql .=

[PHP] About date time...

2006-02-28 Thread Gustav Wiberg
Hi Thanx for your input about date time... Here's some functions that worked for me after some searching... function currenttime() { $today = getdate(); $ithours = $today[hours]; if (intval($ithours)10) { $ithours = 0 . $ithours; } $itminutes = $today[minutes]; if (intval($ithours)10) {

[PHP] Re: About date time...

2006-02-28 Thread Barry
Gustav Wiberg wrote: Hi Thanx for your input about date time... Here's some functions that worked for me after some searching... function currenttime() { $today = getdate(); $ithours = $today[hours]; if (intval($ithours)10) { $ithours = 0 . $ithours; } $itminutes = $today[minutes]; if

Re: [PHP] About date time...

2006-02-28 Thread Andrei
I don't understand! Why don't u use date function and just format it as u want? Andy Gustav Wiberg wrote: Hi Thanx for your input about date time... Here's some functions that worked for me after some searching... function currenttime() { $today = getdate(); $ithours = $today[hours];

Re: [PHP] Fw: 参加してみませんか?

2006-02-28 Thread Barry
Andrei wrote: u... Nice... I would agree if I would understand something... lol Andy sns-コミュニティー wrote: ■□■ コミュニティー・エンターテイメント ■□■ □■□ ソーシャルネットワーキングサイトに参加してみませんか? □■□ メンバーより招待された方のみで構成されている為、安心快適!! ポイント代・料金等は一切御座いません。全て無料でお使いになれます! http://tada-asobi.com/tada/keijiban3/

[PHP] More CLASS help

2006-02-28 Thread Jason Gerfen
I am not sure if what I am doing here is a problem or not. Pointers? class mySubnet { var $data; function SubnetSettings( $level, $add_vlan, $edit_vlan, $del_vlan ) { $subnets = new mySubnet; } } -- Jason Gerfen When asked what love is: Love is the Jager talking. ~Craig Baldo -- PHP

RE: [PHP] More CLASS help

2006-02-28 Thread jblanchard
[snip] I am not sure if what I am doing here is a problem or not. Pointers? class mySubnet { var $data; function SubnetSettings( $level, $add_vlan, $edit_vlan, $del_vlan ) { } } [/snip] Call the constructor outside of the class. $subnets = new mySubnet; -- PHP General Mailing List

[PHP] usort(): The argument should be an array

2006-02-28 Thread Remember14a
Can anyone comment and fix this error Warning: usort(): The argument should be an array in /home2/wwwabcde/public_html/search/searchfuncs.php on line 300 below is part of the code which gives this error, the line

Re: [PHP] About date time...

2006-02-28 Thread tedd
Thanx for your input about date time... Here's some functions that worked for me after some searching... function currenttime() { -snip- lot's of code. Hi Gustav: Not meaning to embarrass, but your code could be shortened considerably by using date(), like so: Your lengthy -- function

Re: [PHP] More CLASS help

2006-02-28 Thread Jochem Maas
Jason Gerfen wrote: I am not sure if what I am doing here is a problem or not. Pointers? pointers don't 'exist' in php (like they do in C) - oh crap, you meant 'pointers' in the general english language sense. the question would be what are you trying to do? class mySubnet { var

Re: [PHP] usort(): The argument should be an array

2006-02-28 Thread Robin Vickery
On 28/02/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Can anyone comment and fix this error Warning: usort(): The argument should be an array in /home2/wwwabcde/public_html/search/searchfuncs.php on line 300 [...] usort($res, cmp); Put a print_r($res) above

[PHP] usort(): The argument should be an array

2006-02-28 Thread Remember14a
No this doesnt solve error. let me give you more details to understand problem with the said code. go to this link, please. http://www.abcdefg.us/search/search.php in search enter, Justice, you get response without an error. Now enter law, you get error, pasted below, Warning: usort(): The

Re: [PHP] Re: URL output query

2006-02-28 Thread Rafael
Chris wrote: Rafael wrote: Hi Chris, if the only thing you want is to get the domain (having the whole URL) you have more than one way to solve it. Chris -it's a little akward that Chris answered to Chris- already told you about parse_url(), and since we're talking about strings, I

Re: [PHP] usort(): The argument should be an array

2006-02-28 Thread Thorsten Suckow-Homberg
$row[4]; $res[$i]['size'] = $row[5]; $res[$i]['weight'] = $result_array[$row[0]]; $i++; } usort($res, cmp); echo mysql_error(); $res['maxweight'] = $maxweight; $res['results'] = $results; return $res; /**/ } ? That's not enough, we need the part that sits above and

[PHP] Re: usort(): The argument should be an array

2006-02-28 Thread Robin Vickery
On 28/02/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: No this doesnt solve error. let me give you more details to understand problem with the said code. go to this link, please. http://www.abcdefg.us/search/search.php in search enter, Justice, you get response without an error. Now

[PHP] Session problem when upgrading from 4 to 5.

2006-02-28 Thread Matthijs Dijkstra
Hi, Unfortunately it is not possible (for me) to initialise the 'session.save_path' directive in PHP 5. Up to version 4.3.5. there was no problem and the directive was set to '/tmp'. After upgrading to 5.0.2. and later to 5.1.2. I did not succeed in initialising the directive.

Re: [PHP] Re: How can I stop PHP from resolving symlinks?

2006-02-28 Thread Roy Souther
It is and the key word here is Follow as in resolve the real file location before parsing. This is clearly an Apache problem. I have asked this question on a few Apache forums and lists now and have not had any response. Is there any way to make Apache parse the files where it finds them

Re: [PHP] move_uploaded_file and CPU wait state (IO)

2006-02-28 Thread Aleksandar Skodric
Hi, Yes, /tmp is on another disk then the final directory. I shall move it to the same disk (tmp_upload_dir) right now. Question: can I define tmp_upload_dir to be otherwise just for one host in apache conf, like: php_ini upload_tmp_dir /some/dir I am not sure that this works for all PHP

Re: [PHP] Where to put my class files

2006-02-28 Thread Curt Zirzow
On Tue, Feb 28, 2006 at 12:55:18PM +0700, Peter Lauri wrote: Best group member, I want to run the backend of the system under HTTPS for security reasons. The pages in HTTP and HTTPS are both using the same classfiles. Right now I have the class files in httpdocs/classes/ In the

[PHP] working with ini files

2006-02-28 Thread Benjamin Adams
I have created my own ini file. I can read the values into an array fine. but What I want to do is change a value in the ini file. Example file.ini dog = 3 cat = 4 fish = 7 altered file.ini dog = 3 cat = 5 fish = 7 how can I do this, I tried using ini_set but its not working. help would be

RE: [PHP] working with ini files

2006-02-28 Thread Jim Moseby
I have created my own ini file. I can read the values into an array fine. but What I want to do is change a value in the ini file. Example file.ini dog = 3 cat = 4 fish = 7 altered file.ini dog = 3 cat = 5 fish = 7 how can I do this, I tried using ini_set but its not working.

RE: [PHP] working with ini files

2006-02-28 Thread jblanchard
[snip] I have created my own ini file. I can read the values into an array fine. but What I want to do is change a value in the ini file. Example file.ini dog = 3 cat = 4 fish = 7 altered file.ini dog = 3 cat = 5 fish = 7 [/snip] ini_set is for the php.ini, not yours. You will need to open

Re: [PHP] working with ini files

2006-02-28 Thread Aleksandar Skodric
May I presume that your ini file is just simple plain text file? Check then how you can use PHP to handle files: http://nl2.php.net/manual/en/function.file.php http://nl2.php.net/manual/en/function.fopen.php http://nl2.php.net/manual/en/function.fwrite.php Although, I suggest creating such

[PHP] Array sort question

2006-02-28 Thread PHP
Hi, How can I sort a 2 dimensional array by number of elements? Ex: rgArray[0] = ("1","2"); rgArray[1] = ("1"); rgArray[2] = ("1","2","3","4"); rgArray[3] = ("1","2","3"); Now I would like to sort it so I can loop through them from least elements to most (or vice versa): rgArray[1] (now

RE: [PHP] Array sort question

2006-02-28 Thread jblanchard
[snip] How can I sort a 2 dimensional array by number of elements? [/snip] Start by RTFM http://www.php.net/manual/en/function.count.php

Re: [PHP] Array sort question

2006-02-28 Thread Jeremy Privett
[EMAIL PROTECTED] wrote: [snip] How can I sort a 2 dimensional array by number of elements? [/snip] Start by RTFM http://www.php.net/manual/en/function.count.php I love how infinitely helpful people on this mailing list are. It's a wonder people are being turned off to PHP. There's

RE: [PHP] Array sort question

2006-02-28 Thread jblanchard
[snip] I love how infinitely helpful people on this mailing list are. It's a wonder people are being turned off to PHP. There's no one here willing to help new people more than throwing them RTFM responses. [/snip] Are you new here? I would rather teach a man how to fish than give him his supper

Re: [PHP] Array sort question

2006-02-28 Thread Saline Erik
Sometimes I just need a point in the right direction. So RTFM is not so bad. Erik On Feb 28, 2006, at 11:26 AM, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: [snip] I love how infinitely helpful people on this mailing list are. It's a wonder people are being turned off to PHP. There's no

Re: [PHP] Array sort question

2006-02-28 Thread Jeremy Privett
[EMAIL PROTECTED] wrote: [snip] I love how infinitely helpful people on this mailing list are. It's a wonder people are being turned off to PHP. There's no one here willing to help new people more than throwing them RTFM responses. [/snip] Are you new here? I would rather teach a man how to

Re: [PHP] Array sort question

2006-02-28 Thread Jeremy Privett
Saline Erik wrote: Sometimes I just need a point in the right direction. So RTFM is not so bad. Erik If you say so. In that case, jblanchard, I apologize for my outburst. -- Jeremy Privett Director of Product Development Zend Certified Engineer Completely Unique [EMAIL PROTECTED] Phone:

Re: [PHP] Array sort question

2006-02-28 Thread John Nichel
Jeremy Privett wrote: [EMAIL PROTECTED] wrote: [snip] How can I sort a 2 dimensional array by number of elements? [/snip] Start by RTFM http://www.php.net/manual/en/function.count.php I love how infinitely helpful people on this mailing list are. It's a wonder people are being

RE: [PHP] Array sort question

2006-02-28 Thread jblanchard
[snip] If you say so. In that case, jblanchard, I apologize for my outburst. [/snip] Apology accepted. Look, several of us have been on this list for years and have helped several others through their issues. Mailing lists like this (try a C++ newsgroup for example) are much more merciless than

Re: [PHP] About date time...

2006-02-28 Thread Gustav Wiberg
- Original Message - From: tedd [EMAIL PROTECTED] To: php-general@lists.php.net; Gustav Wiberg [EMAIL PROTECTED] Sent: Tuesday, February 28, 2006 4:17 PM Subject: Re: [PHP] About date time... Thanx for your input about date time... Here's some functions that worked for me after

Re: [PHP] Array sort question

2006-02-28 Thread Robin Vickery
On 28/02/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: The array sorting suggestions you provide will not sort based on the number of items in each array, which is what the OP wanted. That's not entirely fair. I would have said his usort() suggestion was a better pointer than a link to count()

RE: [PHP] Array sort question

2006-02-28 Thread jblanchard
[snip] That's not entirely fair. I would have said his usort() suggestion was a better pointer than a link to count() - which gives no hint as to how to sort the list, which is after all what the OP's trying to do. ObSuggestion: function byLength($a, $b) { return sizeof($a) - sizeof($b); }

Re: [PHP] About date time...

2006-02-28 Thread Gustav Wiberg
- Original Message - From: tedd [EMAIL PROTECTED] To: php-general@lists.php.net; Gustav Wiberg [EMAIL PROTECTED] Sent: Tuesday, February 28, 2006 4:17 PM Subject: Re: [PHP] About date time... Thanx for your input about date time... Here's some functions that worked for me after

Re: [PHP] html area

2006-02-28 Thread Grant Young
Tiny_MCE is another fairly simple editor - although I've experienced some quirks that can be quite annoying/tricky. http://tinymce.moxiecode.com/ Regards, Grant -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] About date time...

2006-02-28 Thread Grant Young
Hi Gustav. I'm a swede, and I we use hours 0 - 24. 8 pm = 20 for us. 9 pm = 21 for us 10 pm = 22... and so on... But with date()-function there is 10 pm that shows (and I want 22 to show instead) I'm using PHP 4.0.3... Do I have to use getdate() then? (getdate()-function showed 22...)

Re: [PHP] About date time...

2006-02-28 Thread tedd
Gustav: I'm a swede, and I we use hours 0 - 24. Well... I don't know what I am, but non sum qualis eram. In any event, you want military time -- simple enough -- just change the h to H, like so: echo(Time: . date('H\:\ i\:\ s') . br/ ); You can find more code examples at:

Re: [PHP] About date time...

2006-02-28 Thread Gustav Wiberg
- Original Message - From: Grant Young [EMAIL PROTECTED] To: php-general@lists.php.net Cc: [EMAIL PROTECTED] Sent: Tuesday, February 28, 2006 11:25 PM Subject: Re: [PHP] About date time... Hi Gustav. I'm a swede, and I we use hours 0 - 24. 8 pm = 20 for us. 9 pm = 21 for us 10

[PHP] Basic PDO Questions

2006-02-28 Thread Chris Drozdowski
I have a three quick PDO questions. 1) If a PDOStatement is created within a function or method, is it's server result set connection is automatically freed up when the function returns (I assume so, but want to make sure)? 2) Does setting a PDOStatement to null (PDOStatement = null)

Re: [PHP] move_uploaded_file and CPU wait state (IO)

2006-02-28 Thread Chris
Aleksandar Skodric wrote: Hi, Yes, /tmp is on another disk then the final directory. I shall move it to the same disk (tmp_upload_dir) right now. Question: can I define tmp_upload_dir to be otherwise just for one host in apache conf, like: php_ini upload_tmp_dir /some/dir snip I'm

Re: [PHP] About date time...

2006-02-28 Thread Gustav Wiberg
- Original Message - From: tedd [EMAIL PROTECTED] To: php-general@lists.php.net; Gustav Wiberg [EMAIL PROTECTED] Sent: Tuesday, February 28, 2006 11:34 PM Subject: Re: [PHP] About date time... Gustav: I'm a swede, and I we use hours 0 - 24. Well... I don't know what I am, but

[PHP] fopen failing, permission denied

2006-02-28 Thread Dan Baker
I have the following code snippet: $h = fopen($path/file.txt, 'x+'); And it generates the following error: Warning: fopen(/home/./myarea/file.txt): failed to open stream: Permission denied The path is correct, but the php process doesn't seem to have file permissions in the folder. Is

[PHP] Editing an existing pdf?

2006-02-28 Thread Jay Contonio
I am just looking for someone to point me in the right direction. I need to be able to *edit* an existing pdf, not create a new one. I basically would be adding an image or text from a form to an existing pdf. Does the PDFLib have an overlay function? These will not be 72 DPI pdf's either.

RE: [PHP] Array sort question

2006-02-28 Thread tedd
snip I would rather teach a man how to fish than give him his supper on a silver platter. /snip Write his code and you can reduce his frustration for a day, but teach him to program and you'll frustrate him for life. tedd --

Re: [PHP] working with ini files

2006-02-28 Thread Adam Ashley
On Tue, 2006-02-28 at 13:32 -0500, Benjamin Adams wrote: I have created my own ini file. I can read the values into an array fine. but What I want to do is change a value in the ini file. Example file.ini dog = 3 cat = 4 fish = 7 altered file.ini dog = 3 cat = 5 fish = 7 how can

Re: [PHP] Editing an existing pdf?

2006-02-28 Thread Max Schwanekamp
Jay Contonio wrote: I am just looking for someone to point me in the right direction. I need to be able to *edit* an existing pdf, not create a new one. I basically would be adding an image or text from a form to an existing pdf. Does the PDFLib have an overlay function? These will not be 72 DPI

Re: [PHP] fopen failing, permission denied

2006-02-28 Thread Chris
Dan Baker wrote: I have the following code snippet: $h = fopen($path/file.txt, 'x+'); And it generates the following error: Warning: fopen(/home/./myarea/file.txt): failed to open stream: Permission denied The path is correct, but the php process doesn't seem to have file permissions in

Re: [PHP] Editing an existing pdf?

2006-02-28 Thread Max Schwanekamp
Jay Contonio wrote: With FPDF you have been able to add jpegs or pngs to existing high-res pdfs? I understand adding data using the FDF file but what about an image? Yeah, I use FPDF on a fairly busy site to generate PDFs that have one of various logos embedded. The PDF can be regular 72DPI

Re: [PHP] Different results in function on PHP 4 and PHP 5

2006-02-28 Thread Chris
Stephen Lake wrote: Good Afternoon Folks, After pounding my head into the ground for days over a problem I am having, I decided to post here to see what you guys and girls think. I have a user defined function that outputs categories from a database and assosiated eShops. Now in PHP 4 this

[PHP] Dynamic Form List - how to change values

2006-02-28 Thread Pat
I have a list from a MYSQL database that I am dumping to a screen. I'd like the user to be able to change the quantity on the form for any record on the screen, then post that information back so the user can review it, and I can then update the database. Simple checkout routine. Or so I

[PHP] Re: html area

2006-02-28 Thread juanito
2wsxdr5 wrote: I am looking for a simple html area text area type editor, similar to to what you find in the phpbbs and Joomla. I don't need a lot of features it is just to edit small snipits of html and I really want it to be very simple to implement. I have been looking for the past few

Re: [PHP] Basic PDO Questions

2006-02-28 Thread Curt Zirzow
On Tue, Feb 28, 2006 at 05:48:36PM -0500, Chris Drozdowski wrote: I have a three quick PDO questions. 1) If a PDOStatement is created within a function or method, is it's server result set connection is automatically freed up when the function returns (I assume so, but want to make