Re: [PHP] Re: PHP and MySQL bug

2003-01-04 Thread Michael J. Pawlowsky
Personally I say get yourself a good simple dbconnect class and make life easy. Also if you ever change users, database name etc, you onlu have one place to replace it in your code. I wrote mine based on http://www.vtwebwizard.com/tutorials/mysql/ Take a look at it. Nice and simple. Mike

[PHP] No Global Code Fixing

2003-01-04 Thread Michael J. Pawlowsky
Well I've been fixing up all my code (and other peoples which is worst) getting ready to do an upgrade to 4.3. and turning off globals and warnings on. I very often move parameters that were once POSTed as a GETs. For instance... some one does a search but is not logged in, they can see the resul

Re: [PHP] No Global Code Fixing

2003-01-04 Thread Michael J. Pawlowsky
- 1 Array ( [0] => 2 [1] => 3 ) 3 This is the key And that actually worked... I can live without the unset()'s. Just need to add the same for POST and do an include with it. Anyone have a better idea? *** REPLY SEPARATOR *** On 04/01/2003 at 1:22 PM Mic

Re: [PHP] No Global Code Fixing

2003-01-04 Thread Michael J. Pawlowsky
Hey that's great... I didn't know about $_REQUEST I suppose the order of overlapping is set in php.ini I think I saw that somewhere. Thanks As for tunring it back on... in .htaccess I like the idea of having cleaner code *** REPLY SEPARATOR *** On 04/01/2003 at 1

Re: [PHP] Re: PHP and MySQL bug

2003-01-04 Thread Michael J. Pawlowsky
Personally I think the problem lies somewhere between the chair and the keyboard (Sorry, couldn't resist) :-) *** REPLY SEPARATOR *** On 04/01/2003 at 4:58 PM Stefan Hinz, iConnect (Berlin) wrote: >It doesn't work because of the /* Some code including ... */ part ;-) >

[PHP] You gotta love it...

2003-01-04 Thread Michael J. Pawlowsky
When doing a function seach at www.php.net I just got: Parse error: parse error in /local/Web/sites/phpweb/search.php on line 233 Twice in a row... Maybe they will be posting us a question soon!! :-) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.ph

Re: [PHP] I can't code today to save my life! :(

2003-01-04 Thread Michael J. Pawlowsky
try if(stristr($_SERVER['REREQUEST_URI'], "register.php"){ echo "at register"; } else { echo "Not"; } Not tested but should work.. also case insensitive now... *** REPLY SEPARATOR *** On 04/01/2003 at 4:21 PM Phil Powell wrote: >I have $REQUEST_URI that will

Re: [PHP] I can't code today to save my life! :(

2003-01-04 Thread Michael J. Pawlowsky
I must be doibg drugs with all those typos... Typos removed: *** REPLY SEPARATOR *** On 04/01/2003 at 4:43 PM Michael J. Pawlowsky wrote: >try > >if(stristr($_SERVER['REREQUEST_URI'], "register.php"){ > echo "at register"

Re: [PHP] counter problem

2003-01-04 Thread Michael J. Pawlowsky
Use this... enjoy $numtoguess) $message="Your guess was too high."; else $message="That is the correct number."; if(isset($_POST['guess'])) $guess=(int)$_POST['guess']; else $guess=0; print_r($_POST); ?> Guess number: Type y

Re: [PHP] counter problem

2003-01-04 Thread Michael J. Pawlowsky
This also works with the ternary operator... I don't think it likes the ++ because it doesn't know the type yet. $numtoguess) $message="Your guess was too high."; else $message="That is the correct number."; if(isset($_POST['guess'])) $guess=(int)$_POST['guess']; else

Re: [PHP] Second (Bizarre) Question regarding PHP and ASP

2003-01-04 Thread Michael J. Pawlowsky
I'm not sure I totally understand... But why not just call it like a web page using curl? *** REPLY SEPARATOR *** On 04/01/2003 at 6:43 PM Phil Powell wrote: >I don't know how to post this one so I'm sorry for such bizarre >cross-posting, but honestly I don't know where t

Re: [PHP] counter problem

2003-01-04 Thread Michael J. Pawlowsky
I won't keep it up long... but go here... you will see it works... http://rc.mikeathome.net:8080/test/index.php *** REPLY SEPARATOR *** On 04/01/2003 at 7:17 PM Anthony Ritter wrote: >Michael J. Pawlowsky wrote in message: > >> This also works with the

Re: [PHP] web visitor viewing a script?

2003-01-04 Thread Michael J. Pawlowsky
or rename the file to .phps for PHP source. Many servers recognize this mime type as source and send you the file. But if you are thinking about security... the script is compiled and executed on the server. What you see are the results of the application. Get it? This is good and bad... Beca

Re: [PHP] Read-only gif support in 4.3.0

2003-01-04 Thread Michael J. Pawlowsky
I just installed 4.3 today... configured as ./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mcrypt --with-zlib - -with-gd --enable-exif --with-jpeg-dir=/usr/lib --with-png --with-ttf --with-fre etype --enable-gd-native-ttf I run this code: and it works fine Mike *

Re: [PHP] Second (Bizarre) Question regarding PHP and ASP

2003-01-04 Thread Michael J. Pawlowsky
http://www.php.net/manual/en/ref.curl.php have the page send back whatever info you need. *** REPLY SEPARATOR *** On 04/01/2003 at 8:33 PM Phil Powell wrote: >CURL? I only understand CURL as a Vignette command, sorry, you lost me. > >Phil > >"Michael J

RE: [PHP] Read-only gif support in 4.3.0

2003-01-04 Thread Michael J. Pawlowsky
when you do a phpinfo() what are the compiled with options? *** REPLY SEPARATOR *** On 04/01/2003 at 6:24 PM Adam Plocher wrote: >This encoded message has been converted to an attachment. > >Michael, thanks for the response.. > >Only prob is I'm using the win32 precompiled

RE: [PHP] Read-only gif support in 4.3.0

2003-01-04 Thread Michael J. Pawlowsky
If I look at my phpinfo I get: gd GD Support enabled GD Version bundled (2.0 compatible) FreeType Support enabled FreeType Linkage with TTF library GIF Read Support enabled JPG Support enabled PNG Support enabled WBMP Support enabled Notice the GIF Read Support Why don

RE: [PHP] Function to catch all mySQL errors?

2003-01-04 Thread Michael J. Pawlowsky
Also if you dont want ot to break you need to add the "@" operator in front Mike *** REPLY SEPARATOR *** On 04/01/2003 at 6:47 PM Adam Plocher wrote: >This encoded message has been converted to an attachment. > >How about something like this.. > >function runquery($query) >{

[PHP] Good Linux Admin Mail List

2003-01-05 Thread Michael J. Pawlowsky
Perhaps a weird place to ask.. but, anyone have a really good (advanced without to many newbie questions) Linux System Administrators Mail List? Thanks, Mike -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Unexpected $end error?

2003-01-05 Thread Michael J. Pawlowsky
look at your loop. you have mis matched which starts one *** REPLY SEPARATOR *** On 05/01/2003 at 5:56 PM Vincent Bouret wrote: >Can someone tell me why I keep getting that error: > >Parse error: parse error, unexpected $end in D:\Program Files\Apache >Group\Apache2\htdocs\pr

[PHP] Web Based PHP CVS

2003-01-05 Thread Michael J. Pawlowsky
Does anyone know of any decent PHP/Web front ends to CVS? Thanks Mike P.S. Still looking for a good Linux SysAdmin Mail list. I don't understand Romanian but thanks for the answer! :-) -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] No Idea - Comparing Lines

2003-01-06 Thread Christopher J. Crane
Ok, this is the first time I will post a message without a line of code. I am not sure how to go about this task. So I will describe it and maybe someone will have some thoughts. I use PHP to connect to our many routers and get data using snmp. I have written a script that refreshes itself every 1

Re: [PHP] No Idea - Comparing Lines

2003-01-06 Thread Christopher J. Crane
$unix_time_1 = $unix_time_1; > etc > > > On Mon, 2003-01-06 at 15:51, Christopher J. Crane wrote: > > Ok, this is the first time I will post a message without a line of code. I > > am not sure how to go about this task. So I will describe it and maybe > > someone will hav

Re: [PHP] No Idea - Comparing Lines

2003-01-06 Thread Christopher J. Crane
d to seconds))) * 8)) / 1000 = kbits per hour $kbitsout = ((($OctetsOutB - $OctetsOutA) / ($TimeB - $TimeA)) * 8 ) / 1000; print "$kbitsout Kbits - $LineCount\n"; $LineCount++; } "Christopher J. Crane" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news

