Re: [PHP] Avoid object twice

2008-06-03 Thread Yui Hiroaki
HI! I had mistake in code in php. When I excute My.php, it say Hello When I excute b.php, it say Hello Good I would like to execute b.php and show only Good If you know it ,please teach me! Here is code below; -b.php ?php function __autoload($class_name) {

Re: [PHP] Storing £ (pound sterling) sign and displaying in HTML email

2008-06-03 Thread Graham Cossey
On Tue, Jun 3, 2008 at 12:06 AM, James Dempster [EMAIL PROTECTED] wrote: This is most likely a character encoding issue. Check that the html encoding is set to the same type as what your storing it as in mysql. Thanks James, it certainly was a character encoding issue. My dev box didn't have

Re: [PHP] Avoid object twice

2008-06-03 Thread James Dempster
I don't see how it's possible for you to get Hello after Good, when the file that cause's Hello is required to do Good /James On Mon, Jun 2, 2008 at 2:00 PM, Yui Hiroaki [EMAIL PROTECTED] wrote: Please take a look at code. a.php $obj=new my(Hello); $obj-buff(); Class

Re: [PHP] Avoid object twice

2008-06-03 Thread James Dempster
I suggest you don't put code other than class structures in class files. Also don't execute My.php just execute b.php which though __autoload includes My.php. -b.php ?php function __autoload($class_name) { include_once $class_name . '.php'; } $obj=new My(Hello);

Re: [PHP] Avoid object twice

2008-06-03 Thread Yui Hiroaki
Thank you for a good suggest! Somehow, I have to execute my.php also. This program have to run. 1)My.php 2)b.php My.php show Hello - it is OK, b.php shows Hello Good it is NOT good. I need to get only Good Please give me a suggestion. Regards, Yui 2008/6/3 James Dempster [EMAIL PROTECTED]:

Re: [PHP] Avoid object twice

2008-06-03 Thread Yui Hiroaki
Thank you for a good suggest! Somehow, I have to execute my.php also. This program have to run. 1)My.php 2)b.php My.php show Hello - it is OK, b.php shows Hello Good it is NOT good. I need to get only Good Please give me a suggestion. Regards, Yui 2008/6/3 James Dempster [EMAIL PROTECTED]:

Re: [PHP] Avoid object twice

2008-06-03 Thread Yui Hiroaki
Please look at my.php my.php load $obj=new My(Hello); $obj-buff(); so, if a.php load, it absolutely got hello in load b.php Regards, Yui 2008/6/3 Thijs Lensselink [EMAIL PROTECTED]: Quoting Yui Hiroaki [EMAIL PROTECTED]: Thank you for a good suggest! Somehow, I have to execute my.php

Re: [PHP] Avoid object twice

2008-06-03 Thread Thijs Lensselink
Quoting Yui Hiroaki [EMAIL PROTECTED]: Thank you for a good suggest! Somehow, I have to execute my.php also. This program have to run. 1)My.php 2)b.php My.php show Hello - it is OK, b.php shows Hello Good it is NOT good. I need to get only Good Please give me a suggestion. Regards, Yui

Re: [PHP] Avoid object twice

2008-06-03 Thread Thijs Lensselink
Quoting Yui Hiroaki [EMAIL PROTECTED]: Please look at my.php my.php load $obj=new My(Hello); $obj-buff(); so, if a.php load, it absolutely got hello in load b.php Regards, Yui 2008/6/3 Thijs Lensselink [EMAIL PROTECTED]: Quoting Yui Hiroaki [EMAIL PROTECTED]: Thank you for a good

RES: [PHP] question, about mysql query

2008-06-03 Thread Thiago Pojda
Didn't read everything but if you just don't want duplicates, can't select distinct help you? Atenciosamente, www.softpartech.com.br Thiago Henrique Pojda Desenvolvimento Web +55 41 3033-7676 [EMAIL PROTECTED] Excelência em Softwares Financeiros -Mensagem original- De: LKSunny

Re: [PHP] question, about mysql query

