Re[2]: [PHP] Code optimization: single vs. double quotes?
Hi, Tuesday, October 28, 2003, 9:26:13 AM, you wrote: CWP Curt Zirzow mailto:[EMAIL PROTECTED] CWP on Monday, October 27, 2003 3:16 PM said: 5. no newline after the tr. :) There are some broswer issues with tr and td's not being on the same line. CWP Ok I resisted sending this earlier but it appears it is now necessary. CWP ;) CWP Here is how I WOULD have written that line had it been in my own code. CWP (Minus some CSS that could be put in.) CWPecho table\n CWP. tr\n CWP. td class=\row_bright\$somevalue/td\n CWP. /tr\n CWP./table\n; I find the . operator to be very slow with strings :) (slow being relative of course) -- regards, Tom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] RE: Verify bUixCtJf for jay.blanchard@niicommunications.com
Hi, Tuesday, October 28, 2003, 3:08:56 AM, you wrote: JB Do you realize how large a PITA this is? For everyone who sends an JB e-mail to the PHP general list they have to take the time to answer JB this. SPAM about SPAM. Wonderful. It is a pain but if we all did it, it would stop an awful lot of spam :) http://www.bluebottle.com/ -- regards, Tom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Upgrading GD...
On Tue, 28 Oct 2003 01:26:05 -0500 Leif K-Brooks [EMAIL PROTECTED] wrote: Ryan Thompson wrote: Just a thought. Try using phpinfo() to find out the compile options. Use that and just add the GD compile options after upgrading GD. That's usually how I go about adding a new module. I can never remember what I've compiled into it. Thing is, I don't know how to get GD, how to compile PHP, or anything else. Is there something explaining how somewhere? http://www.php.net/manual/en/installation.php Or, just 1. Download the source. I'm sure you know where to find it. :) 2. Unpack. For example, if you've downloaded the xxx.tar.gz version, $ tar -xvzf php-xxx.tar.gz 3. cd to the resulting directory 4. run $ ./configure --with-your-options-here --together-with-additional-options NOTE: Find out your present configuration options as stated earlier. 5. run $ make 6. change to super user mode (root) 7. then run $ make install That should do it. (Unless, of course, you encounter some configure or make problems.) Don't forget to restart your webserver (Apache, I assume). $ service httpd restart And, I assume you're using linux hence the $ sign... - E - __ Do You Yahoo!? Yahoo! BB is Broadband by Yahoo! http://bb.yahoo.co.jp/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] How to deal with XML?
On Tue, 28 Oct 2003 01:29:35 -0500 Leif K-Brooks [EMAIL PROTECTED] wrote: Robert Cummings wrote: PHP docs are SGML as far as I can remember. How so? PHP isn't XML, SGML, HTML, or anything else besides PHP. ? He's talking about the DOCS and *not* PHP... ;) - E - __ Do You Yahoo!? Yahoo! BB is Broadband by Yahoo! http://bb.yahoo.co.jp/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] RE: Verify bUixCtJf for jay.blanchard@niicommunications.com
Hi, Sorry that link was not what I was thinking of, here is a better one. http://hr.uoregon.edu/davidrl/confirm/ -- regards, Tom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Site Replication Software
Does any one know of some good PHP software to replicate websites (allow customer's to choose a template based website, etc.) Can't seem to find anything. TIA, Daryl -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Upgrading GD...
- Edwin - wrote: That should do it. (Unless, of course, you encounter some configure or make problems.) And of course, I did: configure: error: Cannot find rfc822.h. Please check your IMAP installation. -- The above message is encrypted with double rot13 encoding. Any unauthorized attempt to decrypt it will be prosecuted to the full extent of the law. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] passing variables
Joao Andrade wrote: Hey everybody, That's lame but I've been looking for a while and found nothing. What are the ways to pass variables to another script? As far as I'm concerned there are POST and GET variables, and I know they can by set via HTML forms, but I only know how to pass user input variables. How could I automaticaly set a POST or GET variable through a script? Is it possible to set those variables from outside a script? Could an array be passed? http://www.php.net/sessions http://www.php.net/serialize http://www.php.net/unserialize -- Burhan Khalid phplist[at]meidomus[dot]com http://www.meidomus.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Upgrading GD...
On Tue, 28 Oct 2003 02:57:08 -0500 Leif K-Brooks [EMAIL PROTECTED] wrote: - Edwin - wrote: That should do it. (Unless, of course, you encounter some configure or make problems.) And of course, I did: configure: error: Cannot find rfc822.h. Please check your IMAP installation. Okay, the easiest to get around this is of course to remove --with-imap... ;) But, if you need it, of course, you need to install it then. Some info - http://www.php.net/manual/en/ref.imap.php Btw, don't forget to run $ rm config.cache before you run ./configure again... Also, there's another list specifically for php-installation - php-install (whatever the name is...). Make sure that you write about your environment (OS, etc.) with specific version numbers, etc. - E - __ Do You Yahoo!? Yahoo! BB is Broadband by Yahoo! http://bb.yahoo.co.jp/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Parsing specific portions of XML files
If it's anything like the Microsoft XML DOM object, you can use an XPath query to select the portion of the XML file that you want. Ryan Thompson [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] I'm stumped. I think it's just the logic I can't figure out. I have a file formatted for Docbook in XML. I'm trying to figure out a way to parse a specifice portion of an itemizedlist. It's for a change log. I want users to be able to view changes made to just one version and possibly for all. I can't use multiple change logs cause it the same file is used to make the text version that goes into the release documentation. Anyone got any ideas that can give me a push in the right direction. -- Ryan Thompson [EMAIL PROTECTED] http://osgw.sourceforge.net == A computer scientist is someone who fixes things that aren't broken --Unknown -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Parsing specific portions of XML files
See if xslt will help you. Ryan Thompson wrote: I'm stumped. I think it's just the logic I can't figure out. I have a file formatted for Docbook in XML. I'm trying to figure out a way to parse a specifice portion of an itemizedlist. It's for a change log. I want users to be able to view changes made to just one version and possibly for all. I can't use multiple change logs cause it the same file is used to make the text version that goes into the release documentation. Anyone got any ideas that can give me a push in the right direction. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] [xml] character data
Tom Rogers wrote: Hi, Saturday, October 11, 2003, 6:26:01 AM, you wrote: DA I do not understand why this line does not work : DA $info[$element] = $content; DA but yet this works: echo $content; DA why? what is the trick? [ snipped ] the function characterData can be called with whitespace which is probably overwriting your content try this $content = trim($content); if(!empty($content)) $info[$element] = $content; Or you can strip all the whitespace from the xml document and send that in. -- Burhan Khalid phplist[at]meidomus[dot]com http://www.meidomus.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Tricky variable syntax...
- Original Message - From: Curt Zirzow [EMAIL PROTECTED] To: php [EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 1:24 PM Subject: Re: [PHP] Tricky variable syntax... * Thus wrote René Fournier ([EMAIL PROTECTED]): echo 'file name: '.$$fld_name.'br'; What I want to do is echo the value of $img_photo_name. But how can I refer to it? The straight forward method would be: $fld_name = $$fld . _name; echo 'file name: '.$$fld_name.'br'; OR easier (IMHO) echo 'file name: ' . Chr(36) . $fld_name . 'br'; -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Tricky variable syntax...
René Fournier wrote: But here's my problem: echo 'file name: '.$$fld_name.'br'; What I want to do is echo the value of $img_photo_name. But how can I refer to it? Thanks. ...Rene Is this for file uploads? It that case you should use $_FILES superglobal array. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] php sessions
Hi, I'm developing a web application which is making use of sessions. I have the following configuration is my php.ini file session.use_cookies = 0 session.use_trans_sid = 1 session.auto_start = 0 register_globals = On This does not give me a new session_id when the application is opened in the same machine. If opened from different machines it gives me a different session_id. I create sessions using session_register() function. My php version is 4.2.2 How to create a unique session for every new browser instance? -vimala/. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] [PHP-GENERAL] Serving docs from PHP
Beginner to PHP so I guess this could be a really simple answer. I have a page linking to a ms word doc however the doc doesn't open up in word within the sectioned part of the browser but displays a load of gobble e.g.. ÐÏࡱá þ L N þÿÿÿK ÿÿÿì¥Á 7 ` ` ` ~ « « « I can open a word doc in the browser from a html page just not a PHP file. I 've checked the Apache httpd conf file and the mine types which are fine But I think I missing something in the PHP conf files. Thanks for any help. Alex James -- -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] [PHP-GENERAL] Serving docs from PHP
Alex James wrote: Beginner to PHP so I guess this could be a really simple answer. I have a page linking to a ms word doc however the doc doesn't open up in word within the sectioned part of the browser but displays a load of gobble e.g.. L N K7 ` ` ` ~ ? ? ? ? ? ? I can open a word doc in the browser from a html page just not a PHP file. I 've checked the Apache httpd conf file and the mine types which are fine But I think I missing something in the PHP conf files. Thanks for any help. Alex James Your php page has a link to the word document like this a href=word.docMy Document/a? Show some code. -- By-Tor.com It's all about the Rush http://www.by-tor.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] [PHP-GENERAL] Serving docs from PHP
You probably want to add the mime type with 'header(Content-type: application/x-ms-word);'. Regards. -Gregory -Original Message- From: Alex James [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 7:57 AM To: [EMAIL PROTECTED] Subject: [PHP] [PHP-GENERAL] Serving docs from PHP Beginner to PHP so I guess this could be a really simple answer. I have a page linking to a ms word doc however the doc doesn't open up in word within the sectioned part of the browser but displays a load of gobble e.g.. ÐÏࡱá þ L N þÿÿÿK ÿÿÿì¥Á 7 ` ` ` ~ « « « I can open a word doc in the browser from a html page just not a PHP file. I 've checked the Apache httpd conf file and the mine types which are fine But I think I missing something in the PHP conf files. Thanks for any help. Alex James -- -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] [PHP-GENERAL] Serving docs from PHP
John Nichel wrote: Your php page has a link to the word document like this a href=word.docMy Document/a? Show some code. Sorry Here is the link in menu6.php h3a href=index.php?m=6PK PATTERNS/a/h3 a href=index.php?m=6c=pkPatterns/MicroModel.docMicro models/a a href=index.php?m=6c=pkPatterns/test.htmlTest/a and getting called in here in index.php ?php $c = $_GET[c]; if ($c != ) { include($c); } else { include(content1.php); } ? Thanks Alex James -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Scratch card 14 digit number generation
Hi, Does anyone know howto generate a scratch card number for a phone card, and what are the things that has to be considered, tariff plans validity, expirary etc. If anyone has any idea please let me know. - JFK kishor Nilgiri Networks -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] How to deal with XML?
[snip] Just a small correction. I could be wrong but I don't believe XML is a subset of SGML but created to be used instead of. It was created from the ground up to replace SGML(not the easiest language to work with). [/snip] From the first paragraph of the intro at http://www.w3c.org/XML/ Extensible Markup Language (XML) is a simple, very flexible text format derived from SGML (ISO 8879). Originally designed to meet the challenges of large-scale electronic publishing, XML is also playing an increasingly important role in the exchange of a wide variety of data on the Web and elsewhere. It is a subset of SGML (which is too far ingrained to go away). For more on PHP and XML see http://us4.php.net/xml -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] [PHP-GENERAL] Serving docs from PHP
Alex James wrote: ?php $c = $_GET[c]; if ($c != ) { include($c); } else { include(content1.php); } ? The code is very unsafe, you include and execute any file, even remote if enabled in php.ini. You should use realpath() and substr() to check if the variable realy points to pkPatterns/ directory. Then check the file extension using pathinfo() and return apropriate Content-type header. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] sockets - fine tunning
Hi, I think curt is right about transfer encoding being a problem, however i feel it may not be 'the' problem. This timing issue looks like you are running into a 'blocking' kind of situation. Cosmin, Have you tried the 'Connection: close' header? Getting back to transfer encoding you might want to look at the RFC - http://www.w3.org/Protocols/rfc2616/rfc2616.html where they explain how it's to be handled. all the best Curt Zirzow wrote: * Thus wrote Cosmin ([EMAIL PROTECTED]): On Sun, 2003-10-26 at 15:30, Raditha Dissanayake wrote: are you getting any 1xx status codes from the web server? here are the full headers: Transfer-Encoding: chunked This is probably the problem. If you inspect your data, you'll notice that it has extra characters in it right now. You can change your protocol version to HTTP/1.0 or send a header to tell the server you don't want chuncked (don't know that off hand). Curt -- Raditha Dissanayake. http://www.radinks.com/sftp/ | http://www.raditha/megaupload/ Lean and mean Secure FTP applet with | Mega Upload - PHP file uploader Graphical User Inteface. Just 150 KB | with progress bar. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] keyword search syntax
If you put up a full text index on it you can do searches that smell like a primitive search engine. best regards Robb Kerr wrote: On Tue, 28 Oct 2003 02:09:06 +, David Otton wrote: Personally, I'd normalize that into a keyword table, a record table and a joining table. However, the SQL keyword you're looking for is LIKE WHERE field LIKE '%$variable%' I agree. I'd structure the data quite differently. But, I've got the data from a client and at this point I don't have the authority to restructure the database. Thanx for the tip on the LIKE command. Robb -- Raditha Dissanayake. http://www.radinks.com/sftp/ | http://www.raditha/megaupload/ Lean and mean Secure FTP applet with | Mega Upload - PHP file uploader Graphical User Inteface. Just 150 KB | with progress bar. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Parsing specific portions of XML files
Hi, You cannot parse a specific section only, the parser will go through the whole document. What you can do is to skip the section that does not interest you. I have seen two good suggestions that both smell of DOM (xslt has dom under the hood). With SAX you can just have a simple string comparision in the start_element handler that watches out for the node that interests you and then set a flag. If you could post a short sample of your xml someone might be able to help you more. best regards Ryan Thompson wrote: I'm stumped. I think it's just the logic I can't figure out. I have a file formatted for Docbook in XML. I'm trying to figure out a way to parse a specifice portion of an itemizedlist. It's for a change log. I want users to be able to view changes made to just one version and possibly for all. I can't use multiple change logs cause it the same file is used to make the text version that goes into the release documentation. Anyone got any ideas that can give me a push in the right direction. -- Raditha Dissanayake. http://www.radinks.com/sftp/ | http://www.raditha/megaupload/ Lean and mean Secure FTP applet with | Mega Upload - PHP file uploader Graphical User Inteface. Just 150 KB | with progress bar. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] [PHP-GENERAL] Serving docs from PHP
Alex James wrote: John Nichel wrote: Your php page has a link to the word document like this a href=word.docMy Document/a? Show some code. Sorry Here is the link in menu6.php h3a href=index.php?m=6PK PATTERNS/a/h3 a href=index.php?m=6c=pkPatterns/MicroModel.docMicro models/a a href=index.php?m=6c=pkPatterns/test.htmlTest/a and getting called in here in index.php ?php $c = $_GET[c]; if ($c != ) { include($c); } else { include(content1.php); } ? Thanks Alex James On the page that you're trying to serve the Micro$oft Document (index.php), you're going to have to include the content type in the header, something like... header ( Content-type: application/msword ); See here... http://us4.php.net/manual/en/function.header.php -- By-Tor.com It's all about the Rush http://www.by-tor.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDF File generation on Fly in PHP
Hello, I've just came through a function which generates PDF files on fly in a php script. On going through the documentation, I came to know that It needs to be compiled in a different fashion using a configure parameter. I would be happy if someone could help me out. I use Windows XP and PHP 4.3.3 and I couldn't find the configure.exe anywhere in my system... Thanks Regards, ___ Vijay Corporate Communications Satyam Computer Services Limited TSR Towers, Rajbhavan Road Somajiguda, Hyderabad-500 082 INDIA * : +91 (40) 23306767 Extn 7825 * : [EMAIL PROTECTED] Göd döësn't pläy dícë. - Älbërt Ëínstëín -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] keyword search syntax
On Tue, 28 Oct 2003 19:37:10 +0600, Raditha Dissanayake wrote: If you put up a full text index on it you can do searches that smell like a primitive search engine. best regards Thanx. The LIKE operator wouldn't work. But, your tip on creating a FULLTEXT index and executing a MATCH... AGAINST command worked like a dream. -- Robb Kerr Digital IGUANA -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] [PHP-GENERAL] Serving docs from PHP
John Nichel wrote: On the page that you're trying to serve the Micro$oft Document (index.php), you're going to have to include the content type in the header, something like... header ( Content-type: application/msword ); See here... http://us4.php.net/manual/en/function.header.php Thanks John for your reply. I have tried putting a header before the html tag unfortunately all this does is output index.php in ms word format within the browser. As you've seen with some of the code supplied I want to simulate how a frameset works. So the sidebar (or menu=m) stays the same with the area defined for content changing upon menu options. However how can I open a word doc from a normal HTML file on apache and I can't with a PHP file ? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] [PHP-GENERAL] Serving docs from PHP
Alex James wrote: John Nichel wrote: On the page that you're trying to serve the Micro$oft Document (index.php), you're going to have to include the content type in the header, something like... header ( Content-type: application/msword ); See here... http://us4.php.net/manual/en/function.header.php Thanks John for your reply. I have tried putting a header before the html tag unfortunately all this does is output index.php in ms word format within the browser. As you've seen with some of the code supplied I want to simulate how a frameset works. So the sidebar (or menu=m) stays the same with the area defined for content changing upon menu options. However how can I open a word doc from a normal HTML file on apache and I can't with a PHP file ? Okay, if you're going to include a MSWord document in a normal HTML file, how do you do thatwhat's your code to do it? -- By-Tor.com It's all about the Rush http://www.by-tor.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
--- S.P.Vimala [EMAIL PROTECTED] wrote: How to create a unique session for every new browser instance? I'm not sure if this fits your definition of new browser instance, but there is no way for a remote Web server to distinguish between two instances of the same browser running on the client machine. Maybe that explains something? Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] PDF File generation on Fly in PHP
Hi, Have you already checked out www.fpdf.org? Regards, Frank Hello, I've just came through a function which generates PDF files on fly in a php script. On going through the documentation, I came to know that It needs to be compiled in a different fashion using a configure parameter. I would be happy if someone could help me out. I use Windows XP and PHP 4.3.3 and I couldn't find the configure.exe anywhere in my system... Thanks Regards, ___ Vijay Corporate Communications Satyam Computer Services Limited TSR Towers, Rajbhavan Road Somajiguda, Hyderabad-500 082 INDIA * : +91 (40) 23306767 Extn 7825 * : [EMAIL PROTECTED] Göd döësn't pläy dícë. - Älbërt Ëínstëín -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: PDF File generation on Fly in PHP
on windows you need to comment out the php_pdf.dll (or similar) in php.ini and reboot apache/iis to enable the pdf extension. pete Vijay Killu wrote: Hello, I've just came through a function which generates PDF files on fly in a php script. On going through the documentation, I came to know that It needs to be compiled in a different fashion using a configure parameter. I would be happy if someone could help me out. I use Windows XP and PHP 4.3.3 and I couldn't find the configure.exe anywhere in my system... Thanks Regards, ___ Vijay Corporate Communications Satyam Computer Services Limited TSR Towers, Rajbhavan Road Somajiguda, Hyderabad-500 082 INDIA * : +91 (40) 23306767 Extn 7825 * : [EMAIL PROTECTED] Göd döësn't pläy dícë. - Älbërt Ëínstëín -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] [PHP-GENERAL] Serving docs from PHP
Okay, if you're going to include a MSWord document in a normal HTML file, how do you do thatwhat's your code to do it? Ah...good point. Thought It would work like a frame. But now thinking about it I'm trying to embed a word doc in the html and guess because I not using some object or activeX control it won't work. Right I'm going to save the word docs as txt files and include ? Thanks Alex James -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Menu populated based on previous menu
Searched all the sites I could find for this problem to no avail. I have two dropdown menus in a form. The first menu contains a list of MANUFACTURERS obtained from a database. The second contains a list of MODELS also obtained from the database. I want the second menu to be populated based upon the selection in the first. In other words, once a visitor has selected a MANUFACTURER they'll be presented with a list of MODELS that are available from the selected MANUFACTURER. I know how to do the queries, but don't know how to initiate the query and rebuild the second menu when the first selection is made without adding a SUBMIT button and loading a second page. Anyone know how to accomplish this? Thanx in advance. -- Robb Kerr Digital IGUANA Helping Digital Artists Achieve their Dreams http://www.digitaliguana.com http://www.cancerreallysucks.org -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Menu populated based on previous menu
I've solved same kind of problems with the help of HTML frames, if you are interested, drop me a mail, or if you find better option, please let me know. Nitin - Original Message - From: Robb Kerr [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 9:15 PM Subject: [PHP] Menu populated based on previous menu Searched all the sites I could find for this problem to no avail. I have two dropdown menus in a form. The first menu contains a list of MANUFACTURERS obtained from a database. The second contains a list of MODELS also obtained from the database. I want the second menu to be populated based upon the selection in the first. In other words, once a visitor has selected a MANUFACTURER they'll be presented with a list of MODELS that are available from the selected MANUFACTURER. I know how to do the queries, but don't know how to initiate the query and rebuild the second menu when the first selection is made without adding a SUBMIT button and loading a second page. Anyone know how to accomplish this? Thanx in advance. -- Robb Kerr Digital IGUANA Helping Digital Artists Achieve their Dreams http://www.digitaliguana.com http://www.cancerreallysucks.org -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Menu populated based on previous menu
From: Robb Kerr [EMAIL PROTECTED] Searched all the sites I could find for this problem to no avail. I have two dropdown menus in a form. The first menu contains a list of MANUFACTURERS obtained from a database. The second contains a list of MODELS also obtained from the database. I want the second menu to be populated based upon the selection in the first. In other words, once a visitor has selected a MANUFACTURER they'll be presented with a list of MODELS that are available from the selected MANUFACTURER. I know how to do the queries, but don't know how to initiate the query and rebuild the second menu when the first selection is made without adding a SUBMIT button and loading a second page. Anyone know how to accomplish this? Thanx in advance. This is a pretty common question. You need to employ some Javascript to get this to work the way you want it to, though. To do this purely in PHP, then the SUBMIT button required, as PHP cannot change the client side form elements, only the source code sent to the browser. That said, you can use your queries in PHP to build the Javascript variables / arrays. As you loop through the query results, you create the arrays with all of the possible MODEL values. Then when your user selects a MANUFACTURER, the javascript reads the arrays that PHP wrote into the source code and loads the appropriate one into the MODEL select box. Keep searching, examples are out there. ---John Holmes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Menu populated based on previous menu
Searched all the sites I could find for this problem to no avail. I have two dropdown menus in a form. The first menu contains a list of MANUFACTURERS obtained from a database. The second contains a list of MODELS also obtained from the database. I want the second menu to be populated based upon the selection in the first. In other words, once a visitor has selected a MANUFACTURER they'll be presented with a list of MODELS that are available from the selected MANUFACTURER. I know how to do the queries, but don't know how to initiate the query and rebuild the second menu when the first selection is made without adding a SUBMIT button and loading a second page. You can't do this with PHP (server-side), you'll need to use JavaScript (client-side). Check out some JavaScript sites for examples, then use PHP to populate the JavaScript arrays. Larry -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Menu populated based on previous menu
Thanx for the tips. I'll search the JavaScript sites and see what I can come up with. -- Robb Kerr Digital IGUANA -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Menu populated based on previous menu
here is a link that might help http://www.macromedia.com/support/ultradev/ts/documents/client_dynamic_listb ox.htm Radu - Original Message - From: Robb Kerr [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 5:59 PM Subject: Re: [PHP] Menu populated based on previous menu Thanx for the tips. I'll search the JavaScript sites and see what I can come up with. -- Robb Kerr Digital IGUANA -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Possible query problem
Yestery day I got help from several of you on my function. I tried to get complicated today and so here it is. I am working on a peice of code where if a condition of a database entery is 0 then it will take you to one page if it is one it will take you to another page. Here is the function: $payment1 = $_POST[payment]; function payment(){ global $payment1; if ($payment1 == 0){ header ('Location: http://ftudor/test/test_page.html'); } elseif ($payment1 == 1) { header ('Location: http://ftudor/test/test_page2.html'); } } payment(); It works (thanks to many) but I have another problem. Basically the user will have to supply a username and password, then the sql statement will go through something like this: $query=SELECT payment FROM payment WHERE dln='.$_POST[dln].' = payment.dln='.$_POST[dln].' and users.password='.$_POST[password].'; then it should return a 0 or a 1 and that will go into the function and route a user to the right page. Since I don't have a payment processing tool in place I have to hfake a condition. The page just cycles into itself and keeps promting for username and password over and over. Do you think it's my sql? Frank __ Do you Yahoo!? The New Yahoo! Shopping - with improved product search http://shopping.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] URL Variables
Is there a way to preserve URL variables and have a link simply add a new variable to the end? I am tabulating data and I have URL variables defining which dataset to view and in what way to view it. I would now like to set the SQL statement up with a limit and add some Previous, Next commands, and even paging numbers, but how should I go about setting up the link so that the existing URL variables are preserved? Thanks in advance! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Possible query problem
On Tuesday, October 28, 2003 8:50 AM Frank Tudor wrote: $query=SELECT payment FROM payment WHERE dln='.$_POST[dln].' = payment.dln='.$_POST[dln].' and users.password='.$_POST[password].'; Okay, there seem to be a few problems here. The first issue is: users.password Using this means you are referencing a table which you've identified as users, however there is no such table in your query. If the password field is part of the payment table, then you would reference it as payment.password. However if the password field is part of a users table, then you need to perform a join here, as you will be attempting to get the data from two tables. The second issue is here: WHERE dln='.$_POST[dln].' = payment.dln='.$_POST[dln] You're first comparind dln to $_POST['dln'], and then to payment.dln and then to $_POST['dln'] again. What fields is it you're trying to compare? Each where clause in sql must be joined with an and, or, like, etc. So perhaps you were trying for something like this: WHERE dln = '.$_POST[dln].' and payment.dln = '.$_POST[dln] However, if this were the case you're essentially asking the same thing twice. So, based on your query, I suspect you're trying for something like this: $query = 'select payment from payment where dln = \''.$_POST['dln'].'\' and password = \''.$_POST['password'].'\''; However, this again assumes that the password and dln fields are in the same table. If they're in separate tables then you'll need to perform a join. Hope this helps. Cheers, Pablo -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Possible query problem
[snip] $query=SELECT payment FROM payment WHERE dln='.$_POST[dln].' = payment.dln='.$_POST[dln].' and users.password='.$_POST[password].'; [/snip] Breaking the above apart ... $query= SELECT payment FROM payment WHERE dln='.$_POST[dln].' = payment.dln='.$_POST[dln].' and users.password='.$_POST[password].'; It appears that you have one too many dln='.$_POST[dln].' -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] URL Variables
On Tuesday, October 28, 2003 8:57 AM Jed R. Brubaker wrote: Is there a way to preserve URL variables and have a link simply add a new variable to the end? I am tabulating data and I have URL variables defining which dataset to view and in what way to view it. I would now like to set the SQL statement up with a limit and add some Previous, Next commands, and even paging numbers, but how should I go about setting up the link so that the existing URL variables are preserved? $_SERVER['HTTP_REFERER'] will give you the referring url with all vars attached, so then all you'll need to do is append your new vars to the end of this. Cheers, Pablo -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] revised query problem (sorry)
$query=SELECT payment FROM payment WHERE payment.dln='.$_POST[dln].' = users.dln='.$_POST[dln].' and payment.payment='.$_POST[payment].'; Will this work? Frank __ Do you Yahoo!? Exclusive Video Premiere - Britney Spears http://launch.yahoo.com/promos/britneyspears/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Possible query problem
I didn't look into your problem, but I want to mention one thing that stands out to me. --- Frank Tudor [EMAIL PROTECTED] wrote: $query=SELECT payment FROM payment WHERE dln='.$_POST[dln].' = payment.dln='.$_POST[dln].' and users.password='.$_POST[password].'; Never, ever build an SQL query using data directly from the client. You place yourself at the mercy of every user of your site and their creative potential. This code constitutes a security vulnerability. Filter all data, assign it to another variable (so you know it has been filtered), and then build your query using the filtered data: $clean['dln'] = ''; if ($_POST['dln'] looks like a valid value) { $clean['dln'] = $_POST['dln']; } $sql = ... {$clean['dln']} ...; Something similar to that anyway. Hope that helps. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] URL Variables
--- Jed R. Brubaker [EMAIL PROTECTED] wrote: Is there a way to preserve URL variables and have a link simply add a new variable to the end? Sure, just use $_SERVER['QUERY_STRING'], which is the current query string, and append whatever new URL variables you want. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] revised query problem (sorry)
Yours: $query=SELECT payment FROM payment WHERE payment.dln='.$_POST[dln].' = users.dln='.$_POST[dln].' and payment.payment='.$_POST[payment].'; Mine: $query=SELECT payment FROM payment WHERE payment.dln='.$_POST[dln].' AND users.dln='.$_POST[dln].' and payment.payment='.$_POST[payment].'; See the difference? -Original Message- From: Frank Tudor [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 9:09 AM To: 1PHP Subject: [PHP] revised query problem (sorry) $query=SELECT payment FROM payment WHERE payment.dln='.$_POST[dln].' = users.dln='.$_POST[dln].' and payment.payment='.$_POST[payment].'; Will this work? Frank __ Do you Yahoo!? Exclusive Video Premiere - Britney Spears http://launch.yahoo.com/promos/britneyspears/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] revised query problem (sorry)
[snip] $query=SELECT payment FROM payment WHERE payment.dln='.$_POST[dln].' = users.dln='.$_POST[dln].' and payment.payment='.$_POST[payment].'; Will this work? [/snip] Aside from what Chris said (excellent advice!) the query above will not work because the 4rth line = users.dln='.$_POST[dln].' has no conditional on it. In other words you cannot say WHERE foo=foo=bar=bar you need to say where foo=foo and bar=bar and payment=paypment Other than that this is bad for the reasons Chris stated. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] URL Variables
Thanks! Chris Shiflett [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] --- Jed R. Brubaker [EMAIL PROTECTED] wrote: Is there a way to preserve URL variables and have a link simply add a new variable to the end? Sure, just use $_SERVER['QUERY_STRING'], which is the current query string, and append whatever new URL variables you want. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: php-general Digest 28 Oct 2003 17:26:53 -0000 Issue 2382
There's a nice GPL class that does this quite well. It could save you a lot of work and will definitely provide an example. Check out; http://www.phpclasses.org/search.html?words=linked_selectgo_search=1 On 10/28/03 12:26 PM, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: - Original Message - From: Robb Kerr [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 5:59 PM Subject: Re: [PHP] Menu populated based on previous menu Thanx for the tips. I'll search the JavaScript sites and see what I can come up with. -- Robb Kerr Digital IGUANA -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Menu populated based on previous menu
There's a nice GPL class that does this quite well. It could save you a lot of work and will definitely provide an example. Check out; http://www.phpclasses.org/search.html?words=linked_selectgo_search=1 On 10/28/03 12:26 PM, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: - Original Message - From: Robb Kerr [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 5:59 PM Subject: Re: [PHP] Menu populated based on previous menu Thanx for the tips. I'll search the JavaScript sites and see what I can come up with. -- Robb Kerr Digital IGUANA -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Menu populated based on previous menu
I've found some JavaScripts that will do what I require. Here's the question before I get to deeply into hacking the scripts... Can you embed PhP in JavaScript. In other words, the Java requires that arrays be filled. The entries into these arrays need to come from my database which is accessed via PhP. In Java line... new Array() can I embed the PhP... ?php echo $database['field']; ? Thanx, -- Robb Kerr Digital IGUANA -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Menu populated based on previous menu
Hi Robb. This is exactly what you'll need to do. Something like the following, assuming you're populating an array with user information: script type=text/javascript !-- var users = new Array(); ?php $count = 0; while (!$users-EOF)) { echo 'users['.$count.'] = '.$users-fields['username'].chr(10); $count++; $users-MoveNext(); } ? //-- /script The users array will now be populated with the usernames returned from your query. Cheers, Pablo -Original Message- From: Robb Kerr [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 9:48 AM To: [EMAIL PROTECTED] Subject: Re: [PHP] Menu populated based on previous menu I've found some JavaScripts that will do what I require. Here's the question before I get to deeply into hacking the scripts... Can you embed PhP in JavaScript. In other words, the Java requires that arrays be filled. The entries into these arrays need to come from my database which is accessed via PhP. In Java line... new Array() can I embed the PhP... ?php echo $database['field']; ? Thanx, -- Robb Kerr Digital IGUANA -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] HELP!! - Xitami php install
Hi, I'm running Windows XP, and Xitami version 2.4d10, I can get get PHP 4.0.3 installed and working fine, (on my www book's companion CD) but it doesn't have a few of the functions I want. I've just tried installing 4.3.3 and 4.3.4 and can't get either to work... when trying to access a php file, I just get a 'cannot find server' message from my browser. I've got the [Filter] .php=c:\php\php.exe and [Mime] Php=application/x-httpd-php in my defaults.cfg, any thoughts? HELP -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] installing php onto xitami, HELP!
Hi, I'm running Windows XP, and Xitami version 2.4d10, I can get get PHP 4.0.3 installed and working fine, (on my www book's companion CD) but it doesn't have a few of the functions I want. I've just tried installing 4.3.3 and 4.3.4 and can't get either to work... when trying to access a php file, I just get a 'cannot find server' message from my browser. I've got the [Filter] .php=c:\php\php.exe and [Mime] Php=application/x-httpd-php in my defaults.cfg, any thoughts? HELP -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] [PHP-GENERAL] Serving docs from PHP
Alex James wrote: Okay, if you're going to include a MSWord document in a normal HTML file, how do you do thatwhat's your code to do it? Ah...good point. Thought It would work like a frame. But now thinking about it I'm trying to embed a word doc in the html and guess because I not using some object or activeX control it won't work. Right I'm going to save the word docs as txt files and include ? Thanks Alex James So you were previously doing this from a Windows server? If not, instead of trying to include the document with php's 'include', have php output the html code that works. When you call it as an include, Apache is going to treat it as the mime type of the document that called it (in this case, php). -- By-Tor.com It's all about the Rush http://www.by-tor.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Menu populated based on previous menu
On Tue, 28 Oct 2003 09:52:02 -0800, Pablo Gosse wrote: Hi Robb. This is exactly what you'll need to do. Something like the following, assuming you're populating an array with user information: script type=text/javascript !-- var users = new Array(); ?php $count = 0; while (!$users-EOF)) { echo 'users['.$count.'] = '.$users-fields['username'].chr(10); $count++; $users-MoveNext(); } ? //-- /script The users array will now be populated with the usernames returned from your query. Cheers, Pablo Thanx Pablo. I'll give that a try. -- Robb Kerr Digital IGUANA -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
Chris Shiflett [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] --- S.P.Vimala [EMAIL PROTECTED] wrote: How to create a unique session for every new browser instance? I'm not sure if this fits your definition of new browser instance, but there is no way for a remote Web server to distinguish between two instances of the same browser running on the client machine. That can't be true. I don't claim to understand exactly how it works, but here is what happens for me. I have an application that I log into. Once I'm logged in, if I open the URL in another browser window, it just gives me the login page. My guess is that the first browser window is passing a cookie identifying the session that the second one doesn't know about. In your case, when you're not using cookies, the session ID must be passed on the URL. I don't know much about using trans_sid, so i can't help you further. -- Rob Maybe that explains something? Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Menu populated based on previous menu
You may want to look at the following article: http://www.zend.com/zend/tut/drop-down.php Luis -Original Message- From: Robb Kerr [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 9:46 AM To: [EMAIL PROTECTED] Subject: [PHP] Menu populated based on previous menu Searched all the sites I could find for this problem to no avail. I have two dropdown menus in a form. The first menu contains a list of MANUFACTURERS obtained from a database. The second contains a list of MODELS also obtained from the database. I want the second menu to be populated based upon the selection in the first. In other words, once a visitor has selected a MANUFACTURER they'll be presented with a list of MODELS that are available from the selected MANUFACTURER. I know how to do the queries, but don't know how to initiate the query and rebuild the second menu when the first selection is made without adding a SUBMIT button and loading a second page. Anyone know how to accomplish this? Thanx in advance. -- Robb Kerr Digital IGUANA Helping Digital Artists Achieve their Dreams http://www.digitaliguana.com http://www.cancerreallysucks.org -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
--- Rob Adams [EMAIL PROTECTED] wrote: I'm not sure if this fits your definition of new browser instance, but there is no way for a remote Web server to distinguish between two instances of the same browser running on the client machine. That can't be true. It can, and it is. The only way a Web server could distinguish between them is if the browsers sent something unique per instance within the HTTP request. So, you could write a browser that does this in theory, but that doesn't really do you much good unless you can convince your users to use it. It would be very unusual behavior, so I doubt anyone would want this. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] OT - Quick JavaScript Question
I know this is a bit off topic, but does anyone know of a way I can take the server time in php and get it into javascript? here is the code so far for my javascript clock, but it uses the clients time. I either need to replace the Date() function with another, or somehow import php's time. I have the time from the server in $LogInOutHours:$LogInOutMinutes:$LogInOutSeconds $LogInOutAmPm Thanks, Jake function startclock() { var thetime=new Date(); var nhours=thetime.getHours(); var nmins=thetime.getMinutes(); var nsecn=thetime.getSeconds(); var AorP= ; if (nhours=12) AorP=PM; else AorP=AM; if (nhours=13) nhours-=12; if (nhours==0) nhours=12; if (nsecn10) nsecn=0+nsecn; if (nmins10) nmins=0+nmins; document.timesheet.time.value = nhours+:+nmins+:+nsecn; document.timesheet.ampm.value = AorP; setTimeout('startclock()',1000); }
[PHP] Calendar Tool
Hey everyone. I am the creater of a PHP script called TotalCalendar (http://sweetphp.com/TotalCalendar/) and I am looking for a little advice and suggestions about making a tool for it. I want to build an application that users can download and install on their local machines which connects to a site's calendar (that site obviously would have to have TotalCalendar installed on it). This client application would connect to the site's calendar and retrieve all necessary info about different events located inside the calendar. Anyway, the advice I am looking for is where to start the application. PHP-GTK has been brought to my attention as a useful tool to build something like this, however, I have absolutely no experience with it. I was wondering if anyone could point me in the right direction for a detailed tutorial or applications that would help me build something like this. I have found a couple tutorials that show really simple things like creating buttons, but not much more than that. Please let me know if anyone can help me out with this. I am open for any type of suggestions for this building this tool. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] OT - Quick JavaScript Question
--- Jake McHenry [EMAIL PROTECTED] wrote: I know this is a bit off topic, but does anyone know of a way I can take the server time in php and get it into javascript? Well, that part isn't off-topic, in my opinion. JavaScript and HTML are the exact same thing from the perspective of PHP; they're output. So yes, you can get any information from PHP to JavaScript by writing it: script language=javascript ... ? $ts = time(); echo var ts = $ts;\n; ? ... /script My JavaScript syntax might be wrong, but hopefully you get the idea. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Calendar Tool
Matt Palermo wrote: Hey everyone. I am the creater of a PHP script called TotalCalendar (http://sweetphp.com/TotalCalendar/) and I am looking for a little advice and suggestions about making a tool for it. I want to build an application that users can download and install on their local machines which connects to a site's calendar (that site obviously would have to have TotalCalendar installed on it). This client application would connect to the site's calendar and retrieve all necessary info about different events located inside the calendar. Anyway, the advice I am looking for is where to start the application. PHP-GTK has been brought to my attention as a useful tool to build something like this, however, I have absolutely no experience with it. I was wondering if anyone could point me in the right direction for a detailed tutorial or applications that would help me build something like this. I have found a couple tutorials that show really simple things like creating buttons, but not much more than that. Please let me know if anyone can help me out with this. I am open for any type of suggestions for this building this tool. I hope it not just me but the site doesn't come up. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Re: Calendar Tool
Oops... The link to the site is: http://www.sweetphp.com/projects/TotalCalendar/ Sorry. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] OT - Quick JavaScript Question
- Original Message - From: Chris Shiflett [EMAIL PROTECTED] To: Jake McHenry [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 2:14 PM Subject: Re: [PHP] OT - Quick JavaScript Question --- Jake McHenry [EMAIL PROTECTED] wrote: I know this is a bit off topic, but does anyone know of a way I can take the server time in php and get it into javascript? Well, that part isn't off-topic, in my opinion. JavaScript and HTML are the exact same thing from the perspective of PHP; they're output. So yes, you can get any information from PHP to JavaScript by writing it: script language=javascript ... ? $ts = time(); echo var ts = $ts;\n; ? ... /script My JavaScript syntax might be wrong, but hopefully you get the idea. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php I have tried this already, and it works, the JavaScript get's the server's time, but then the JavaScript clock doesn't keep counting, it's stuck at the servers time. It needs that Date() function to keep pulling the time from the local machine I guess. I was wondering if anyone knew of a way I could pass the server time into the JavaScript Date() function to make it start counting from that time, instead of the users machine time. Thanks, Jake -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] OT - Quick JavaScript Question
Jake McHenry wrote: I have tried this already, and it works, the JavaScript get's the server's time, but then the JavaScript clock doesn't keep counting, it's stuck at the servers time. It needs that Date() function to keep pulling the time from the local machine I guess. I was wondering if anyone knew of a way I could pass the server time into the JavaScript Date() function to make it start counting from that time, instead of the users machine time. Thanks, Jake Yes, http://devedge.netscape.com/library/manuals/2000/javascript/1.5/reference/date.html#1193137 Jordan S. Jones -- I am nothing but a poor boy. Please Donate.. https://www.paypal.com/xclick/business=list%40racistnames.comitem_name=Jordan+S.+Jonesno_note=1tax=0currency_code=USD -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
Chris Shiflett [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] --- Rob Adams [EMAIL PROTECTED] wrote: I'm not sure if this fits your definition of new browser instance, but there is no way for a remote Web server to distinguish between two instances of the same browser running on the client machine. That can't be true. It can, and it is. The only way a Web server could distinguish between them is if the browsers So there is a way, and it's not true. Test it yourself. Login to a PHP app using a standard browser and session cookies and see for yourself. I understand the philosophy of the web server only seeing what the client sends it, but it looks like my client (IE6, right here) does send different requests per instance. It's not just 'in theory.' sent something unique per instance within the HTTP request. So, you could write a browser that does this in theory, but that doesn't really do you much good unless you can convince your users to use it. It would be very unusual behavior, so I doubt anyone would want this. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] strange issue
Hey all, I've researched this to the greatest extent and I can't seem to find anything written about this. I have a new server (RH 9) with PHP4.2.2 and Apache 2. I can't seem to upload anything over 1 KB. I can upload small gifs and JPGs that are a few hundred bytes, but I can't seem to upload anything over that. I get no error messages, it simply doesn't upload it. I can upload no problem with a perl script. My upload_max_filesize value is set at 10M. You can view my php_info at http://mlm.vervecreations.com/php.php Any insight would be appreciated. Thanks! Jacob Bolton
[PHP] data from database
Hi, I will write a function that returns the result of a recordset. I tried this: Function getPersonen() { openDB(); //function that I implements in another file $query = SELECT * FROM Cursisten; $result = mysql_query($query) or die(Fout bij uitvoeren query); $resultrow = mysql_fetch_array( $result ); closeDB(); //function that I implements in another file mysql_free_result($result); return $resultrow; } I call this function: $resultaat = getPersonen(); // Printen resultaten in HTML print table\n; while ($line = mysql_fetch_array($resultaat, MYSQL_ASSOC)) { print \ttr\n; foreach ($line as $col_value) { print \t\ttd$col_value/td\n; } print \t/tr\n; } print /table\n; In runtime I have the following error Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/schoolre/public_html/Hitek/Online/Registratie/showPerson.php on line 8 What is wrong? Alain -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] OT - Quick JavaScript Question
On Tue, Oct 28, 2003 at 02:27:28PM -0500, Jake McHenry wrote: : Chris Shiflett responded: : --- Jake McHenry [EMAIL PROTECTED] wrote: : : I know this is a bit off topic, but does anyone know of a way I : can take the server time in php and get it into javascript? : : JavaScript and HTML are the exact same thing from the perspective of : PHP; they're output. So yes, you can get any information from PHP to : JavaScript by writing it: : : script language=javascript : ... : ? : $ts = time(); : echo var ts = $ts;\n; : ? : ... : /script : : I have tried this already, and it works, the JavaScript get's the server's : time, but then the JavaScript clock doesn't keep counting, it's stuck at the : servers time. It needs that Date() function to keep pulling the time from : the local machine I guess. I was wondering if anyone knew of a way I could : pass the server time into the JavaScript Date() function to make it start : counting from that time, instead of the users machine time. That's because you're only giving it a static time and not a real JavaScript Date() object. Try this: script language=javascript ... var ts = new Date(?php echo time(); ?); ... /script -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
--- Rob Adams [EMAIL PROTECTED] wrote: Test it yourself. With all due respect, it seems you should be doing the testing. Login to a PHP app using a standard browser and session cookies and see for yourself. I understand the philosophy of the web server only seeing what the client sends it, but it looks like my client (IE6, right here) does send different requests per instance. Then show us these requests and point out how they are different. Otherwise, I have to assume you have no idea what you're talking about. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
I will test it, because it seems I don't understand this issue as much as I could. But I can already tell you results I see right now: I open a web browser (IE) and login to my application. I open another window (IE) and goto the web application, and it asks me to login. This is all on the same computer. (As I've explained all this before.) Now, perhaps I don't know what I'm talking about, and this is a different issue. If so, I'm pretty sure you'll certainly try to set me straight. If not, then it certainly seems relevant to the discussion, and that my one client (IE) is sending two different requests from two different windows on the same computer. -- Rob Chris Shiflett [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] --- Rob Adams [EMAIL PROTECTED] wrote: Test it yourself. With all due respect, it seems you should be doing the testing. Login to a PHP app using a standard browser and session cookies and see for yourself. I understand the philosophy of the web server only seeing what the client sends it, but it looks like my client (IE6, right here) does send different requests per instance. Then show us these requests and point out how they are different. Otherwise, I have to assume you have no idea what you're talking about. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
From: Chris Shiflett [EMAIL PROTECTED] --- Rob Adams [EMAIL PROTECTED] wrote: Test it yourself. With all due respect, it seems you should be doing the testing. Login to a PHP app using a standard browser and session cookies and see for yourself. I understand the philosophy of the web server only seeing what the client sends it, but it looks like my client (IE6, right here) does send different requests per instance. Then show us these requests and point out how they are different. Otherwise, I have to assume you have no idea what you're talking about. If you are not relying on a cookie based session, then this will work. Each login could be assigned a different session ID, so the requests for each browser will be different because of the different session IDs. ---John Holmes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] php sessions
Hi Rob. That seems perfectly logical. I've written a Content Management System which (when it's finished in a couple of months ;o) run the website at the university where I work. I can presently open an instance of the CMS in IE, login as admin, then open a new window and request another instance of the CMS, and login as a less-privelidged user. I can then use these two separate instances and work as two individual users in the CMS at the same time. Cheers, Pablo -Original Message- From: Rob Adams [mailto:[EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 11:56 AM To: [EMAIL PROTECTED] Subject: Re: [PHP] php sessions I will test it, because it seems I don't understand this issue as much as I could. But I can already tell you results I see right now: I open a web browser (IE) and login to my application. I open another window (IE) and goto the web application, and it asks me to login. This is all on the same computer. (As I've explained all this before.) Now, perhaps I don't know what I'm talking about, and this is a different issue. If so, I'm pretty sure you'll certainly try to set me straight. If not, then it certainly seems relevant to the discussion, and that my one client (IE) is sending two different requests from two different windows on the same computer. -- Rob Chris Shiflett [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] --- Rob Adams [EMAIL PROTECTED] wrote: Test it yourself. With all due respect, it seems you should be doing the testing. Login to a PHP app using a standard browser and session cookies and see for yourself. I understand the philosophy of the web server only seeing what the client sends it, but it looks like my client (IE6, right here) does send different requests per instance. Then show us these requests and point out how they are different. Otherwise, I have to assume you have no idea what you're talking about. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] data from database
$result = mysql_query($query) You need to pass the connection resource returned from your mysql_connect call as a second parameter. Regards. -Gregory -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
So you're saying if the session ID is passed in on the URL it will work. But I'm using cookies. The only thing that gets passed on the URL is a pagename. Perhaps there is something funky about my setup, but it has always worked this way for me. -- Rob Cpt John W. Holmes [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] From: Chris Shiflett [EMAIL PROTECTED] --- Rob Adams [EMAIL PROTECTED] wrote: Test it yourself. With all due respect, it seems you should be doing the testing. Login to a PHP app using a standard browser and session cookies and see for yourself. I understand the philosophy of the web server only seeing what the client sends it, but it looks like my client (IE6, right here) does send different requests per instance. Then show us these requests and point out how they are different. Otherwise, I have to assume you have no idea what you're talking about. If you are not relying on a cookie based session, then this will work. Each login could be assigned a different session ID, so the requests for each browser will be different because of the different session IDs. ---John Holmes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] data from database
Gregory Kornblum wrote: $result = mysql_query($query) You need to pass the connection resource returned from your mysql_connect call as a second parameter. Regards. -Gregory While it is a good practice to do this, it is not necessary... If link_identifier isn't specified, the last opened link is assumed. If no link is open, the function tries to establish a link as if mysql_connect() was called with no arguments, and use it. The result of the query is buffered. -- By-Tor.com It's all about the Rush http://www.by-tor.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
* Thus wrote Rob Adams ([EMAIL PROTECTED]): I will test it, because it seems I don't understand this issue as much as I could. But I can already tell you results I see right now: I open a web browser (IE) and login to my application. I open another window (IE) and goto the web application, and it asks me to login. This is all on the same computer. (As I've explained all this before.) Now, perhaps I don't know what I'm talking about, and this is a different issue. If so, I'm pretty sure you'll certainly try to set me straight. If not, then it certainly seems relevant to the discussion, and that my one client (IE) is sending two different requests from two different windows on the same computer. This is entirely up to the client, deciding to send a cookie or not when opening a new browser window. You can even turn the behaviour, you describe, off in IE. The problem is the php script doesn't know that the browser you opened (that give you back the login screen) is even related to the other browser window. All the php script knows is that you simply don't have a cookie. Curt -- My PHP key is worn out PHP List stats since 1997: http://zirzow.dyndns.org/html/mlists/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
Curt Zirzow [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] * Thus wrote Rob Adams ([EMAIL PROTECTED]): I will test it, because it seems I don't understand this issue as much as I could. But I can already tell you results I see right now: I open a web browser (IE) and login to my application. I open another window (IE) and goto the web application, and it asks me to login. This is all on the same computer. (As I've explained all this before.) Now, perhaps I don't know what I'm talking about, and this is a different issue. If so, I'm pretty sure you'll certainly try to set me straight. If not, then it certainly seems relevant to the discussion, and that my one client (IE) is sending two different requests from two different windows on the same computer. This is entirely up to the client, deciding to send a cookie or not when opening a new browser window. You can even turn the behaviour, you describe, off in IE. The problem is the php script doesn't know that the browser you opened (that give you back the login screen) is even related to the other browser window. All the php script knows is that you simply don't have a cookie. That has been my point all along. Perhaps I misunderstood you: there is no way for a remote Web server to distinguish between two instances of the same browser running on the client machine. vs. The problem is the php script doesn't know that the browser you opened (that give you back the login screen) is even related to the other browser window. Aren't these almost exactly opposite statements? Isn't the web server distinguishing between the two instances? Using the cookie? -- Rob Curt -- My PHP key is worn out PHP List stats since 1997: http://zirzow.dyndns.org/html/mlists/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] SESSIONMANAGEMENT -- gute php mailing list / gute leute
Hallo ! Ich bin auf der Suche nach einer guten PHP Mailing-Liste, am besten in Deutsch...Falls ich hier falsch bin, bitte ich um Entschuldigung. Problem: SESSION-MANAGEMENT Achtung! !! session.use_cookies=0 !! (und sollen es auch bleiben) 1. Wieso kann ich nicht per $_GET['lid'] auf $_POST['lid']=lf_session_id(); zugreifen? (Danach ist ein Header(Location... drin - der überschreibt?) 2. Wie bekomme ich ein vernünftiges Sessionmanagement OHNE COOKIES hin? Eingesetzt wird PHP 4.2.2. Bei dieser PHP-Version funktioniert das nicht, wie beschrieben. Bug? (scheint so, schonmal nach gegoogled) session_start(); liefert immer neue werte... es wird keine session übernommen. 3. Probiert habe ich bereits auch eine CLASS zu schaffen, diese ist jedoch nicht global erreichbar (nach Redirect) Ich bin für jeden Tipp dankbar, der mich weniger verzweifeln läßt. Tausend Dank ! Christoph Lockingen -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] data from database
alain dhaene wrote: Hi, I will write a function that returns the result of a recordset. I tried this: Function getPersonen() { openDB(); //function that I implements in another file $query = SELECT * FROM Cursisten; $result = mysql_query($query) or die(Fout bij uitvoeren query); $resultrow = mysql_fetch_array( $result ); Get rid of the above line, unless you plan on passing the array. From the looks below, you want to pass the identifier though. If you do want to pass the result array instead of the identifier, leave as is. closeDB(); //function that I implements in another file mysql_free_result($result); If you are going to pass the identifier, you just killed it here. If you are going to pass the data array, swap these two lines, ie free your result before you close your connections. return $resultrow; Change this line to... return $result if you are not planning on passing the array. } I call this function: $resultaat = getPersonen(); // Printen resultaten in HTML print table\n; while ($line = mysql_fetch_array($resultaat, MYSQL_ASSOC)) { What you do with this, all depends on how you rewrite your function. If you're passing the identifier, you can leave it as is, if you're passing the result data array, you need to get rid of the while loop. print \ttr\n; foreach ($line as $col_value) { print \t\ttd$col_value/td\n; } print \t/tr\n; } print /table\n; In runtime I have the following error Warning: mysql_fetch_array(): supplied argument is not a valid MySQL result resource in /home/schoolre/public_html/Hitek/Online/Registratie/showPerson.php on line 8 What is wrong? Alot, I suggest you check out the MySQL functions http://us4.php.net/manual/en/ref.mysql.php -- By-Tor.com It's all about the Rush http://www.by-tor.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] revised query problem (sorry)
* Thus wrote Pablo Gosse ([EMAIL PROTECTED]): Yours: $query=SELECT payment FROM payment WHERE payment.dln='.$_POST[dln].' = users.dln='.$_POST[dln].' and payment.payment='.$_POST[payment].'; Mine: $query=SELECT payment FROM payment WHERE payment.dln='.$_POST[dln].' AND users.dln='.$_POST[dln].' and payment.payment='.$_POST[payment].'; See the difference? heh.. still wont work :/ the table users still isn't in the FROM list like what was suggested in the last post: $query=SELECT payment FROM payment, users WHERE payment.dln=users.dln AND users.dln='.untainted($_POST[dln]).' and payment.payment='.untainted($_POST[payment]).'; Curt -- My PHP key is worn out PHP List stats since 1997: http://zirzow.dyndns.org/html/mlists/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
Another test: I just downloaded and installed Mozilla (1.5). I logged into my site, opened another window, and was logged in there also. I logged out of the second window, hit a Home link on the first window, and got a login screen. This is new behavior for a browser for me, but now I understand how it works. Thanks for the discussion. -- Rob Rob Adams [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] Curt Zirzow [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] * Thus wrote Rob Adams ([EMAIL PROTECTED]): I will test it, because it seems I don't understand this issue as much as I could. But I can already tell you results I see right now: I open a web browser (IE) and login to my application. I open another window (IE) and goto the web application, and it asks me to login. This is all on the same computer. (As I've explained all this before.) Now, perhaps I don't know what I'm talking about, and this is a different issue. If so, I'm pretty sure you'll certainly try to set me straight. If not, then it certainly seems relevant to the discussion, and that my one client (IE) is sending two different requests from two different windows on the same computer. This is entirely up to the client, deciding to send a cookie or not when opening a new browser window. You can even turn the behaviour, you describe, off in IE. The problem is the php script doesn't know that the browser you opened (that give you back the login screen) is even related to the other browser window. All the php script knows is that you simply don't have a cookie. That has been my point all along. Perhaps I misunderstood you: there is no way for a remote Web server to distinguish between two instances of the same browser running on the client machine. vs. The problem is the php script doesn't know that the browser you opened (that give you back the login screen) is even related to the other browser window. Aren't these almost exactly opposite statements? Isn't the web server distinguishing between the two instances? Using the cookie? -- Rob Curt -- My PHP key is worn out PHP List stats since 1997: http://zirzow.dyndns.org/html/mlists/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] Libs?
Anyone know where I can get a good collection of PHP Libs (free) for PHP 4? I'm looking for some that can create PDF as well as Word or others. Also faxing abilities and such. Thanks! Robert ~~~ Anytime four New Yorkers get into a cab together without arguing, a bank robbery has just taken place. -Johnny Carson. ~~~ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] OT - Quick JavaScript Question
- Original Message - From: Eugene Lee [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, October 28, 2003 2:45 PM Subject: Re: [PHP] OT - Quick JavaScript Question On Tue, Oct 28, 2003 at 02:27:28PM -0500, Jake McHenry wrote: : Chris Shiflett responded: : --- Jake McHenry [EMAIL PROTECTED] wrote: : : I know this is a bit off topic, but does anyone know of a way I : can take the server time in php and get it into javascript? : : JavaScript and HTML are the exact same thing from the perspective of : PHP; they're output. So yes, you can get any information from PHP to : JavaScript by writing it: : : script language=javascript : ... : ? : $ts = time(); : echo var ts = $ts;\n; : ? : ... : /script : : I have tried this already, and it works, the JavaScript get's the server's : time, but then the JavaScript clock doesn't keep counting, it's stuck at the : servers time. It needs that Date() function to keep pulling the time from : the local machine I guess. I was wondering if anyone knew of a way I could : pass the server time into the JavaScript Date() function to make it start : counting from that time, instead of the users machine time. That's because you're only giving it a static time and not a real JavaScript Date() object. Try this: script language=javascript ... var ts = new Date(?php echo time(); ?); ... /script -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php This doesn't work either. 1) the time now is 5 minutes fast compared to what it actually is on the server. 2) it still is not counting, it's stuck at the wrong time. Any other ideas? The date/time on the system is correct. I tried echoing the time() in php, and get this, 1067373085. Thanks, Jake -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] SESSIONMANAGEMENT -- gute php mailing list / gute leute
Babelfish: I am on the search for a good PHP mailing list, best in German... case I here wrong am, please I around apology. Problem: SESSION MANAGEMENT Note! !! session.use_cookies=0!! (and it is to also remain) 1. Why I can not by $_get['lid ' ] on $_post['lid']=lf_session_id(); access? (afterwards is a Header(Location... in it - overwrites?) 2. How do I get a reasonable session management WITHOUT COOKIES? PHP 4.2.2 is used. With this PHP version that does not function, as described. Nose? (seems so, already times after gegoogled) session_start(); always new worth... it does not supply a session is taken over. 3. Tried I already also a CLASS to create, these am however not global attainable (after Redirect) I am for everyone tap gratefully, which lets me despair less. Thousand thanks! Christoph Lockingen It seems like he's trying to write the session ID to the $_POST array, which reminds me of a bad idea. I think his goal is to use sessions without using cookies. Anybody who speaks german care to answer? Or perhaps use babelfish? On Tuesday 28 October 2003 12:16 pm, christoph lockingen wrote: Hallo ! Ich bin auf der Suche nach einer guten PHP Mailing-Liste, am besten in Deutsch...Falls ich hier falsch bin, bitte ich um Entschuldigung. Problem: SESSION-MANAGEMENT Achtung! !! session.use_cookies=0 !! (und sollen es auch bleiben) 1. Wieso kann ich nicht per $_GET['lid'] auf $_POST['lid']=lf_session_id(); zugreifen? (Danach ist ein Header(Location... drin - der überschreibt?) 2. Wie bekomme ich ein vernünftiges Sessionmanagement OHNE COOKIES hin? Eingesetzt wird PHP 4.2.2. Bei dieser PHP-Version funktioniert das nicht, wie beschrieben. Bug? (scheint so, schonmal nach gegoogled) session_start(); liefert immer neue werte... es wird keine session übernommen. 3. Probiert habe ich bereits auch eine CLASS zu schaffen, diese ist jedoch nicht global erreichbar (nach Redirect) Ich bin für jeden Tipp dankbar, der mich weniger verzweifeln läßt. Tausend Dank ! Christoph Lockingen -- Evan Nemerson [EMAIL PROTECTED] -- The greatest mistake is to imagine that the human being is an autonomous individual. The secret freedom which you can supposedly enjoy under a despotic government is nonsense, because your thoughts are never entirely your own. Philosophers, writers, artists, even scientists, not only need encouragement and an audience, they need constant stimulation from other people. It is almost impossible to think without talking. If Defoe had really lived on a desert island, he could not have written Robinson Crusoe, nor would he have wanted to. Take away freedom of speech, and the creative faculties dry up. -George Orwell -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Libs?
On Tuesday 28 October 2003 12:17 pm, Robert Sossomon wrote: Anyone know where I can get a good collection of PHP Libs (free) for PHP 4? I'm looking for some that can create PDF as well as Word or others. Also faxing abilities and such. Do you mean extensions to PHP, or libraries written in PHP? If the former, http://pecl.php.net/ if the latter, http://pear.php.net/ For PDFs, I currently reccomend FPDF from fpdf.org. It's written in PHP, which may or may not be what you want. For Word, you should create RTFs. Faxing I'm really not sure about- never looked into it. Thanks! Robert ~~~ Anytime four New Yorkers get into a cab together without arguing, a bank robbery has just taken place. -Johnny Carson. ~~~ -- Evan Nemerson [EMAIL PROTECTED] -- To achieve adjustment and sanity and the conditions that follow from them, we must study the structural characteristics of this world first and, then only, build languages of similar structure, instead of habitually ascribing to the world the primitive structure of our language. -Alfred Korzybski -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
--- CPT John W. Holmes [EMAIL PROTECTED] wrote: If you are not relying on a cookie based session, then this will work. Each login could be assigned a different session ID, so the requests for each browser will be different because of the different session IDs. What John is explaining here is that the URLs could be different if that is how the session ID is propogated, thus making the requests different (they're for different URLs). So, if you click a link from: http://example.org/foo.php?PHPSESSID=12345 it could be for: http://example.org/bar.php?PHPSESSID=12345 Hope that helps. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] (Semi OT) Number of concurent Users.
Hi I was wondering if anyone has any idea about how many users the next configuration can hold : Front End = Dual Xeon 2.4Ghz Compaq DL360 G3 1GB of memory SQL Server = Compaq DL 380 G3 Dual Xeon 2.4Ghz 2GB Memory 15K disks (RAID 0+1) Site can be a content site like weberdev.com or a simple ecommerce site running on Linux / Apache / MySQL / PHP. Any idea how many concurrent users can run on such a configuration? Any idea how this number will grow using one of the performance suits for PHP on the market? Sincerely berber Visit http://www.weberdev.com/ http://www.weberblog.com/ Today!!! To see where PHP might take you tomorrow. Share your code : http://addexample.weberdev.com Search for PHP Code from your browser http://toolbar.weberdev.com Share your thoughts : http://www.weberblog.com/submit.php?type=storytopic=PHP_Web_Logs -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Variables not passing to mail script
At 03:59 PM 10/27/2003 -0800, Jeff - Harbornet wrote: Disregard last email. I figured it out. Thanks. Care to tell the rest of us? I'm a newby and would like to know. Bob Rea PlusWeb [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] www.petard.us -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Variables not passing to mail script
From: Bob Rea [EMAIL PROTECTED] At 03:59 PM 10/27/2003 -0800, Jeff - Harbornet wrote: Disregard last email. I figured it out. Thanks. Care to tell the rest of us? I'm a newby and would like to know. Hmmm, that's obvious, since you can't even spell newbie. ;) ---John Holmes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
Chris Shiflett [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] --- CPT John W. Holmes [EMAIL PROTECTED] wrote: If you are not relying on a cookie based session, then this will work. Each login could be assigned a different session ID, so the requests for each browser will be different because of the different session IDs. What John is explaining here is that the URLs could be different if that is how the session ID is propogated, thus making the requests different (they're for different URLs). So, if you click a link from: That doesn't seem to be what he's saying. because of the different session IDs. It seems to me a better example of what he is saying would be: http://example.org/foo.php?PHPSESSID=12345 vs. http://example.org/foo.php?PHPSESSID=67890 But I was talking about cookies anyway. Which is where different browsers have different behaviors. In IE, by default, it will not pass a cookie from a new browser window. In Mozilla, by default, a new window keeps all the cookies currently set. I've mostly used IE, so I've always thought that it never passed cookies from a new browser window. Apparently, it just depends on which browser you're using and how it is setup. -- Rob http://example.org/foo.php?PHPSESSID=12345 it could be for: http://example.org/bar.php?PHPSESSID=12345 Hope that helps. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
--- Rob Adams [EMAIL PROTECTED] wrote: That doesn't seem to be what he's saying. because of the different session IDs. It seems to me a better example of what he is saying would be: http://example.org/foo.php?PHPSESSID=12345 vs. http://example.org/foo.php?PHPSESSID=67890 Perhaps I should have elaborated a bit more. Browser instance A: 1. Request http://example.org/foo.php 2. PHP assigns PHPSESSID of 12345 3. Returned page has a link for http://example.org/bar.php?PHPSESSID=12345 4. Request http://example.org/bar.php?PHPSESSID=12345 Browser instance B: 1. Request http://example.org/foo.php 2. PHP assigns PHPSESSID of 67890 3. Returned page has a link for http://example.org/bar.php?PHPSESSID=67890 4. Request http://example.org/bar.php?PHPSESSID=67890 Because A4 and B4 are different requests, they get different responses. So, in a way, the server is able to distinguish between the two instances, but only because of that. If instance A sends the request in B4, it will get the same response as instance B would have. That wasn't a great explanation, but maybe it is at least better than my last attempt. But I was talking about cookies anyway. Which is where different browsers have different behaviors. In IE, by default, it will not pass a cookie from a new browser window. This is very interesting. I might try to research this a bit more and see what the motivation was for doing this. From a user perspective, it seems very counterintuitive. Thanks for the info. Chris = My Blog http://shiflett.org/ HTTP Developer's Handbook http://httphandbook.org/ RAMP Training Courses http://www.nyphp.org/ramp -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] show_source
Is there a way to stop the function show_source() from putting extra code at the begginning and end of the code it grabs? Beginning: codefont color=#00 Middle: br / End: /font/code I am doing a str_replace to get rid of it, but it would be nice to be able to pass a parameter to the funtion to stop it from adding the extra code. Thanks for your time. Nathan Maki _ See when your friends are online with MSN Messenger 6.0. Download it now FREE! http://msnmessenger-download.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] php sessions
From: Chris Shiflett [EMAIL PROTECTED] But I was talking about cookies anyway. Which is where different browsers have different behaviors. In IE, by default, it will not pass a cookie from a new browser window. This is very interesting. I might try to research this a bit more and see what the motivation was for doing this. From a user perspective, it seems very counterintuitive. Thanks for the info. It may depend upon how you open the second window, too. Control-N may use the same cookies whereas starting a whole new instance may not. ---John Holmes... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] php sessions
On Tuesday, October 28, 2003 2:13 PM CPT John W. Holmes wrote: It may depend upon how you open the second window, too. Control-N may use the same cookies whereas starting a whole new instance may not. This is the case with IE. If I'm in my CMS and ctrl-N to get a new window, I can operate under both windows using the same session. If I open a new instance of IE and go to a page in the CMS beyond the login screen, it boots me back to the login screen. Cheers, Pablo -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] How do i mod php.ini to use an outside smtp?
php v4.12 on redhat linux 6.2. Is it possible to give a domain or ip instead of a path?? - MD -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php