Re: [PHP] Best way to figure out whether a query returns RESULT or NON-RESULT

2004-10-16 Thread Chris
Karam Chand wrote: Hello, I have an app where one module is similar to phpMyAdmin (well only .1%) with error_reporting() set to E_ALL. Now a user can execute any query. What is the best way to know whether a query is result or non-result. e.g. . . . Thanks in advance Regards, Karam As it

[PHP] Regex help...

2004-10-16 Thread Murray @ PlanetThoughtful
Hi All, I rather badly need some help with a regular expression. I need to identify the occurrence of the following search string in another string, and replace it with some text followed by the identified search string. search string pa

Re: [PHP] Best way to figure out whether a query returns RESULT or NON-RESULT

2004-10-16 Thread Karam Chand
Hello, mysql_query() returns non-false even if there was an UPDATE statement and the query was successful. But if I put the $result variable in mysql_num_rows() it returns an error, $result in invalid handle. I was asking how to know that where its an UPDATE statement so I dont call

[PHP] Re: php_printer functions, how to detect printer is ready to print out

2004-10-16 Thread David Robley
On Sat, 16 Oct 2004 09:16, Ck wrote: Hi. I am currently working on a project that the script should print-out documents whenever local users wishe to print-out. However, my concern is how to detect THE printer is ready to print out NOT only its driver is installed. Thank you in

Re: [PHP] Best way to figure out whether a query returns RESULT or NON-RESULT

2004-10-16 Thread Marek Kilimajer
Karam Chand wrote: Hello, mysql_query() returns non-false even if there was an UPDATE statement and the query was successful. But if I put the $result variable in mysql_num_rows() it returns an error, $result in invalid handle. I was asking how to know that where its an UPDATE statement so I

[PHP] urlencode() and newlines?

2004-10-16 Thread Nick Wilson
hello all, For reasons beyond my immediate control i have to keep some strings of text in a text *new line delimited* text file. I also have to urlencode those strings for use in my script. Like this: ## text file This is a line\nThis is another line This is another string\nwith some

[PHP] dirty words

2004-10-16 Thread Mag
Hi, I am useing file_get_contents on a remote page then using stristr() to make sure there are no bad words and its a family site. Right now I am checking for just 3 bad words which means 3 stristr() function calls, but if the bad words increase then that would mean more calls I have seen

RE: [PHP] dirty words

2004-10-16 Thread Chris Kay
in_array() can check your $string against a array and return if a bad word is in string Is this what you are after? Chris Kay (CK) [EMAIL PROTECTED] -Original Message- From: Mag [mailto:[EMAIL PROTECTED] Sent: Sunday, 17 October 2004 12:41 AM To: php php Subject: [PHP] dirty words

RE: [PHP] dirty words

2004-10-16 Thread Mag
Hey! Thanks, I think in_array() is what I was looking for, but by a quick glance I think its case sensitive (?), I didnt want to use a class for this coz it kind of seemed like using a gun instead of a flyswatter :-) Also, any way to check if a remote file exists? I am presently using this:

Re: [PHP] urlencode() and newlines?

2004-10-16 Thread Marek Kilimajer
Nick Wilson wrote: hello all, For reasons beyond my immediate control i have to keep some strings of text in a text *new line delimited* text file. I also have to urlencode those strings for use in my script. Like this: ## text file This is a line\nThis is another line This is another

Re: [PHP] dirty words

2004-10-16 Thread Kevin Waterson
This one time, at band camp, Mag [EMAIL PROTECTED] wrote: Hi, I am useing file_get_contents on a remote page then using stristr() to make sure there are no bad words and its a family site. Right now I am checking for just 3 bad words which means 3 stristr() function calls, but if the bad

Re: [PHP] urlencode() and newlines?

2004-10-16 Thread Nick Wilson
* and then Marek Kilimajer declared Nick Wilson wrote: hello all, For reasons beyond my immediate control i have to keep some strings of text in a text *new line delimited* text file. I also have to urlencode those strings for use in my script. Like this: ## text file This is

Re: [PHP] urlencode() and newlines?

2004-10-16 Thread Marek Kilimajer
Nick Wilson wrote: * and then Marek Kilimajer declared Nick Wilson wrote: hello all, For reasons beyond my immediate control i have to keep some strings of text in a text *new line delimited* text file. I also have to urlencode those strings for use in my script. Like this: ## text file

Re: [PHP] urlencode() and newlines?

2004-10-16 Thread Nick Wilson
* and then Marek Kilimajer declared echo urlencode(This is a line\nThis is another line); Yep, i can see that it's encoded but when the data is POSTed to a form, it does not come out as a newline... Are you sure the other side accepts, does not remove newlines? Create a form

