You are here: Com object with PHP How to use? « All PHP « IT news, forums, messages
Com object with PHP How to use?

Posted by JAYO on 01/18/07 23:00

I have a COM Server that create an object with PHP, then from the html
input sentence using onchange, goes to a javascript function, as
parameter the input value, within this value i want to get from the COM
Server an answer. From PHP the object is created with new, as:
$coi = new COM("Coi4ImplP.Coi4");
and I can get from the server the answer as:
$hresult=$coi->Empresa($_POST["empresa"]);
$ruta=$coi->Ruta();
$niveles=$coi->Niveles();
$nombree=$coi->Nombre();
but in the input area from the html page in the from like:
<td><input type="text" size="25" name="cuenta[<? echo($n); ?>]"
value="<? echo($cuenta[$n]); ?>" onChange="<? echo
rdes($cuenta[$n]);?>"></td>

the function is:
function rdes(cta){
var <?php global $coi; $k=$coi->Ruta(); echo('$k='.$k); ?>;
alert($k);
}

I get an error in the page, if I change $k=$coi->Ruta(); to $k=5; it
works fine.

Can somebody help me please?

Thank you in advance.

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация