[PHP] aquestion about php extensions

2004-05-27 Thread php
Hello, i compile c file with vc++ (php extension). is there any possibility to execute php script in this extension? [php code will be in one string] --- ... //this is mod.c code ZEND_FUNCTION(my_function) { for(i=0;i<5;i++) { zend_execute_php_script( //is any functi

[PHP] Re: Aspect Oriented Programming & PHP

2004-05-27 Thread Bert Slagter
Michael Lauzon wrote: Since PHP5 is going to feature OOP (Object Oriented Programming), will that mean PHP6 will feature AOP (Aspect Oriented Programming)...so far it seems AOP is only being used for Java at the moment; but hopefully general programming and scripting languages will start using t

[PHP] How can I filter options?

2004-05-27 Thread dunj
Hi, every one. I am now caught in a difficulty. I create a form to query the database. There are two 'select' items in the form. For example, I refer to the first 'select' item as $province and the second as $city. When I select a item of $province, I wish $city contains only the cities of th

RE: [PHP] .htpasswd login

2004-05-27 Thread Jami
Your looking for this: $_SERVER['PHP_AUTH_USER'] When running under Apache as module doing HTTP authentication this variable is set to the username provided by the user. See Reserved Variables: http://www.php.net/reserved.variables Jami Moore LightSPARK Digital Designs http://www.lightsparkdig

[PHP] .htpasswd login

2004-05-27 Thread Daniel Baughman
I have some sites that I would like to view the user name that someone provided to the basic authentication mechanism in apache. Does php/apache provide a means for this?

RE: [PHP] Newbie Question: Variables on the fly

2004-05-27 Thread csnm
Thanks for the reply Denis, Let me elaborate a bit. I have a php page which I want to pass a series of variables via a url string. eg myPage.php?dataPoint1=10&dataPoint2=20&dataPoint3=30 The thing is I won;t know until runtime how many dataPoints there will be so I have also included 1 additional

RE: [PHP] Newbie Question: Variables on the fly

2004-05-27 Thread Dennis Seavers
Yikes!! List members, I apologize for sending a reply-requested e-mail over this list. Feel free to punish me by responding. What's worse: I took another list member to task for the same thing! "Ego deflation commences in 5 ... 4 ... 3 ... " Dennis JackArse (the "JackArse" is silent) > [Orig

RE: [PHP] Newbie Question: Variables on the fly

2004-05-27 Thread Dennis Seavers
Maybe others will catch on to your intention, but I think you need to provide a bit more information. For example, what variables do you want to create (drawn from a file source, or create on the fly)? Where will they come from (a database, perhaps)? You could create a script that creates variab

[PHP] Newbie Question: Variables on the fly

2004-05-27 Thread csnm
Hello, I'm sure this is a newbie question but I don't know the syntax. I want to create a series of variables within a php script at runtime with a for loop. eg myVar1 myVar2 myVar3 etc What is the proper syntax to do this? Thanks, Tim -- PHP General Mailing List (http://www.php.net/) To unsu

[PHP] Update Multiple Records From Form

2004-05-27 Thread Albert Padley
I feel I'm so close. I have a form with multiple database records with a checkbox to indicate which records to update set up like so: $name = "ed[" . $row['id'] . "]"; Each text input is set up like so: On the processing page I am doing this: foreach($ed as $id=>$val){ $query = "U

RE: [PHP] Keep PHP variable values between script calls - XML RPC

2004-05-27 Thread Lance Lovette
If you only need to persist a handful of request-agnostic variables you may be able to make use of an extension I wrote. Note that it doesn't work under Windows and I haven't tested it under PHP 4.3.x. http://pwee.sourceforge.net/ Lance > -Original Message- > From: Santiago Peirano [mai

[PHP] Re: Aspect Oriented Programming & PHP

2004-05-27 Thread Manuel Lemos
Hello, On 12/31/1969 09:00 PM, Michael Lauzon wrote: Since PHP5 is going to feature OOP (Object Oriented Programming), will that mean PHP6 will feature AOP (Aspect Oriented Programming)...so far it seems AOP is only being used for Java at the moment; but hopefully general programming and scripting

[PHP] Aspect Oriented Programming & PHP

2004-05-27 Thread Lauzon, Michael
Since PHP5 is going to feature OOP (Object Oriented Programming), will that mean PHP6 will feature AOP (Aspect Oriented Programming)...so far it seems AOP is only being used for Java at the moment; but hopefully general programming and scripting languages will start using them as well?! Micha

Re: [PHP] Regular expression question

2004-05-27 Thread Justin Patrin
Rob Ellis wrote: On Thu, May 27, 2004 at 09:59:05AM -0700, Dan Phiffer wrote: So I'm trying to implement a simple wiki-like syntax for hyperlinking. Basically I want to match stuff like [this], where the word 'this' gets turned into a hyperlink. I have that working, but I want to be able to esca

Re: [PHP] handle E_STRICT with own error handler

2004-05-27 Thread Curt Zirzow
* Thus wrote Bert Slagter ([EMAIL PROTECTED]): > Hi, > > I tried to use my own error handler to handle all non-fatal errors. But > to my surprise it seems to be impossible to handle E_STRICT level > notices. I don't know whether this is by design, not yet implemented or > a know bug that I over

[PHP] Re: handle E_STRICT with own error handler

2004-05-27 Thread Bert Slagter
Jason, Please read my question a bit better :). PHP indeed does report the E_STRICT notices fine, that's not my problem. I know how error handling in PHP works :). But I have my own error handler (see: set_error_handler()) and handle all notices and warnings myself (and all other E_USER_* of cou

