[PHP] insert data to mysql

2001-04-23 Thread shawn
t;$phone", "$fax", "$model", "$country", "$details", "$type")"; $result = MYSQL_QUERY($sql) or die ("Couldn't execute query"); MYSQL_CLOSE(); Im new (no kidding?), so i hope this is easy, also, is there a address anyone can point me to for a archive of this list? Thanks in advance, Shawn

[PHP] RE: insert data to mysql

2001-04-23 Thread shawn
thing else that I should be passing to the script to let it know to write to fields within the table? Shawn

Re: [PHP] insert data to mysql

2001-04-23 Thread shawn
ariables from a form, and emailing them to a recipient, also it is supposed to write the data to a database. The email works fine, but it just isnt writting to the database? Shawn "thanks for the link"

[PHP] insert into

2001-04-24 Thread shawn
mail', '$address', '$city', '$state', '$zip', '$phone', '$fax', '$model', '$country', '$details', '$type'); MYSQL_CLOSE(); ?> Thanks, also if you know any tutorials for PHP and MySQL Shawn

RE: [PHP] PHP 4.0.5 is out

2001-04-30 Thread SHAWN
Is anyone else having problems with the Windows binary zip? I've downloaded it a couple times and it keeps saying that it's corrupt. Thanks! Shawn Sellars -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-ma

[PHP] wordwrap

2001-05-05 Thread shawn
Is there a tag in php that acts like "wordwrap=virtual" does in html? I have a script that is sending out variables in a email from a contact form, but for a comments section it will not wordwrap in the email. Thanks Shawn

[PHP] session_start ()

2001-05-07 Thread shawn
ally), so thanks for the help, ill be going through the manual while I wait :-) Shawn

[PHP] InterSystems Cache DB and PHP

2001-11-09 Thread SHAWN
Does anyone know if PHP can be used (other than with ODBC) with the Cache database from InterSystems? Thanks in Advance, Shawn Sellars

[PHP] Help w/ exec() on Win2k, IIS5.

2001-03-28 Thread SHAWN
uck in a loop! Can anyone tell me how to successfully use this command? Or if not, any other ideas on how to get the file names inside a directory into an array? Thanks in Advance, Shawn Sellars

[PHP] URL vars in URL var?

2002-12-03 Thread Shawn McKenzie
ated as vars of the main URL. Any help appreciated, Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] URL vars in URL var?

2002-12-03 Thread Shawn McKenzie
Great thanks! Since I'm doing this from an anchor or in the browser location bar, I just replaced the & in the url var with %26. Works great! -Shawn "Adam Voigt" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED

[PHP] Objects and Classes?

2002-12-10 Thread Shawn McKenzie
oes anyone have good info or methodology on when to use a class and what components make sense to include in the class? How many classes? I could send my code to anyone who is a guru in this that could just give me some high-level advice. Thanks! Shawn (Just learning) -- PHP General Mai

[PHP] Re: Objects and Classes?

2002-12-12 Thread Shawn McKenzie
Very cool! Thanks! "Christopher Raymond" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > > Shawn: > > I beleive I can clarify the purpose of objects/classes for you and > enrich my clarification with a couple of example

[PHP] Include?

2002-12-12 Thread Shawn McKenzie
uld be for only URLs (myscript.php?page=http://mysite.com/dir/cool.html, or relative URLs (myscript.php?page=/dir/cool.html). Can I do this without allowing someone to include files by filesystem reference??? Thanks! Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, v

[PHP] Code contents of a function

2003-01-02 Thread Shawn McKenzie
uot;; echo "something else"; someotherfunction(); into a string. Any ideas??? TIA -Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Code contents of a function

2003-01-02 Thread Shawn McKenzie
} > else { > sumotherfunction(); > } > > etc > > > > -Original Message- > > From: Shawn McKenzie [mailto:[EMAIL PROTECTED]] > > Sent: Friday, 3 January 2003 12:18 PM > > To: [EMAIL PROTECTED] > > Subject: [PHP] Code contents of a function >

[PHP] Parse source for braces

