Re: [PHP]php and consol interface

2006-01-30 Thread Barry
Gregory Machin wrote: Hi I'm developing a web interface for server admin in php, but the bos has added a complication, he wants ssh / telnet colson for as well, is i posible to create a consol app in php ? My original idea was to have a couple of files that the web interface would you to

[PHP] this line throws up an undefined index.

2006-01-30 Thread Ross
? $filename = basename($_SERVER['SCRIPT_FILENAME']); $link= ../text_only/$filename; ? any ideas how to prevent this error? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] this line throws up an undefined index.

2006-01-30 Thread Jochem Maas
Ross wrote: ? $filename = basename($_SERVER['SCRIPT_FILENAME']); $link= ../text_only/$filename; ? any ideas how to prevent this error? $_SERVER is an array. and also a variable. we can be sure it exists if we are running a webserver php module, so we don't need to test if it's set or not BUT

RE: [PHP] this line throws up an undefined index.

2006-01-30 Thread Albert
Ross wrote: ? $filename = basename($_SERVER['SCRIPT_FILENAME']); $link= ../text_only/$filename; ? any ideas how to prevent this error? From the PHP Documentation: $_SERVER is an array containing information such as headers, paths, and script locations. The entries in this array are created

Re: [PHP] php and consol interface

2006-01-30 Thread Jochem Maas
Gregory Machin wrote: Hi I'm developing a web interface for server admin in php, but the bos has added a complication, he wants ssh / telnet colson for as well, is i your boss has just (theoretically) doubled the ammount of work you have to do, a cmdline interface is not something you bolt on

[PHP] writing multidimensional arrays to file ?

2006-01-30 Thread Gregory Machin
Hi I'm looking for a good example of writing multidimensional arrays, and reading them back . Thanks for you time . -- Gregory Machin [EMAIL PROTECTED] [EMAIL PROTECTED] www.linuxpro.co.za www.exponent.co.za Web Hosting Solutions Scalable Linux Solutions www.iberry.info (support and admin) +27

[PHP] Re: writing multidimensional arrays to file ?

2006-01-30 Thread Barry
Gregory Machin wrote: Hi I'm looking for a good example of writing multidimensional arrays, and reading them back . Thanks for you time . serialize: http://de.php.net/serialize Greets Barry -- Smileys rule (cX.x)C --o(^_^o) -- PHP General Mailing List (http://www.php.net/) To

RE: [PHP] writing multidimensional arrays to file ?

2006-01-30 Thread Albert
Gregory Machin [mailto:[EMAIL PROTECTED] Hi I'm looking for a good example of writing multidimensional arrays, and reading them back . http://za2.php.net/manual/en/function.serialize.php and http://za2.php.net/manual/en/function.unserialize.php Call serialize() when saving the array to the

[PHP] Re: writing multidimensional arrays to file ?

2006-01-30 Thread Barry
Gregory Machin wrote: Hi I'm looking for a good example of writing multidimensional arrays, and reading them back . Thanks for you time . serialize: http://de3.php.net/serialize http://de3.php.net/manual/en/function.unserialize.php Greets Barry -- Smileys rule (cX.x)C --o(^_^o) --

[PHP] PHP 5 Backwards Compatability

2006-01-30 Thread Tod Thomas
Is their a list of portability problems to be aware of when switching from v4 to v5? Maybe a table that compares the two? Thanks. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] writing multidimensional arrays to file ?

2006-01-30 Thread Jochem Maas
Gregory Machin wrote: Hi I'm looking for a good example of writing multidimensional arrays, and reading them back . serialize() and alternatively if you find it handy to be able to manually read the contents of the array written to the file there is also var_export() which can return valid php

Re: [PHP] php and consol interface

2006-01-30 Thread Jochem Maas
Gregory Machin wrote: Thanks for the input .. yes my idea was to use an .ini to store the configs. Do you know of any tutorials for creating php command line interafaces / applications .. The biggest problem is that the 2 interfaces have to share the same config, other wise there could be hug

Re: [PHP] PHP 5 Backwards Compatability

2006-01-30 Thread Silvio Porcellana [tradeOver]
Tod Thomas wrote: Is their a list of portability problems to be aware of when switching from v4 to v5? Maybe a table that compares the two? Thanks. You can start here: http://www.zend.com/php5/migration.php Silvio -- tradeOver | http://www.tradeover.net ...ready to become the King of the

Re: [PHP] PHP 5 Backwards Compatability

