Welcome Guest, Not a member yet? Register   Sign In
AjaxFw (CJAX) For CodeIgnater 5.0 Stable
#81

[eluser]mmmx[/eluser]
Hi,
I am experiencing anather problem:
it seems uri_string() from url_helper doesn't work on ajax.php.

More it seems default method for response controllers is the one with same name of controller and not index(). isnt't it?
#82

[eluser]Ajaxboy[/eluser]
Can you provide an example how you are using it?, the url usage it's pretty straight forward using ajax.php?controller/function/var1/var2 etc,, please see url styles doc: http://cjax.sourceforge.net/docs/passing_parameters.php and http://cjax.sourceforge.net/docs/url_styles.php
#83

[eluser]mmmx[/eluser]
[quote author="Ajaxboy" date="1355077660"]Can you provide an example how you are using it?, the url usage it's pretty straight forward using ajax.php?controller/function/var1/var2 etc,, please see url styles doc: http://cjax.sourceforge.net/docs/passing_parameters.php and http://cjax.sourceforge.net/docs/url_styles.php[/quote]

Thi is my file application/response/parmetro.php controller
Code:
<?php
class Parmetro extends CI_Controller
{
function __construct()
{
  parent::__construct();

  $this->load->helper('url');
}
function index()
{
  echo "index function";
  echo "<br>uri string".uri_string();
        
}
function group($id=8)
{
  echo "id=$id <br />";
  if(!isset($id)) echo "id not set";
  echo "<br>uri string".uri_string();
}
function parmetro()
{
  echo "parmetro function";
  echo "<br>uri string".uri_string();
        
}
}

First, if I call:
ajax.php?parmetro or ajax/parmetro
I get output from function parmetro() not from function index()

Second:
in any case if I call any function of this controller I can't get uri_string() function from standard url_helper
to give me the uri segment, both if i have in the url ? or /.
I need it to have a callback to work

On the countrary everything works as expected if i put the same controller in the ordinary controllers/ folder (but then can't use ajaxfw Sad )
#84

[eluser]mmmx[/eluser]
$ajax->overLay() and session data

And here just a question:

if I have

Code:
$overlay = $ajax->overLay(base_url().'index.php/mycontroller/myfunction');
$ajax->Exec("link", $overlay);

when i clik the link 'link' it overlays the output of mycontroller/myfunction
BUT mycontroller/myfunction can't retrive userdata session variables previously defined (so for example I can't check user permission)
How can I do that? HOW does actually append method work?

thanks again for your attention

Maybe you canmove this to the 5.2 5.3 version post?
I can work around other issues easy, but for this one I have to do to much invasive tricks i think




Theme © iAndrew 2016 - Forum software by © MyBB