Re: [PHP] Help on PHP vs JAVA
On Thu, 21 Feb 2002, Berlina wrote: Hello to everybody, I need some help for writting a comparison of PHP vs JAVA, and of course, I need that PHP wins ;-D PHP and JAVA are different tools. It depends what you want to do. You can take advanteges from both. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Using 'Location' and variables
On Thu, 21 Feb 2002, Jim Koutoumis wrote: I'm sure that this is possible, but I haven't found any info/examples on it yet,.. What I have is a php script that processes data that been submitted by a FORM. You can make this using javascript. You generate HTML form with hidden fields and at the end execute script xxx.post() /script or something like that. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: How do I keep a page from caching in I.E
4.09.2002, 17:48, Victor V. Evtushenko wrote: Donpro wrote: Hi, Using I.E. 5.5. I can't seem to keep a page from caching. When I click on Have you read HOWTO: Prevent Caching in Internet Explorer? http://support.microsoft.com/default.aspx?scid=kb;EN-US;q234067 According to the description I inserted header('Expires: -1'); It is fine if it is Internet Explorer. But e.g. Opera ignore the header. After BACK it displays old content. I even switched off all cache options in preferences but it does not help. the browser BACK button, I get the cached page so I have to click on Refresh to get the actual page content. I've placed the following at the top of the HTML file but it doesn't seem to do anything. Any help would be appreciated. Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] header question
On Wed, 11 Sep 2002, Meltem Demirkus wrote: I want to know if there is any way to send data in header(Location:login.php) .I know how to send like this a href=\login.php?id=$ID\ but I need to use header and I dont know howto do this?... header( Location: login.php?id=${ID} ); What for {} ? Rather: header( Location: login.php?id=$ID ); -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Problem with REMOTE_ADDR
Whenever I use REMOTE_ADDR, it gives me the IP of the server. Of course, I am not interested in this and want the IP of the client. I put this code in to resolve it and it still didnt work. What am I doing wrong? Try HTTP_CLIENT_IP. It is set in some situations. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] COOKIE Question.
I'm having some issue's with $_COOKIE and $HTTP_COOKIE_VARS, I can't seem to retrieve data from them. First I set the cookie like so: setcookie (Access, Test_Value,time()+31536000); Try this: setcookie(Access, Test_Value,time()+31536000,/); - slash as 4th parametr. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] == case-sensitive?
I've never really payed attention to this before, but now I noticed that == is case-sensitive, how do I make it == with different cases ? if(strtolower($a) == strtolower($b)) -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Visual Studio .NET as PHP IDE
Does anyone use VStudio .NET as your IDE in developing PHP Scripts? If so, have you found a way to make it so that it understands PHP? In particular color coding and the understanding of where functions start and end (for the solution explorer, etc). I was not using VStudio .NET but if I know Microsoft they try to cut using any other no-microsoft technologies. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Why my php pages are cached in browsers?
In browsers, my php pages are cached. All the code that is returned by php are stored. In version 4.1 this not ocurred, anybody can help me? First: Check if you send headers: header('Pragma: no-cache'); header('Expires: Thu, 01 Jan 1970 01:00:00 GMT'); header('Cache-Control: no-cache, must-revalidate, private'); Second: If your appache sends HTTP 1.0 try to change to HTTP 1.1. HTTP 1.0 do not know Cache-Control. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] How to create user in mySQL ?
Why do people insist on asking MySQL questions on a PHP list? search for flush privileges on the MySQL website. Mayby it is the most inteligent newsgroup. ;-) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Move Database
Hi, I am moving my site from one server to another, how can i copy all the data in my datbase to my new server? Also is it possibel to do this one table at a time? Backup from command line: mysqldump -h MYSQLHOST -u MYSQLUSER -p DATABASE backup.sql or mysqldump -h MYSQLHOST -u MYSQLUSER -p DATABASE TABLE 1 TABLE 2 ... TABLE N backup.sql In backup.sql you get CREATE and INSERT syntax. In new server you can execute: mysql -h NEWMYSQLHOST -u MYSQLUSER -p DATABASE backup.sql Of course in new server you must create DATABASE before. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] cookies
The only problem is once the cookie is set, it never seems to go away. This one should have expired in 30 minutes right? I can still go in and get to the other pages without it telling me to log in. What did I do wrong? Mayby your pages are cached. Do you send no-cache headers ? -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php-java formatting
This all works fine except I want each empty field of the alert box to be on it's own line. I try adding \n to the lines of the alert string but it prints out the \n. How can I format this string so that it shows correctly in the alert box? Just you use '\n' but you have to do something wrong. Look this: $x = 'Fill fields:\nfirstname\nsurname\nfirm'; echo script alert('$x'); /script; On the screen you get: Fill fields: firstname surname firm It works in Netscape and Internet Explorer. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] MySQL vs PostgreSQL
I'm just deciding which DB to use for my projects and I'm not clear with one thing... When considering a database for web, is MySQL good enough? I read it only supports table locking, which is not very satisfying in such a multiuser environment as the internet.. PostgreSQL has transactions and locks single records - MySQL locks whole tables. I read something like this: MySQL is more popular because a lot application is made in MySQL. If you make a new application from the base - choose PostgreSQL. Based on your experience, what are pros and cons of MySQL and why most of you prefer to use MySQL to PostgreSQL, which is aparently more powerful.. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] system()
When using the system() function, let's say starting up a program, can that program start in the background while the rest of the page is parsed or does it have to wait until the system command has finished whatever it is doing? It is impossible. system() is not asynchronous. Only a command that is executed in system() can by asynchronous - system() finishes but the command continues work on the server. If you need some results of the command system(COMMAND) has to return a handle point that you could use at the end of the page. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] MySQL vs PostgreSQL
What about transactions ? In all the discussion noone points that PostgreSQL uses them. Maybe noone uses transactions so they have no matter. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Directory Listing with php on unix boxes
Here is where I'm running into some problems. I need the file listing to be sorted as if I were performing an 'ls -lt' listing on the server itself. I do not think opendir() or readdir() quarantees any sort. You where lucky rather you got dirs in the time order. You should use filemtime() or something like this to sort dirs. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PHP Editors
I'm running Apache 2.0 as a service and PHP (like a module) onto a Windows Advanced Server. Im looking for a good and free Editor to use with PHP (With debugging features). Can anyone with experience guide me? Look up archives. You will get full list of PHP editors. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] POST_with_PHP_--_please_help_!
That's right, but with curl it's not a true redirection: you just print the content of the target page, you don't redirect to the page. What I need is automated forms, that send the same data as forms but without user interaction. I can't use javascript to automatically send a form. Maybe something like this: $fs = fsockopen(target.com,80); fputs($fs, ' POST /index.html HTTP/1.1 Accept: */* Content-Type: application/x-www-form-urlencoded Accept-Encoding: gzip, deflate Host: target.com Content-Length: 41 data1=value1data2=value2 '); Your script sends data to http://target.com/index.html At the end you can do location. That is all you can do. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] How to compare 2 strings
How to compare 2 strings in PHP I hawe 2 array where I have only string values some values in both arrays are same but if command don't send me a good result. e.g foreach ($array1 as $a1) { foreach($array2 as $a2){ if ($a1 == $a2) echo good; //never system send me a good result else echo bad; } } If you have in one array test and in the other also test (not Test nor TEST but test) it must work. By the way in else echo bad; you have not got a quotation mark after bad. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Confirmation e-mail
I am developing a website with a user login system, i would like to send an confirmation e-mail to the user when he/she registers for the site, asking for confirmation...for instance click on a link to activate thier account. My question is what would be the best approach to achieve this? How is this usualy done? Any thoughts and help is appreciated. You keep the content of e-mail in a file and use to complete an e-mail after clicking. You send such e-mail by PHP command mail and that is all. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Newbie php.ini
Thursday, February 13, 2003, , wrote: In my opinion php.ini is the least problem. Appache configuration is also important. You must secure your server, switch off unused ports. There is no default security configuration because it depends on the whole system. I'm completely new to php but am interested in getting things runnng on a live apache server. The default php.ini file has a huge security disclaimer at the top stating that the default configuration is not sufficiently secure for production. It references the php manual chapter on security for more information. I've read the manual, but in my green state it's still not clear to me what I should change to keep my server from being hacked. Would anyone be able to provide a standard ini file or list of changes to the default that would keep me out of trouble with regards to security and let me learn to use php as time permits? Thanks, Val -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Re: How to navigate backwards in PHP ???
$HTTP_SERVER_VARS[HTTP_REFERER]; - or - PHP 4.1.0 and later $_SERVER[HTTP_REFERER]; Not as reliable as passing it yourself though. Some browsers may block sending http_referer. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PHP caching ideas?
Is the general logic to slice the page into some general pieces. For example ones that have always general data and those that change. Then the ones that don't change are streamed to the user using passthrough and the rest of the page is generated dynamically with the newest relevant data. If a page has parts that change and not you can make frameset. In a frame that does not change you send caching headers. Durign generating page you can cache in memory unchangeble parts. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] People who searched this also searched this!
Hi guys, Does anybody have a working example of doing the lists of 'People who searched this also searched this!' that I see on Amazon and other websites. That is a very complex problem. It is not for PHP. PHP may only insert queries and get results and another system computers all data. Such system is based on statistic or artificial neuron nets. For example the company Net Perceptions makes such systems as NetP based on statistic but they are not very fast. If you would like to buy their system you would have to sell some good cars. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] weird IE cookie problem
Is the time set properly on your machine? Double check both the time AND the timezone. I went nuts trying to fix a similar problem once just to find out that someone had changed the timezone on the PC for a test and then forgot to put it back. It is very easy to check. Set $expires = 0; It makes a session cookie independed from time set. If you set a session cookie you will know you have problem with time set. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] ldap_add problem
I get the following error: Warning: LDAP: add operation could not be completed. in /var/www/html/user/adduser_p.php on line 65 Where in my log files can I go to look for more detailed info on that error, I don't know if I have logging enabled for slapd. 1. after ldap_add print ldap_error 2. Problems: 2a: access rights 2b: Wrong objectclass: sure you add it with right values: all attrubites include in class in objectclass. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Who can tell me where I can get the cracked Zend Encoder3.0 ?
Who can tell me where I can get the cracked Zend Encoder 3.0 ? By the way write do [EMAIL PROTECTED] for cracked Windows XP ;-) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Convert GIF to JPG with or without GD
does anyone know a way to convert a gif file to jpg ? I've made a photo album and, want to resize pictures to create thumbnails.. GD allow resizing jpeg files, but not gif files... So... how can I create a jpeg file from the gif source ? (may be with an external software...) ??? Command 'convert' from packet Image Magic (Linux) It is problem with GD: Since all GIF support was removed from the GD library in version 1.6, this function is not available if you are using that version of the GD library. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] publishing php mysql website on cd-rom
My organization has a need to publish some of our web content on a CD-ROM. I'm in search of suggestions on how to publish our dynamic content (php/mysql templates) in some sort of runtime configuration that would let users browse the site from cd. What's involved with this? Is there such a thing as runtime mySQL? What would it take to serve PHP from a CD? In my opinion the best is to use something like wget -r in Linux. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] File locking problem
I'm having file locking problems. I'm using fopen() to write a file via FTP. At the end, I'm doing... fflush($fp); fclose($fp); ...and then I include it immediately after. But many times I only get part of what I wrote to the file, which suggests that it wasn't really flushed and closed properly. Do you use include or require. In such situation you should not use include. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Convert GIF to JPG with or without GD
The GD library bundled with PHP 4.3 can read gif images (but not write them) And imagejpeg allows to create the jpeg file. -- Krzysztof Dziekiewicz -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] XML into PHP
Wednesday, November 13, 2002, , wrote: How would i call a page in PHP that is XML? eg; if i had a file that was like below. http://www.philipnz.com/news/rss.xml and i wanted to include it onto a page. Look into PHP manual: XML parser functions -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] posible bug, require and symlinks
When I require a file from index.php, if there's no .. on the path (a relative path, but not going back), the relative path is from where the original file is, but if there's a .. on the path, the relative path is from where the symlink is (although php identifies the script as the original file in the error message). ??? written too complicated. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] LDAP specific?
I can show a jpeg using a href with a target, either in a new page or a frame. To do this, PHP needs to be fed 'header(Content-type: image/jpeg)'. This can be put more or less anywhere in the very short script used for showing the jpeg and works. However, if I try to put any more html code into the script, i.e. 'print html';, print 'body'; etc, *anywhere*, I get a headers already sent error. You can not put any html code with image code. If you send some html you mean to send header(Content-Type: text/html) with header(Content-type: image/jpeg) Where do you want go to ? You can do so: There is on the page http://xxx/user.html?name=smith some html code where a user can act. Among the html code you insert img src=http://xxx/userfoto.html?name=smith; On http://xxx/userfoto.html you send header(Content-type: image/jpeg) and the image content and no html code. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php