I am using codeignitor with jquery.
My JS is as following:
$(document).ready(function() {
var p = {};
$('#c开发者_如何学Goontent').load(/mycontroller/myfunction,p,function(str){
});
});
It gave me an invalid regular expression flag r error on line 3. I am not sure it is a JS error, or the codeignitor mod_rewrite issue.
Can someone please shred some lights?
You need quotes around the path:
"/mycontroller/myfunction"
the .load()
function takes a url in the form of a string.
var p = {};
$('#content').load("/mycontroller/myfunction",p,function(str){
});
精彩评论