doa24uk Posted November 30, 2009 Share Posted November 30, 2009 Hi guys, I want to simulate opening a window & actually visiting a site for the following url. http://mysite.com/ping/?title=mytitle&blogurl=myurl&chk_weblogscom=on&chk_blogs=on Alternatively, you can use xml-rpc to send the details but I don't think that's possible with php is it?? This would mean dynamically creating an xml file from a mysql database ... and I don't think that's possible Quote Link to comment Share on other sites More sharing options...
oni-kun Posted November 30, 2009 Share Posted November 30, 2009 You can dynamically create iframes of some sort (such as an autosurf). If you have the url in the GET then it'll be somewhat simple to browse the site within a frame. Quote Link to comment Share on other sites More sharing options...
premiso Posted November 30, 2009 Share Posted November 30, 2009 To open a window you will need to use Javascript. As far as generating an XML file dynamically from a MySQL database you bet that is possible. If you create a loop of your own markup it would work or even try using simple_xml. Quote Link to comment Share on other sites More sharing options...
doa24uk Posted November 30, 2009 Author Share Posted November 30, 2009 I should be more specific. This will be run as a cron job therefore no user integration / visual output is required ... the script simply needs to open the URL to send the ping. I've found the following code that apparently works for classic ASP ... can anyone translate this to php?? function SendPing(byval strBlogName, byval strBlogUrl, byval strPageUrl, byval strFeedUrl) ‘ build ping XMLRPC call strData = “<?xml version=”"1.0″”?>” strData = strData & “<methodCall>” strData = strData & “<methodName>weblogUpdates.extendedPing</methodName>” strData = strData & “<params>” strData = strData & “<param>” strData = strData & “<value>” & strBlogName & “</value>” strData = strData & “</param>” strData = strData & “<param>” strData = strData & “<value>” & strBlogUrl & “</value>” strData = strData & “</param>” strData = strData & “<param>” strData = strData & “<value>” & strPageUrl & “</value>” strData = strData & “</param>” strData = strData & “<param>” strData = strData & “<value>” & strFeedUrl & “</value>” strData = strData & “</param>” strData = strData & “</params>” strData = strData & “</methodCall>” ‘ post to Pingomatic XMLRPC ping URL set objHttp = Server.CreateObject(”MSXML2.ServerXMLHTTP”) objHttp.open “POST”, “http://rpc.pingomatic.com/”, false objHttp.setRequestHeader “Content-Type”, “text/xml” objHttp.setRequestHeader “Content-Length”, len(strData) objHttp.Send strData ‘ check response if (objHttp.status = 200) then strReturn = objHttp.responseText end if ‘ release object set objHttp = nothing ‘ passback SendPing = strReturn end function strData = SendPing(”The Title Of Your Website”, “The URL of your website”, “The URL of the new article”, “The URL of your RSS feed”) 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.