I want to implement basic line highchart (http://www.highcharts.com/demo/line-basic)
using ajax. chart values update through ajax.
please help me how I do it
thanks
The highcharts website has an article about this here http://docs.highcharts.com/#preprocessing-live-data
This covers the basics of getting new data from the server using Ajax. If you want to add a new series to the chart, then you need to call
chart.addSeries(data)
Th is is documented here http://api.highcharts.com/highcharts#Chart.addSeries()
Please take look at example where data is loaded by ajax
http://www.highcharts.com/demo/line-ajax
Related
I'm looking for leads on how to implement a (search-)result browser without using paging. But more like how twitter/facebook do it.
At first only 10 or so results need to be displayed but when scrolling down, more results (if any) should be added asynchronously. I've found examples with a [more] button at the end but I would like the browser to automatically fetch more when the bottom of the pane is reached.
I'm having trouble finding the right examples. Probably because I don't know what keywords to google on...
Hope you can help me out in the right direction!
Kind regards,
Paul
I advise you read following article regarding this subject:
Infinite Scroll in ASP.NET MVC
There is also a sample application available here.
Refer to the Replace paging with jQuery and subsonic continuous scrolling method blog post.
Have a look at the following pages:
On Scroll down how to make ajax call and get the respone data
create-a-dynamic-scrolling-content-box-using-ajax
I believe that should help you!
I have a project that require me to do a auto complete search using CI and YUI.
User will enter search keywords in textfield 1 and the result will shown in textfield 2..
YUI is client-side JavaScript. What you should do is read some documentation on autocomplete first, and on CodeIgniter second and then you could start building your solution.
Basically, you have to make a few things.
For one, you should create a client-side page with what is basically an <input> or <textarea> tag and a div for your results and hook a YUI autocomplete handler to that field. To be able to use YUI, you first need to include the YUI script:
<script src="http://yui.yahooapis.com/3.4.1/build/yui/yui-min.js"></script>
And you also need to load the autocomplete module and configure it:
YUI().use('autocomplete', function (Y) {
// enter code here
}
Second, you need to build a server-side script with CI that will listen for queries, do database or whatever searches and return JSON or some other format of results.
You'll then give the URL of this CI query web script to YUI AutoComplete configuration and YUI will do the AJAX and stuff for you.
Those are very general steps, but your question is also pretty generic. If you ask more specific questions, you'll get better answers (or better, just search and read the documentation).
First, I've already tried showing a graph using a FileContentResult and the write method. But I can't use both since my requirement requires me to show a grid on 1 tab and a graph on the next tab. So I need to store the graph in a ViewBag and render it to a view, but I'm unable to do that. Is there anyway around?
Note: I'm using the Chart object from System.Web.Helpers namespace.
Thanks,
czetsuya
You can render chart as partial view.
you can use System.Web.Helpers namespace here an example:
http://msdn.microsoft.com/en-us/library/system.web.helpers.chart(v=vs.99).aspx
A chart is just an image. Link to it.
<img src="#Html.Action("ImageAction")" alt="Chart" />
I found a solution (without executing the same query), I stored the image in a cache and later refer to it via a unique key. Unfortunately, I needed to issue another http request for it. See post here: http://czetsuya-tech.blogspot.com/2012/02/how-to-render-chart-object-in-view-in.html
Is it possible to get this kind of charts http://msdn.microsoft.com/en-us/library/ee704599.aspx using ASP.NET MVC 3.0 Chart Helper?
when i am passing Presentation XML to helper as a chart theme it is just does not work.
Anything i can do?
Don't know if you're still looking for an answer to this question. Do you mean is it possible to get a chart that looks like the one you linked to? Here's a pretty nice walk-through for one that looks similar, and some example presentation xml. If this is what you're already doing, you should post your img tag, action method, xml string, and any other relevant code. You might just have something out of place.
I'm trying to find tutorials or code to allow users to customise their page, just like twitter ,wordpress and tumblr do.
Could someone tell me what technology their using?
i'm a .net developer, but maybe they're using jquery?
Any help would be great.
Thanks
You can use javascript to change style sheets and the DOM
Question is a bit broad. To change the page you simply need to manipulate the DOM or change the CSS associated with the page's elements. This can be done any number of ways. E.g. you could write out a new CSS class dynamically, you could add new elements to the DOM itself or you could modify the existing attributes of the page. e.g. to set the background of the page you can do something like:
(assuming JQuery)
$("body").css('background-image','url(path/to/image)');
Hope that helps,
-fs