[PHP] Re: Compare two TXT files

2004-07-17 Thread Paul Chvostek
with the file() function, then use the array_diff() function to spit out a list of lines in one file but not the other. Or, you could tell us more about what you're actually trying to do. :) p -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse

[PHP] Re: Webcapture to PDF

2004-05-13 Thread Paul Chvostek
a browser's idea of what carbon-based lifeforms think is pretty. If your goal is to take browser snapshots, then look at one of first two tools mentioned. If your goal is simply to convert HTML to ps/pdf, then html2ps is the way to go. -- Paul Chvostek

Re: [PHP] Re: strip comments from HTML?

2004-05-06 Thread Paul Chvostek
; print ereg_replace(!--([^-][^-]?[^]?)*--, ,$text);' one two whee, it works! :) -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http

[PHP] Re: strip comments from HTML?

2004-05-06 Thread Paul Chvostek
. And the close of the comment can't be prepresented as a range, since it's multiple characters. Not to say it can't be done. I just can't think of how at the moment. :) -- Paul Chvostek [EMAIL PROTECTED] it.canada

Re: [PHP] Re: strip comments from HTML?

2004-05-06 Thread Paul Chvostek
ereg_replace([^ac],,$text); returns So ... this is interesting, and perhaps I'll investigate it further if the spirit moves me. ;-) -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca

Re: [PHP] paging methodology

2004-05-05 Thread Paul Chvostek
changes while someone's browsing. Note that this is not safe code as is. :) At the very least, you should format-check $_GET['offset'] before using it for anything. p -- Paul Chvostek [EMAIL PROTECTED] it.canada

[PHP] Re: Regular Expression

2004-05-04 Thread Paul Chvostek
? Why not just strip out the braces and explode on commas? That'll be lighter than regexps any day. If the input is guaranteed to be formatted the way you describe, you could do something like: $out = explode(,, substr($in, 1, strlen($in)-2)); -- Paul Chvostek

[PHP] Re: Challenge: Sessions Frames

2004-01-25 Thread Paul Chvostek
variables at the same time, you may be experiencing file locking issues in your session files. Check http://php.net/session_write_close for some discussion on this. I don't understand what's happening here. Any thoughts? If none of the above suggestions help, then I have no clue. :-) p -- Paul

[PHP] Re: RewriteRule REGEX ?

2004-01-24 Thread Paul Chvostek
are trying to point requests for /articles.php?id=123 to a file named 123 in the directory articles, then you'll still need to inspect your error_log. -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp

Re: [PHP] web page thumbs

2004-01-21 Thread Paul Chvostek
. ** -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe

[PHP] Re: Form woes

2004-01-21 Thread Paul Chvostek
received this e-mail in error please e-mail the sender. ** -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web

[PHP] Re: alternative to protecting files through http auth.

2004-01-14 Thread Paul Chvostek
site, you can create an unbrowsable storage directory protected with a .htaccess file. If the filesystem permissions are correct, your PHP script will be able to read content from that directory, because PHP code isn't subject to .htaccess rules. -- Paul Chvostek

[PHP] Re: detecting flash in php

2004-01-08 Thread Paul Chvostek
-- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe

Re: [PHP] Counting back 90 days...

2004-01-05 Thread Paul Chvostek
. ;-) -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe

Re: [PHP] Counting back 90 days...

2004-01-05 Thread Paul Chvostek
timestamps have been around since unix began, and strtotime supports arbitrary human-readable formats. PHP supports both of these. How does PHP make dates more difficult? -- Paul Chvostek [EMAIL PROTECTED] it.canada

[PHP] Re: What would the best way to veladate a URL string?

2003-12-13 Thread Paul Chvostek
... -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe

[PHP] wrong headers from server