2003-01-06 Thread Shawn McKenzie
braces that may be there (if, while, switch, foreach, etc...). Anybody have some code to do this??? function someFunc() { if(something) { something... } while(something) { something... } } // So I need the code from the beginning of the function to here TIA -Shawn -- PHP General Mailing

[PHP] Vars in URL

2003-02-05 Thread Shawn McKenzie
I want to pass vars to another site but I don't want to use a form. How can I pass these vars to another site without the vars being shown in the URL. I tried header("Location:"); TIA, Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: htt

Re: [PHP] Vars in URL

2003-02-05 Thread Shawn McKenzie
, but this shows the return url var in the url address bar. I want to pass vars to paypal without them being shown in the url address bar. TIA -Shawn "Chris Shiflett" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > --- Shawn McKenzie

Re: [PHP] Vars in URL

2003-02-05 Thread Shawn McKenzie
. "\r\n\r\n"; $fp = fsockopen (/xclick/, 80, $errno, $errstr, 30); if(!$fp) { echo "$errstr ($errno)"; } else { fputs($fp, $header . $req); while(!feof($fp)) { $res = fgets ($fp, 1024); } fclose ($fp); } Thanks! Shawn "Chris Shiflett&q

[PHP] emulate full post wth redirect

2003-02-05 Thread Shawn McKenzie
Wow, has it really been a year. No replies??? Any ideas??? Anyone??? Thanks! Shawn "Bobby Patel" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hello, I want to emulate a POST request to Paypal. Originally a POST request > is

[PHP] issues with ksort()

2003-02-07 Thread Shawn McKenzie
sort($myarray); foreach($sortedarray as $key => $val) { echo "$key = $val"; } Any ideas??? TIA -Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: issues with ksort()

2003-02-07 Thread Shawn McKenzie
Ah Thanks! -Shawn - Original Message - From: "Paul Chvostek" <[EMAIL PROTECTED]> To: "Shawn McKenzie" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Friday, February 07, 2003 11:18 AM Subject: Re: issues with ksort() On Fri, Feb 07, 2003 at

[PHP] Need help storing and displaying html/text!

2003-02-10 Thread Shawn McKenzie
I have a form and I want the user to be able to enter html in a text area. This will then be stored in an array in a config file. Example $htmlstuff[1] = '

[PHP] Re: Need help storing and displaying html/text!

2003-02-10 Thread Shawn McKenzie
Hmmm... I guess no one is doing this??? Seems fairly common. Thanks! Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > I have a form and I want the user to be able to enter html in a text area. > This will t

[PHP] Anyone? more info...

2003-02-10 Thread Shawn McKenzie
Is more info needed, or was everyone just going post replies like: "see stripslashes() and htmlentities()" *** I have a form and I want the user to be able to enter html in a text area. This will then be stored in an array in a config file. E

[PHP] Re: How can I install PHP 4.2.3 and Apache on WIN98 ?

2003-02-10 Thread Shawn McKenzie
P, restart Apache, and it should work fine. FYI... Posting in this forum you're most likely to just get a link to the Apache documentation. HTH -Shawn "Rija" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > I want to run php 4.

[PHP] Re: Anyone? more info...

2003-02-10 Thread Shawn McKenzie
n display > don't do it automatically, add them before insertion to a database > > but which one is easiest for you depends on your sites configuration and > what code you've already written, etc... > > -philip > > > On Mon, 10 Feb 2003, Shawn McKenzie wrote:

[PHP] Issue saving php that includes constant---

2003-02-11 Thread Shawn McKenzie
t generates the form (maybe _LOGIN = "Login" ), then the result after my var_export() to the file is this: $var = 'To Login click the login link below";'; Any ideas on how to keep the text of the constant definition in the string instead of it being evaluated??? TIA

[PHP] var_export() strips slashes

2003-02-12 Thread Shawn McKenzie
double "'); $b = var_export($a, TRUE); echo $b; Displays: array ( 'it's here' => 'single, \' double "', ) And: $c = eval($b); generates a parse error in the eval'ed code. Any help??? TIA, -Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: var_export() strips slashes

2003-02-12 Thread Shawn McKenzie
Is this a real bug, or am I just doing something stupid? :-) Thanks! Shawn > Seems that var_export() strips slashes from my array keys even though the > docs say that it returns valid PHP code. This is bad if I want to use $b > below to define another array, gives a parse error on t

[PHP] Undefined offset notices

2003-02-19 Thread Shawn McKenzie
oreach($command as $name => $cmds) { if($tmpcmds[$i] == $name) { $docmd = $cmds; eval($docmd); } } $i++; } // Line 281 TIA, Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Derive bottom-most dir from string???

2003-02-20 Thread Shawn McKenzie
Is there an easy way to derive the bottom-most directory from a string containing a path? Example: $somepath = "html/testsite/templates/shopping"; Becomes: "shopping" TIA -Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Derive bottom-most dir from string???

2003-02-20 Thread Shawn McKenzie
Sorry... Think I was over complicating it. Seems the last element of $somearray from $somearray = explode("/", $somepath); will work well. Thanks! Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... &g

[PHP] rewrite rule help anyone?

2003-02-22 Thread Shawn McKenzie
".html"; } $newdisplay = str_replace($hrefs, $newhrefs, $newdisplay); return $newdisplay; } //finds href=" in the string containing the html function find_hrefs($tmpcontent) { while($start = strpos($tmpcontent, 'href="', $end)) { $start = $start

[PHP] Re: rewrite rule help anyone?

2003-02-23 Thread Shawn McKenzie
No takers??? Did I say, Please! Thanks! Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Slightly off topic, but I have some PHP also ;-) > > I am trying to make search engine friendly URLs for a site, but want this to > be fair

[PHP] MIME help needed please...

2003-02-23 Thread Shawn McKenzie
I got this from the user contributed notes in the php.net manual. It seems to work fine most of the time, but Eudora and Pegasus users either get mangled attachments or no attachments. Can anyone see a problem (most files are zip, but sometimes tar.gz or sit) I tried using Content-Type: applicati

[PHP] Re: PHP_SELF syntax

2003-02-23 Thread Shawn McKenzie
Works great for me. The error may be from a previous line. What is the error? -Shawn "Peter Gumbrell" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Could someone tell me why this code prompts a parse error. I have tried it > several different way. The st

[PHP] regex question?

2003-02-23 Thread Shawn McKenzie
4 or more... How can I write my expression to match 1 or more pairs??? For example: script.php?var=val script.php?var=val&var2=val2 script.php?var=val&var2=val2&var3=val3 etc...etc...etc... TIA, Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: regex question?

2003-02-24 Thread Shawn McKenzie
Anyone? please? Thanks! Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I'm using the following to try and replace urls in my html output: > > $newhrefs = preg_replace("/script.php\?(.*)=(.*)&(.*)=(.*)&(.*)=(.*)/&

[PHP] derive function that called a function?

2003-02-24 Thread Shawn McKenzie
with other peoples' code and don't want to modify their functions (e.g. what args they call my function with). But in certain cases I need to take certain actions if my function was called by a particular function. TIA Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscr

[PHP] Re: MIME help needed please...

2003-02-25 Thread Shawn McKenzie
Is this a stupid question, or does no one know what is wrong??? Thanks! Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I got this from the user contributed notes in the php.net manual. It seems > to work fine most of the time, but Eu

[PHP] Easier queries?

2003-07-14 Thread Shawn McKenzie
tomers' Sort of analogous to MS SQL Views? Sound good, or is there a better way? TIA -Shawn P.S. I've also seen mention of some graphical query builders. Can anyone recommend a good FREE one? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Eval var from query

2003-07-14 Thread Shawn McKenzie
How can I evaluate a var that is from a text field of a database? Example: MySQL field `name` = hi my name is $name In my script I have: $name = "Shawn"; After fetching a query result as an associative array I have the contents of the `name` field in $data If I echo $data I get:

[PHP] Re: Eval var from query

2003-07-14 Thread Shawn McKenzie
eval($data) returns Parse error: parse error, unexpected T_STRING in C:\apps\apache2\htdocs\test\query.php(23) : eval()'d code on line 1 Thanks! Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > How can I evaluate a var that is from a