[PHP] Fatal error

2004-10-16 Thread Pahlevanzadeh Mohsen
Dear members,I get an error,What does mean my error? : Fatal error: Maximum execution time of 30 seconds exceeded in /var/www/html/votting/vote_implement.php on line 8 = -DIGITAL SIGNATURE--- ///Mohsen Pahlevanzadeh Network administrator programmer

Re: [PHP] Another regex problem - help!

2004-10-16 Thread Jason Wong
On Sunday 17 October 2004 03:54, Murray @ PlanetThoughtful wrote: In this case, I'm trying to perform a preg_match using the following expression: preg_match(/^\[\[ft.$fn[1].:(.*)\]\]$/m,$content,$ft); Nearly there, except that ']' is not a special char and should not be escaped. In the

Re: [PHP] Fatal error

2004-10-16 Thread Juan Pablo Herrera
In your script use set_time_limit(0), and look http://ar2.php.net/manual/en/function.set-time-limit.php for understand the function. Regards, JP Dear members,I get an error,What does mean my error? : Fatal error: Maximum execution time of 30 seconds exceeded in

Re: [PHP] Fatal error

2004-10-16 Thread Kevin Waterson
This one time, at band camp, Pahlevanzadeh Mohsen [EMAIL PROTECTED] wrote: Dear members,I get an error,What does mean my error? : Fatal error: Maximum execution time of 30 seconds exceeded in /var/www/html/votting/vote_implement.php on line 8 It means the Maximum execution time of 30 seconds

[PHP] Header sending

2004-10-16 Thread Pahlevanzadeh Mohsen
Dear members,I need to post a header without Form tag. Already i have used input tag (hidden type),But i don't kbow to how do it. Please guide me Yours,Mohsen = -DIGITAL SIGNATURE--- ///Mohsen Pahlevanzadeh Network administrator programmer

[PHP] Is there a way to...

2004-10-16 Thread GH
Is there a way to make sure that a page is only loaded via a require or include statement? or other type of SSI? I would like to make sure that a 'parent document' (namely admin_template.php) only calls the php file? Thanks -- PHP General Mailing List (http://www.php.net/) To unsubscribe,

Re: [PHP] Header sending

2004-10-16 Thread Chris Shiflett
--- Pahlevanzadeh Mohsen [EMAIL PROTECTED] wrote: I need to post a header without Form tag. The header() function can be used to add a header to the response: http://www.php.net/header I'm not sure what this has to do with a form tag... Chris = Chris Shiflett - http://shiflett.org/ PHP

Re: [PHP] Is there a way to...

2004-10-16 Thread GH
Your right, this is not what I was expecting, I was thinking there was another way... Sounds good.. but any other suggestions? On Sat, 16 Oct 2004 21:40:56 -0400, Minuk Choi [EMAIL PROTECTED] wrote: well, this is probably not what you were expecting... but you can try this

Re: [PHP] PHP App User Permissions Tecnique

2004-10-16 Thread GH
However I would think that using the db would allow for you to change the persons while they are using the site and would not make them have to relog in suggestions? On Fri, 15 Oct 2004 10:52:53 +0200, Ian Firla [EMAIL PROTECTED] wrote: Definitely store them in a session. A db lookup

[PHP] guessing timezone based on country/state/city

2004-10-16 Thread Justin French
I have an event CMS where really, I should know the TZ of the events, which can happen world wide. However the user base is not computer heads, so I can't just ask them. So, I'm faced with the prospect of making an educated guess based on the Country, State and Capital City information

Re: [PHP] Best way to figure out whether a query returns RESULT or NON-RESULT

2004-10-16 Thread Karam Chand
Thanks. Never knew there existed (===). Silly me :) Regards, Karam --- Marek Kilimajer [EMAIL PROTECTED] wrote: Karam Chand wrote: Hello, mysql_query() returns non-false even if there was an UPDATE statement and the query was successful. But if I put the $result variable in

Re: [PHP] guessing timezone based on country/state/city

2004-10-16 Thread Curt Zirzow
* Thus wrote Justin French: I have an event CMS where really, I should know the TZ of the events, which can happen world wide. However the user base is not computer heads, so I can't just ask them. So, I'm faced with the prospect of making an educated guess based on the Country, State

[PHP] Another regex problem - help!

2004-10-16 Thread Murray @ PlanetThoughtful
Hi All, I'm trying to match a particular pattern in a multi-line string. The string might look like: string Some text. Some more text. [[ft1: An example of the search string [[fn2 [[ft2: Another example of a search string]] Extra text /string In this case, I'm trying to perform a