Re: [PHP] Invalid chars in XML
CDATA tags is what you need --- Ellis (Sent from my iPod) On 2010-09-20, at 16:57, Bastien Koert wrote: > On Mon, Sep 20, 2010 at 4:07 PM, robert mena wrote: >> Hi, >> >> I am trying to parse a XML file with simplexml_load but it gave me error. >> While inspecting the contents I found a & inside the value of a tag. >> something & something. >> >> After I've removed the & everything went fine. So which chars I should not >> put in my file? Should I use some conversion function like html_entities? >> >> Does the receiver of the XML has to do anything to convert is back? >> > > > The following should not be used inside XML > > & ampersand > ' single quote > " double quote >> greater than > < less than > > you could simply wrap all your data in CDATA tags > -- > > Bastien > > Cat, the other other white meat > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] How to catch an exception using SoapClient.
like any other exception ... using a try catch block ;) Ellis 110010100001 " Unfortunately, no one can be told what The Matrix is. You have to see it for yourself. " twitter.com/floverdevel facebook.com/ellis.antaya google.com/profiles/ellis.antaya linkedin.com/in/ellisantaya On Mon, Aug 6, 2012 at 10:56 PM, James Newman < james.new...@primalmedia.co.nz> wrote: > I was wondering how I'd catch an exception using SoapClient. > > > > $data = array( > 'Particular'=>'Payment for stuff', > 'Email' =>'e mail address', > 'CardNumber'=>', > 'CardType' =>'MC', > 'CardExpiry'=>'0423', > 'CardHolderName'=>'James Newman', > 'CardCSC' =>'111', > 'StoreCard' =>'true' > ); > $vars = array( > 'trace' => 1, > 'exceptions' => true, > 'cache_wsdl' => WSDL_CACHE_NONE, > 'features' => SOAP_SINGLE_ELEMENT_ARRAYS); > $client = new SoapClient("http://XMLSERVICEURLws/paymentws.asmx?WSDL";, > $vars); > > #$out = $client->ListCards($text); > #$this->_result = $client->ProcessPurchase($data); > $this->_result = $client->ProcessAuthorise($data); > #var_dump($client->__getLastRequestHeaders()); > #var_dump($client->__getTypes()); > print_r($this->_result); >
Re: [PHP] Re: Delaying $(document).ready() in jQuery until php script finish
i'm not sure i understand your problem ?!? php runs on the server, delivers html code and/or javascript to the browser and only from there the jQuery will execute it's main loop and start trigger some events such as the ready event. So the php script is always finish when javascript start to execute ... On Fri, Mar 4, 2011 at 12:18, Nathan Rixham wrote: > Richard Sharp wrote: > >> I have been banging my head trying to figure out how to delay >> $(document).ready() command until my php script finish running and load >> data into a csv file. Any ideas >> > > *which* PHP script? are you returning an HTML document then keeping the > script going in the background, /or/ are you requesting another script (by > js, clicking a link, posting a form), /or/? > > I know it's a jQuery question, but it might be a PHP related gotcha. > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- Ellis 110010100001 twitter.com/floverdevel facebook.com/ellis.antaya google.com/profiles/ellis.antaya linkedin.com/in/ellisantaya
Re: [PHP] Re: Delaying $(document).ready() in jQuery until php script finish
Also, the $(document).ready() is triggered when the DOM is ready to be manipulated. I dont know why you would consider alter the behavior of this event, maybe what you want is to create yourself a custom event handler ... On Sun, Mar 6, 2011 at 21:43, Ellis Antaya wrote: > i'm not sure i understand your problem ?!? > > php runs on the server, delivers html code and/or javascript to the browser > and only from there the jQuery will execute it's main loop and start trigger > some events such as the ready event. So the php script is always finish > when javascript start to execute ... > > > On Fri, Mar 4, 2011 at 12:18, Nathan Rixham wrote: > >> Richard Sharp wrote: >> >>> I have been banging my head trying to figure out how to delay >>> $(document).ready() command until my php script finish running and load >>> data into a csv file. Any ideas >>> >> >> *which* PHP script? are you returning an HTML document then keeping the >> script going in the background, /or/ are you requesting another script (by >> js, clicking a link, posting a form), /or/? >> >> I know it's a jQuery question, but it might be a PHP related gotcha. >> >> >> -- >> PHP General Mailing List (http://www.php.net/) >> To unsubscribe, visit: http://www.php.net/unsub.php >> >> > > > -- > Ellis > 110010100001 > > twitter.com/floverdevel > facebook.com/ellis.antaya > google.com/profiles/ellis.antaya > linkedin.com/in/ellisantaya > > -- Ellis 110010100001 twitter.com/floverdevel facebook.com/ellis.antaya google.com/profiles/ellis.antaya linkedin.com/in/ellisantaya
Re: [PHP] passing variables to php script
"it can't work as long as long as there is Q:\ ins his form action" +1 David, which web server are you running (apache, iis, ...)? What is your document_root? And last question, where are your html file and your php file(the full file path)? --- Ellis (Sent from my iPod) On 2012-01-10, at 16:25, Marco Behnke wrote: > Am 10.01.12 21:57, schrieb Ashley Sheridan: >> >> >>> o simply "callrecs.php" and see if that works. >>> > Q: would be referencing a filesystem path, rather a web address >>> > interpreted by a PHP processor. Make sure your .php target is within a >>> > PHP supported web space. >>> If a default application is set within windows for php, the script >>> submitting to Q will be executed. >>> >>> >> >> But wouldn't Windows attempt to execute the PHP script as if it were a CLI >> script, not as if it were within a web server context? That would make >> posting a form pretty pointless. > Indeed. But isn't that the point? We are trying to figure out why his posting > the form does not work. I say, it can't work as long as long as there is Q:\ > ins his form action, no way it will do, because you leave your webserver > context anyways. > > He must change it to a valid web url. > > -- > Marco Behnke > Dipl. Informatiker (FH), SAE Audio Engineer Diploma > Zend Certified Engineer PHP 5.3 > > Tel.: 0174 / 9722336 > e-Mail: ma...@behnke.biz > > Softwaretechnik Behnke > Heinrich-Heine-Str. 7D > 21218 Seevetal > > http://www.behnke.biz