Re: [PHP] Re: Eval var from query

2003-07-14 Thread Shawn McKenzie
Thanks Kevin! That works great. It outputs: hi my name is Shawn Now if I want to assign $data to another var, let's say $newdata and have it eval the $name var inside of that. How would that work? Meaning I want to $newdata = hi my name is Shawn Thanks! Shawn "Kevin Ston

Re: [PHP] Re: Eval var from query

2003-07-14 Thread Shawn McKenzie
Got it! eval( '$newdata = "'.$data.'";'); Thanks! Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Thanks Kevin! That works great. It outputs: hi my name is Shawn > > Now if I want to assign $data to

[PHP] filemtime() on Windows

2003-07-17 Thread Shawn McKenzie
;)); Always returns: 12316906 (December 31, 1969) Any ideas? TIA -Shawn Windows XP PHP 4.3.1 Apache 2.0.45 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: filemtime() on Windows

2003-07-17 Thread Shawn McKenzie
Nevermind. I had a typo in the path. Sorry... -Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I am trying to get the last modified time of an HTML file on my windows > machine. The file is in a sub dir of my script dir and I can u

[PHP] replacing & but not special chars

2003-07-27 Thread Shawn McKenzie
eas on how to do this the right way??? Thanks! Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Allowed mem size exhausted

2003-08-05 Thread Shawn McKenzie
/home/user/public_html/dir/subdir/include/functions.php on line 9 Many thanks! Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: global scope issue

2003-08-14 Thread Shawn McKenzie
OK, so what's the use of having the autoglobal $GLOBALS??? This is contrary to the docs. -Shawn "Ivo Fokkema" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED

[PHP] Re: Best PHP CMS

2003-08-14 Thread Shawn McKenzie
I prefer and use PostNuke. Great community, stable platform, many modules/themes, sensible API for development and AutoTheme HTML theme system for templating, with another system on the way. HTH -Shawn "Anthony" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I

[PHP] Using Constants

2003-08-14 Thread Shawn McKenzie
I'm considering using constants for some predefined paths in my script, like HTML_DIR, INC_DIR. These values won't change and they will be global to all functions. Are there any drawbacks to using constants over reg vars for this sort of thing??? TIA, Shawn -- PHP General Mailing

Re: [PHP] Re: global scope issue

2003-08-14 Thread Shawn McKenzie
Sorry... nevermind. I was developing as part of a team and it seems that my script is included in a function written by someone else. So my vars from my included files are local to the other function and not global. Thanks! Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote

Re: [PHP] where did my errors go?

2003-08-14 Thread Shawn McKenzie
error_reporting and/or display_errors in php.ini? "David T-G" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] global scope issue

2003-08-14 Thread Shawn McKenzie
I'm having problems using global vars. I have read the docs and all of the notes but it's not helping. Simplified example: /dir1/script2.php '1', 'b' => '2'); ?> /dir1/script1.php This is a local include so the vars should be in the gl

Re: [PHP] Re: global scope issue

2003-08-14 Thread Shawn McKenzie
does it matter if a global command has bee issued before with vars other than the $test var? i.e before the include if there is a global $somevar; -Shawn "Curt Zirzow" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > * Thus wrote Ford, Mike [LSS

Re: [PHP] Allowed mem size exhausted

2003-08-14 Thread Shawn McKenzie
Thanks! Would anyone care to expand on the "tools" or the methods for preparing on disk??? Thanks again! -Shawn "Curt Zirzow" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > * Thus wrote David Nicholson ([EMAIL PROTECTED]): > > Hello, > >

[PHP] Looking for library of functions

2003-03-17 Thread Shawn McKenzie
L, replace tags, modify tags, find properties in tags, return entire HTML elements such as tables even if there are nested tables; meaning if I have: It should be able to return the entire table containing the other table. Sorry if I'm not explaining this well. Thanks! Shawn -- PHP

[PHP] Determine memory used from script

2003-06-05 Thread Shawn McKenzie
/ccc/script.php on line 20 I know why I get the error but would like to know when and why my script is consuming so much. Thanks! Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: New word proposition (was: Re: [PHP] HTML and PHP)

2003-06-05 Thread Shawn McKenzie
HAH! I love it! -Shawn "Evan Nemerson" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Clode? I like it. Really, who wants to say "closing php tag", "terminating php > tag", or whatever you say. Why not start calling it a clode? What does

[PHP] ob_get_contents returns FALSE?

2003-06-06 Thread Shawn McKenzie
ents() == FALSE) and: if(!ob_get_contents()) and: if(ob_get_contents() == "") But I do get the following notice at the ob_end_flush(); line which tells me that output buffering is not on: Notice: ob_end_flush() [ref.outcontrol]: failed to delete buffer default output handler. Th