2006-01-30 Thread Jochem Maas
Tod Thomas wrote: Is their a list of portability problems to be aware of when switching from v4 to v5? Maybe a table that compares the two? other than the stuff on php.net (no comparison tables exactly) not really - plenty of people on this list that will help you if you run into problems.

[PHP] pcntl_fork?

2006-01-30 Thread Peter Hoskin
Hi, I have written a script to parse a large amount of XML data and insert it into SQL... deals with approx 80,000 rows each time I run it. I cannot successfully complete this script without running out of memory. Is pcntl_fork suitable to overcome this? I have been playing with pcntl_fork

Re: [PHP] writing multidimensional arrays to file ?

2006-01-30 Thread Gregory Machin
Thanks for you input. I will lookinto alt the sugetions. Many thanks/. Have a grate day . On 1/30/06, Jochem Maas [EMAIL PROTECTED] wrote: Gregory Machin wrote: Hi I'm looking for a good example of writing multidimensional arrays, and reading them back . serialize() and alternatively if

Re: [PHP] pcntl_fork?

2006-01-30 Thread Jochem Maas
Peter Hoskin wrote: Hi, I have written a script to parse a large amount of XML data and insert it into SQL... deals with approx 80,000 rows each time I run it. I cannot successfully complete this script without running out of memory. how much memory do you have set as the max? do you have

Re: [PHP] pcntl_fork?

2006-01-30 Thread Peter Hoskin
Jochem Maas wrote: how much memory do you have set as the max? 512mb do you have control over this value? (i.e. is it not locked down by an admin) yes what are you doing with each row? (I imagine that effectively you From each row, I determine what XML files to fetch and parse... the

Re: [PHP] pcntl_fork?

2006-01-30 Thread Jochem Maas
Peter Hoskin wrote: Jochem Maas wrote: how much memory do you have set as the max? 512mb should be enough. :-) just to give it perspective I have a text file I import on at least a weekly basis (someone else does it actually but i wrote the code) that contains 500,000+ lines

Re: [PHP] Collecting info about columns in a table

2006-01-30 Thread Miles Thompson
No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.1.375 / Virus Database: 267.14.23/243 - Release Date: 1/27/2006 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Regular expression

2006-01-30 Thread Barry
Simple reg help please i want to match the last , in a,b,c,d and replace it with and i tried ereg_replace(,([a-zA-z])*$, and ,$string); but i forgot how to add the d which is also matched now back to the and Can you give any good reg_exp sites where to learn it? Its long ago since i used

[PHP] Other than default grey button

2006-01-30 Thread Jevos, Peter
Hi all I'd like to ask you one ( probably ) simple question. I'm using webmail and I want to use other than default php grey button. I found on the pages how to use image instead of the default button. So I changed INPUT TYPE=submit NAME=move_button VALUE=Move to INPUT TYPE=image'

Re: [PHP] Other than default grey button

2006-01-30 Thread David Grant
Peter, You need to investigate CSS. David Jevos, Peter wrote: Hi all I'd like to ask you one ( probably ) simple question. I'm using webmail and I want to use other than default php grey button. I found on the pages how to use image instead of the default button. So I changed INPUT

Re: [PHP] Regular expression

2006-01-30 Thread Silvio Porcellana [tradeOver]
Barry wrote: Simple reg help please i want to match the last , in a,b,c,d and replace it with and Without using a regexp, you could do: code $string = 'a,b,c,d'; $letters = explode(',', $string); $last_letter = array_pop($letters); $final_string = implode(',', $letters) . ' and '

[PHP] Re: Other than default grey button

2006-01-30 Thread Barry
Jevos, Peter wrote: Hi all I'd like to ask you one ( probably ) simple question. I'm using webmail and I want to use other than default php grey button. I found on the pages how to use image instead of the default button. So I changed INPUT TYPE=submit NAME=move_button VALUE=Move to INPUT

Re: [PHP] Other than default grey button

2006-01-30 Thread Jochem Maas
David Grant wrote: Peter, You need to investigate CSS. I would hesitate to add he needs to investigate how to ask decent questions. (Peter your question lacks context, useful details, a clear problem/question and a direct relevance to php) and given the statement default php grey button I

RE: [PHP] Other than default grey button

2006-01-30 Thread Jevos, Peter
Dear Jochem, Thanks a lot for your answer You're right, I know how to change bgcolor in html or set something like this. I'm using Squirrelmail and I need to change its layout. I set some backgrounds color, fonts and this elemtary things. I need to change design of buttons. All I need is some

Re: [PHP][SOLVED] Regular expression

