themistral Posted May 15, 2010 Share Posted May 15, 2010 Hi guys, I want to call a function from a third party website. I have included the file and know that is working ok. However, the function in this external file is not listed in the functions available to my website. How can I use this function? Can anyone help with this? Thanks! Quote Link to comment Share on other sites More sharing options...
JAY6390 Posted May 15, 2010 Share Posted May 15, 2010 If the file is parsed on the remote server before you receive it then you won't get it into your code. You need the file to be output. If you type the url directly into your browser can you see the correct code when you view the source? Quote Link to comment Share on other sites More sharing options...
themistral Posted May 15, 2010 Author Share Posted May 15, 2010 Thanks for the reply Jay. Yes the function works as expected on the external url - if that's what you meant. How do I force the file to be output? Quote Link to comment Share on other sites More sharing options...
JAY6390 Posted May 15, 2010 Share Posted May 15, 2010 If you have access to the remove server you can create a simple script to output the data, or even ftp onto the server and retrieve the file via phps ftp functions. if not, you wont be able to do this Quote Link to comment Share on other sites More sharing options...
themistral Posted May 15, 2010 Author Share Posted May 15, 2010 Ah, ok. Thanks for the help Jay. I will have a play and see what I can do! Quote Link to comment Share on other sites More sharing options...
CodeMaster Posted May 15, 2010 Share Posted May 15, 2010 Well I think you need a webservice to do this like Soap or XML-RPC. What does the function do? Do you want to call the function from server A and then the function runs "something" on server B and returns output to server A? Then you definitely need SOAP or something for this. Quote Link to comment Share on other sites More sharing options...
themistral Posted May 16, 2010 Author Share Posted May 16, 2010 Thanks for the reply CodeMaster. Website B parses variable to the function on Website A, which then processes the information and returns that info for use on Website B. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.