Re: [PHP] Case Matching

2003-01-06 Thread Michael J. Pawlowsky
What field type did you make the usernames? TEXT types are case incensitives use VARCHAR *** REPLY SEPARATOR *** On 06/01/2003 at 2:09 PM [EMAIL PROTECTED] wrote: >Not really sure if this would be a PHP or a MySQL issue. I'm using a >database to store username for authenti

[PHP] Loading Information into an array.

2003-01-10 Thread Philip J. Newman
I have a table with images and comments. if i have $x amout of images that each have a comment. the comments are displayed in the center colum of the table with the images loading left and right of each comment. http://www.philipnz.com/example.jpg I can get the images to load in their left and

Re: [PHP] test

2003-01-12 Thread Philip J. Newman
this was a functional email - Original Message - From: "Karl James" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, January 13, 2003 12:24 AM Subject: [PHP] test > test > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Cookie, header, output problems

2003-01-14 Thread J. Alden Gillespy
// nothing } } } If I leave the script the way it is, the browser isn't redirected no matter what I put in the header() statement. However, if I uncomment the echo statement, giving the browser some output, then the redirect works fine. Has anyone experienced this? And if so, how do I fix it? Thanks. J. Alden Gillespy (aka Dogga) Microsoft Beta Tester: - Office 11 - Content Management Server (CMS) 2002 - Systems Management Server (SMS) 2003 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Setcookie() and header()

2003-01-14 Thread J. Alden Gillespy
der() statement, then the cookie is successfully set. Anyone else having this problem? J. Alden Gillespy (aka Dogga) Microsoft Beta Tester: - Office 11 - Content Management Server (CMS) 2002 - Systems Management Server (SMS) 2003 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

RE: [PHP] Setcookie() and header()