2006-01-30 Thread Barry
Silvio Porcellana [tradeOver] wrote: Barry wrote: Simple reg help please i want to match the last , in a,b,c,d and replace it with and Without using a regexp, you could do: code $string = 'a,b,c,d'; $letters = explode(',', $string); $last_letter = array_pop($letters);

Re: [PHP] Other than default grey button

2006-01-30 Thread John Nichel
Jevos, Peter wrote: Hi all I'd like to ask you one ( probably ) simple question. I'm using webmail and I want to use other than default php grey button. I found on the pages how to use image instead of the default button. So I changed INPUT TYPE=submit NAME=move_button VALUE=Move to INPUT

Re: [PHP] Other than default grey button

2006-01-30 Thread Jochem Maas
Jevos, Peter wrote: Dear Jochem, Thanks a lot for your answer not often I get thanked for ranting (well psuedo-rant, if you had said 'my client demands it, tell me now, it's urgent' at the end of your post it would really have been a rant ;-) You're right, I know how to change bgcolor in

RE: [PHP] Other than default grey button

2006-01-30 Thread Jevos, Peter
Dear Jochem . I know that I'm probably out of this mailing list. I did almost everything , just buttons remains. I looked at the scripts, it is php and I tried to change something but unsuccesfull. Therefore I wrote to this mailing list, cause I thought this is matter of php I visited

[PHP] Re: Regular expression

2006-01-30 Thread Al
Barry wrote: Simple reg help please i want to match the last , in a,b,c,d and replace it with and i tried ereg_replace(,([a-zA-z])*$, and ,$string); but i forgot how to add the d which is also matched now back to the and Can you give any good reg_exp sites where to learn it? Its long ago

Re: [PHP] Other than default grey button

2006-01-30 Thread Barry
Jevos, Peter wrote: Dear Jochem . I know that I'm probably out of this mailing list. I did almost everything , just buttons remains. I looked at the scripts, it is php and I tried to change something but unsuccesfull. Therefore I wrote to this mailing list, cause I thought this is matter of

Re: [PHP] Other than default grey button

2006-01-30 Thread Jochem Maas
Jevos, Peter wrote: Dear Jochem . I know that I'm probably out of this mailing list. I did almost everything , just buttons remains. I looked at the scripts, it is php and I tried to change something but unsuccesfull. Therefore I wrote to this mailing list, cause I thought this is matter of

[PHP] How can I dynamically place a small on a large image?

2006-01-30 Thread Al
I'm working on an application using the html map tag where I'd like to automatically place a small image on a larger image automatically. For example, I've got a table of map coordinates such as: map name=Map area shape=rect coords=469,188,488,205 href=/courses/Start_Locs/Loc_Maps/baes.jpg

Re: [PHP] How can I dynamically place a small on a large image?

2006-01-30 Thread Philip Hallstrom
I'm working on an application using the html map tag where I'd like to automatically place a small image on a larger image automatically. For example, I've got a table of map coordinates such as: map name=Map area shape=rect coords=469,188,488,205 href=/courses/Start_Locs/Loc_Maps/baes.jpg

Re: [PHP] How can I dynamically place a small on a large image?

2006-01-30 Thread Al
Philip Hallstrom wrote: I'm working on an application using the html map tag where I'd like to automatically place a small image on a larger image automatically. For example, I've got a table of map coordinates such as: map name=Map area shape=rect coords=469,188,488,205

[PHP] PHP hosting with multiple domains?

2006-01-30 Thread gryffyn
I know every month or so someone asks What's a good web hosting company to use for my PHP projects?.. I have most of the responses archived and have searched online a bit, but I have a specific wish and was hoping someone else had already found a good hosting company that'd let me do what I

Re: [PHP] PHP hosting with multiple domains?

2006-01-30 Thread Silvio Porcellana [tradeOver]
[EMAIL PROTECTED] wrote: snip / hah.. I'll stop now. Think you get the idea. The convenient management of multiple domains with a hosting provider is my ultimate goal. Go with http://www.hub.org I've got a couple of domains with them - and I think they are great. Silvio -- tradeOver |

Re: [PHP] PHP hosting with multiple domains?

2006-01-30 Thread Richard Davey
On 30 Jan 2006, at 17:34, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: The thing I'm having trouble nailing down is one that might let me host multiple domains under a single hosting account and share bandwidth and HD space. I have a couple of domains that aren't really doing anything

Re: [PHP] PHP hosting with multiple domains?

2006-01-30 Thread Lists
On Jan 30, 2006, at 11:13 AM, Richard Davey wrote: I use Pair Networks (www.pair.com I vote Pair too. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Passing Credentials

2006-01-30 Thread News1
Hi. I asked a similar question last, week, but I don't think I asked it correctly. What I am trying to do is to web into a web server that I control (no problem here). However, from there, I want to be able to click a button on the web page and have multiple web cameras be displayed on my

[PHP] Vbulletin question

2006-01-30 Thread Albert Peschar
Hi. I have a small question ;-). I have a PHP script. I want that script to check if a visitor is logged in, in Vbulletin. I know somebody who did this but he says he doesn't has time to explain. So if a visitor is logged in, in the vbulletin forum and he visits my PHP script, that script has

Re: [PHP] Vbulletin question

2006-01-30 Thread John Nichel
Albert Peschar wrote: Hi. I have a small question ;-). I have a PHP script. I want that script to check if a visitor is logged in, in Vbulletin. I know somebody who did this but he says he doesn't has time to explain. So if a visitor is logged in, in the vbulletin forum and he visits my PHP

