Re: [PHP] help with setting menu styles with PHP

2006-03-16 Thread Anthony Ettinger
I did something similar on my page. I did a simple comparison in a loop through the menu DOM, foreach ($nodeList as $node){ if ($currentPage eq $nodeHref) { //set class attribute = 'active'; } } On 3/16/06, tedd [EMAIL PROTECTED] wrote: http://www.inspired-evolution.com/About_Me.php What

Re: [PHP] help with this error message please

2006-03-06 Thread Angelo Zanetti
Mark wrote: Can anyone tell me why i am getting this message when trying to login to the admin section, i am running the script off my local machine. Warning: session_register() [function.session-register]: Cannot send session cookie - headers already sent by (output started at

Re: [PHP] help with this error message please

2006-03-05 Thread chris smith
On 3/5/06, Mark [EMAIL PROTECTED] wrote: Can anyone tell me why i am getting this message when trying to login to the admin section, i am running the script off my local machine. Warning: session_register() [function.session-register]: Cannot send session cookie - headers already sent by

Re: [PHP] help with nl2br

2006-03-03 Thread Max Schwanekamp
canobit canobit wrote: I have cobbled the following code that when it retrieves the data from Mysql, the data is displayed with no line breaks which results in one large paragraph. I have been trying for quite awhile without sucess to get nl2br working with this code. The original data is

Re: [PHP] help with nl2br

2006-03-03 Thread canobit canobit
Thanks Pablo, that did the trick with one minor change, I had to remove the . in the quotations as it is was leading the first line of text with a . echo . nl2br($row[2]) . /b; TD. On 3/3/06, Pablo M. Rivas [EMAIL PROTECTED] wrote: Hello canobit: Did you try echo . . nl2br($row[1]) . /b;

Re: [PHP] help with nl2br

2006-03-03 Thread canobit canobit
snip All that said, you might want to invest some time in learning a DB abstraction layer such as ADODb or PEAR::DB (there are lots of others). You'll commonly find convenience functions to do things like output query results into an HTML table. Why waste time debugging the wheel? --

Re: [PHP] Help! Apache 2.2 gives segmentation fault errors with PHP.

2006-02-16 Thread Olaf Greve
Hi all, Yesterday I had trouble when configuring Apache 2.2 with PHP 4.4.2, which caused Apache to crash (segmentation fault) when calling various PHP functions. Just before heading home I encountered the source of the issue, as well as the solution. The hint to the answer resided in the

Re: [PHP] Help! Apache 2.2 gives segmentation fault errors with PHP.

2006-02-15 Thread Jochem Maas
apache2 needs to be built/run using the prefork worker module (as opposed to a threaded worker module which causes php to blow up quite often [due to the fgact that there are php extensions which are not thread safe]) - check that first. the duplicate name errors seem to stem fom the fact that

Re: [PHP] Help! Apache 2.2 gives segmentation fault errors with PHP.

2006-02-15 Thread Kevin Kinsey
Olaf Greve wrote: Hi guys, I suspect something went wrong in the way I try to use PHP. Basically, I first removed the installed /usr/ports/lang/php4 port, then built and installed the /usr/ports/www/mod_php4 port, and then added various php4-extensions, using the

RE: [PHP] Help Defending against Email Injection Attacks

2006-02-06 Thread Jim Moseby
- The most foolproof solution I can think of would be to continue logging the successful entries to a database and _not_ send the email. That way even if they get through, no emails get sent. The form would log the feedback and send an email to the admin that a comment is available for

Re: [PHP] Help Defending against Email Injection Attacks

2006-02-06 Thread John Hinton
Greg Schnippel wrote: Has anyone developed a really good defense against email injection attacks? I'm waging a prolonged campaign against these luser hordes on a number of non-profit sites I help maintain. I've tried to secure all of the feedback forms using the function below that I cobbled

Re: [PHP] Help Defending against Email Injection Attacks

2006-02-06 Thread Russell Jones
Why dont you just break the code. Before anything goes through replace colons with dashes, dashes with underscores, etc. Stuff that will not mess up readability but would prevent it from being parsed by the mail function. On 2/6/06, Jim Moseby [EMAIL PROTECTED] wrote: - The most foolproof

Re: [PHP] Help Defending against Email Injection Attacks

2006-02-06 Thread Liam Delahunty
On 2/6/06, Jim Moseby wrote: Is it time to abandon using mail() for all user contributed data? Sort of. Don't write any user input to the headers. Send the data to a default address, don't include anything in the subject or the headers from the input and you'll avoid the problems. -- Kind

Re: [PHP] Help Defending against Email Injection Attacks

2006-02-06 Thread Stut
Greg Schnippel wrote: Has anyone developed a really good defense against email injection attacks? I've implemented a complex algorithm to help prevent this problem. Every form I have has a text field with a random name surrounded by the text... If you are human please enter 'human'

Re: [PHP] Help Defending against Email Injection Attacks

2006-02-06 Thread Chris
Greg Schnippel wrote: Has anyone developed a really good defense against email injection attacks? snip A bit late but this is a good guide: http://securephp.damonkohler.com/index.php/Email_Injection -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit:

Re: [PHP] Help with mysql_query and INSERT INTO

2006-02-05 Thread Johan Martin
On Saturday, Feb 4, 2006, at 07:22 America/Los_Angeles, Colin Davis wrote: I need to insert a new record into a MySQL table which has an auto_increment field Ref as the primary index. When I have inserted the new record, I need to get the new Ref value in order to name some files to

Re: [PHP] Help with mysql_query and INSERT INTO

2006-02-05 Thread Colin Davis
Thank you, that is perfect. Regards Colin Davis http://www.ukpages.org Johan Martin [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] http://www.php.net/manual/en/function.mysql-insert-id.php This will give you the record id of the last record inserted (or created). Johan Martin

Re: [PHP] Help retrieving an HTML array

2006-02-02 Thread Richard Lynch
On Wed, February 1, 2006 3:06 pm, John Nichel wrote: I also don't _have_ to declare variables, don't _have_ to call mysql_close, etc, but that doesn't make it a good practice. The above 'standard' is pretty and all, but how many browsers out there are 100% standards compliant? Quoting will

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread Jochem Maas
Mauricio Pellegrini wrote: Hi , I have a HTML page with a form in which there are some inputs like these: input type=text name=xname value=3303 input type=text name=xname value=9854 input type=text name=xname value=n... the name of the input is always

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread Robert Cummings
On Wed, 2006-02-01 at 11:07, Mauricio Pellegrini wrote: Hi , I have a HTML page with a form in which there are some inputs like these: input type=text name=xname value=3303 input type=text name=xname value=9854 input type=text name=xname value=n...

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread Joe Henry
The input name must include [] (brackets) to let php know it's an array. Ex: input type=text name=xname[] value=3303 On Feb 1, 2006, at 9:07 AM, Mauricio Pellegrini wrote: Hi , I have a HTML page with a form in which there are some inputs like these: input type=text name=xname

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread John Nichel
Please don't hijack threads. Mauricio Pellegrini wrote: Hi , I have a HTML page with a form in which there are some inputs like these: input type=text name=xname value=3303 input type=text name=xname value=9854 input type=text name=xname value=n...

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread Mauricio Pellegrini
Thank you all for your valuable support. The problem is solved. Note: This kind of input definition (without the brackets) actually *DOES* create an array under HTML 4.x (and its subindexes are accesible thru javascript) input type=text name=xname value=3303 input type=text

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread John Nichel
Mauricio Pellegrini wrote: Thank you all for your valuable support. The problem is solved. Note: This kind of input definition (without the brackets) actually *DOES* create an array under HTML 4.x (and its subindexes are accesible thru javascript) input type=text name=xname

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread David Dorward
Robert Cummings wrote: input type=text name=xname[] value=n... I also took the liberty of adding double quotes to your attributes. There's no excuse for writing slop. Slop? authors may specify the value of an attribute without any quotation marks. The attribute value may only contain

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread Richard Lynch
Change it to: input name=xname[] On Wed, February 1, 2006 10:07 am, Mauricio Pellegrini wrote: Hi , I have a HTML page with a form in which there are some inputs like these: input type=text name=xname value=3303 input type=text name=xname value=9854

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread Richard Lynch
On Wed, February 1, 2006 2:52 pm, David Dorward wrote: Robert Cummings wrote: input type=text name=xname[] value=n... I also took the liberty of adding double quotes to your attributes. There's no excuse for writing slop. Slop? authors may specify the value of an attribute without any

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread David Dorward
Richard Lynch wrote: There's no excuse for writing slop. We recommend using quotation marks even when it is possible to eliminate them. Presumably because its less hassle to do so then to try to remember the exceptions. It doesn't make code that ignores that suggestion slop. -- David

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread Robert Cummings
On Wed, 2006-02-01 at 18:34, David Dorward wrote: Richard Lynch wrote: There's no excuse for writing slop. We recommend using quotation marks even when it is possible to eliminate them. Presumably because its less hassle to do so then to try to remember the exceptions. It doesn't

Re: [PHP] Help retrieving an HTML array

2006-02-01 Thread John Nichel
David Dorward wrote: Robert Cummings wrote: input type=text name=xname[] value=n... I also took the liberty of adding double quotes to your attributes. There's no excuse for writing slop. Slop? Yes, slop, ie sloppy. authors may specify the value of an attribute without any

Re: [PHP] Help with getting PHP to see Pear.

2006-01-24 Thread Sumeet
Payne wrote: Hi, I just installed SuSE 10 and I am having a problem with my phpnuke site and my maia site. PHPNUKE gives me this error... *Warning*: main(db/mysql.php): failed to open stream: No such file or directory in */srv/www/htdocs/bse/db/db.php* on line *53* *Warning*: main(): Failed

Re: [PHP] Help with getting PHP to see Pear.

2006-01-24 Thread Jesús Fernández
if you look to your phpinfo it says: '--without-pear' Maybe you'll need to install it with pear support or is it right just to add pear to the include_path? -- Esú - http://esu.proyectoanonimo.com http://www.proyectoanonimo.com

RE: [PHP] Help with getting PHP to see Pear.

2006-01-23 Thread Albert
Payne wrote: How can I get php to see pear, it is installed. I have install modules with pear for maia and horde but neither seem to see pear. I'm running SuSE 9.3 and had to add /usr/share/php to the include path in /etc/php.ini to be able to use the installed PEAR extensions. To enable

RE: [PHP] help me plz

2006-01-20 Thread Thomas
this with javascript (if you do not need 'fresh' data) Thomas -Original Message- From: Robert Graham [mailto:[EMAIL PROTECTED] Sent: 19 January 2006 09:34 AM To: suresh kumar Cc: php-general@lists.php.net Subject: Re: [PHP] help me plz suresh kumar wrote: hi, i am using 2 combo box one

Re: [PHP] Help with regular expressions

2006-01-19 Thread Richard Lynch
On Tue, January 17, 2006 1:54 pm, Carl Furst wrote: Ok I am so stumped.. I'm doing something stupid and I can't figure it out.. Here's the code: ?php $eml = '[EMAIL PROTECTED] ceo'; if (strpos($eml, ' ')) echo yep, there are spaces\n; //does strpos see the spaces? echo

Re: [PHP] help me plz

2006-01-18 Thread Max Belushkin
If this is on the same web page, your question has nothing to do with PHP - look into, i.e., JavaScript. suresh kumar wrote: hi, i am using 2 combo box one for country another one for city.when i select country name from combo box their corresponding city names has to be changed in their

RE: [PHP] help me pllzzzzzz

2006-01-18 Thread Jay Blanchard
[snip] i am having 2 combo box one for city another one for country,when i select particular country say india their corresponding cities will be displayed in city combobox as delhi,bangalore.,when i select Australia thier cities like perth,brisbanewill be displayed.plz help

Re: [PHP] help me pllzzzzzz

2006-01-18 Thread John Nichel
Jay Blanchard wrote: [snip] i am having 2 combo box one for city another one for country,when i select particular country say india their corresponding cities will be displayed in city combobox as delhi,bangalore.,when i select Australia thier cities like

RE: [PHP] help me pllzzzzzz

2006-01-18 Thread Dan Parry
Or my sense of sailing to deadlines :) -Original Message- From: John Nichel [mailto:[EMAIL PROTECTED] Sent: 18 January 2006 16:11 To: php-general@lists.php.net Subject: Re: [PHP] help me pllzz Jay Blanchard wrote: [snip] i am having 2 combo box one for city another one

RE: [PHP] help me pllzzzzzz

2006-01-18 Thread Duffy, Scott E
: RE: [PHP] help me pllzz Or my sense of sailing to deadlines :) -Original Message- From: John Nichel [mailto:[EMAIL PROTECTED] Sent: 18 January 2006 16:11 To: php-general@lists.php.net Subject: Re: [PHP] help me pllzz Jay Blanchard wrote: [snip] i am having 2 combo box one

Re: [PHP] help me pllzzzzzz

2006-01-18 Thread Jochem Maas
suresh kumar wrote: hi, i am having 2 combo box one for city another one for country,when i select particular country say india their corresponding cities will be displayed in city combobox as delhi,bangalore.,when i select Australia thier cities like perth,brisbanewill

Re: [PHP] help me pllzzzzzz

2006-01-18 Thread Anas Mughal
You need to build JavaScript logic for that. Try searching on JavaScript developer sites and mailing lists. This has nothing to do with PHP -- unless you are dynamically building the JavaScript. -- Anas Mughal On 1/18/06, suresh kumar [EMAIL PROTECTED] wrote: hi, i am having 2 combo

Re: [PHP] help me pllzzzzzz

2006-01-18 Thread Robert Cummings
On Wed, 2006-01-18 at 11:11, John Nichel wrote: Jay Blanchard wrote: [snip] i am having 2 combo box one for city another one for country,when i select particular country say india their corresponding cities will be displayed in city combobox as delhi,bangalore.,when i

Re: [PHP] help me pllzzzzzz

2006-01-18 Thread Richard Correia
Whatever Suresh, I know as a beginer you are facing this problems. I would suggest that you check standalone htm version of php document. The dynamic combo script can be located at http://www.weberdev.com/get_example.php3?count=4074mode=text This site has 1000s of FREE ready to use

Re: [PHP] help me plz

2006-01-18 Thread Robert Graham
suresh kumar wrote: hi, i am using 2 combo box one for country another one for city.when i select country name from combo box their corresponding city names has to be changed in their corresponding combo box.i dont know how 2 implement this.pz give me some idea.its urgent.

Re: [PHP] Help with regular expressions

2006-01-17 Thread John Nichel
Carl Furst wrote: Ok I am so stumped.. I'm doing something stupid and I can't figure it out.. Here's the code: ?php $eml = '[EMAIL PROTECTED]ceo'; if (strpos($eml, ' ')) echo yep, there are spaces\n; //does strpos see the spaces? echo preg_replace('/\s/', '', $eml);

Re: [PHP] Help with regular expressions

2006-01-17 Thread Al
John Nichel wrote: Carl Furst wrote: Ok I am so stumped.. I'm doing something stupid and I can't figure it out.. Here's the code: ?php $eml = '[EMAIL PROTECTED]ceo'; if (strpos($eml, ' ')) echo yep, there are spaces\n; //does strpos see the spaces? echo

RE: [PHP] Help with regular expressions

2006-01-17 Thread php-mail
-- -Original Message- From: Al [mailto:[EMAIL PROTECTED] Sent: 17 January 2006 22:45 To: php-general@lists.php.net Subject: Re: [PHP] Help with regular expressions John Nichel wrote: Carl Furst wrote: Ok I am so stumped.. I'm doing something stupid and I can't figure it out.. Here's

Re: [PHP] Help with regular expressions

2006-01-17 Thread Al
Al wrote: John Nichel wrote: Carl Furst wrote: Ok I am so stumped.. I'm doing something stupid and I can't figure it out.. Here's the code: ?php $eml = '[EMAIL PROTECTED] ceo'; if (strpos($eml, ' ')) echo yep, there are spaces\n; //does strpos see the spaces?

Re: [PHP] help plz

2006-01-16 Thread Richard Correia
Hey Suresh, I know ..we all have faced similar problem when we started our career in php perl mysql. Please visit the http://weberdev.com for ultimate article and code example for Php and Mysql. Try Wrox books for php5. Thanks Richard On 1/16/06, suresh kumar [EMAIL PROTECTED] wrote: hi,

Re: [PHP] help plz

2006-01-16 Thread Jay Paulson
I have this book and have been very impressed with it. However, if you are a beginner programmer I would say not to get it until you understand the basic programming concepts and have a working knowledge of PHP. :) On 1/16/06 1:14 AM, Ligaya Turmelle [EMAIL PROTECTED] wrote: I personally

RE: [PHP] help plz

2006-01-16 Thread Weber Sites LTD
A good book to check out : 100+ Practical PHP Solutions http://www.sitepoint.com/launch/weberdev/2/7 Download the sample chapter and see if you like it. Sincerely berber Visit the Weber Sites Today, To see where PHP might take you tomorrow. PHP code examples : http://www.weberdev.com

Re: [PHP] help plz

2006-01-16 Thread Ligaya Turmelle
I am also assuming you actually do know the basics of MySQL and PHP and are looking for that next step - past the beginner stuff. Ligaya Turmelle wrote: I personally liked George Schlossnagle's book Advanced PHP Programming, published by Sams.

Re: [PHP] help plz [Books]

2006-01-16 Thread Travis Doherty
Ligaya Turmelle wrote: I personally liked George Schlossnagle's book Advanced PHP Programming, published by Sams. I am also assuming you actually do know the basics of MySQL and PHP and are looking for that next step - past the beginner stuff. I agree. I have seen this book alone take

Re: [PHP] Help taking a string from a file

2006-01-15 Thread Curt Zirzow
On Sat, Jan 14, 2006 at 09:03:24AM -0700, Lists wrote: My goal is to take just the HTML for the image and link from the Flickr badge js script. ... ? // allow retrieval of external web source ini_set('allow_url_fopen',1); // get flickr js file $photo =

Re: [PHP] help plz

2006-01-15 Thread Ligaya Turmelle
I personally liked George Schlossnagle's book Advanced PHP Programming, published by Sams. http://www.amazon.com/gp/product/0672325616/qid=1137394700/sr=2-1/ref=pd_bbs_b_2_1/104-0195316-0794320?s=booksv=glancen=283155 suresh kumar wrote: hi, i am working as a web designer in PHP Mysql.i

Re: [PHP] Help for ISPs rolling out PHP

2006-01-13 Thread Richard Lynch
On Thu, January 12, 2006 1:51 pm, Ben Rockwood wrote: I'm working with a medium sized ISP to start rolling out PHP and MySQL services to customers. I've been looking around for best practices or help with such a roll out but not found anything. I'm confident I can roll out the services but

Re: [PHP] Help for ISPs rolling out PHP

2006-01-12 Thread Timothy Brier
Ben Rockwood wrote: I'm working with a medium sized ISP to start rolling out PHP and MySQL services to customers. I've been looking around for best practices or help with such a roll out but not found anything. I'm confident I can roll out the services but with so many other ISPs currently

Re: [PHP] Help getting PHP and GPG to work

2006-01-09 Thread Jason Petersen
On 1/9/06, zedleon [EMAIL PROTECTED] wrote: Has anybody had success using PHP and GPG to send encripted email from a form? Yes. You're on the right track. The method I used was to create a temp file with my data, encrypt it with GPG, read it back into a string, then mail() it. (Of course

Re: [PHP] Help getting PHP and GPG to work

2006-01-09 Thread Jason Petersen
On 1/9/06, Support [EMAIL PROTECTED] wrote: quote for the book- PHP scripts will invoke the encryption process, and the public key has to be on the key ring of the user invoking the encryption. On the Web server, PHP usually runs as user nobody or www or as the user for your Web server.

Re: [PHP] help register domain name

2006-01-05 Thread John Nichel
n.g. wrote: hi, i want to register a domain name through NetworkSolutions.com, but it require a credit card which i dont have to pay the bill. if you have a credit card, i can transfer to your account, and then you please regiter the domain using my info. or if you have any other ways to do

RE: [PHP] help register domain name

2006-01-05 Thread Jay Blanchard
[snip] hi, i want to register a domain name through NetworkSolutions.com, but it require a credit card which i dont have to pay the bill. if you have a credit card, i can transfer to your account, and then you please regiter the domain using my info. or if you have any other ways to do

Re: [PHP] help register domain name

2006-01-05 Thread Shafiq Rehman
This person should be awarded with some great prize :) Great topic. On 1/5/06, Jay Blanchard [EMAIL PROTECTED] wrote: [snip] hi, i want to register a domain name through NetworkSolutions.com, but it require a credit card which i dont have to pay the bill. if you have a credit card, i

Re: [PHP] help register domain name

2006-01-05 Thread Al
John Nichel wrote: n.g. wrote: hi, i want to register a domain name through NetworkSolutions.com, but it require a credit card which i dont have to pay the bill. if you have a credit card, i can transfer to your account, and then you please regiter the domain using my info. or if you have

Re: [PHP] help register domain name

2006-01-05 Thread Mark Charette
Al wrote: John Nichel wrote: n.g. wrote: hi, i want to register a domain name through NetworkSolutions.com, but it require a credit card which i dont have to pay the bill. if you have a credit card, i can transfer to your account, and then you please regiter the domain using my info. or

Re: [PHP] Help Desk software

2005-12-22 Thread Peppy
http://phptickets.org/ - Original Message - From: Glenn Sieb [EMAIL PROTECTED] To: php-general@lists.php.net Cc: Daniel Lahey [EMAIL PROTECTED] Sent: Tuesday, December 20, 2005 10:13 PM Subject: Re: [PHP] Help Desk software Daniel Lahey said the following on 12/20/2005 10:28 PM

Re: [PHP] Help Desk software

2005-12-21 Thread Daniel Lahey
I found one set of links that might prove helpful: http:// www.helpdesk.com/software-helpdesk.htm A lot of the software doubles as asset management software or comes bundled with such a module. There are a yitload of links on that page. I'm only on the Bs. Good luck. On Dec 21, 2005,

Re: [PHP] Help Desk software

2005-12-21 Thread Tim Boring
On Wed, 2005-12-21 at 09:17 -0800, Daniel Lahey wrote: I found one set of links that might prove helpful: http:// www.helpdesk.com/software-helpdesk.htm A lot of the software doubles as asset management software or comes bundled with such a module. There are a yitload of links on that

Re: [PHP] Help Desk software

2005-12-20 Thread Glenn Sieb
Daniel Lahey said the following on 12/20/2005 10:28 PM: Can anyone recommend some good Open-Source Help Desk software for PHP? (I know this is a little off-topic, but I'm having a hard time finding decent Open Source software.) IMHO the best is RT, which is Perl and Mason.

Re: [PHP] Help with the copy command...

2005-12-16 Thread Robin Vickery
On 12/15/05, Tim Meader [EMAIL PROTECTED] wrote: Okay, this seems like a ridiculously easy question which shouldn't even need asking, but I'm having trouble getting the builtin copy command to work properly. It seems to work fine as long as I feed it a full constant string path for each

Re: [PHP] Help with the copy command...

2005-12-16 Thread Tim Meader
What difference are you seeing in the files I give in the example? Are they not identical paths? Thanks. Hristo Yankov wrote: The two examples you give are not the same? I see different files. Please, doublecheck. --- Tim Meader [EMAIL PROTECTED] wrote: Okay, this seems like a

Re: [PHP] Help with the copy command...

2005-12-16 Thread adriano ghezzi
just put the wrong lines in a file and run it from the shell with php -f you should get more info about what's going wrong hyh ciao! 2005/12/16, Tim Meader [EMAIL PROTECTED]: What difference are you seeing in the files I give in the example? Are they not identical paths? Thanks. Hristo

Re: [PHP] Help with the copy command...

2005-12-15 Thread Hristo Yankov
The two examples you give are not the same? I see different files. Please, doublecheck. --- Tim Meader [EMAIL PROTECTED] wrote: Okay, this seems like a ridiculously easy question which shouldn't even need asking, but I'm having trouble getting the builtin copy command to work properly. It

Re: [PHP] Help with preg_match and windows domain logins...

2005-12-12 Thread Robin Vickery
On 12/13/05, Daevid Vincent [EMAIL PROTECTED] wrote: I'm trying to do what should be a very simple regex, but can't seem to get PHP to work, yet regex-coach and even an XML .XSD work fine: Valid forms of a windows logon are: foo\bar \\foo\bar [...] //preg_match('/()?.+(\\).+/',

Re: [PHP] help with preg_replace only part of the string

2005-12-06 Thread David Grant
Replace the middle (.*) with ([^]*). This tells the regex engine to ignore new opening tags. Cheers, David Georgi Ivanov wrote: Hi, I want to replace the content of html links : a href=foo name=blaREPLACETHIS/a. $html=preg_replace(/(a.*name=.*)(.*)\/a/isU,$link,$html,1); This generally

Re: [PHP] help with preg_replace only part of the string

2005-12-06 Thread Richard Heyes
Georgi Ivanov wrote: Hi, I want to replace the content of html links : a href=foo name=blaREPLACETHIS/a. $html=preg_replace(/(a.*name=.*)(.*)\/a/isU,$link,$html,1); This generally works but removes a,/a tags too. How to make it work without removing anything else than (.*) in the middle of

Re: [PHP] help with preg_replace only part of the string

2005-12-06 Thread Miles Thompson
At 07:06 AM 12/6/2005, Richard Heyes wrote: Georgi Ivanov wrote: Hi, I want to replace the content of html links : a href=foo name=blaREPLACETHIS/a. $html=preg_replace(/(a.*name=.*)(.*)\/a/isU,$link,$html,1); This generally works but removes a,/a tags too. How to make it work without removing

Re: [PHP] help avoid multiple login

2005-11-29 Thread Jochem Maas
Matt Monaco wrote: If you store your login object in a session, when the browser window is closed the object will automatically be destroyed, thus calling the destructor. exactly what is it that triggers the object destruction??? since when is it normal practice for a browser to do a request

Re: [PHP] help avoid multiple login

2005-11-29 Thread Richard Heyes
Jochem Maas wrote: it might be possible to use some browser plugin to hit the server if it notices that it's window is being closed... although I have a sneaking suspicion that Flash, for instance, has the same problem as javascript with not being able to differentiate between the page

Re: [PHP] help avoid multiple login

2005-11-29 Thread Jochem Maas
Richard Heyes wrote: Jochem Maas wrote: it might be possible to use some browser plugin to hit the server if it notices that it's window is being closed... although I have a sneaking suspicion that Flash, for instance, has the same problem as javascript with not being able to differentiate

RE: [PHP] help avoid multiple login

2005-11-28 Thread mail.pmpa
-Mensagem original- De: Matt Monaco [mailto:[EMAIL PROTECTED] Enviada: terça-feira, 29 de Novembro de 2005 0:02 Para: php-general@lists.php.net Assunto: [PHP] help avoid multiple login Create an object with the functionality of your choosing, in the destructor perform your cleanup

RE: [PHP] help avoid multiple login

2005-11-28 Thread mail.pmpa
De: Matt Monaco [mailto:[EMAIL PROTECTED] Create an object with the functionality of your choosing, in the destructor perform your cleanup operations. The problem is I don't know when a member closes the browser window. If I knew that i would automatically logout that member. Thanks. -- PHP

Re: [PHP] help avoid multiple login

2005-11-28 Thread Matt Monaco
If you store your login object in a session, when the browser window is closed the object will automatically be destroyed, thus calling the destructor. In response to the message you send directly to me, you would create a file called Login.class.php and at the top of each page include the

Re: [PHP] Help with Reverse Tree Traversal using Recursion ..

2005-11-14 Thread Richard Lynch
On Mon, November 14, 2005 7:46 am, Greg Schnippel wrote: I have a large data tree that I wanted to display in an outline format. I used a textbook tree recursion function to go through the data and display it as nested unordered lists: function outputTree($id) { if

Re: [PHP] Help with Reverse Tree Traversal using Recursion ..

2005-11-14 Thread Greg Schnippel
Richard - Thanks for the helpful suggestion but that won't resolve my problem the way I currently have it written because I'm creating a new, nested ul each time I loop through: print ul; foreach ($parent as $key = $value) { ... } print /ul; So when I tried this, the output was still inverted

RE: [PHP] Help with new config

2005-11-01 Thread Rob Agar
hi John You'll probably see whats up if you tell php to spit out error messages - set display_errors = 1 in php.ini hth Rob -Original Message- From: John Taylor-Johnston [mailto:[EMAIL PROTECTED] Sent: Tuesday, 1 November 2005 12:32 PM To: PHP-General Subject: [PHP] Help with

Re: [PHP] Help with a regular expression for 0, 1 or 2 decimal places

2005-10-24 Thread Richard Lynch
On Mon, October 24, 2005 3:59 pm, Shaun wrote: I am trying to create a regular expression for a width of a room, the value can be a whole integer (up to 999) with up to 2 decimal places -when it is stored in the database mysql will pad the value accordingly. /^[0-9]{1,3}.?[0-9]{0,2}?$/

RE: [PHP] Help needed / failed to open stream: Permission denied

2005-10-19 Thread Jim Moseby
Hello, Trying to read a binary file in MySQL database, i have the following error : Warning: fopen(./) [function.fopen]: failed to open stream: Permission denied in d:\...\download.php on line 57 This is line 57 $file_handle = fopen(./ . $file_name, r); and my function

Re: [PHP] Help needed / failed to open stream: Permission denied

2005-10-19 Thread Jochem Maas
Ndagi Mutiri wrote: Hello, I can't be of any help here but couldn't help noticing that th OP (Ndagi) is dealing with dutch language DB entities and comments/output in french and code (vars etc) in english bet that can be a PITA :-) Trying to read a binary file in MySQL database, i

Re: [PHP] Help with logic :(

2005-10-14 Thread aaronjw
Hi all, Just wondering how one would do multiple rows? Instead of me me copying and pasting the same row of code 15 times (multiple data entry form), I just loop until it counts 15? Loops are not a strong point for me at all :( Thanks in advance!!! Aaron -- PHP General Mailing List

Re: [PHP] Help with logic :(

2005-10-14 Thread aaronjw
NEVERMIND. Solved it. Thanks!!! A Hi all, Just wondering how one would do multiple rows? Instead of me me copying and pasting the same row of code 15 times (multiple data entry form), I just loop until it counts 15? Loops are not a strong point for me at all :( Thanks in advance!!!

Re: [PHP] Help with logic :(

2005-10-14 Thread Dan McCullough
Not a problem, good to see. On 10/14/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: NEVERMIND. Solved it. Thanks!!! A Hi all, Just wondering how one would do multiple rows? Instead of me me copying and pasting the same row of code 15 times (multiple data entry form), I just

Re: [PHP] help me in creating tables on the fly

2005-10-12 Thread Jochem Maas
Suresh Pandian wrote: hello friends, im currently working on creating musical forum. i need to create tables for every song uploaded on the fly to save the comments and rates entered by the viewers. im unable to create tables on the fly. ... if I

Re: [PHP] help me in creating tables on the fly

2005-10-12 Thread Jasper Bryant-Greene
Suresh Pandian wrote: im currently working on creating musical forum. i need to create tables for every song uploaded on the fly to save the comments and rates entered by the viewers. im unable to create tables on the fly. can anyone know how to create tables on the fly .plz

Re: [PHP] Help with logic :(

2005-10-11 Thread Jochem Maas
Richard Lynch wrote: On Mon, October 10, 2005 3:24 pm, Dan McCullough wrote: create a function to check if the rndnumber=couponcode row count = 0 if not then redo rndnumber if it does = 0 then insert rndnumber N! You are creating a RACE CONDITION in which ONE

Re: [PHP] Help with logic :(

2005-10-11 Thread aaronjw
Hi Richard, Ok... I do already have a Unique index on the column but this process is something that I cannot echo out the error code to the user. The code is generated on the fly when an order an is placed so you can see... I can't echo out the error to the customer. Can I do an if statement IF

Re: [PHP] Help with logic :(

2005-10-11 Thread Dan McCullough
Yes I believe that is what Richard was saying about Trap the INSERT error, you should get an error back from the database about having a problem with the insert instead of showing that error you will want to add some logic that when that error occurs you simply generate another number. On

Re: [PHP] Help with logic :(

2005-10-11 Thread Jochem Maas
Dan McCullough wrote: Yes I believe that is what Richard was saying about Trap the INSERT error, you should get an error back from the database about having a problem with the insert instead of showing that error you will want to add some logic that when that error occurs you simply generate

Re: [PHP] Help with logic :(

2005-10-11 Thread aaronjw
Thanks everyone. Makes sense. Now I got another issue. When I try to see if an error exists I get this: Warning: mysql_error(): supplied argument is not a valid MySQL-Link resource in /home//public_html/Store/test.php on line 14 Is there a setting somewhere that I need to set to make

Re: [PHP] Help with logic :(

2005-10-11 Thread Dan McCullough
got some code so we can see? On 10/11/05, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote: Thanks everyone. Makes sense. Now I got another issue. When I try to see if an error exists I get this: Warning: mysql_error(): supplied argument is not a valid MySQL-Link resource in

<    1   2   3   4   5   6   7   8   9   10   >