Codeigniter + Infinity scroll help |
(12-14-2018, 04:36 PM)HarrysR Wrote: So to sum up, two major questions: My first reaction is to think in terms of one controller using several methods. For instance, an "index" method would load the initial "page" and some other method - let's call it "filter" - is the target URL in the dropdown change .ajax call. A hypothetical "scroll" method would handle the infinite-scrolling workload by way of a separate ajax call. It would be equally valid to use two controllers - one for the initial page load and another that responds to ajax requests. Is it "safe" to use ".html(data)"? Without any knowledge of what you are outputting and where it came from I cannot answer. The use of ".html(data)" isn't inherently dangerous on its own. (Actually, your likely going to want to use ".append(data)" instead of ".html".) Either way, the danger lies in data that came from "the outside" and could be attempting an exploit of some kind. But the danger isn't any different from loading a view page. |
Messages In This Thread |
Codeigniter + Infinity scroll help - by HarrysR - 12-11-2018, 03:15 PM
RE: Codeigniter + Infinity scroll help - by Pertti - 12-12-2018, 01:37 AM
RE: Codeigniter + Infinity scroll help - by HarrysR - 12-12-2018, 09:07 AM
RE: Codeigniter + Infinity scroll help - by dave friend - 12-14-2018, 10:54 AM
RE: Codeigniter + Infinity scroll help - by HarrysR - 12-14-2018, 12:56 PM
RE: Codeigniter + Infinity scroll help - by dave friend - 12-14-2018, 04:03 PM
RE: Codeigniter + Infinity scroll help - by HarrysR - 12-14-2018, 04:36 PM
RE: Codeigniter + Infinity scroll help - by dave friend - 12-14-2018, 06:16 PM
RE: Codeigniter + Infinity scroll help - by HarrysR - 12-14-2018, 06:43 PM
|