[PHP] wiki question

2006-01-30 Thread Jay Blanchard
Howdy all! I have been searching for a PHP wiki that will allow me to use and ODBC connection to a MS_SQL server database. Does anyone know if such an animal exists? Thanks! Jay -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Embed XHTML code using PHP's XSLT processor

2006-01-30 Thread Markus Fuchs
This'll be a rather long post because of the code snippets, so please bear with me. I'm trying to embed XHTML code from a XML file and I'm wondering why PHP's XSLT doesn't indent it correctly. So, this stylesheet: ?xml version=1.0 encoding=iso-8859-1 ? xsl:stylesheet version=1.0

Re: [PHP] PHP hosting with multiple domains?

2006-01-30 Thread Miles Thompson
http://www.hub.org All the flexibility you need, as well as being fast, courteous and responsive. Miles At 01:34 PM 1/30/2006, [EMAIL PROTECTED] wrote: I know every month or so someone asks What's a good web hosting company to use for my PHP projects?.. I have most of the responses archived

Re: [PHP] PHP hosting with multiple domains?

2006-01-30 Thread tedd
I know every month or so someone asks What's a good web hosting company to use for my PHP projects?.. I have most of the responses archived and have searched online a bit, but I have a specific wish and was hoping someone else had already found a good hosting company that'd let me do what I

Re: [PHP] wiki question

2006-01-30 Thread Mike Smith
...dang, hit the reply, not the reply to all...Sorry about that Jay. http://sourceforge.net/projects/phpwiki/ I haven't tried it, but it looks like phpwiki supports adodb/pear, so if you've got you mssql extension loading you should be able to use it. How's that for a product endorsement! Mike

[PHP] Embedding HTML in PHP

2006-01-30 Thread Jedidiah
I apologize for the multi-post if this has reached the group already, but I have never heard any reply back on it, which seems unusual for this group. If I am asking in the incorrect place, could someone please direct me to the correct forum? I send out a daily devotion via a CRON job.

Re: [PHP] Passing Credentials

2006-01-30 Thread Rory Browne
You're still not being very clear. On 1/30/06, News1 [EMAIL PROTECTED] wrote: Hi. I asked a similar question last, week, but I don't think I asked it correctly. What I am trying to do is to web into a web server that I control (no problem here). Web into a web server? However, from

RE: [PHP] Passing Credentials

2006-01-30 Thread News1
Rory, Thanks for the feedback -- I will try to be clearer. Yes, I want to login into a web page and from there get to another webpage. The webcams are on my network. I can access them directly; however, I would like to create a page where several are visible at once. So, I would like to be

Re: [PHP] Embed XHTML code using PHP's XSLT processor

2006-01-30 Thread Björn Bartels
Hi , this happens because a xml-parser (your browser,...) has to remove all spaces, etc.which are not nessesary. hope that helps bb Am $date schrieb $from: This'll be a rather long post because of the code snippets, so please bear with me. I'm trying to embed XHTML code from a XML file and

Re: [PHP] Passing Credentials

2006-01-30 Thread Rory Browne
Sounds like a job for the Session system. On 1/30/06, News1 [EMAIL PROTECTED] wrote: Rory, Thanks for the feedback -- I will try to be clearer. Yes, I want to login into a web page and from there get to another webpage. The webcams are on my network. I can access them directly; however, I

[PHP] Re: secure logon php page

2006-01-30 Thread Kevin McBride
Barry wrote: Alain Roger wrote: Hi, I would like to write a secured logon page but i do not have any idea where to start... i've alreay setup my Apache server for using SSL, but what about the PHP code ? with or without cookie ? crypted or not ? You could also use digital certificates

Re: [PHP] Passing Credentials

