|
2011-04-05
, 22:18
|
Posts: 560 |
Thanked: 422 times |
Joined on Mar 2011
|
#2
|
The Following User Says Thank You to demolition For This Useful Post: | ||
|
2011-04-05
, 22:40
|
Posts: 237 |
Thanked: 193 times |
Joined on Feb 2010
@ Brighton, UK
|
#3
|
But the bigger problem I have is that when I get the response with the script and runs it, it should try to communicate with the server. This is becuase in the <script type="text/javascript"> there is a function filter which looks like this:
I have been running wireshark to see all the packets thats being transmitted/recieved. But all I see is a ACK and then nothing more. So what I think is that this $("#chartContainer").load() stuff is already on my computer. But if so how do I access this and what datatype is it??Code:function filter() { var query = "userId=11111&daysBack=" + $("#daysBack").val(); $("#chartContainer").load("/statistics/typedistributionchart?" + query); }
Yours,
The Following User Says Thank You to mr id For This Useful Post: | ||
|
2011-04-06
, 06:43
|
Posts: 289 |
Thanked: 101 times |
Joined on Oct 2009
|
#4
|
Looks like fairly standard JavaScript JQuery running in a browser :
var query
is a dynamically built string where
$("#daysBack").val()
is most likely the value inputted or held in the html form element with 'id="daysBack"'
$("#chartContainer").load("/statistics/typedistributionchart?" + query);
is then calling the url query and displaying the returned HTML in a visual element with an 'id=chartContainer'
If I were you I'd look at what:
http://THE_SITE/statistics/typedistr...111&daysBack=2
returns, assuming a valid user ID of course.
Does it return HTML? Will you need to parse out the bits you want from this markup? Does the site offer a cleaner way of getting this data?
|
2011-04-06
, 07:16
|
Posts: 237 |
Thanked: 193 times |
Joined on Feb 2010
@ Brighton, UK
|
#5
|
|
2011-04-06
, 07:31
|
Posts: 289 |
Thanked: 101 times |
Joined on Oct 2009
|
#6
|
|
2011-04-06
, 07:34
|
Posts: 237 |
Thanked: 193 times |
Joined on Feb 2010
@ Brighton, UK
|
#7
|
Thanks, I will look into it!
I did not mean the site was running Qt but my application that need the charts does
But the bigger problem I have is that when I get the response with the script and runs it, it should try to communicate with the server. This is becuase in the <script type="text/javascript"> there is a function filter which looks like this:
Yours,