2003-01-14 Thread J. Alden Gillespy
do I go about doing this? :) Thanks again for your help so far. J. Alden Gillespy (aka Dogga) Microsoft Beta Tester: - Office 11 - Content Management Server (CMS) 2002 - Systems Management Server (SMS) 2003 > > > -Original Message- > From: Michael Sims [mailto:[EMA

[PHP] I would like to display a list of the same products only if productPublic = staff or members.

2003-01-31 Thread Philip J. Newman
I would like to list 2 possable items in a mysql queary. SELECT * FROM products WHERE productType = '$productType AND Where productPublic = 'staff' OR productPublic = 'members' ORDER BY productId DESC LIMIT 10 I would like to display a list of the same products only if productPublic = staff or me

[PHP] getting data from a HTML table

2003-02-25 Thread Christopher J. Crane
I use a website to get data that I would like with the following code: function StockLookup($company) { $LookupUrl = "http://quote.yahoo.com/l?s=$company";; $Results = implode('', file("$LookupUrl")); list($split1, $split2) = split('', $Results); list($Final, $split3) = split('', $split2); pr

[PHP] Re: problem in writing into an html text file

2003-02-27 Thread Alejandro Trujillo J.
what software are you using ??? -- Alejandro Trujillo J. Cube Systems LTDA. web : csltda.com Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Checking for HTTP:// at the start of a string and more ////

2003-02-28 Thread Philip J. Newman
I would like to check for HTTP:// at the start of a string and for at least 1 . and a / at the end of a string. I have tried ereg, but the documentation is not too clear how to format. -- Philip J. Newman. Head Developer [EMAIL PROTECTED] +64 (9) 576 9491 +64 021-048-3999 -- Friends

[PHP] IS there a way.

2003-02-28 Thread Philip J. Newman
Is there a way to PING a URL and check if it returns a valid code like 200 ... ?? -- Philip J. Newman. Head Developer [EMAIL PROTECTED] +64 (9) 576 9491 +64 021-048-3999 -- Friends are like stars You can't allways see them, but they are always there. -- Websites: PhilipN

[PHP] Checking Access to a directory Via a PHP/MYSQL Databace.

2003-03-01 Thread Philip J. Newman
Is there a way that i can restrict access to an entire directory using PHP/MYSQL so only valid users in the Database can have access to a resource? -- Philip J. Newman. Head Developer [EMAIL PROTECTED] +64 (9) 576 9491 +64 021-048-3999 -- Friends are like stars You can't allway

[PHP] Upper and lower case.

2003-03-01 Thread Philip J. Newman
Question: is it better to store user names as upper and lower case? should they bee converted to one case? I have a script the checks for names and ... Mark is not the same as mark, or MaRk ... is there a way of making a string into lower case? -- Philip J. Newman. Head Developer [EMAIL

Re: [PHP] Upper and lower case.

2003-03-01 Thread Philip J. Newman
LOL got a reply to this before i ever got the message my self ... - Original Message - From: "Philip J. Newman" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Sunday, March 02, 2003 10:56 AM Subject: [PHP] Upper and lower case. > Question: > > is i

[PHP] PHP SQL Code

2003-03-01 Thread Philip J. Newman
I would like yo show the users in a list that have a date that is more than 60 days old. $sql = "SELECT * FROM stompers WHERE sUpdated < from_unixtime(unix_timestamp(now())-(15760*60)) AND sActive = 'Y' ORDER BY sUpdated DESC"; This don't quite work .. Any su

Re: [PHP] PHP SQL Code

2003-03-02 Thread Philip J. Newman
This one returns a 'Could not get Query' warning ... so thats out. - Original Message - From: "John W. Holmes" <[EMAIL PROTECTED]> To: "'Philip J. Newman'" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Monday, March 03, 2003 5:3

[PHP] Checking for Null Variables

2003-03-07 Thread Christopher J. Crane
How do I check if a variable is blank or not. I am returning data from a MySQL database and if a field is empty I would like to do something different. I tried if($field["Name"] == "") { do this } else { do this } It does not work right. Actually, at one point, it was working in the exact opposit

[PHP] Re: Checking for Null Variables

2003-03-07 Thread Christopher J. Crane
will not create a $field["Name"]. > > So, if using : > $field=mysql_fetch_array($resource, MYSQL_ASSOC) > if(empty($field["Name"])) { do this } > else { do this } > > OR > $field=mysql_fetch_array($resource) > if(!isset($field["Name"])) { do

[PHP] Re: PHP and DB2 on AS400

2003-03-07 Thread Alejandro Trujillo J.
I never do that, but, you can do it with the ODBC that is supported in Windows PHP version, that is my idea for you. -- Alejandro Trujillo J. Cube Systems LTDA. web : csltda.com Using M2, Opera's revolutionary e-mail client: http://www.opera.com/m2/ -- PHP General Mailing List

[PHP] Join

2003-03-09 Thread Philip J. Newman
-- Philip J. Newman. Head Developer [EMAIL PROTECTED] +64 (9) 576 9491 +64 021-048-3999 -- Friends are like stars You can't allways see them, but they are always there. -- Websites: PhilipNZ.com - Design. http://www.philipnz.com/ [EMAIL PROTECTED] Philip's Domain /

[PHP] Images out side the wwwroot

2003-03-09 Thread Philip J. Newman
If i was to use PHP to call all my images from out side the wwwroot, dose anyone have a method that they use? -- Philip J. Newman. Head Developer [EMAIL PROTECTED] +64 (9) 576 9491 +64 021-048-3999 -- Friends are like stars You can't allways see them, but they are always

[PHP] Checking for a Valid Email String.

2003-03-11 Thread Philip J. Newman
Required: Help for checking for a valid email string. -- Philip J. Newman. Head Developer [EMAIL PROTECTED] +64 (9) 576 9491 +64 021-048-3999 -- Friends are like stars You can't allways see them, but they are always there. -- Websites: PhilipNZ.com - Design.

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

2003-03-11 Thread Philip J. Newman
how ever i don't think most ISPs let users pick names with the + sign in it - Original Message - From: "Paul Chvostek" <[EMAIL PROTECTED]> To: "David E.S.V." <[EMAIL PROTECTED]> Cc: "Philip J. Newman" <[EMAIL PROTECTED]>; <[EMAIL PRO

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

2003-03-11 Thread Philip J. Newman
You have used the ' in sted of the " i assume that there is no difference? - Original Message - From: "Paul Chvostek" <[EMAIL PROTECTED]> To: "David E.S.V." <[EMAIL PROTECTED]> Cc: "Philip J. Newman" <[EMAIL PROTECTED]>; <[EMAI

[PHP] Making a Loop.

2003-03-12 Thread Philip J. Newman
nection) or die ("Could not get Query"); while ($row = mysql_fetch_array($sql_result)) { $productCode=$row["productCode"]; echo "$productCode"; } // END WHILE. echo""; } and it dose not work any help? --

Re: [PHP] Making a Loop.[Scanned]

2003-03-12 Thread Philip J. Newman
assuming the value is 10, I stall can't get it to work - Original Message - From: "Michael Egan" <[EMAIL PROTECTED]> To: "Philip J. Newman" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Wednesday, March 12, 2003 9:29 PM Subject: RE: [PHP] Ma

[PHP] Splitting a string

2003-03-13 Thread Christopher J. Crane
I have a CSV file that has 7 fields. One of the fields has a number, and some of the numbers start with a "S". If that number start with a "S", I want to strip it off. I am not sure how to do that. I first wrote the script to open the file, load each line into an array and split the array by field.

[PHP] PDF Creation

2003-03-13 Thread Christopher J. Crane
I am just getting into PDF creation and I am having some issues. Can anyone send me a simple script that creates a PDF doc. I would like it to open in the browser after creation, not create a file. If someone has a simple one with an image placement as well that would be great. I can figure it out

[PHP] Crypting Passwords for storage.

2003-03-13 Thread Philip J. Newman
I have a user admin for a site, how ever passwords are stored in plane text. Is there away to crypt and then read the crypt when verifying that string vs the plane text in the password box? -- Philip J. Newman. Head Developer [EMAIL PROTECTED] -- PHP General Mailing List (http

[PHP] My PHP mysql Command

2003-03-14 Thread Philip J. Newman
$sql .= " ORDER BY gId DESC LIMIT $gStart, 10"; echo $sql; $sql_result = mysql_query($sql, $connection) or die (mysql_error()); MY ERROR MESSAGE IS ... 10You have an error in your SQL syntax near 'WHERE (gAccessLevel = 'level-1' OR gAccessLevel = 'level-2

Re: [PHP] mysql_connect issue

2003-03-14 Thread Philip J. Newman
try mysql_connect("loghost:3306","$username","$password"); - Original Message - From: "Steve Shead" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Saturday, March 15, 2003 12:14 PM Subject: [PHP] mysql_connect issue > I'm trying to get a small PHP based log reader to run but get t

[PHP] Confused a little with = to and grater than ...

2003-03-15 Thread Philip J. Newman
"2"; } else if ($gAccessLevel == "level-3") { $glevel = "3"; } if ($slevel >= $glevel) { //LOAD PAGE }else { // ERROR MESSAGE HERE. { -- Philip J. Newman. Head Developer [EMAIL PROTECTED] +64 (9) 576 9491 +64 021-048-3999 -- Friends are lik

[PHP] File upload Stuff ... well kinda.

2003-03-15 Thread Philip J. Newman
RIghto then. Just make a nice website, on my windows box and everything and when i moved it to the live server, the things that didn't work where file uploads. What (if any) settings do i have to use for a Linux dir .. to allow access for the file to be uploaded? -- Philip J. Newman.

Re: [PHP] download php

2003-07-10 Thread Daniel J. Rychlik
You should also store passwords in a non-readable to the world directory. -Dan - Original Message - From: "Marek Kilimajer" <[EMAIL PROTECTED]> To: "Mantas Kriauciunas" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Thursday, July 10, 2003 5:01 AM Subject: Re: [PHP] download php >

[PHP] Code and Good Design Methods

2003-07-12 Thread Dan J. Rychlik
I am reading PHP and MySQL web development 2nd edition book. Chapter 6 talks about displaying dynamic web content using class objects. For the type of project that I am building, this is not optimal. How do I keep my self from having html mixed with my PHP code? In other words how do I serpe

Re: [PHP] Re: Code and Good Design Methods

2003-07-12 Thread Dan J. Rychlik
hmm.. ill have a look. Thanks again. - Original Message - From: "zbranigan" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Saturday, July 12, 2003 9:15 PM Subject: [PHP] Re: Code and Good Design Methods > >>>>> "Dan" == Dan J Rych

Re: [PHP] Re: Failed to Receive in E:\...\mailscript.php on line 25

2003-07-19 Thread Philip J. Newman
thanks - Original Message - From: "Jason Wong" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Sunday, July 06, 2003 7:06 PM Subject: Re: [PHP] Re: Failed to Receive in E:\...\mailscript.php on line 25 > On Sunday 06 July 2003 14:59, Håkon Strandenes wrote: > > This is not my server, so

[PHP] Passing value back to SWF

2003-07-19 Thread Dan J. Rychlik
I have a swf file that I have created with a appropriate loadvarnum() function. I have created a $statusmsg dynamic text field. When I execute my script with a button action I am able to This works fine. print "&statusmsg="."Passing value"; But when I print "&statusmsg=". $testvariable; Re

[PHP] Is their a flash and php mailing list?

2003-07-26 Thread Dan J. Rychlik
Is their a flash and php mailing list? or PHP for Flash mailing list?

[PHP] Changing Bytes to KB, to megs, to gigs.

2003-07-26 Thread Philip J. Newman
My goal is to input the amount of Bytes used by a user as $inputbox and calculate how many kbs,megs,gigs along with $cost for the price per meg. $inputbox bytes = $kbs kb.$megs meg @ $0.05c per Meg = \$$cost$gigs gig."; ?> This is what I get outputted. 414478244 bytes = 404763.910156 kb. 395.27

Re: [PHP] htmlspecialchars() and HTML code

2003-08-08 Thread Thaddeus J. Quintin
Thanks everybody! Looks like I was just thinking about the problem too hard. Thaddeus John W. Holmes wrote: Thaddeus J. Quintin wrote: CPT John W. Holmes wrote: > Try this: > > This is <some> text > > If you submit that "text" and then print $_RE

[PHP] Session Trouble

2003-08-14 Thread Christopher J. Crane
I have created a helpdesk application with a login. I am using sessions to keep track of information I need for the session. That information is User's ID User's Last Name User's First Name If the User is Authenticated and the type user they are. Here is the page the form goes to after submitting

[PHP] htmlspecialchars() and HTML code

2003-08-14 Thread Thaddeus J. Quintin
Hello- I'm working on a site where users have the option to type HTML code into a textarea, or upload HTML code from a local file which is then displayed in the text area. The obvious problem is that an uploaded file that contains a closing tag for a textarea can wreak havoc and eat up the rest

Re: [PHP] htmlspecialchars() and HTML code

2003-08-14 Thread Thaddeus J. Quintin
problem. If the HTML file that they upload has '<' or '>' entities, then these characters will be displayed in the text area as '<' and '>' symbols. So when the text is submitted from the textarea, all of the user's HTML entities

[PHP] Correct Coding

2003-08-14 Thread Christopher J. Crane
Is this the best way to do this? if(isset($Task) && $Task == "Add") { Do something } I want to check if the variable is set and if so, if it is "Add". -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] [HELP] - Session_Unregister Not working

2003-08-14 Thread Christopher J. Crane
I can not get a variable in a session to unset() and then re-populate and it is destroyed. Please follow below to get the flow of what I am doing. I have created a helpdesk application with a login. I am using sessions to keep track of information I need for the session. That information is User'

Re: [PHP] The stupidest question of the month.

2003-08-14 Thread Dan J. Rychlik
I wrote a similiar IO Socket script by what you are describing. I used perl and the IO::Socket module. It was pretty straight forward and their is plenty of docs out there on that module. Just a thought Good Luck! Daniel - Original Message - From: "René Fournier" <[EMAIL PROTECTED]

[PHP] Iterative regular expression replacement

2003-08-19 Thread Thaddeus J. Quintin
I'm looking to replace the 'nth' instance of an expression within a string. Example (very simple)- $string="My mom can beat up your mom and your mom's dog"; $pattern="mom"; $replacement="dad"; I want to be able to replace any particular instance of the pattern within that string. I was getting

[PHP] iterative regular expression replacement

2003-08-19 Thread Thaddeus J. Quintin
I'm looking to replace the 'nth' instance of an expression within a string. Example (very simple)- $string="My mom can beat up your mom and your mom's dog"; $pattern="mom"; $replacement="dad"; I want to be able to replace any particular instance of the pattern within that string. I was getting

Re: [PHP] Iterative regular expression replacement

2003-08-19 Thread Thaddeus J. Quintin
Perfect solution. Thanks, I don't know how I overlooked the preg_replace_callback function. That's exactly what I needed. Thaddeus CPT John W. Holmes wrote: From: "Thaddeus J. Quintin" <[EMAIL PROTECTED]> I'm looking to replace the 'nth' instance o

[PHP] Quotes in regular expressions

2003-08-21 Thread Thaddeus J. Quintin
Lets say I'm trying to extract some data from an HTML document. I want to get the values of the 'src' attributes of various tags. For example- http://www.yahoo.com";> here's the pattern I've been trying- /\bsrc=(['|"])[^\\1]*[\\1]/im Basically, match the 'src=' followed by some type of quote,

Re: [PHP] Quotes in regular expressions

2003-08-21 Thread Thaddeus J. Quintin
the 'm' option, i've had previous problems with that before), and I can simplify the expression and grab everything including the quotes, so I'm really not sure what's failing. Thanks- Thaddeus Ford, Mike [LSS] wrote: On 21 August 2003 17:03, Thaddeus J. Quintin wrote:

Re: [PHP] Quotes in regular expressions

2003-08-21 Thread Thaddeus J. Quintin
. not the prettiest answer, but I put good comments around it! Thaddeus Scott Fletcher wrote: Try parsing it as a string where the double quote would become a string. See if that help. (Parse the whole characters into strings then find the double quote.) "Thaddeus J. Quintin" <[EMA

[PHP] File System

2003-03-16 Thread Philip J. Newman
How do i delete a file ... ? kill?? dele *srugs* -- Philip J. Newman. Head Developer [EMAIL PROTECTED] +64 (9) 576 9491 +64 021-048-3999 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] File System

2003-03-16 Thread Philip J. Newman
result = unlink("file.txt") or die("Operation failed!'); > > On Monday, March 17, 2003, at 12:58 AM, Philip J. Newman wrote: > > > How do i delete a file ... ? > > > > kill?? dele *srugs* > > > > -- > > Philip J. Newm

[PHP] LIsting all the Members who have not loged in for 60 days ...

2003-03-18 Thread Philip J. Newman
$lastDate is a unix time stamp in mySql ... how can i list ONLY the users who have not logged in for 60days? -- Philip J. Newman. Head Developer [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Re: Creating graphs with PHP?

2003-03-20 Thread Christopher J. Crane
JPGRAPH is the best I have found so far. Good documentation and great results. I use it for a lot of graphing purposes, the most being stock market charts and graphs. "Joseph Szobody" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] Dennis, Try this: http://www.aditus.nu/jpgraph/ Jose

[PHP] Random Number Generation

2003-03-20 Thread Christopher J. Crane
I have a script that loads 13 or more file names into an array. Then at random I select one of the names out of the array. This files are background songs used on my webpage. Streaming a different song each time the page is refreshed or loaded. My issue is I do not want the same song to ever be pla

Re: [PHP] Re: Creating graphs with PHP?

2003-03-20 Thread Christopher J. Crane
If PHP is install the GD modules are already there. Write a should script and put it on your server and access it through your web browser. It will tell you if GD is installed and what version. I do a lot of work with these and would be willing to help you get started. By the way, most people her

[PHP] Re: Increase a month

2003-03-20 Thread Christopher J. Crane
echo "\$month: ".date(F,strtotime($month)).""; you have escaped the $ by placing the \ in front of it. Remove it. "Shaun" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Hi, > > could someone tell me why this: > > $month = date(m); >echo "\$month: ".date(F,strtotime($month))."

[PHP] $siteGalleryUserPath when it is made by PHP dose not give 0777 access for $destination to be made.

2003-03-20 Thread Philip J. Newman
uot;Directory for User, $sUser, Doesn't Exist.. Creating.."; mkdir("$siteGalleryUserPath",0777); } //Code to Add the gallery photoset directory here.. //(add a directory $datestamp under the username dir.. mkdir("$destination",0777); // LINE 72 from error above. end snip -- Philip J. Newman. Head Developer [EMAIL PROTECTED]

[PHP] Wrapping text output

2003-03-21 Thread Philip J. Newman
$my_data = "This is a really long string that could go on for ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and ever and don't wrap to my table it makes it bigger"; echo $my_data; How can I make this wrap to the table?

[PHP] PHP Send Mail Main headers.

2003-03-24 Thread Philip J. Newman
ot;>\r\n"; $headers .= "X-Priority: 3\r\n"; $headers .= "X-MSMail-Priority: Normal\r\n"; $headers .= "X-Mailer: iCEx Networks HTML-Mailer v1.0"; Is this about all i need to send a mail in PHP excluding the mail(); -- Philip J. Newman. Head Developer [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Formatting code.

2003-03-25 Thread Philip J. Newman
Is there any documents on how code should be layed out? -- Philip J. Newman. Head Developer [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] How do i valadate an email address?

2003-03-26 Thread Philip J. Newman
How would i check that an e-mail has the right parts in it. for example. username @ domain . ext Thanks / Jim Bob -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] logging ip address when submitting a form

2003-03-27 Thread Philip J. Newman
$HTTP_X_FORWARDED_FOR phpinfo(); Check that its in your PHP Info. $REMOTE_ADDR will return the Remote Address. I use This small loop. if (!$HTTP_X_FORWARDED_FOR) { $HTTP_X_FORWARDED_FOR=$REMOTE_ADDR; } / Phil - Original Message - From: "Joakim Larsson" <[EMAIL PROTECTED]> To: <[EMAIL

Re: [PHP] Uploading Files Via PHP

2003-03-27 Thread Philip J. Newman
You could chnage the permissions when you want to write something then change it back when your done. Thats what i do. / Phil - Original Message - From: "Jennifer Goodie" <[EMAIL PROTECTED]> To: "Dan Rossi" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Friday, March 28, 2003 6:17 AM Sub

Re: [PHP] Re: Internet Explorer toolbar

2003-03-27 Thread Philip J. Newman
Now Now children. - Original Message - From: "Dan Rossi" <[EMAIL PROTECTED]> To: "Leif K-Brooks" <[EMAIL PROTECTED]> Cc: "Peter Houchin" <[EMAIL PROTECTED]>; "Dan" <[EMAIL PROTECTED]>; "php-general" <[EMAIL PROTECTED]> Sent: Friday, March 28, 2003 6:47 PM Subject: RE: [PHP] Re: Internet E

Re: [PHP] Re: Internet Explorer toolbar

2003-03-27 Thread Philip J. Newman
Again ... Now Now Kiddies your all way out of line. - Original Message - From: "Leif K-Brooks" <[EMAIL PROTECTED]> To: "Dan Rossi" <[EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Friday, March 28, 2003 7:55 PM Subject: Re: [PHP] Re: Internet Explorer toolbar > Correct, but he asked for

Re: [PHP] Re: Internet Explorer toolbar

2003-03-28 Thread Philip J. Newman
Mummy and Daddy sto fighting. - Original Message - From: "Dan Rossi" <[EMAIL PROTECTED]> To: "Philip J. Newman" <[EMAIL PROTECTED]>; "Leif K-Brooks" <[EMAIL PROTECTED]> Cc: "Peter Houchin" <[EMAIL PROTECTED]>; "Dan

[PHP] Random Password Making.

2003-03-28 Thread Philip J. Newman
Whats the best way to make a random password with 4 letters and 2 numbers? -- Philip J. Newman. Head Developer [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Time stamp and changing to a date.

2003-03-28 Thread Philip J. Newman
$mydate = "20030328231154"; $myPrintDate=date ("l dS of F Y h:i:s A",$mydate); echo "$myPrintDate"; Whats wrong -- Philip J. Newman. Head Developer [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Checking a string for # of charactors.

2003-03-28 Thread Philip J. Newman
I would like to check that a string as more than 20 charactors in it. Can someone point me in the right direction. Thanks .. -- Philip J. Newman. Head Developer [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Dynamic include_path

2003-03-31 Thread Derek J. Belrose
Hey folks, What we are looking to do is give a specific include path for each site in our customer base. This running on MacOSX so basically we have sites set up like: /Users/username/Sites/site.com/phpinc There can be numerous sites in each users directory and numerous users in /Users. Basic

[PHP] OCINewcollection fails after being used more then once

2003-04-02 Thread Andries J. Algera
I am trying to use the ocicollection functions. Initially everything works fine, but after reloading the page for the second time I get the following error: OCITypeByName: OCI-22303: type "SISTRUT"."MENSERRO" not found When I try half a minute later, I do manage reload the page without any err

[PHP] Newman's Problem with Images.

2003-06-05 Thread Philip J. Newman
My problem is this: I have a site that has 3 levels of access. 1,2,3 when i upload files to say $unixtimestamp/image1.jpg anyone can list the images in this directory $unixtimestamp/. I would like to hide the images out side the doc root ... is this possable .. so i can load something l

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