Re: [PHP] array key starting with digit ending with string

2004-05-27 Thread Matt Matijevich
[snip] not sure I follow 100% but you could use a regular expression to detemine if it starts with a string. if (preg_match('/^\d/',$array_key)) { //do something } [/snip] I mean starts with a digit, sorry for 2 emails. I should proofread. -- PHP General Mailing List (http://www.php.net/) To u

Re: [PHP] array key starting with digit ending with string

2004-05-27 Thread Matt Matijevich
[snip] if($data[$currentVarNameInCycle]) { do something } Is there some way force the recognition of the key when it leads with a digit? [/snip] not sure I follow 100% but you could use a regular expression to detemine if it starts with a string. if (preg_match('/^\d/',$array_key)) { //

Re: [PHP] Regular expression question

2004-05-27 Thread Rob Ellis
On Thu, May 27, 2004 at 09:59:05AM -0700, Dan Phiffer wrote: > So I'm trying to implement a simple wiki-like syntax for hyperlinking. > Basically I want to match stuff like [this], where the word 'this' gets > turned into a hyperlink. I have that working, but I want to be able to > escape the op

[PHP] array key starting with digit ending with string

2004-05-27 Thread Larry Brown
I have an unusual situation where I have to communicate with an MS based soap server. They have named one of their variables with a name leading with a 1 such as 1variable. Nusoap loads the variable descriptions from the wsdl document and compares the variable names I am trying to send with the o

Re: [PHP] include and require

2004-05-27 Thread Michal Migurski
> Can anyone help me with this one: > Is there a difference between "include()" and "require()" ? http://php.net/require http://php.net/include require() and include() are identical in every way except how they handle failure. include() produces a Warning while require()

RE: [PHP] include and require

2004-05-27 Thread Chris W. Parker
Lieve Vissenaeken on Thursday, May 27, 2004 11:05 AM said: > Can anyone help me with this one: > Is there a difference between "include()" and "require()" ? yes i can help you with it. go to www.php.net and search for "include". you will then find the answer you

RE: [PHP] include and require

2004-05-27 Thread php chucker
include() will output warning message and the script continues require() will output error message and will halt the script -Original Message- From: Lieve Vissenaeken [mailto:[EMAIL PROTECTED] Sent: Thursday, May 27, 2004 2:05 PM To: [EMAIL PROTECTED] Subject: [PHP] include and require

[PHP] Re: Regular expression question

2004-05-27 Thread Jason Barnett
This should work: ^\\ # Don't match if a backslash precedes \[ # Open bracket ([^\]]+?) # Text, including whitespace \] # Close bracket By the way, using a tool called The Regex Coach I solved your problem in about 10 seconds. For those having regex problems you might

[PHP] Re: handle E_STRICT with own error handler

2004-05-27 Thread Jason Barnett
Bert Slagter wrote: Hi, I tried to use my own error handler to handle all non-fatal errors. But to my surprise it seems to be impossible to handle E_STRICT level notices. I don't know whether this is by design, not yet implemented or a know bug that I overlooked - but it seems rather strange :).

[PHP] include and require

2004-05-27 Thread Lieve Vissenaeken
Hi, Can anyone help me with this one: Is there a difference between "include()" and "require()" ? Thanks for helping... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

Re: [PHP] Keep PHP variable values between script calls - XML RPC

2004-05-27 Thread Jason Barnett
If you're trying to prevent hitting the database then just cache the page result and store it as a temporary html file. Then serve the temporary file whenever people visit (and update every 15 minutes). Jason -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.ph

[PHP] Re: Keep PHP variable values between script calls - XML RPC

2004-05-27 Thread Jason Barnett
Sounds like a pretty run-of-the-mill storage issue; or did you want to save XML messages? In any case, storing the information in a session is probably the easiest and most straightforward way to do this. Or store the information in a database. Jason -- PHP General Mailing List (http://www.ph

[PHP] Re: Changing environment variables ? (stupid question)

2004-05-27 Thread Jason Barnett
Oooh, wish you'd said Windows, I coulda given you a walkthru there. The environment variable that you want to set cannot (AFAIK) be changed by Apache. You'll need to change the variable in Solaris itself. So sayeth google: http://docs.sun.com/db/doc/806-7612/6jgfmsvrt?a=view -- PHP General Mai

[PHP] Re: Putting an image or logo on another image.

2004-05-27 Thread Jason Barnett
I haven't done image manipulation much, but for good source code on how to do it look at JpGraph. It creates image canvases and draws graph images on top of a canvas, it's really quite impressive. http://www.aditus.nu/jpgraph/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, vi

[PHP] Re: Getting the name of the Class

2004-05-27 Thread Jason Barnett
Since you're invoking this as a static method the only solution that comes to mind is to use the PHP5 builtin class Reflection_Method and/or Refelction_Class. Perhaps something like: Class Test { function Test() { echo 'Test'; } } Class MyClass extends Test { function Debug() { p

[PHP] Re: can myapp.exe run on Win ce or pocket pc?

2004-05-27 Thread Jason Barnett
Shelby wrote: Hi, I would like to develope a desktop application using PHP. I was wondering can the .exe program run on Win CE/Pocket PC? Please don't spam the list, we saw the message the first time. Well in order to run the application on a pocket PC you'd need a PHP binary for your specific p

[PHP] Regular expression question

2004-05-27 Thread Dan Phiffer
So I'm trying to implement a simple wiki-like syntax for hyperlinking. Basically I want to match stuff like [this], where the word 'this' gets turned into a hyperlink. I have that working, but I want to be able to escape the opening bracket, so that it's possible to do \[that] without having it

[PHP] Re: How to check for a $_GET without throwing a Notice?

2004-05-27 Thread Justin Patrin
Brian Dunning wrote: How do I check for the presence of an optional $_GET param without throwing a "Notice: Undefined index" when the param is not present? Tried all three of these, they all produce the Notice when the param is not passed: if ($_GET['id']) if ($_GET['id'] != "") if (isset $_GET

Re: [PHP] Self Testing PHP Code... Is it possible or practical??

2004-05-27 Thread Greg Donald
> Hello all. I have been reading much lately about the wonders of writing > self testing code for java, perl and others. Is this a feasible task to > accomplish in PHP? I have googled every search I can think of and there > just does not appear to be any information regarding self testing php >

[PHP] handle E_STRICT with own error handler

2004-05-27 Thread Bert Slagter
Hi, I tried to use my own error handler to handle all non-fatal errors. But to my surprise it seems to be impossible to handle E_STRICT level notices. I don't know whether this is by design, not yet implemented or a know bug that I overlooked - but it seems rather strange :). To reproduce: - cr

Re: [PHP] Keep PHP variable values between script calls - XML RPC

2004-05-27 Thread Santiago Peirano
Jay Blanchard wrote: [snip] Ok, here we go. I would like to implement an XML-RPC server (a script of course) that keeps the value of certain variables between the different invocations of the script. I think that it should be possible, but I don't know where to start (none of the search in inte

[PHP] Self Testing PHP Code... Is it possible or practical??

2004-05-27 Thread Adam Reiswig
Hello all. I have been reading much lately about the wonders of writing self testing code for java, perl and others. Is this a feasible task to accomplish in PHP? I have googled every search I can think of and there just does not appear to be any information regarding self testing php out th

RE: [PHP] ISSET problem with Form

2004-05-27 Thread Jay Blanchard
[snip] I'm new to PHP, so how would I go about using sessions? I assume one needs to update _SESSION['name'] = $name; with the state of the form and then use IF ? Then I'm stuck again! [/snip] start here http://www.php.net/session P.S. Always reply to the list, you may not get a response. Your e-

RE: [PHP] Keep PHP variable values between script calls - XML RPC

2004-05-27 Thread Jay Blanchard
[snip] Ok, here we go. I would like to implement an XML-RPC server (a script of course) that keeps the value of certain variables between the different invocations of the script. I think that it should be possible, but I don't know where to start (none of the search in internet gave me a starti

RE: [PHP] ISSET problem with Form

2004-05-27 Thread Jay Blanchard
[snip] I've had the script working with two states but can't get the third state working!!! Any help or alternative ideas much appreciated as this is causing me a serious headache!!! [/snip] Sessions would be a better way to handle this. -- PHP General Mailing List (http://www.php.net/) To unsubs

Re: [PHP] Keep PHP variable values between script calls - XML RPC

2004-05-27 Thread Matt Matijevich
[snip] I would like to implement an XML-RPC server (a script of course) that keeps the value of certain variables between the different invocations of the script. [/snip] Could you store them in a file? Maybe a database. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit

[PHP] ISSET problem with Form

2004-05-27 Thread Tom Chubb
If you use ISSET together with a hidden field when posting a form to itself to enter a second-state, is there a way of using it again to get to a third-state. Basically, I'm trying to convert a 3 file script into a single file and first I check to see if it's been submitted and then using ELSE I e

[PHP] Keep PHP variable values between script calls - XML RPC

2004-05-27 Thread Santiago Peirano
Ok, here we go. I would like to implement an XML-RPC server (a script of course) that keeps the value of certain variables between the different invocations of the script. I think that it should be possible, but I don’t know where to start (none of the search in internet gave me a starting poin

Re: [PHP] Server Push

2004-05-27 Thread jon
I used to work for a fairly major chat site that used software by iChat to push slides -- and I'll be darned if I could figure out how they did it. Some weird quirk of HTTP, I'd think. Anyway -- getting a basic socket server up in running in the language of your choice and using something like

Re: [PHP] imagejpeg

2004-05-27 Thread Chris Hayes
At 15:10 27-5-04, you wrote: I'm trying to create thumbnails for my images and everything seems to work correctly except for trying to save them. I've tried outputting directly with imagejpeg($im) and that works, but when trying imagejpeg($im, "new.jpeg") it does not create a new image in the curre

[PHP] Server Push

2004-05-27 Thread George Lantz
I am just looking for some different techniques on how server push is done on PHP: I am fascinated by the PHP Live! Support Solution (http://www.phplivesupport.com). I would like to try to replicate this functionality just to see how it works and maybe use it on my own website. Does anyone know h

[PHP] imagejpeg

2004-05-27 Thread Pat Hanna
I'm trying to create thumbnails for my images and everything seems to work correctly except for trying to save them. I've tried outputting directly with imagejpeg($im) and that works, but when trying imagejpeg($im, "new.jpeg") it does not create a new image in the current directory. I even tried ch

[PHP] Failover mechanism

2004-05-27 Thread Surojit MUNDLE
Hello Listers, I am very new to PHP and have a query. The problem I want to solve is that I have 4 servers for a similar application in different parts of the world. Based on where the request comes from I redirect him to the closest server. Now what I want to do is to have a Backup server whi

Re: [PHP] is_object($_SESSION['dagobertduck']);

2004-05-27 Thread Matthias H. Risse
thanks. fixed that with simple un/serialize(). somehow i assumed php would be capable of recognizing automatically that it makes sense with object to do this automatically (who really needs unexplicitly a string instead of o valid object when puttin them into a session-var?) thanks anyway m -- PHP

[PHP] Re: combining string values

2004-05-27 Thread Craig
Concatenate using: . HTH Craig "Tommy Atherton" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > hi > > I have a problem, I'm trying to combine the value of two strings > together into a final string. For example > > $path = '/tmp/photos/'; > $filename = 'pic1.jpg'; > > $finalvalu

Re: [PHP] Re: clearing new pages

2004-05-27 Thread Craig
\n"; ?> Is another option Craig "Rick Fletcher" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > > > Hi, > > > a file called a.php prints "hello" to the browser then calls > > > b.php which prints "goodbye" to the browser. > > > the output looks like this: > > > > > > hello > >

[PHP] Changing environment variables ? (stupid question)

2004-05-27 Thread Harry Sufehmi
I'm having problems getting PHP to talk to Oracle, and I think it's caused by some environment variables. Using phpinfo(), it's clear that I've managed to change (for example) the _SERVER["ORACLE_HOME"] (server variable?) by using SetEnv statement in httpd.conf. But, _ENV["ORACLE_HOME"] (environ