Search Results

Search found 5 results on 1 pages for 'blackmage'.

Page 1/1 | 1 

  • PHP SOAP Transfering Files

    - by blackmage
    Hey, I am new to SOAP and I am trying to learn how to transfer files (.zip files) between a client and server using PHP and SOAP. Currently I have a set up that looks something like this: enter code here require('libraries/nusoap/nusoap.php'); $server = new nusoap_server; $server-configureWSDL('server', 'urn:server'); $server-wsdl-schemaTargetNamespace = 'urn:server'; $server-register('sendFile', array('value' = 'xsd:string'), array('return' = 'xsd:string'), 'urn:server', 'urn:server#sendFile'); But I am unsure on what the return type should be if not a string? I am thinking of using a base64_encode but I am not sure how to. Any advice would be greatly appreciated.

    Read the article

  • Objective-C NSMutableDictionary Disappearing

    - by blackmage
    I am having this problem with the NSMutableDictionary where the values are not coming up. Snippets from my code look like this: //Data into the Hash and then into an array yellowPages = [[NSMutableArray alloc] init]; NSMutableDictionary *address1=[[NSMutableDictionary alloc] init]; [address1 setObject:@"213 Pheasant CT" forKey: @"Street"]; [address1 setObject:@"NC" forKey: @"State"]; [address1 setObject:@"Wilmington" forKey: @"City"]; [address1 setObject:@"28403" forKey: @"Zip"]; [address1 setObject:@"Residential" forKey: @"Type"]; [yellowPages addObject:address1]; NSMutableDictionary *address2=[[NSMutableDictionary alloc] init]; [address1 setObject:@"812 Pheasant CT" forKey: @"Street"]; [address1 setObject:@"NC" forKey: @"State"]; [address1 setObject:@"Wilmington" forKey: @"City"]; [address1 setObject:@"28403" forKey: @"Zip"]; [address1 setObject:@"Residential" forKey: @"Type"]; [yellowPages addObject:address2]; //Iterate through array pulling the hash and insert into Location Object for(int i=0; i<locationCount; i++){ NSMutableDictionary *anAddress=[theAddresses getYellowPageAddressByIndex:i]; //Set Data Members Location *addressLocation=[[Location alloc] init]; addressLocation.Street=[anAddress objectForKey:@"Street"]; locations[i]=addressLocation; NSLog(addressLocation.Street); } So the problem is only the second address is printed, the 813 and I can't figure out why. Can anyone offer any help?

    Read the article

  • AJAX problem-onreadystate does not work

    - by blackmage
    I am having a problem where my AJAX code does not get past the onreadtstate. The if( XMLHttpRequestObject) works fine, but the other part does not. The code is below: enter code here function getXmlHttpRequestObject() { if (window.XMLHttpRequest && !(window.ActiveXObject)) { XMLHttpRequestObject= new XMLHttpRequest(); return XMLHttpRequestObject; } else if (window.ActiveXObject) { try{ XMLHttpRequestObject=new ActiveXObject("Msxml2.XMLHTTP"); return XMLHttpRequestObject; }catch(exception1){ try{ XMLHttpRequestObject= new ActiveXObject("Microsoft.XMLHTTP"); return XMLHttpRequestObject; }catch(exception2){ }//end exception 2 }//end exception 1 }//end if else else{ document.getElementById('ajax_status').innerHTML='Status: Cound not create XmlHttpRequest Object.' + 'Consider upgrading your browser.'; } }//end function getXmlHttpRequestObject() { function loadJavascript( src, url ){ XMLHttpRequestObject=getXmlHttpRequestObject(); if( XMLHttpRequestObject){ //an alert will work here XMLHttpRequestObject.onreadystatechange = function() { alert("Here"); //Nothing at this pint works if (XMLHttpRequestObject.readyState == 4 && XMLHttpRequestObject.status == 200) { includeJavaScript( sId, url, oXmlHttp.responseText ); } } } }//end LoadJavaScript Does anyone have an idea of what can be going wrong?

    Read the article

  • Inserting Newline from XML to Database

    - by blackmage
    I am trying to parse this xml document in which a newline is required for certain fields and must be inserted into the database with the newline. But I've been running into problems. 1)First Problem: \n Character The first problem I had was using the \n like below. <javascript>jquery_ui.js\nshadowbox_modal.js\nuser_profile.js\ntablesorter.js</javascript> The problem was in the database the field came out ot be jquery_ui.js\nshadowbox_modal.js\n... and when output into html it was jquery_ui.jsnshadowbox_modal.jsn............... 2) Then I tried actually having newlines in the xml <javascript>jquery_ui.js shadowbox_modal.js user_profile.js tablesorter.js</javascript> The problem was the output become %20%20%20%20%20%20%20%20%20%20shadowbox_modal.js, and so forth. So how can I get a newline to hold from xml when entered into a database and then output with the newline still?

    Read the article

  • Ajax Javascript method cannot be called

    - by blackmage
    I made this method to load javascript functions dynamically. It does include the .js file but when I call a method, the method says that it is undefinited. The following to .js files are ajax_object.js and user_manager.js . The alert outside the function is read and works but the alert inside does not. enter code here //ajax_object.js //Load a javascript library function loadJavascript( src, url ){ XMLHttpRequestObject=getXmlHttpRequestObject(); if( XMLHttpRequestObject){ XMLHttpRequestObject.onreadystatechange = function() { if (XMLHttpRequestObject.readyState == 4 ){ if (XMLHttpRequestObject.status == 200 || XMLHttpRequestObject.status == 304) { includeJavaScript( src, url, XMLHttpRequestObject.responseText ); } } } } XMLHttpRequestObject.open('GET', url, true); XMLHttpRequestObject.send(null); }//end LoadJavaScript //Add Library to header function includeJavaScript(src, fileUrl, xmlObject) { if ( ( xmlObject != null ) && ( !document.getElementById( src ) ) ){ var documentHead = document.getElementsByTagName('HEAD').item(0); var includeScript = document.createElement( "script" ); includeScript.language = "javascript"; includeScript.type = "text/javascript"; //includeScript.id = src; includeScript.src=fileUrl.concat(src); includeScript.defer = true; includeScript.text = xmlObject; documentHead.appendChild( includeScript ); } } //user_manager.js //First alert is read alert("Outside User Manager"); function selectUserManagerModuleType(){ XMLHttpRequestObject=getXmlHttpRequestObject(); //This doesn't work //throws selectUserManagerModuleType undefined alert("Inside The User Manager"); }

    Read the article

1