2003-09-01 Thread Paul Chvostek
results depending on how it's called: curl -D- http://hostname/test.jpg | grep Content- Content-Type: text/html curl -I http://hostname/test.jpg | grep Content- Content-Type: image/jpeg What's going on here? -- Paul Chvostek [EMAIL PROTECTED

[PHP] Re: easier than switch

2003-08-04 Thread Paul Chvostek
']]; Is that long the lines of what you're looking for? -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web/ -- PHP General

[PHP] Re: subtracting dates...

2003-08-02 Thread Paul Chvostek
for folks over 33. ;) -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web/ -- PHP General Mailing List (http://www.php.net

[PHP] Re: Hi

2003-07-22 Thread Paul Chvostek
this doesn't sound like a problem with Hi, as your subject line indicated. -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web

[PHP] Re: How to..

2003-07-21 Thread Paul Chvostek
sanity checking. This method may be prone to security problems. -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web

[PHP] Re: Mail From option in PHP.ini

2003-07-18 Thread Paul Chvostek
. You also might get a performance gain by doing things through FastCGI, though you'd lose some of the module-specific features like persistent database connections. Worth testing, anyway. Let us know how it goes. :) -- Paul Chvostek [EMAIL PROTECTED

[PHP] Re: running SSH through a PHP script

2003-07-18 Thread Paul Chvostek
always match ^[a-z0-9]+$ . Nothing being used in the ssh command should be allowed to have [;|] in it. Be so anal and paranoid that you risk compromising functionality, and you're less likely to screw yourself. -- Paul Chvostek [EMAIL PROTECTED

Re: [PHP] How unsafe is register_globals?

2003-07-17 Thread Paul Chvostek
it on at the moment. Any idea how I give the user local register_globals control without also letting them alter the other php.ini options? -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http

Re: [PHP] How unsafe is register_globals?

2003-07-17 Thread Paul Chvostek
and open_basedir. I don't have a non-production machine to test it on at the moment. Any idea how I give the user local register_globals control without also letting them alter the other php.ini options? -- Paul Chvostek [EMAIL PROTECTED

[PHP] How unsafe is register_globals?

2003-07-16 Thread Paul Chvostek
?) Thoughts? -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http://www.it.ca/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] How unsafe is register_globals?

2003-07-16 Thread Paul Chvostek
enough an AllowOverride statement that only register_globals can be changed? I wouldn't want a user to use his .htaccess file to turn off safe_mode or open_basedir. -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting

[PHP] Re: elegant way of doing something else the last time through a loop?

2003-07-15 Thread Paul Chvostek
.= ' ORDER BY name'; -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web/ -- PHP General Mailing List (http://www.php.net

[PHP] Re: Mailing list server with PHP frontend

2003-07-13 Thread Paul Chvostek
) to be the authoritative address of the sender, superceding the From and Reply-To headers. The only way around it is to spoof the envelope sender, thereby falsifying your headers. Gahgh. Now ... if you were to write a class to manage Mailman configs ... that would be useful. ;-) -- Paul Chvostek

[PHP] Re: Mind exploded on this one!

2003-07-11 Thread Paul Chvostek
as $value) ${$value} = true; Is either of these approaches what you're after? -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http

[PHP] Re: what's wrong with this?????

2003-07-08 Thread Paul Chvostek
the pieces together probably makes sense in the long run. -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web/ -- PHP General

Re: [PHP] Regular Expression

2003-07-08 Thread Paul Chvostek
built will also match an $address of p\o box. -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web/ -- PHP General Mailing

[PHP] Re: script not stopping