[PHP] Re: ob_get_contents returns FALSE?

2003-06-06 Thread Shawn McKenzie
Any advice? Thanks! Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I can't get ob_get_contents() to return false, or I don't know how to test > for it. Help appreciated. The following never echos STARTING!!! > > ob

[PHP] How to determine if output buffering is on?

2003-06-07 Thread Shawn McKenzie
O.K. so how can I determine if output buffering has been started??? Thanks! Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] ftp_ssl_connect() Problem

2003-05-27 Thread Shawn McKnight
b' '--with-gd=/usr/local/gd' '--with-zlib-dir=/usr/local' '--enable-sockets' '--enable-ftp' (this command reflects my last successful change and lacks the '--with-openssl=/usr/local/ssl' I would have expected) Thanks for any help that can be prov

[PHP] Re: ANY POSTNUKER? Security problem!

2003-05-29 Thread Shawn McKenzie
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 It is also a simple drop-down box setting in the admin / settings. - -Shawn "Nabil" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > i have problem with session in postnuke. > > the problem is that while i m

Re: [PHP] How to determine if output buffering is on?

2003-06-08 Thread Shawn McKenzie
ALSE) and: if(!ob_get_contents()) and: if(ob_get_contents() == "") But I do get the following notice at the ob_end_flush(); line which tells me that output buffering is not on: Notice: ob_end_flush() [ref.outcontrol]: failed to delete buffer default output handler. Thanks! Shawn "Leif

[PHP] Re: How to use objects, variables in an eval() func ?