2006-01-30 Thread David Tulloh
You want to use sessions, they allow you to store information such as login details between requests. Have a look at a simple tutorial, like this Zend one. http://www.zend.com/php/beginners/php101-10.php News1 wrote: Rory, Thanks for the feedback -- I will try to be clearer. Yes, I want

Re: [PHP] Embedding HTML in PHP

2006-01-30 Thread Miles Thompson
No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.1.375 / Virus Database: 267.14.23/243 - Release Date: 1/27/2006 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Test message - is there content?

2006-01-30 Thread Miles Thompson
I've noticed the past couple of posts to the list do not show any content. So this is a test. If you see content, please reply to me directly, not on the list. Thanks and regards - Miles Thompson -- No virus found in this outgoing message. Checked by AVG Anti-Virus. Version: 7.1.375 / Virus

Re: [PHP] Embedding HTML in PHP

2006-01-30 Thread Richard Correia
Try to pass your content through htmlentities function. You can see the use of this function at http://www.weberdev.com/get_example-4208.html Thanks Rich On 1/31/06, Jedidiah [EMAIL PROTECTED] wrote: I apologize for the multi-post if this has reached the group already, but I have never

Re: [PHP] Embedding HTML in PHP

2006-01-30 Thread Chris
Hi, If you're mailing it somewhere you'll need to wrap it (see wordwrap). The random points are the mail server starting a new line (approx every 1024 characters). Jedidiah wrote: I apologize for the multi-post if this has reached the group already, but I have never heard any reply back on

Re: [PHP] query regard forms in PHP

2006-01-30 Thread Richard Correia
Another die hard question .. huh? Your all problems can be solved if you spend some time on http://weberdev.com. The answer to your question is www.weberdev.com/get_example-3927.html Thanks Richard Correia On 1/29/06, suresh kumar [EMAIL PROTECTED] wrote: hai, i am having 3

[PHP] PHP5 Build - test.php not working

2006-01-30 Thread Tod Thomas
I just built phpV5.1.2 with the same options I used to build php4: ./configure --prefix=/opt/php5 --with-apxs2=/opt/apache/bin/apxs --with-mysql=/opt/mysql --disable-cgi --with-zlib After make install I had libphp5.so in the ./apache/modules directory as expected. I commented out my

Re: [PHP] PHP5 Build - test.php not working

2006-01-30 Thread Richard Correia
I think your webserver is not treating .php as script file. AddType application/x-httpd-php .php http://www.weberdev.com/Manuals/PHP/install.windows.apache2.html The above instructions are for windows, but you will get the idea. Thanks, Rich On 1/31/06, Tod Thomas [EMAIL PROTECTED] wrote:

Re: [PHP] PHP5 Build - test.php not working

2006-01-30 Thread Tod Thomas
Richard Correia wrote: I think your webserver is not treating .php as script file. AddType application/x-httpd-php .php http://www.weberdev.com/Manuals/PHP/install.windows.apache2.html The above instructions are for windows, but you will get the idea. Thanks, Rich I thought about

[PHP] mail sending issues...

2006-01-30 Thread Richard Schilling
I've been troubleshooting mail for a couple of days and searching every mail list archive/documentation/etc I could find. Hoping someone can help me troubleshoot my mail sending problem. I can't get the PHP mail function to send mail properly - even to addresses on the local host. I'm using

Re: [PHP] PHP5 Build - test.php not working

2006-01-30 Thread Richard Correia
can you try httpd -v, which all dynamic modules are listed? Rich On 1/31/06, Tod Thomas [EMAIL PROTECTED] wrote: Richard Correia wrote: I think your webserver is not treating .php as script file. AddType application/x-httpd-php .php

Re: [PHP] pcntl_fork?

2006-01-30 Thread Peter Hoskin
Chris wrote: Hi Peter, If you can get it working can you send me a sample? Certainly... database connections must be CLEAN! Meaning, you should close them when they're no longer needed. Additionally, each fork should open its own DB connection. My completed code: ?

Re: [PHP] pcntl_fork?

2006-01-30 Thread Peter Hoskin
Sharing variables between processes and their forks needs something like shmop or systemv shared memory. Additionally, shared memory only lets you share basic variables and not database resources... or as far as I understand. So, each fork is required to create its own connection to the

[PHP] PHP session_id()

2006-01-30 Thread Jacques
Hi all Is it possible that the PHP engine can generate duplicate session id's for one application? Can one assume that the session id generated and saved in a database will always be unique (never to be repeated)? Regards Jacques -- PHP General Mailing List (http://www.php.net/) To