Welcome Guest, Not a member yet? Register   Sign In
using helpers outside the systems folder
#2

[eluser]crumpet[/eluser]
I have not found a perfect solution for this.
One thing you can do is write your ajax functions so that they take a parameter called URL and then call that function from within your view file and use a php brace there where you echo the value you need.

Code:
[removed]
$("form").submit(function(){  
    ajaxFunction(<?php echo uriHelperFunc() ?>);
});
[removed]

Or you can just practice bad coding practises and put all your javascript in your view files and then you can put php wherever you want (what i did)


Messages In This Thread
using helpers outside the systems folder - by El Forum - 08-31-2008, 10:33 AM
using helpers outside the systems folder - by El Forum - 09-01-2008, 07:37 PM
using helpers outside the systems folder - by El Forum - 09-01-2008, 08:13 PM
using helpers outside the systems folder - by El Forum - 09-29-2008, 06:44 PM



Theme © iAndrew 2016 - Forum software by © MyBB