2003-06-10 Thread Shawn McKenzie
Maybe: global $yourobject; -Shawn "Lpa" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Hi, I have an eval which evaluate a block of code before echo the result on the screen.. Here is the func : function t_eval($texte) { ob_start(); eval("?

[PHP] Re: shorthand "if" notation

2003-06-11 Thread Shawn McKenzie
Ternary operator. Look in the comparison operators section: http://us2.php.net/manual/en/language.operators.comparison.php -Shawn "Adrian Greeman" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > > I am confused by the shorthand "if" notation. &

Re: [PHP] Eval or $$ are they the same or is $$ safer

2003-06-11 Thread Shawn McKenzie
Can you expand on this? I haven't found a ref to the $$ except for variable variables. $$ What does it do? How is it used? Thanks! Shawn "Leif K-Brooks" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Use $$ unless you need to use eval. Easier to read, f

[PHP] failed to delete buffer default output handler

2003-06-13 Thread Shawn McKenzie
echo ob_get_level(); returns 1 but the next line: ob_end_clean(); returns Notice: ob_end_clean() [ref.outcontrol]: failed to delete buffer default output handler. Any ideas? Thanks! Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] Help with output from system() or backticks

2002-08-13 Thread Shawn Sellars
Have you tried it like this? $output = `$executable $param`; $output = explode("\n",$output); print_r($output); It works for me! I get the same weird response as you when I try to create the array directly off of the system call. Good Luck, Shawn Sellars -Origin

[PHP] Extract HTML tags

2002-10-09 Thread Shawn McKenzie
tring only containing content after up to and including Any ideas on simple ways to do this? TIA -Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Odd request

2002-10-12 Thread Shawn McKenzie
tp://somwhere.com";); and determine the height that this page ($string) would render in a browser. Render iframe at determined height with src = "http://somwhere.com";. Any way in php to determine at what height html content will render??? If not, should there be? TIA -Sha

[PHP] Re: How to navigate backwards in PHP ???

2002-10-12 Thread Shawn McKenzie
$HTTP_SERVER_VARS["HTTP_REFERER"]; - or - PHP 4.1.0 and later $_SERVER["HTTP_REFERER"]; Not as reliable as passing it yourself though. HTH -Shawn "-<>-" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... >

[PHP] Re: $html_code .= include ("filetoinclude.txt");

2002-10-13 Thread Shawn McKenzie
function file_get_contents($filename) { $fp = @fopen($filename, "r"); if (!($fp)) { return 0; } while (!feof($fp)) { $temp .= fread($fp, 4096); } return $temp; } and then: $html_code = file_get_contents(filetoinclude.txt); HTH -Shawn

[PHP] newline in string

2002-10-13 Thread Shawn McKenzie
I have loaded an html file into a string. How can I search the string for newlines/linefeeds? I know they are there, because if I echo the string and view source in the browser, some tags are on new lines. Example: TIA -Shawn -- PHP General Mailing List (http://www.php.net/) To

Re: [PHP] newline in string

2002-10-13 Thread Shawn McKenzie
Thanks everyone. I'' be breaking the string after the newline so that I can convert the html to php echos and write them to a file. -Shawn "John W. Holmes" <[EMAIL PROTECTED]> wrote in message 000d01c272c1$54d0$7c02a8c0@coconut">news:000d01c272c1$5

Re: [PHP] Replace illegal filename chars???

2002-10-24 Thread Shawn McKenzie
Doesn't work. It returned the same as what I put in: What's Up Doc? -Shawn "Maxim Maletsky" <[EMAIL PROTECTED]> wrote in message news:20021024122630.4E99.MAXIM@;php.net... > > Use a regular expression like: > > $str = ereg_replce("/[^[:alnum:]]/i"

Re: [PHP] Replace illegal filename chars???

2002-10-24 Thread Shawn McKenzie
Thanks, the ereg_replace example didn't work for me (even after fixing the typo). A-Za-z0-9 is fine for my needs, replacing them with "". What is your preg_replace allowing? Thanks! Shawn "Peter Mr. Eps Thoenen" <[EMAIL PROTECTED]> wrote in message news:A733FF9B1

[PHP] ereg_replace???

2002-10-28 Thread Shawn McKenzie
I need to replace all NON alpha-numeric characters in a string. Example: input: "-What's Up Doc?" output: "WhatsUpDoc" I received this in a previous post, but it doesn't work: $str = ereg_replace("/[^[:alnum:]]/i", '', $str); T

[PHP] Re: Free compiler for Win

2002-10-28 Thread Shawn McKenzie
There is a GNU gcc compiler for windows. -Shawn "Marcello Lupo" <[EMAIL PROTECTED]> wrote in message news:0210281543120J.00435@;hunters... > Hi to all, > anyone know a good free complier for win 2000/NT to compile PHP and so on? > thanks, > Bye > MArselo --

Re: [PHP] ereg_replace???

2002-10-28 Thread Shawn McKenzie
Thanks! Why does preg_replace("^\W^","",$str); not remove undescores _ ? Are they alpha-numeric? I had to do this preg_replace("^\W|_^","",$str); TIA, Shawn "John W. Holmes" <[EMAIL PROTECTED]> wrote in message news:000201c27eab$f4e

[PHP] preg_replace (underscore)

2002-10-28 Thread Shawn McKenzie
Why does preg_replace("^\W^","",$str); not remove undescores _ ? Are they alpha-numeric? I had to do this preg_replace("^\W|_^","",$str); TIA, Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Fw: [PHP] preg_replace (underscore)

2002-10-29 Thread Shawn McKenzie
Thanks, but I'm trying to replace ALL non alpha-numeric characters, which I'm doing with the preg_replace, however it leaves the _. Seems silly to use preg_replace and then use str_replace. Thanks! Shawn "John Meyer" <[EMAIL PROTECTED]> wrote in message news:<[EMA

[PHP] PHP code in form field - var_export() (slashes)?

2003-09-23 Thread Shawn McKenzie
O.K. I am collecting PHP code in a textarea and then using var_export() to a file for later use. In the file, the PHP is in single-quotes. I am having issues trying to make sure that things are escaped correctly. If PHP code is submitted with no single-quotes and no escaping, then all is well.

Re: [PHP] PHP code in form field - var_export() (slashes)?

2003-09-24 Thread Shawn McKenzie
e and assign back to the same array that I had it in in the first place. Thanks! -Shawn "Jason Wong" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > On Wednesday 24 September 2003 12:00, Shawn McKenzie wrote: > > > O.K. I am collecting PHP code in a textar

[PHP] Re: Help! the Error_Reporting doesn't work

2003-09-25 Thread Shawn McKenzie
What do you mean "it doesn't work"? It doesn't display errors? How do you know that you have errors? Are you running your own script or someone else's? -Shawn "Luckyeagle" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I have se

[PHP] magic_quotes_gpc and \

2003-10-09 Thread Shawn McKenzie
the destination script, additional escapes \ are added. So how do I get to the original code above? strip_slashes will strip all slashes, even the original ones that are supposed to be there. Thanks! -Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] displaying var in textarea

2003-10-10 Thread Shawn McKenzie
e-quotes are not shown in the HTML source as " Is this just a behavior of the textarea??? Thanks! -Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Re: Echo $PHP_SELF not working

2003-10-10 Thread Shawn McKenzie
Unless you do an extract($_POST); in a main include somewhere before your form. For $PHP_SELF just do $PHP_SELF = $_SERVER['PHP_SELF']; or to get all of the $_SERVER vars, do extract($_SERVER); -Shawn "Jeff McKeon" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PRO

[PHP] Re: $PHP_SELF and include all variables?

2003-10-14 Thread Shawn McKenzie
$_SERVER['GET'] will give an array of all get vars in the URL. Or maybe: $_SERVER['QUERY_STRING'] Which gives the entire get query string in the URL. -Shawn "Tristan Pretty" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I'm using

[PHP] Code optimization: single vs. double quotes?

2003-10-23 Thread Shawn McKenzie
I came across this post and was hoping to get a gurus opinion on the validity. TIA -Shawn I remember reading somewhere re: PHP coding that it is a better coding practice to use single quotes as much as possible vs. using double quotes in scripts. When using double quotes, you are forcing PHP to

[PHP] Re: Code optimization: single vs. double quotes?

2003-10-23 Thread Shawn McKenzie
Thanks guys! I want to hear all opinions, but hopefully a PHP dev will give us the straight poop. -Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I came across this post and was hoping to get a gurus opinion on the > validity. TIA >

[PHP] copying a directory

2003-10-26 Thread Shawn McKenzie
I need to copy a directory from one location to the other. I didn't find a function for this. Is copy() supposed to work on directories as well as files, or is there another? TIA -Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] copying a directory

2003-10-26 Thread Shawn McKenzie
Thanks, but I was looking for a multi-platform way via a function. I just bit the bullet and looped thru with readdir() and copied the files. -Shawn "Burhan Khalid" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Shawn McKenzie wrote: > > > I need

[PHP] HTTP1.1 problems maybe?

2003-11-12 Thread Shawn McKenzie
1.1, then all loads well in IE. Any ideas on things to look at or a method to troubleshoot??? Thanks! -Shawn -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] HTTP1.1 problems maybe?

2003-11-12 Thread Shawn McKenzie
-Encoding: gzip Vary: Accept-Encoding Connection: close Transfer-Encoding: chunked Content-Type: text/html 7d3 actual html from page Thanks! -Shawn "Chris Shiflett" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > --- Shawn McKenzie <[EMAIL PROTECTED]>

Re: [PHP] HTTP1.1 problems maybe?

2003-11-12 Thread Shawn McKenzie
Sorry, here is zip with data from mozilla also. mozilla works with HTTP 1.1 enabled in preferences. -Shawn "Shawn McKenzie" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > I've never sent attachment to this group, hope it is ok. > > Any help is muc

  1   2   3   4   5   6   7   8   9   10   >