2008-06-03 Thread Daniel Brown
This isn't a PHP question at all. It's a MySQL question. However, answers are below, with forwards to the appropriate lists for archiving purposes. On Mon, Jun 2, 2008 at 9:19 PM, LKSunny [EMAIL PROTECTED] wrote: two table, tablea and tableb tablea uid, col1, col2, col3 1,xx, xx, xx

[PHP] problem with include directive under XHTML

2008-06-03 Thread Robert Huff
I'm working on a project that involves converting HTML to XHTML. Not strictly sure this is a PHP issue, but testing (so far) has eliminated other possibilities. Can someone offer suggestions why, on the same server (Apache 2.2.8), this works: !DOCTYPE HTML PUBLIC -//W3C//DTD

[PHP] Re: problem with include directive under XHTML

2008-06-03 Thread Michael Kelly
Robert Huff wrote: I'm working on a project that involves converting HTML to XHTML. Not strictly sure this is a PHP issue, but testing (so far) has eliminated other possibilities. Can someone offer suggestions why, on the same server (Apache 2.2.8), this works: !DOCTYPE HTML

Re: [PHP] Avoid object twice

2008-06-03 Thread Yui Hiroaki
The code is blelow; -b.php ?php function __autoload($class_name) { include_once $class_name . '.php'; } $objref=new My(Good); $objref-buff(); ? --- --My.php-- ?php $obj=new My(Hello); $obj-buff(); Class My{

Re: [PHP] Avoid object twice

2008-06-03 Thread Stut
On 3 Jun 2008, at 17:12, Yui Hiroaki wrote: The code is blelow; -b.php ?php function __autoload($class_name) { include_once $class_name . '.php'; } $objref=new My(Good); $objref-buff(); ? --- --My.php-- ?php

Re: [PHP] question, about mysql query

2008-06-03 Thread Wolf
LKSunny [EMAIL PROTECTED] wrote: two table, tablea and tableb tablea uid, col1, col2, col3 1,xx, xx, xx 2,xx, xx, xx 3,xx, xx, xx tableb id, uid, col1, firstdata 1, 1, xx, 1 2, 2, xx, 0 3, 2, xx, 0 4, 1, xx, 0 i want query tablea, and join tableb, uid is

Re: [PHP] Avoid object twice

2008-06-03 Thread Jim Lucas
Yui Hiroaki wrote: The code is blelow; -b.php ?php function __autoload($class_name) { include_once $class_name . '.php'; } $objref=new My(Good); $objref-buff(); ? --- --My.php-- ?php $obj=new My(Hello);

[PHP] About MS SQL Connections...

2008-06-03 Thread Lic. Eduardo R. Hernández Osorio
Hello. I have a problem with a Desktop Edition MS SQL Server servant, when I try to get connected to crosswise of PHP functions to this, it provokes an error and I can not achieve the connection. However when I try the same operation on an Standard Edition MS SQL Server servant I am able to

Re: [PHP] Avoid object twice

2008-06-03 Thread Shawn McKenzie
Stut wrote: On 3 Jun 2008, at 18:35, Yui Hiroaki wrote: Sorry I still have a problem. Let's take a step back. What are you *actually* trying to do. I'm assuming it's not just printing out Hello and Good. What is the real problem you're trying to solve and what are the constraints that are

Re: [PHP] Avoid object twice

2008-06-03 Thread Yui Hiroaki
Thank you for everyone who helps me! I got a message what I want. Thank you! Yui 2008/6/4 Jim Lucas [EMAIL PROTECTED]: Yui Hiroaki wrote: The code is blelow; -b.php ?php function __autoload($class_name) { include_once $class_name . '.php'; }

Re: [PHP] Avoid object twice

2008-06-03 Thread Stut
On 3 Jun 2008, at 18:35, Yui Hiroaki wrote: Sorry I still have a problem. Let's take a step back. What are you *actually* trying to do. I'm assuming it's not just printing out Hello and Good. What is the real problem you're trying to solve and what are the constraints that are causing

Re: [PHP] About MS SQL Connections...

2008-06-03 Thread Dan Joseph
On Tue, Jun 3, 2008 at 1:43 PM, Lic. Eduardo R. Hernández Osorio [EMAIL PROTECTED] wrote: Hello. I have a problem with a Desktop Edition MS SQL Server servant, when I try to get connected to crosswise of PHP functions to this, it provokes an error and I can not achieve the connection.

Re: [PHP] Avoid object twice

2008-06-03 Thread Yui Hiroaki
Sorry I still have a problem. I separete files belows; -My.php--- ?php Class My{ private $word; function __construct($getword){ $this-word=$getword; } public function buff(){ echo $this-word.br /; } } ?

Re: [PHP] problem with include directive under XHTML

2008-06-03 Thread Robert Huff
Robbert van Andel writes: I've had this problem. It's because of the ? and ? that surrounds your XML. Your php configuration probably has short tags enabled. Negative, Prior research found this problem, and the short tags setting, which was promptly set to OFF,

Re: [PHP] problem with include directive under XHTML

2008-06-03 Thread Robbert van Andel
What is the error message you are getting? On Tue, Jun 3, 2008 at 11:37 AM, Robert Huff [EMAIL PROTECTED] wrote: Robbert van Andel writes: I've had this problem. It's because of the ? and ? that surrounds your XML. Your php configuration probably has short tags enabled.

Re: [PHP] problem with include directive under XHTML

2008-06-03 Thread Robbert van Andel
I've had this problem. It's because of the ? and ? that surrounds your XML. Your php configuration probably has short tags enabled. I have had to use php to output this ?PHP echo ' ?xml version=1.0 encoding=utf-8?' ; ? On Tue, Jun 3, 2008 at 7:25 AM, Robert Huff [EMAIL PROTECTED] wrote:

[PHP] no array passed error

2008-06-03 Thread PJ
I don't know if this is the right list, it seems php and postgresql are rather interdependent in the webside I am debugging :(, but here goes: I'm getting this error: pg_execute() [a href='function.pg-execute'function.pg-execute/a]: No array passedE_WARNING for this line of code: if(

Re: [PHP] no array passed error

2008-06-03 Thread Nathan Nobbe
On Tue, Jun 3, 2008 at 4:28 PM, PJ [EMAIL PROTECTED] wrote: I don't know if this is the right list, it seems php and postgresql are rather interdependent in the webside I am debugging :(, but here goes: I'm getting this error: pg_execute() [a href='function.pg-execute'function.pg-execute/a]:

Re: [PHP] no array passed error

2008-06-03 Thread Ted Wood
PJ, I remember the days when this stuff seemed beyond mystical. 1. $dbh and $query are not built-in variables... but they need to be defined somewhere earlier in the code. That could even be in a different file if the file you're in has been included. 2. One trick to try is to use the php

[PHP] Regex in PHP

2008-06-03 Thread VamVan
Hello All, For example I have these email addressess - [EMAIL PROTECTED] [EMAIL PROTECTED] [EMAIL PROTECTED] What would be my PHP function[Regular expression[ to that can give me some thing like yahoo.com hotmail.com gmail.com Thanks

Re: [PHP] Regex in PHP

2008-06-03 Thread Liran Oz
You can use this: $str = '[EMAIL PROTECTED]'; preg_match('/[EMAIL PROTECTED]@(.+)/', $str, $matches); var_dump($matches);//will be in $matches[1] Or without regex: echo substr($str, strpos($str, '@')+1); Liran - Original Message - From: VamVan [EMAIL PROTECTED] To:

Re: [PHP] Regex in PHP

2008-06-03 Thread Nathan Nobbe
On Tue, Jun 3, 2008 at 8:39 PM, VamVan [EMAIL PROTECTED] wrote: Hello All, For example I have these email addressess - [EMAIL PROTECTED] [EMAIL PROTECTED] [EMAIL PROTECTED] What would be my PHP function[Regular expression[ to that can give me some thing like yahoo.com hotmail.com