2003-07-07 Thread Paul Chvostek
On Mon, Jul 07, 2003 at 03:28:27PM -0600, Micah Montoy wrote: if ($_POST[imgList] = ){ You're *assigning* a variable in this condition. -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca

[PHP] Re: script not stopping

2003-07-07 Thread Paul Chvostek
Paul Chvostek [EMAIL PROTECTED] wrote in message news:[EMAIL PROTECTED] On Mon, Jul 07, 2003 at 03:28:27PM -0600, Micah Montoy wrote: if ($_POST[imgList] = ){ You're *assigning* a variable in this condition. On Mon, Jul 07, 2003 at 04:02:21PM -0600, Micah Montoy wrote: How do I

[PHP] security question

2003-07-04 Thread Paul Chvostek
Can anyone think of any security caveats with regard to turning output_buffering on? I can't, but it's too hot to think straight these days Tnx. -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp

[PHP] Re: [PHP-DB] Database question

2003-07-03 Thread Paul Chvostek
variable and then re-used by another session. Check out http://www.php.net/features.persistent-connections for details. -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting

Re: [PHP] online file management

2003-07-02 Thread Paul Chvostek
- Original Message - From: Paul Chvostek [EMAIL PROTECTED] I'm looking for a tool that will allow online file management, with a UI something like that of a traditional FTP client. The ideal candidate would authenticate based on a MySQL table and would be able to handle

Re: [PHP] safe_mode and file/directory ownership

2003-07-02 Thread Paul Chvostek
/en/features.safe-mode.php Other than that consider turning off safe mode if you have access to it, or turn it off for your virtual host. Paul Chvostek wrote: I've got a script whose configuration creates a storage directory owned by the web server in which files get stored, also owned

Re: [PHP] online file management

2003-07-02 Thread Paul Chvostek
and downloaded once or twice then deleted, I won't have to deal with ongoing performance issues. -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http

[PHP] online file management

2003-07-01 Thread Paul Chvostek
FTP client, but I'm open to that if nothing else is available. Before I write one myself, is there a package that has already been built that any one can recommend (or recommend against)? Thanks. :-) -- Paul Chvostek [EMAIL PROTECTED] it.canada

[PHP] safe_mode and file/directory ownership

2003-07-01 Thread Paul Chvostek
won't be able to suid to another user. If I make the directory owned by the user, the files will be inaccessible, but if I make the directory uid 80, then *it* will be inaccessible. Is there some other solution to storing (and then retrieving) files with safe_mode on? Thanks. -- Paul Chvostek

[PHP] Re: WEB HOST

2003-06-24 Thread Paul Chvostek
if you have enough technical ability to install your own software. -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web

Re: [PHP] Re: WEB HOST

2003-06-24 Thread Paul Chvostek
. I haven't yet written the scripts to cancel or do automatic software installation yet. They're on the menus so folks can see what's coming. You should be able to get into phpMyAdmin, but it can take a minute for your password to be updated after you confirm the account. -- Paul Chvostek

[PHP] Re: sending headers

2003-06-23 Thread Paul Chvostek
://samspade.org/t/safe . -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web/ -- PHP General Mailing List (http://www.php.net

[PHP] Re: Performance question

2003-06-23 Thread Paul Chvostek
. -- Paul Chvostek [EMAIL PROTECTED] it.canadahttp://www.it.ca/ Free PHP web hosting!http://www.it.ca/web/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit

[PHP] Re: Another hosting question....

2003-06-19 Thread Paul Chvostek
knowledgeable, the upstream connectivity is fast and reliable (though not multihomed AFAIK). The servers are FreeBSD with CPanel (unless you specifically require something else), and the prices are excellent. Plus, he's local. :-) His cage is at 151 Front, just down the hall from mine. -- Paul

Re: [PHP] Automatic Headers and Footers

2003-06-09 Thread Paul Chvostek
. :) -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http://www.it.ca/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Cannot execute... Cron jobs

2003-03-12 Thread Paul Chvostek
to 127.0.0.1, but even if the script is publically runable, it can check HTTP_HOST and REMOTE_ADDR before doing anything critical. Scott never mentioned the rest of his setup; judging its security is premature. -- Paul Chvostek [EMAIL PROTECTED

[PHP] Re: seperate streetname from number

2003-03-11 Thread Paul Chvostek
{ $name=$what; $number= } $retval[0]=trim($name); $retval[1]=trim($number); return $retval; } -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http

Re: [PHP] Re: Enabling HTTP_REFERER

2003-03-11 Thread Paul Chvostek
enable this variable again? -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http://www.it.ca/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http

Re: [PHP] Re: Enabling HTTP_REFERER

2003-03-11 Thread Paul Chvostek
the HTTP_REFERER variable. I call it up and it's empty, so I did a print_r($HTTP_SERVER_VARS); and there wasn't a variable called HTTP_REFERER. I've heard that some servers disable it. Since I have a dedicated server, how can I enable this variable again? -- Paul Chvostek

Re: [PHP] Checking for a Valid Email String.

2003-03-11 Thread Paul Chvostek
); if (!getmxrr($domain,$mxhosts)) return(false); if (!count($mxhosts) 0) return(false); return(true); } -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http

Re: [PHP] Checking for a Valid Email String.

2003-03-11 Thread Paul Chvostek
][a-z]+$',$what)) return(false); list($user,$domain) = explode(@,$what); if (!getmxrr($domain,$mxhosts)) return(false); if (!count($mxhosts) 0) return(false); return(true); } -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever

[PHP] how do I strptime?

2003-02-27 Thread Paul Chvostek
a subshell every time I process a date, but I'd also like to avoid jumping through hoops with mktime. Is there a better way? Tnx. -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http

[PHP] Re: search script

2003-02-24 Thread Paul Chvostek
likely to get a quick response on the php-db list, and a more concise response if you include the type of database you're using. -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http

[PHP] Re: file not opening in internet explorer

2003-02-19 Thread Paul Chvostek
No they're not. They might be rw-r--r--, but not what you put. When you talk about file modes, it's safer to refer to them in octal. So rw-r--r-- would be 644, and rw-rw-rw- would be 666. Less confusion. p -- Paul Chvostek [EMAIL PROTECTED] Operations

[PHP] Re: Cron Job help Needed

