Re: [PHP] Urgent:Mysql read only, please help?
and i login as root login where? you *nix machine? Else make sure that you connect to the MySql server as a user with enough privilige (read, write, update, delete...) -elias E K L [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hi all, Anybody can help me to fix this problem: ERROR 1036: Table 'trade_account_credit' is read only I just want to update the table and i login as root.But i came across the error, please help. It's very urgent. _ Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Life of environment variable set put putenv()
never tried it though...but through my experience i would say: The Environment values that are set within a script can be seen only within child scripts (ie when script1.php spwans scrip2.php) -elias Arcady Genkin [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I could not find this in the docs, but maybe I've been looking in the wrong place. Could someone give me an authorative answer or point me to it someplace else, to the question: When you set an environment variable with putenv(), is there a chance that it would be visible to any other PHP script served by the same apache child? Many thanks, -- Arcady Genkin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Header Location problem with PHP as CGI
Hello, I'm desperate here... I hope this question hasn't been asked a million times before (I sure did not find an answer in the archives) I'm developing a site that runs perfectly on a surver with the PHP module in apache. The problem is that the site will be hosted on a server with PHP as CGI (from PHPinfo: Configure Command './configure' '--prefix=/usr/local/php' '--enable-static' '--enable-safe-mode=yes' '--enable-track-vars=yes' '--enable-memory-limit=yes' '--enable-short-tags=no' '--with-gd=/usr/local' '--with-mysql=/usr/local/mysql' '--enable-force-cgi-redirect' ) I have a couple of Header: Locations in the site that are not working properly. The redirect actualy happens BUT the address in the addressbar of the browser doesn't change. A little example: the first time someone visits he has to choose his language. At that moment a cookie is set. The next time he reaches the www.site.com/index.html some code checks for the cookie and he should get redirected to the first page in his language that is www.site.com/language/home/index.html What actualy happens is that he gets to see the page but in the addressbar it still shows www.site.com/index.html This gives a couple of ptoblems: when the user clicks refresh on his browser, the address in the addressbar gets refreshed. on that first page there is a java applet that doesn't get found (it looks for it in the root instead of in the home-directory. I hope this all is a littlebit understandable ... I don't know if this is important but I added a .htaccess in the root that forces .html to get parsed as php: *** Action application/x-httpd-php /cgi/php.cgi AddHandler application/x-httpd-php .html *** I don't think this has something to do with it but I add it just in case. Thanks to anyone who can shed some light on my problem! Bert please check my email address if you would like to mail me -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] file()
On Saturday 19 May 2001 01:27, elias wrote: hello, i have my file which reads like: dir3/dir3-3/ dir2/ dir1/ s [...] as you noticed that in each element of the array $a a space is appended for an unknown reason! Wild guess: You're on a Unixy server and the file is in DOS format (CRLF endings)? -- Christian Reiniger LGDC Webmaster (http://sunsite.dk/lgdc/) Very funny, Scotty! Now beam up my clothes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] globalize all variables not coming from a certain form...
Hi everybody, Is it possible (and if it is, how) to globalize all the variables, that come from some form, automatically? For example: function do_something(){ global $form; if($form != func){ /* globalize all the variables that come from a form called $form . How to do it? */ } } Yes, I could it manually - global $firstname,$lastname,$addres, etc etc...but the function is being used by different scripts and I need to globalize only these variables that come from that particular form ... and all that 'automatically'. Any ideas? Thanks, Siim Einfeldt -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] adodb 1.10 released
http://php.weblogs.com/adodb Database wrapper library 1.10. Now supports cached recordsets. Example below: include('adodb.inc.php'); include('tohtml.inc.php'); $ADODB_CACHE_DIR = '/usr/local/adodbcache'; $conn = ADONewConnection('oracle');/* Oracle 8, use 'oci8' */ $conn-PConnect('','scott','tiger'); $rs = $conn-CacheExecute(15,'select * from table'); rs2html($rs); /* recordset to html table */ The 15 in CacheExecute() indicates that the recordset will be cached for 15 seconds. Subsequent calls with this SQL statement will use the cached results until the 15 seconds expires. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
php-general Digest 19 May 2001 11:52:01 -0000 Issue 695
php-general Digest 19 May 2001 11:52:01 - Issue 695 Topics (messages 53497 through 53514): Re: PHP and XHTML 53497 by: dempsejn.georgetown.edu 53498 by: Brian Clark Network Connectivity help please 53499 by: Brian 53502 by: Mohamed LRHAZI 53503 by: Brian Mac IE 5.0 upload problem 53500 by: Jason Lam 53504 by: Julian Wood Life of environment variable set put putenv() 53501 by: Arcady Genkin 53510 by: elias Urgent:Mysql read only, please help? 53505 by: E K L 53509 by: elias Date and Time Functions like MySQL? 53506 by: Chris Lee Re: Server limits/recommendations 53507 by: John Lim weird error! 53508 by: elias Header Location problem with PHP as CGI 53511 by: Bert Re: file() 53512 by: Christian Reiniger globalize all variables not coming from a certain form... 53513 by: Siim Einfeldt aka Itpunk adodb 1.10 released 53514 by: John Lim Administrivia: To subscribe to the digest, e-mail: [EMAIL PROTECTED] To unsubscribe from the digest, e-mail: [EMAIL PROTECTED] To post to the list, e-mail: [EMAIL PROTECTED] -- i won't pretend to be an XML guru, but isn't saying php won't work with XHTML akin to saying php won't work with javascript1.3, dhtml, netscape 6 etc? php generates code...html, dhtml, whatever...i fail to see how php couldn't generate what anyone would need for XHTML, or anything else along those lines -jack - Original Message - From: Rasmus Lerdorf [EMAIL PROTECTED] Date: Friday, May 18, 2001 6:59 pm Subject: Re: [PHP] PHP and XHTML I would like to start using the XHTML syntax for my future projects, but I heard that PHP is not compatible with XHTML. For example, in XHTML the ID attribute is used in place of the deprecated NAME tag. But PHP depends on the NAME attribute in forms, etc. Is there any way around this? Has anyone used XHTML and PHP together successfully, and if so how did you get around the previously mentioned problem? Any help woould be much appreciated, thanks in advance. Completely false. PHP works fine with XHTML. -Rasmus -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: php-list- [EMAIL PROTECTED] Hi Rasmus, @ 6:59:09 PM on 5/18/2001, Rasmus Lerdorf wrote: I would like to start using the XHTML syntax for my future projects, but I heard that PHP is not compatible with XHTML. For example, in XHTML the ID attribute is used in place of the deprecated NAME tag. But PHP depends on the NAME attribute in forms, etc. Is there any way around this? Has anyone used XHTML and PHP together successfully, and if so how did you get around the previously mentioned problem? Any help woould be much appreciated, thanks in advance. Completely false. PHP works fine with XHTML. In fact, I wrote a Swiss Army Chain Saw type of class, that started out as an XHTML class of sorts, to speed up my development. Navid, are you sure you aren't confusing XHTML with XML? -Brian -- PGP is spoken here: 0xE4D0C7C8 Please, DO NOT carbon copy me on list replies. I'm writing a script to help us manage one of our Class C networks. The page loads all of the host IPs, who owns them, phys desc. of the box, and does a forward reverse lookup on all of the addresses. I'd like to add a column that shows which machines are currently reachable on the network. A simple ping would probably be easiest, but parsing a standard ping for 254 hosts would cause the script to have about a 10 minute load time. are there any quick easy, and most importly, low system overhead, solutions to this problem? Brian Artiaco [EMAIL PROTECTED] Brian, Why don't leave the pinging to some other script, and have that other script run continuesouly and upfate a sql table with the ststus of each and time stamp of when it was last ping'ed...etc Mohamed~ Brian wrote: I'm writing a script to help us manage one of our Class C networks. The page loads all of the host IPs, who owns them, phys desc. of the box, and does a forward reverse lookup on all of the addresses. I'd like to add a column that shows which machines are currently reachable on the network. A simple ping would probably be easiest, but parsing a standard ping for 254 hosts would cause the script to have about a 10 minute load time. are there any quick easy, and most importly, low system overhead, solutions to this problem? Brian Artiaco [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] Good point, I considered,
[PHP] more on problem
As a follow up on my last post, the following works on my Windows system but not on my Unix system: $Type = filetype($Directory); On Unix it always returns a null value. Urb -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Netscape 6, What a piece of s$#@ , anyone else had problems with php and Netscape 6?
Brandon, might I suggest that you start using the HTML Validator at www.w3.org if you intend to write HTML that is viewable in Netscape 6.x. As pointed out by many others, Netscape 6 is a browser which does things according to W3C specs (mostly... a lot better than most other browsers anyway) and you are quite clearly not aware of what those specs are. I tried validating your HTML shown below. It is not even close to being valid HTML 4.01 Transitional, which is the loosest standard anyone should aim for at the moment (for the general progression of the WWW as a unity). Try the validator. It really is quite nice, and it *will* teach you how to write compliant HTML. Regards, Jakob Kruse Brandon Orther [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... This is the HTML that is returned by PHP. Does anyone know why Netscape Would have problems viewing it? html head titleControl Maestro Menu System/title meta http-equiv=Content-Type content=text/html; charset=iso-8859-1 link rel=stylesheet href=menu.css type=text/css /head body bgcolor=#FF text=#00 MARGINWIDTH=0 LEFTMARGIN=0 MARGINHEIGHT=0 TOPMARGIN=0 background=../html/gray-background.giftable width=100% height=100% border=0 cellspacing=0 cellpadding=0 tr td valign=top table width=100% border=0 cellspacing=0 cellpadding=0 tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Web%20Mailimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=Web%20MailWeb Mail/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Account%20Managmentimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=Account%20ManagmentAccount Managment/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Supportimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=SupportSupport/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Billingimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=BillingBilling/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Domain%20Managmentimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=Domain%20ManagmentDomain Managment/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Business%20Centerimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=Business%20CenterBusiness Center/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr /table /td td background=menu_edge.gif width=8img src=menu_edge.gif/td/tr/table /body /html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] hosting closed web application for multiple users
I have a requirement like this: - the php script should be runnable by httpd user only. - the php script will include other files. - the php script should run as the user. - the user must not be able to access the source code of the scripts. What I can think of so far: Put the script in a directory only accessible by the httpd user (www), e.g.: # mkdir -p /home/app # cp script.php /home/app # chown root.www /home/app # chmod 550 /home/app # chown root.root /home/app/script.php # chmod 555 /home/app/script.php So script.php is safe from the user (except when somehow the user manages to get its current directory changed to /home/app, where then she can take script.php easily). To prevent the user getting her hands to the script.php via www user, I set the Apache configuration: Options SymLinksIfOwnerMatch to prevent the user linking to /home/app or /home/app/script.php (unless the user can trick www or some other privileged user to create the link for her). and makes sure that Apache only runs wrapped CGI scripts, and php runs as a cgi binary and not server module. Now I just need to make sure that: 1) user cannot trick script.php to read and display itself out to the browser, or copy itself to some public directory. 2) user cannot trick other root processes to read script.php for her. Is there a better alternative? Regards, Steve -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] mail() problem
Hi, Below the code i use. Everything works, the $mailto variable is buils up from a database and contains more then one email adresses. Now my question: how can i make the receivers of my message NOT to see the email addresses of all the receivers, so then can't reply to all? $mail =$mailto; $title =$subject; $mess = $message; mail($mail, $title, $mess, From: [EMAIL PROTECTED]\nReply-To: [EMAIL PROTECTED]\nContent-Type: text/html; charset=iso-8859-1); Thanks! -- Mark Wouters eXpanded Media Web Designer -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] hosting closed web application for multiple users
snip 2) user cannot trick other root processes to read script.php for her. Is there a better alternative? /snip Depending on your budget yes there is. Zend has a PHP encoding utility which performs two functions, first off since it needs to run through their optimizer your PHP scripts will tend to run faster (at the expense of a bit more memory consumption) and also you don't need to worry about preventing the source code from being read as the php scripts are converted into a binary executable. License to use these programs are I believe around $600 per year but offer a wide range of additional features but I would consider it well worth it to a company rather than spending countless tech hours and security testing to prevent the source from being viewed. http://www.zend.com Sincerely, Craig Vincent -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] mail() problem
snip Below the code i use. Everything works, the $mailto variable is buils up from a database and contains more then one email adresses. Now my question: how can i make the receivers of my message NOT to see the email addresses of all the receivers, so then can't reply to all? /snip The simpliest thing to do would be to break up the $mailto into an array with a separate field for each email address you need then use a foreach loop on the array to send out individual mailings. Or to better improve efficiency don't even put the addresses into an array but rather send out the mail in the routine that grabs the email addresses out of your database. Depending on the number of emails you need to send out this is actually a much better solution than just sending out a mail with 50 or 100 email address in the To/CC/BCC adresses. With the majority of my systems I can pump out around 1000 - 1500 individual emails per minute with minimal resources consumed on the system so a solution of this nature more than likely will work out in your favor. Sincerely, Craig Vincent -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] hosting closed web application for multiple users
Actually, We _are_ considering of buying Zend Encoder, but in the middle of thinking for alternatives... :-) However, sometimes vendors do not want user to have access to the _binary also_ (and then run it somewhere else), so that needs some extra protection other than the Encoder too. Regards, Steve At 19/05/2001 21:47, Craig Vincent wrote: snip 2) user cannot trick other root processes to read script.php for her. Is there a better alternative? /snip Depending on your budget yes there is. Zend has a PHP encoding utility which performs two functions, first off since it needs to run through their optimizer your PHP scripts will tend to run faster (at the expense of a bit more memory consumption) and also you don't need to worry about preventing the source code from being read as the php scripts are converted into a binary executable. License to use these programs are I believe around $600 per year but offer a wide range of additional features but I would consider it well worth it to a company rather than spending countless tech hours and security testing to prevent the source from being viewed. http://www.zend.com Sincerely, Craig Vincent -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] mail() problem
Below the code i use. Everything works, the $mailto variable is buils up from a database and contains more then one email adresses. Now my question: how can i make the receivers of my message NOT to see the email addresses of all the receivers, so then can't reply to all? Send the message to yourself and put the string into a BCC field which can be configured in the fourth argument. Urb $mail =$mailto; $title =$subject; $mess = $message; mail($mail, $title, $mess, From: [EMAIL PROTECTED]\nReply-To: [EMAIL PROTECTED]\nContent-Type: text/html; charset=iso-8859-1); Thanks! -- Mark Wouters eXpanded Media Web Designer -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Color of Pixel
Hello ! I got a jpg-picture on my disk. Is there any way to find out the color of a pixel (let's say, I want to know, which color the pixel 1,12 on image img.jpg is.) Ideas ? Martin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Urgent! Need help on semaphores
Hi! I am writing a chat program with php and mysql using semaphores, shared memory and sessions. Chatters A and B will both be using a common file where semaphores are acquired in a while loop. To my grief, the chatting was found to hang at around 50 mins mostly, though other instances of 9 or 20 mins have occurred too. I tracked it down and found that semaphore id gotten using sem_get(2000, 1) will be around 40989 (the max so far). Then the program cannot proceeds because it stucks at sem_get. It just cannot get past that and that causes my connection to mysql processes to sleep when I do a show processlist. Then it hangs the web server because any new connection to mysql will go to sleep mode. The httpd processes can go up to 100 and mysql processes are still quite small like 8. shm_attach(2000, 524288) was used. Didn't sem_release or sem_remove causes the semaphore id gotten using sem_get to be reusable? Why the number keeps jumping and finally dies @ around 40989? Is there a way to increase the semaphore id gotten using sem_get to prolong the lifespan of the program? Or should I copy the php file so that each chatter has its own php file to run? Please advice. Thankyou. Regards -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] The performance of sleep() and usleep()
If i use these functions in my script, what will be the system resource usage? I know, thread will be open while the script is running but, i believe that they will not use extra system resource, won't they? For example, i want to send 10 emails every 30 seconds. Assume that there are 1,000,000 emails. So; for(from 1 to 1,000,000 count) { send 1 email increase couner if counter = 10 emails then sleep(30) else continue } And assume that this for loop will take 10 hours to finish. Will it use the same or higher system resource while it has entered to sleep mode? Thanks for your help -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] count() multidimensional array
I have a multidimensional array being created by a form. Most fields are pre-populated with a few that people can add to the list. There is a box beside each row that they can check whether that item is in or not. My code to list only the rows that were checked is this.. for ($j=1 ; $j=5; $j++) { for ($i=0 ; $icount($check[$j]) ; $i++) { if ($check[$j][$i] == 1)//was boxed checked? { $message .= $pre[$j][$i]. .$post[$j][$i]. .$name[$j][$i]. .$city[$j][$i]. .$state[$j][$i]\n; } } } This code is creating an endless loop and times out the server with memory overruns. What am I missing? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Color of Pixel
I got a jpg-picture on my disk. Is there any way to find out the color of a pixel (let's say, I want to know, which color the pixel 1,12 on image img.jpg is.) Ideas ? http://php.net/imagecolorat -Rasmus -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] hosting closed web application for multiple users
The only idea i have is not perfect, but would stop people without time on their hands from getting your code. (But it could be time consuming for you (but free)) 1) make the source code a string 2) encrypt it, (but try use bizzare, unheard of functions so that it takes longer to work out how to decrypt it) 3) when running the code decrypt it, (use some hash to check the code has been decrypted ok) 4) eval() the code If some code was encrypted as above so people didn't have too much of a clue what was happening. 1) make the code include(httP://www.yoursite.com/code-custid=43824;); 2) maybe cache it on the server for a period of time (otherwise every execution would hit your server, and performance would certainly drop). Assuming the code works, doesn't bring in gaping security holes, and performance doesn't suffer too much then this could be used in a situation, that if someone doesn't pay renewal of license fess (or you fall out with them), you can revoke their access to your code. This would probably work much better if it is a binary from Zend, as people would have the binary, but without getting the ok from your server then the binary stops working. I've used the principle in Visual Basic (where code is compiled so quite safe), and been able to stop people using my software for ever. Not tried it in PHP though... If this is a stupid idea, don't shoot me, I've slept for the 30 hours, and instead of working to get projects finsihed, I'm answering newsgroups ;-) I'd be interested to hear what others think anyway Yours Mr. Adam ALLEN. [EMAIL PROTECTED] http://www.dynamicinteraction.co.uk -Original Message- From: Steven Haryanto [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 19, 2001 3:56 PM To: Craig Vincent Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: [PHP] hosting closed web application for multiple users Actually, We _are_ considering of buying Zend Encoder, but in the middle of thinking for alternatives... :-) However, sometimes vendors do not want user to have access to the _binary also_ (and then run it somewhere else), so that needs some extra protection other than the Encoder too. Regards, Steve At 19/05/2001 21:47, Craig Vincent wrote: snip 2) user cannot trick other root processes to read script.php for her. Is there a better alternative? /snip Depending on your budget yes there is. Zend has a PHP encoding utility which performs two functions, first off since it needs to run through their optimizer your PHP scripts will tend to run faster (at the expense of a bit more memory consumption) and also you don't need to worry about preventing the source code from being read as the php scripts are converted into a binary executable. License to use these programs are I believe around $600 per year but offer a wide range of additional features but I would consider it well worth it to a company rather than spending countless tech hours and security testing to prevent the source from being viewed. http://www.zend.com Sincerely, Craig Vincent -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Unix problem
while ($Directory=readdir($DirHandle)) { $IsFile = is_file($Directory); $IsDir = is_dir($Directory); echo is file=$IsFile - is dir=$IsDir\n; Works fine on Windows box, on a Unix box (RedHat) both is_file() and is_dir() return null no matter what the contents of $Directory is. This is a wild guess.. UPPER and lowercase used instead of only upper of only lowercase.. Spaces in file or directory names.. Bye, B. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] hosting closed web application for multiple users
-Original Message- From: Steven Haryanto [mailto:[EMAIL PROTECTED]] I have a requirement like this: - the php script should be runnable by httpd user only. - the php script will include other files. - the php script should run as the user. - the user must not be able to access the source code of the scripts. Take a look at apc (apc.communityconnect.com), it is primarily a cache, which will boost your performace, but also allows you to take the cached compiled files from the file system and distribute them. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] hosting closed web application for multiple users
btw, have people tried apc 1.0.9 with php-4.0.5? apc runs fine for some of my scripts (though performance improvement is not great at all, or am i doing something wrong). but for some of my more complex scripts, it crashes the httpd binary with segfaults. btw, can you just take the compiled cache file and distribute it? does the file need to be run with apc also? or can the plain zend engine handle it? steve At 19/05/2001 22:45, Matthias Winkelmann wrote: -Original Message- From: Steven Haryanto [mailto:[EMAIL PROTECTED]] I have a requirement like this: - the php script should be runnable by httpd user only. - the php script will include other files. - the php script should run as the user. - the user must not be able to access the source code of the scripts. Take a look at apc (apc.communityconnect.com), it is primarily a cache, which will boost your performace, but also allows you to take the cached compiled files from the file system and distribute them. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Life of environment variable set put putenv()
[EMAIL PROTECTED] (elias) writes: Arcady Genkin [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I could not find this in the docs, but maybe I've been looking in the wrong place. Could someone give me an authorative answer or point me to it someplace else, to the question: When you set an environment variable with putenv(), is there a chance that it would be visible to any other PHP script served by the same apache child? never tried it though...but through my experience i would say: The Environment values that are set within a script can be seen only within child scripts (ie when script1.php spwans scrip2.php) In case anyone was following, the issue has been resolved. Have a look at http://www.php.net/bugs.php?id=10970 Awesome bug resolution turnaround! -- Arcady Genkin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Unix problem
while ($Directory=readdir($DirHandle)) { $IsFile = is_file($Directory); $IsDir = is_dir($Directory); echo is file=$IsFile - is dir=$IsDir\n; Works fine on Windows box, on a Unix box (RedHat) both is_file() and is_dir() return null no matter what the contents of $Directory is. This is a wild guess.. UPPER and lowercase used instead of only upper of only lowercase.. Spaces in file or directory names.. Thanks for the suggestion but if I have: while ($Directory=readdir($DirHandle)) { $IsFile = is_file($Directory); $IsDir = is_dir($Directory); echo is file=$IsFile - is dir=$IsDir\n; echo name=$Directory\n; It displays the name of the file or directory correctly. Urb Bye, B. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] attachements in mail()
Hi, I've another question.. is it possible to send attachements with mail() ?? Thanks, -- Mark Wouters eXpanded Media Web Designer Parijsstraat 74, B-3000 Leuven - Louvain Tel: +32 (16) 31.10.12 Fax: +32 (16) 31.10.19 E-mail: [EMAIL PROTECTED] URL: http://www.expandedmedia.be -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Command output into any array?
Hello, Is it possible to have the contents of a shell_exec command go into an array? I have the following in my PHP script: ? $user=$PHP_AUTH_USER; $command=command.sh; $output=shell_exec($command $user); ? Which calls a shell script dirlist.sh, which returns results similar to the following: www www/docs www/test Is it possible to have each line put into an array? so that it would look like: $results = array(www, www/docs, www/test); The shell script has dynamic output, so the number of lines, and line content wouldn't be the same on every execution. I would like to use a foreach loop to put the output from the script into a form, so I am just wondering if the command/array scenerio is possible. Thank you for any help, Ken Jansons E-Mail: [EMAIL PROTECTED]
[PHP] Getting email out of a database
I am trying to pull all the e-mail address out of a database to be able to do a mass send. This gets me all the e-mail address and puts a , between them which is what I want. $sql = SELECT CONCAT(email) AS str_email FROM customers; $result = mysql_query($sql); $recip = array(); while ($myrow = mysql_fetch_array($result)) $recip[] = $myrow[str_email]; $recipient_list = implode(, ,$recip); I t gives me this list which is what I wanted [EMAIL PROTECTED],[EMAIL PROTECTED],[EMAIL PROTECTED],[EMAIL PROTECTED] But now I would like to get the first address in the list into a variable and the rest in the list to a second variable Like this $v1= [EMAIL PROTECTED] $v2= [EMAIL PROTECTED],[EMAIL PROTECTED],[EMAIL PROTECTED] How would I go about this Best regards, Richard mailto:[EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Getting email out of a database
how about grabbing the first result out of the 'while'??? something like: list($var1) = mysql_fetch_row($result); while( list($email) = mysql_fetch_row($result) ) $var2[] = $email; hope this helps... At 11:04 19/5/2001 -0700, Richard Kurth wrote: I am trying to pull all the e-mail address out of a database to be able to do a mass send. This gets me all the e-mail address and puts a , between them which is what I want. $sql = SELECT CONCAT(email) AS str_email FROM customers; $result = mysql_query($sql); $recip = array(); while ($myrow = mysql_fetch_array($result)) $recip[] = $myrow[str_email]; $recipient_list = implode(, ,$recip); I t gives me this list which is what I wanted [EMAIL PROTECTED],[EMAIL PROTECTED],[EMAIL PROTECTED],[EMAIL PROTECTED] But now I would like to get the first address in the list into a variable and the rest in the list to a second variable Like this $v1= [EMAIL PROTECTED] $v2= [EMAIL PROTECTED],[EMAIL PROTECTED],[EMAIL PROTECTED] How would I go about this Best regards, Richard mailto:[EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] . Christian Dechery (lemming) . http://www.tanamesa.com.br . Gaita-L Owner / Web Developer -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] vpopmail functions
its great to see vpopmail support in 4.0.5. but i can't find any documentation on functions. what are the functions and their parameters. does anybody know? thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Command output into any array?
accually php allready has this command and you are so close to it :) ?php $user = $PHP_AUTH_USER; $command = 'command.sh'; exec($command $user, $result); ? -- Chris Lee [EMAIL PROTECTED] Ken Jansons [EMAIL PROTECTED] wrote in message 001d01c0e08c$54601480$[EMAIL PROTECTED]">news:001d01c0e08c$54601480$[EMAIL PROTECTED]... Hello, Is it possible to have the contents of a shell_exec command go into an array? I have the following in my PHP script: ? $user=$PHP_AUTH_USER; $command=command.sh; $output=shell_exec($command $user); ? Which calls a shell script dirlist.sh, which returns results similar to the following: www www/docs www/test Is it possible to have each line put into an array? so that it would look like: $results = array(www, www/docs, www/test); The shell script has dynamic output, so the number of lines, and line content wouldn't be the same on every execution. I would like to use a foreach loop to put the output from the script into a form, so I am just wondering if the command/array scenerio is possible. Thank you for any help, Ken Jansons E-Mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Lookin For Programmer
Hmmm anyone looking to join me in making a bb called BestBoard? email me at [EMAIL PROTECTED] not thru the list! (note if these are not supposed to go on this list 1 flame will be suffiecent thanks!) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] count() multidimensional array
can't say for sure, but a good guess is some problems with undefined vars. try using fforeach insted, its alot simpler. ?php foreach($check as $j_pos = $j_val) foreach($check[$j_pos] as $i_pos = $i_val) $message .= {$pre[$j_pos][$i_pos]} {$post[$j_pos][$i_pos]} {$name[$j_pos][$i_pos]} {$city[$j_pos][$i_pos]} {$state[$j_pos][$i_pos]} \n; ? input type='checkbox' name='check[0][0]' value='1' checked input type='checkbox' name='check[0][1]' value='1' input type='checkbox' name='check[1][0]' value='1' checked input type='checkbox' name='check[1][1]' value='1' checked input type='checkbox' name='check[2][0]' value='1' input type='checkbox' name='check[2][1]' value='1' input type='checkbox' name='check[3][0]' value='1' input type='checkbox' name='check[3][1]' value='1' checked ok, now we have an example, $check[0][0] $check[1][0] $check[1][1] $check[3][1] are set, the others are not. you can see why 'for($c = 0; $c count($check); $c++)' will not work. foreach simplifies things alot. you also do not need to check 'if ($check[$j][$i] == 1)' becase if it is set at all, then it 'had' to be checked. Is this what you were looking for ? -- Chris Lee [EMAIL PROTECTED] Dean Martin [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... I have a multidimensional array being created by a form. Most fields are pre-populated with a few that people can add to the list. There is a box beside each row that they can check whether that item is in or not. My code to list only the rows that were checked is this.. for ($j=1 ; $j=5; $j++) { for ($i=0 ; $icount($check[$j]) ; $i++) { if ($check[$j][$i] == 1)//was boxed checked? { $message .= $pre[$j][$i]. .$post[$j][$i]. .$name[$j][$i]. .$city[$j][$i]. .$state[$j][$i]\n; } } } This code is creating an endless loop and times out the server with memory overruns. What am I missing? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Mailserver?!
Hi! I want to have a mailapp on my server (win32) wich writes all incoming mails to a MySQL db. Is this possible? - Fredrik A. Takle [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Expense
Does anyone know where I can find some type of Expense Report/Tracking system written in PHP? I'm tired of tracking all my stuff in Excel and sending it in so I thought I'd take a crack at making an online tracking system for multiple employees that could possibly export to Excel if needed. Thanks for any help :-) Clayton DukesCCNA, CCDA, CCDP, CCNPDownload Free Essays, Term Papers and Cisco Training from http://www.gdd.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] globalize all variables not coming from a certain form...
I hate using global variables this way in functions, but it can be done. ?php function test() { global $HTTP_POST_VARS; if ($HTTP_POST_VARS['form'] == 'func') foreach($HTTP_POST_VARS as $pos = $val) global $pos; // reset of your code. } ? there are good reasons for global variables, but use them wisely, globals are offten missused and create illegible code. most variables should be passed as arguments to the function. -- Chris Lee [EMAIL PROTECTED] Siim Einfeldt aka Itpunk [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hi everybody, Is it possible (and if it is, how) to globalize all the variables, that come from some form, automatically? For example: function do_something(){ global $form; if($form != func){ /* globalize all the variables that come from a form called $form . How to do it? */ } } Yes, I could it manually - global $firstname,$lastname,$addres, etc etc...but the function is being used by different scripts and I need to globalize only these variables that come from that particular form ... and all that 'automatically'. Any ideas? Thanks, Siim Einfeldt -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Expense
Clayton, you might want to try hotscripts.com. They have a load of scripts you can choose from, and it's all categorized as well. Good luck Navid Yar -Original Message- From: Clayton Dukes [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 19, 2001 2:22 PM To: [EMAIL PROTECTED] Subject: [PHP] Expense Does anyone know where I can find some type of Expense Report/Tracking system written in PHP? I'm tired of tracking all my stuff in Excel and sending it in so I thought I'd take a crack at making an online tracking system for multiple employees that could possibly export to Excel if needed. Thanks for any help :-) Clayton Dukes CCNA, CCDA, CCDP, CCNP Download Free Essays, Term Papers and Cisco Training from http://www.gdd.net
Re: [PHP] Expense
I did actually look there first. Nothing listed Thanks anyways :-) Clayton Dukes CCNA, CCDA, CCDP, CCNP Download Free Essays, Term Papers and Cisco Training from http://www.gdd.net - Original Message - From: Navid Yar [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, May 19, 2001 3:35 PM Subject: [PHP] Expense Clayton, you might want to try hotscripts.com. They have a load of scripts you can choose from, and it's all categorized as well. Good luck Navid Yar -Original Message- From: Clayton Dukes [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 19, 2001 2:22 PM To: [EMAIL PROTECTED] Subject: [PHP] Expense Does anyone know where I can find some type of Expense Report/Tracking system written in PHP? I'm tired of tracking all my stuff in Excel and sending it in so I thought I'd take a crack at making an online tracking system for multiple employees that could possibly export to Excel if needed. Thanks for any help :-) Clayton Dukes CCNA, CCDA, CCDP, CCNP Download Free Essays, Term Papers and Cisco Training from http://www.gdd.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Expense
Clayton - I'm working on a similar time tracking tool myself...then it exports the data in CSV format. I'm looking at having it complete next week. I'll notify you when it done if your intrested. ~kurth On Sat, 19 May 2001, Clayton Dukes wrote: I did actually look there first. Nothing listed Thanks anyways :-) Clayton Dukes CCNA, CCDA, CCDP, CCNP Download Free Essays, Term Papers and Cisco Training from http://www.gdd.net - Original Message - From: Navid Yar [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, May 19, 2001 3:35 PM Subject: [PHP] Expense Clayton, you might want to try hotscripts.com. They have a load of scripts you can choose from, and it's all categorized as well. Good luck Navid Yar -Original Message- From: Clayton Dukes [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 19, 2001 2:22 PM To: [EMAIL PROTECTED] Subject: [PHP] Expense Does anyone know where I can find some type of Expense Report/Tracking system written in PHP? I'm tired of tracking all my stuff in Excel and sending it in so I thought I'd take a crack at making an online tracking system for multiple employees that could possibly export to Excel if needed. Thanks for any help :-) Clayton Dukes CCNA, CCDA, CCDP, CCNP Download Free Essays, Term Papers and Cisco Training from http://www.gdd.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] converting int to char
how do I convert and integer value to its ASCII correspondent? in C I would go something like: int i = 90; char c; c = i + '0'; // now c would be 'Z' in PHP I'm simply clueless since there's no (char) type... . Christian Dechery (lemming) . http://www.tanamesa.com.br . Gaita-L Owner / Web Developer -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Expense
Definately, thanks! Clayton Dukes CCNA, CCDA, CCDP, CCNP Download Free Essays, Term Papers and Cisco Training from http://www.gdd.net - Original Message - From: Kurth Bemis [EMAIL PROTECTED] To: Clayton Dukes [EMAIL PROTECTED] Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Saturday, May 19, 2001 3:37 PM Subject: Re: [PHP] Expense Clayton - I'm working on a similar time tracking tool myself...then it exports the data in CSV format. I'm looking at having it complete next week. I'll notify you when it done if your intrested. ~kurth On Sat, 19 May 2001, Clayton Dukes wrote: I did actually look there first. Nothing listed Thanks anyways :-) Clayton Dukes CCNA, CCDA, CCDP, CCNP Download Free Essays, Term Papers and Cisco Training from http://www.gdd.net - Original Message - From: Navid Yar [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Saturday, May 19, 2001 3:35 PM Subject: [PHP] Expense Clayton, you might want to try hotscripts.com. They have a load of scripts you can choose from, and it's all categorized as well. Good luck Navid Yar -Original Message- From: Clayton Dukes [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 19, 2001 2:22 PM To: [EMAIL PROTECTED] Subject: [PHP] Expense Does anyone know where I can find some type of Expense Report/Tracking system written in PHP? I'm tired of tracking all my stuff in Excel and sending it in so I thought I'd take a crack at making an online tracking system for multiple employees that could possibly export to Excel if needed. Thanks for any help :-) Clayton Dukes CCNA, CCDA, CCDP, CCNP Download Free Essays, Term Papers and Cisco Training from http://www.gdd.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] converting int to char
Hey, take a look at: http://www.php.net/manual/en/function.chr.php :) Kees -Original Message- From: Christian Dechery [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 19, 2001 9:47 PM To: [EMAIL PROTECTED] Subject: [PHP] converting int to char how do I convert and integer value to its ASCII correspondent? in C I would go something like: int i = 90; char c; c = i + '0'; // now c would be 'Z' in PHP I'm simply clueless since there's no (char) type... . Christian Dechery (lemming) . http://www.tanamesa.com.br . Gaita-L Owner / Web Developer -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] mail function. not working
Way does this not work it sends to the recipient but it will not send to the bcc this is right out of the manual. $recipient .= [EMAIL PROTECTED]; $subject = Hello; $message .= The is the message\n; $message .= --\r\n; //Signature delimiter $message .= http://northwesthost.com;; $headers .= From: Richard Kurth [EMAIL PROTECTED]\n; $headers .= X-Sender: [EMAIL PROTECTED]\n; $headers .= X-Mailer: NorthWestHost\n; $headers .= X-Priority: 1\n; $headers .= Return-Path: [EMAIL PROTECTED]\n; $headers .= Content-Type: text/html; charset=iso-8859-1\n; // Mime type $headers .= bcc:[EMAIL PROTECTED], [EMAIL PROTECTED]\n; // BCCs to mail($recipient, $subject, $message, $headers); Best regards, Richard mailto:[EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] mail function. not working
In article [EMAIL PROTECTED], [EMAIL PROTECTED] (Richard Kurth) wrote: Way does this not work it sends to the recipient but it will not send to the bcc this is right out of the manual. $recipient .= [EMAIL PROTECTED]; $subject = Hello; $message .= The is the message\n; $message .= --\r\n; //Signature delimiter $message .= http://northwesthost.com;; $headers .= From: Richard Kurth [EMAIL PROTECTED]\n; $headers .= X-Sender: [EMAIL PROTECTED]\n; $headers .= X-Mailer: NorthWestHost\n; $headers .= X-Priority: 1\n; $headers .= Return-Path: [EMAIL PROTECTED]\n; $headers .= Content-Type: text/html; charset=iso-8859-1\n; // Mime type $headers .= bcc:[EMAIL PROTECTED], [EMAIL PROTECTED]\n; // BCCs to mail($recipient, $subject, $message, $headers); Try changing all \ns to \r\n (the RFC calls for a CRLF as the line break), the signature delimiter to -- \r\n (a space after the two dashes), and bcc: to Bcc: (capitalize the B and add a space after the colon). If it's still not working, try getting rid of all the extra headers or putting the bcc before them. -- CC -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Include Paths
Hello, I am fairly new to PHP and so far I love it. One question I have is how to call include files outside of their directory without hard coding the real path to the file itself. Is there map path or a similar function in PHP? Also when i use readfile() or fpassthru() when I echo the result what I assume is the file size is added to the end of the line. i.e.( blah blah blah will produce a 14 at the end of the line ) I was curious as to if there is a flag i'm missing that is causing them to do that. Thank you for the help! Dylan Finney www.healthcoast.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Reports in web browser
Hello, I have written some accounting application using PHP, and now I need to create some reports. Those reports need to be printed from web browser. What can I do? Thanks Mihailo. _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Reversing htmlspecialchars()
Hi There, How can i reverse the htmlspecialchars() functions? I can't seem to find a function for that. Thanks, Jeroen Geusebroek -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Reversing htmlspecialchars()
How can i reverse the htmlspecialchars() functions? I can't seem to find a function for that. There is no function to do that. -Rasmus -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] Reversing htmlspecialchars()
Hi Rasmus, How can i reverse the htmlspecialchars() functions? I can't seem to find a function for that. There is no function to do that. Maybe it would be a nice feature to add in PHP? For the moment i'll just have to make my own version then :) Thanks, Jeroen -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] sending attachements with mail
Nobody knows if it's possible to send attachements with mail()?? Thanks, -- Mark Wouters eXpanded Media Web Designer Parijsstraat 74, B-3000 Leuven - Louvain Tel: +32 (16) 31.10.12 Fax: +32 (16) 31.10.19 E-mail: [EMAIL PROTECTED] URL: http://www.expandedmedia.be -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Global variables? (unset/set or what?)
Greetings. I have about two include files which are included in every php page that I have, and I wish to store global variables, such as passwords, usernames and other details information. After going through the PHP manual, all I could find was UNSET/SET global variables, but I don't know if that is the one to use or not... they looked like if they were to be doing something else. Any help or ideas? - Richard -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] get all defined constants?
hi all, can't find a function for getting a complete list of defined constants. this exists for classes, I think it must for constants even if it is undocumented. I'm writing a bit of debug code, and I'd rather not build a bunch of implicit knowledge about my set of constants into the code - I'd like to just dump everything in my environment onto the page. please respond to me @ [EMAIL PROTECTED] tia all, _alex -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Global variables? (unset/set or what?)
Try the define function. That will define a constant that you will always have access to (within functions, through various included files,etc.) Or you can write values to the $GLOBALS array of global variables. $GLOBALS[userPassword]=u8943fd; Will define a variable that is accessible as $userPassword. outside of functions and within functions available after the global $userPassword; command is within the function. HTH, Michael Richard wrote: Greetings. I have about two include files which are included in every php page that I have, and I wish to store global variables, such as passwords, usernames and other details information. After going through the PHP manual, all I could find was UNSET/SET global variables, but I don't know if that is the one to use or not... they looked like if they were to be doing something else. Any help or ideas? - Richard -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] sending attachments with mail
There are a few scripts listed at http://www.hotscripts.com/PHP/Scripts_and_Programs/Email_Systems/Email_Utili ties/ that might do what you want. David Price -Original Message- From: Mark Wouters [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 19, 2001 3:10 PM To: [EMAIL PROTECTED] Subject: [PHP] sending attachements with mail Nobody knows if it's possible to send attachements with mail()?? Thanks, -- Mark Wouters eXpanded Media Web Designer Parijsstraat 74, B-3000 Leuven - Louvain Tel: +32 (16) 31.10.12 Fax: +32 (16) 31.10.19 E-mail: [EMAIL PROTECTED] URL: http://www.expandedmedia.be -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] Reversing htmlspecialchars()
function un_htmlentities($str) { $trans = get_html_translation_table (HTML_ENTITIES); $trans = array_flip ($trans); $str = strtr ($str, $trans); return ($str); } -Original Message- From: Jeroen Geusebroek [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 19, 2001 11:46 PM To: [EMAIL PROTECTED] Subject: [PHP] Reversing htmlspecialchars() Hi There, How can i reverse the htmlspecialchars() functions? I can't seem to find a function for that. Thanks, Jeroen Geusebroek -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Global variables? (unset/set or what?)
So i should start the header (or wherever in the header) with : $GLOBALS[userPassword] = whatever; function cp() { global $userPassword; // $userPassword is 'whatever' // } Did I get it or am I just too tired? - Richard Michael Stearne [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Try the define function. That will define a constant that you will always have access to (within functions, through various included files,etc.) Or you can write values to the $GLOBALS array of global variables. $GLOBALS[userPassword]=u8943fd; Will define a variable that is accessible as $userPassword. outside of functions and within functions available after the global $userPassword; command is within the function. HTH, Michael Richard wrote: Greetings. I have about two include files which are included in every php page that I have, and I wish to store global variables, such as passwords, usernames and other details information. After going through the PHP manual, all I could find was UNSET/SET global variables, but I don't know if that is the one to use or not... they looked like if they were to be doing something else. Any help or ideas? - Richard -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Netscape 6, What a piece of s$#@ , anyone else had problems with php and Netscape 6?
Jakob, You mean tidy? I use it to post-process a 'Today's News page that is created, by script, from a set of other pages. It works very well. Miles Thompson At 03:54 PM 5/19/01 +0200, Jakob Kruse wrote: Brandon, might I suggest that you start using the HTML Validator at www.w3.org if you intend to write HTML that is viewable in Netscape 6.x. As pointed out by many others, Netscape 6 is a browser which does things according to W3C specs (mostly... a lot better than most other browsers anyway) and you are quite clearly not aware of what those specs are. I tried validating your HTML shown below. It is not even close to being valid HTML 4.01 Transitional, which is the loosest standard anyone should aim for at the moment (for the general progression of the WWW as a unity). Try the validator. It really is quite nice, and it *will* teach you how to write compliant HTML. Regards, Jakob Kruse Brandon Orther [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... This is the HTML that is returned by PHP. Does anyone know why Netscape Would have problems viewing it? html head titleControl Maestro Menu System/title meta http-equiv=Content-Type content=text/html; charset=iso-8859-1 link rel=stylesheet href=menu.css type=text/css /head body bgcolor=#FF text=#00 MARGINWIDTH=0 LEFTMARGIN=0 MARGINHEIGHT=0 TOPMARGIN=0 background=../html/gray-background.giftable width=100% height=100% border=0 cellspacing=0 cellpadding=0 tr td valign=top table width=100% border=0 cellspacing=0 cellpadding=0 tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Web%20Mailimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=Web%20MailWeb Mail/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Account%20Managmentimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=Account%20ManagmentAccount Managment/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Supportimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=SupportSupport/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Billingimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=BillingBilling/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Domain%20Managmentimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=Domain%20ManagmentDomain Managment/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr tr td width=1% height=15 valign=middlefont class=text a href=menu.php?open=Business%20Centerimg src=closed.gif border=0 /a /font/td td width=99% height=15 valign=middlefont class=text a href=menu.php?open=Business%20CenterBusiness Center/a/font/td tr td background=divide.gifimg src=divide.gif/td td background=divide.gifimg src=divide.gif/td /tr /table /td td background=menu_edge.gif width=8img src=menu_edge.gif/td/tr/table /body /html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Global variables? (unset/set or what?)
In article 9e6s21$2rk$[EMAIL PROTECTED], [EMAIL PROTECTED] (Richard) wrote: So i should start the header (or wherever in the header) with : $GLOBALS[userPassword] = whatever; function cp() { global $userPassword; // $userPassword is 'whatever' // } You're making an extra step. The variables stored in the $GLOBALS array don't have to be declared as global within a function. They're already available within the function. To make a global variable available within a function's local namespace, you _either_: * pass it by reference: function cp($userPassword) * declare it as a global: global $userPassword * make it an element of the $GLOBALS array: $GLOBALS['userPassword'] (You could also pass by value, but then you're dealing with a copy of the variable instead of the variable itself.) -- CC -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
php-general Digest 19 May 2001 23:59:03 -0000 Issue 696
php-general Digest 19 May 2001 23:59:03 - Issue 696 Topics (messages 53515 through 53569): Unix problem 53515 by: Urb LeJeune 53530 by: B. van Ouwerkerk 53534 by: Urb LeJeune more on problem 53516 by: Urb LeJeune Re: Netscape 6, What a piece of s$#@ , anyone else had problems with php and Netscape 6? 53517 by: Jakob Kruse 53568 by: Miles Thompson hosting closed web application for multiple users 53518 by: Steven Haryanto 53520 by: Craig Vincent 53522 by: Steven Haryanto 53529 by: Mr. Adam ALLEN. 53531 by: Matthias Winkelmann 53532 by: Steven Haryanto mail() problem 53519 by: Mark Wouters 53521 by: Craig Vincent 53523 by: Urb LeJeune Color of Pixel 53524 by: Martin Thoma 53528 by: Rasmus Lerdorf Urgent! Need help on semaphores 53525 by: fidodido.post1.com The performance of sleep() and usleep() 53526 by: BlackLord count() multidimensional array 53527 by: Dean Martin 53543 by: Chris Lee Re: Life of environment variable set put putenv() 53533 by: Arcady Genkin attachements in mail() 53535 by: Mark Wouters Command output into any array? 53536 by: Ken Jansons 53540 by: Chris Lee Getting email out of a database 53537 by: Richard Kurth 53538 by: Christian Dechery vpopmail functions 53539 by: Freedom Lookin For Programmer 53541 by: nicholas PHP Domino?? (Lotus Notes) 53542 by: Mike Kelley Mailserver?! 53544 by: FredrikAT Expense 53545 by: Clayton Dukes 53547 by: Navid Yar 53548 by: Clayton Dukes 53549 by: Kurth Bemis 53551 by: Clayton Dukes Re: globalize all variables not coming from a certain form... 53546 by: Chris Lee converting int to char 53550 by: Christian Dechery 53552 by: Kees Hoekzema mail function. not working 53553 by: Richard Kurth 53554 by: CC Zona Include Paths 53555 by: Dylan Finney Reports in web browser 53556 by: Mihailo Dzigurski Reversing htmlspecialchars() 53557 by: Jeroen Geusebroek 53558 by: Rasmus Lerdorf 53559 by: Jeroen Geusebroek 53565 by: jeroen.php.net 53566 by: Rudi Benkoviè sending attachements with mail 53560 by: Mark Wouters Global variables? (unset/set or what?) 53561 by: Richard 53563 by: Michael Stearne 53567 by: Richard 53569 by: CC Zona get all defined constants? 53562 by: Alex Black Re: sending attachments with mail 53564 by: David Price Administrivia: To subscribe to the digest, e-mail: [EMAIL PROTECTED] To unsubscribe from the digest, e-mail: [EMAIL PROTECTED] To post to the list, e-mail: [EMAIL PROTECTED] -- I'm using the follow snippet while traversing a directory. while ($Directory=readdir($DirHandle)) { $IsFile = is_file($Directory); $IsDir = is_dir($Directory); echo is file=$IsFile - is dir=$IsDir\n; Works fine on Windows box, on a Unix box (RedHat) both is_file() and is_dir() return null no matter what the contents of $Directory is. Any suggestions of what could be wrong with the Unix version? Urb while ($Directory=readdir($DirHandle)) { $IsFile = is_file($Directory); $IsDir = is_dir($Directory); echo is file=$IsFile - is dir=$IsDir\n; Works fine on Windows box, on a Unix box (RedHat) both is_file() and is_dir() return null no matter what the contents of $Directory is. This is a wild guess.. UPPER and lowercase used instead of only upper of only lowercase.. Spaces in file or directory names.. Bye, B. while ($Directory=readdir($DirHandle)) { $IsFile = is_file($Directory); $IsDir = is_dir($Directory); echo is file=$IsFile - is dir=$IsDir\n; Works fine on Windows box, on a Unix box (RedHat) both is_file() and is_dir() return null no matter what the contents of $Directory is. This is a wild guess.. UPPER and lowercase used instead of only upper of only lowercase.. Spaces in file or directory names.. Thanks for the suggestion but if I have: while ($Directory=readdir($DirHandle)) { $IsFile = is_file($Directory); $IsDir = is_dir($Directory); echo is file=$IsFile - is dir=$IsDir\n; echo name=$Directory\n; It displays the name of the file or directory correctly. Urb Bye, B. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] As a follow up on my last post, the following works on my Windows system but not on my Unix system: $Type = filetype($Directory); On Unix it always returns a null value. Urb Brandon, might I suggest that
[PHP] echo question
Hi All: I need to print out several paragraphs of information stored in a MySql field to a web page. To do this I am using: $db = mysql_connect(localhost, dbase, password); mysql_select_db(dbase,$db); $sql = SELECT update FROM members WHERE username = 'Don'; $query = mysql_query($sql); $results = mysql_fetch_array($query); $text = $results[update]; echo $text; but it does not insert the returns between the paragraphs. I think I need to tell it to insert a p in place of the return. There is a way to do this as I have seen it on the PHP site when I was searching for something else. Of course now that I need it I can't find the example. Can someone please help me figure this out? Thank you, Louis Brooks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Global variables? (unset/set or what?)
So this will do then: $GLOBALS[userPassword] = whatever; And when I need to use it, I use echo userPassword; and such alike? What if I would like to change it? Can I simply use 'userPassword=whatever'; ? Thanks, Richard -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Global varia........ **Sorry, I mean... **
Wrong examples written in my past post. $GLOBALS[userPassword] = whatever; global $userPassword; and then write/read from it? - Richard -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] echo question
You are looking for the function nl2br() Information here: http://www.newbienetwork.net/article.php?sid=70 And here: http://www.php.net/manual/en/function.nl2br.php See echo statement below for example implementation. Jason Lotito www.NewbieNetwork.net -Original Message- From: Louis Brooks [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 19, 2001 8:01 PM To: [EMAIL PROTECTED] Subject: [PHP] echo question Hi All: I need to print out several paragraphs of information stored in a MySql field to a web page. To do this I am using: $db = mysql_connect(localhost, dbase, password); mysql_select_db(dbase,$db); $sql = SELECT update FROM members WHERE username = 'Don'; $query = mysql_query($sql); $results = mysql_fetch_array($query); $text = $results[update]; echo nl2br($text); but it does not insert the returns between the paragraphs. I think I need to tell it to insert a p in place of the return. There is a way to do this as I have seen it on the PHP site when I was searching for something else. Of course now that I need it I can't find the example. Can someone please help me figure this out? Thank you, Louis Brooks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Reports in web browser
You need to be more specific than that. You cannot demand the browser to start printing, only thing is to write the contents of the report to a webpage and then the visitor/user can print it out if she/he likes. It depends on how you have stored the reports. - Richard Mihailo Dzigurski [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hello, I have written some accounting application using PHP, and now I need to create some reports. Those reports need to be printed from web browser. What can I do? Thanks Mihailo. _ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Mailserver?!
Check out http://webgadgets.com/phpost/ That's a good way to get started on handling emails with PHP. I'd need to know more about what you want to do to tell you if PHP is the way to do it. If you want to run a mail server which takes incoming emails and directly writes them to a database, PHP probably isn't the way to go. A Java Servlet would probably be a more appropriate application for that. But I don't think that's what you're wanting to do. Plutarck FredrikAT [EMAIL PROTECTED] wrote in message 9e6gud$eie$[EMAIL PROTECTED]">news:9e6gud$eie$[EMAIL PROTECTED]... Hi! I want to have a mailapp on my server (win32) wich writes all incoming mails to a MySQL db. Is this possible? - Fredrik A. Takle [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] get all defined constants?
phpinfo() allways has a list of variables. but of course every variable is allways in $GLOBALS too. -- Chris Lee [EMAIL PROTECTED] Alex Black [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... hi all, can't find a function for getting a complete list of defined constants. this exists for classes, I think it must for constants even if it is undocumented. I'm writing a bit of debug code, and I'd rather not build a bunch of implicit knowledge about my set of constants into the code - I'd like to just dump everything in my environment onto the page. please respond to me @ [EMAIL PROTECTED] tia all, _alex -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] count() multidimensional array
Dean Martin [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... My code to list only the rows that were checked is this.. for ($j=1 ; $j=5; $j++) SNIP This code is creating an endless loop and times out the server with memory overruns. What am I missing? In the end-loop condition, you're using assignment ('=') instead of if-equal ('=='). Effectively, the loop runs until 5 == 0 ;-) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] An excellant example of what PHP can do
Just found this site recently, and after a little playing I found out that it uses the .php3 extension as it's main feature. I believe it uses PHP for just about everything it does, which is a great example of how PHP can do just about anything web technology allows ;) Here it is (excellant for people at work/in foreign countrys): https://www.safeweb.com/ Their triangleboy application of course doesn't use PHP as their server has to spoof packets, but their online site uses it. And they're pretty huge, showing that PHP really can handle high-load websites. Enjoy, Plutarck -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Accessing data from a localhost proxy
I was wondering, when you set your browser's proxy setting to localhost, how do you access that information through a program? In PHP would you open a specific stream, or would you open a socket on 127.0.0.1 with the same port as the one you specified in your browser? Basically when you make your browser use a localhost proxy, where does the information actually go? Does the browser open a socket and send the information to whatever it connects to? If there has to be something listening on that port, what happens if two applications are listening to the same port? Do they both get the same data? Thanks in advance of my other thank yous, Plutarck -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] A universal Database Class
Hello Brandon, On 17-May-01 16:23:12, you wrote: I am making a suite of online tools. Right Now I am connecting to a MS SQL 2000 database. Is there any class out there that will let you send a query to more than just one type of databases? Like someone could run it off a MSSQL server and another could run it off a MySQL database. You may want to try Metabase. It supports many database consistently in such way that you can write fully database independent applications that work with the supported databases: http://phpclasses.UpperDesign.com/browse.html/package/20 Regards, Manuel Lemos Web Programming Components using PHP Classes. Look at: http://phpclasses.UpperDesign.com/?[EMAIL PROTECTED] -- E-mail: [EMAIL PROTECTED] URL: http://www.mlemos.e-na.net/ PGP key: http://www.mlemos.e-na.net/ManuelLemos.pgp -- -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Lookin For Programmer
I reccommend looking around sourceforge.net for current PHP BB projects, and if you find something like you want you can join that project, or you can just create your own project and thus allow people to join in the creation, should they so choose. Plutarck nicholas [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... Hmmm anyone looking to join me in making a bb called BestBoard? email me at [EMAIL PROTECTED] not thru the list! (note if these are not supposed to go on this list 1 flame will be suffiecent thanks!) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] is mod_php4 faster than mod_perl?
i'm wondering if mod_php4 is faster than mod_perl. thank you, christopher -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Email form
I've been out of the loop for so long. I make a normal form, but the action is something.. I don't want it to send from the uers email, but use the server. Some people don't have an email client configured. Can yah help? Thanks, Owen -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] Browscap.ini
So... I cannot for the life of me get browscap.ini to work. Also the browserhawk version of the browscap.ini is sadly out of date. Anyone have any leads for me on getting this to work? I consistently get an empty array returned. Thanks, Wes -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] is mod_php4 faster than mod_perl?
apples oranges. :) but mod_php without cache (e.g., zend cache) still suffers from an overhead of recompiling scripts in every request (serious overhead if the site is complex). -- sh On 19/07/2001 11:03, Christopher Leigh wrote: i'm wondering if mod_php4 is faster than mod_perl. thank you, -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] Browscap.ini
On 19 May 2001 22:13:05 -0700, Weston Houghton [EMAIL PROTECTED] wrote: I cannot for the life of me get browscap.ini to work. Also the browserhawk version of the browscap.ini is sadly out of date. Anyone have any leads for me on getting this to work? I consistently get an empty array returned. First, get_browser() seems to break in every other release, particularly on Windows. You might want to search bugs.php.net to see if it will work at all on your system version. If you are using a build with a functional get_browser(), check out asptracker.com for a more recent browscap.ini. Chris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] PHP Domino?? (Lotus Notes)
Anyone do anything in this arena yet? I searched the archives for 2001 but have yet to go farther back. I know I can use the COM ability to get info from Domino but I'm looking for any success stories with Lotus Domino. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]