PDA

View Full Version : view request url sent via ajax??



php_techy
07-06-2010, 06:20 AM
Hi,
Excuse me if similar issue has been posted earlier.
Am using ajax, calling url

function getFeedWithComments(table,feed_id_1,page,cpage,hashval){
url = 'file1.php?action=feeds_comments&output=xml&table='+table+'&feed_id='+feed_id_1+'&page='+page+'&comment_page='+cpage;
if(hashval){
url+= '&hashval=f'+hashval+'_c';
}
createXHR();
sendRequest(url);
}

I can get the url called by either putting alert OR using live http headers but my client is not a savvy.

I want him to view the current request url sent but how??
What will be the easiest way for this?

Thanks in advance.
Regards

Jesdisciple
07-06-2010, 11:51 AM
Does this feature need to be available in the production code? If so, I would add a query or hash part to the URL to enable it so ordinary users don't have to be aware of it.

But to get the URL on the page, I would absolutely position a span with a red background and white text near an element that is intuitively associated with the request. Or, if that introduces way too much complexity for a maintenance feature, just put the span in one of the window's corners.