2003-02-19 Thread Paul Chvostek
which are operating system specific. (And if you don't know, you probably don't need 'em.) Most likely you will need unix shell access to set up and maintain your cron jobs. Your local unix system administrator (or consultant) can help with that. -- Paul Chvostek

[PHP] pro-rated date

2003-02-17 Thread Paul Chvostek
this? -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http://www.it.ca/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: PHP-based SMS solution

2003-02-12 Thread Paul Chvostek
=sendpage -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http://www.it.ca/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: regex

2003-02-07 Thread Paul Chvostek
[^][.^$()|*+?-]. Check the re_format(7) man page for details. If you don't have a unix box handy, check http://www.freebsd.org/cgi/man.cgi?query=re_format . -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development

[PHP] Re: issues with ksort()

2003-02-07 Thread Paul Chvostek
is the sorted array. It is not. Try something more along the lines of: $testarray=array( [three] = 3, [two] = 2, [one] = 1, ); ksort($testarray); print_r($testarray); -- Paul Chvostek [EMAIL PROTECTED] Operations

[PHP] Powerpoint presentations?!?

2003-02-05 Thread Paul Chvostek
or find another developer? I'd *much* rather do this in pdflib or ming, but that may just not be possible -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http://www.it.ca

Re: [PHP] listbox problems

2003-02-02 Thread Paul Chvostek
']); } print /select\n; } -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http://www.it.ca/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http

[PHP] Re: printing

2003-01-28 Thread Paul Chvostek
on the network. If you're doing this in a Microsoft environment, I have no clue how you'd even approach the problem, let alone solve it. -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development

[PHP] PHP vs Perl for system scripts (non-web)

2003-01-27 Thread Paul Chvostek
at the moment), are there any compelling reasons I should write system stuff in Perl rather than PHP? Thanks. -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http://www.it.ca

Re: [PHP] Populating a list box from a database - The code

2002-12-28 Thread Paul Chvostek
: http://www.php.net/unsub.php -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever it.canada, hosting and development http://www.it.ca/ -- PHP General Mailing List

[PHP] creating random strings?

2002-12-19 Thread Paul Chvostek
this stuff. Including the INSERT, I can create about 10 of these in 60 seconds. So this is more a question of style than of practical limitations. ;) -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever +1

[PHP] Re: ping...

2002-12-13 Thread Paul Chvostek
out various OS man pages at http://www.freebsd.org/docs.html#man . If you're running a Microsoft operating system, you're most likely out of luck. -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever +1 416 598

[PHP] Re: Regex question

2002-12-12 Thread Paul Chvostek
normally. How about: $href=(https?://([a-z0-9]+\.)+[a-z][a-z]+/[a-z0-9_./~%-]*); $repl=a href='\\1'\\1/a; $line=eregi_replace($href, $repl, $line); You can of course make $href less restrictive if you're liberal minded about your URL formats. -- Paul Chvostek

[PHP] Re: fwrite and line breaks

2002-12-12 Thread Paul Chvostek
it. -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever +1 416 598- it.canada - hosting and development http://www.it.ca/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http

[PHP] Re: Beginner question : Removing spaces in forms

2002-12-12 Thread Paul Chvostek
their space bar a number of times after entering a numeric value into a text box? If so, then http://www.php.net/trim may be what you want. If not, you'll need to explain it more concisely. -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever

[PHP] Re: Finding Mode

2002-12-08 Thread Paul Chvostek
() function works ... but I don't recommend using this for bandwidth calculations for co-lo customers because of the hassle of pulling all that data into an array. 95th percentile is more easily calculated in the SQL server than in php. -- Paul Chvostek [EMAIL

[PHP] Re: test for ascii or binary string

2002-11-30 Thread Paul Chvostek
ASCII or whatever you want to call it. But the string is just a string of bits. -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever +1 416 598- it.canada - hosting and development http

[PHP] Re: Hello ! How to write a programme in PHP which executes a routine at a given time ?

2002-11-30 Thread Paul Chvostek
Winamp at 2:30 on computer B ) at given time . I know what to implement the producer 1 and 2. However , I don't know how to implement producer 3. Do you mind to tell me how to make a PHP programme to execute a centian routine at a given time ? Thank you ! -- Paul Chvostek

[PHP] Re: Multidimensional array

2002-11-30 Thread Paul Chvostek
that it doesn't. __ Do you Yahoo!? Yahoo! Mail Plus - Powerful. Affordable. Sign up now. http://mailplus.yahoo.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Paul Chvostek

[PHP] Re: Multidimensional arrays (more and more...)

2002-11-30 Thread Paul Chvostek
with a method, right? -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever +1 416 598- it.canada - hosting and development http://www.it.ca/ -- PHP General Mailing List (http://www.php.net

[PHP] Re: Multidimensional arrays (more and more...)

2002-11-30 Thread Paul Chvostek
of elements in $issue. I never count my multidimensional arrays so it's never come up for me. :-/ -- Paul Chvostek [EMAIL PROTECTED] Operations / Abuse / Whatever +1 416 598- it.canada - hosting and development