Welcome Guest, Not a member yet? Register   Sign In
  redirect problem in IE when url is cloaked
Posted by: El Forum - 10-23-2007, 12:30 PM - No Replies

[eluser]zeratool[/eluser]
hello,

i have a webapp that's built on CI, when viewed in Firefox, there's no problem at all.
The problem is when using IE(all versions). Here is the scenario:

on login page, once the username and password are correct , i do it like this:

redirect('user/page');

IE cannot redirect it(url is cloaked), but the user is being logged in, you will know it when you reload the page, you will see in the status that the session is stored.

Anybody here experienced the same problem?

Your help is very much appreciated, thanks in advance!


  remapping controllers' function calls: what about arguments?
Posted by: El Forum - 10-23-2007, 11:02 AM - Replies (7)

[eluser]Michael Ekoka[/eluser]
I'm experimenting with the controller's _remap() method that overrides a call to specific methods. In the user guide it states that

Quote:The overridden function call (typically the second segment of the URI) will be passed as a parameter the _remap() function
(User Guide : Controllers).

Code:
function _remap($method)
{
    if ($method == 'some_method')
    {
        $this->$method();
    }
    else
    {
        $this->default_method();
    }
}

Now, i would like to be able to call the original method with the arguments that were intended for it, but the guide doesn't mention anything about them.

Has anyone ever played with this?


  Upload From URL
Posted by: El Forum - 10-23-2007, 09:24 AM - Replies (6)

[eluser]Unknown[/eluser]
hi all

I am new to code igniter framework.
In admin side while adding products. I want to upload the image by passing the image URL.
I don't know where to write the exact code of copy function to copy the Url image.

Any body have idea on this, Will provide the suggestion and giuidelines to upload the image from URL.

Thanks in Advance..


  Problem with URI and redirecting
Posted by: El Forum - 10-23-2007, 06:48 AM - Replies (4)

[eluser]Unknown[/eluser]
Hi,

I'm a newbie, and I have the following problem. I'm using a .htaccess with the following contents:

Code:
RewriteEngine on
RewriteCond $1 !^(index\.php|images|robots\.txt)
RewriteRule ^(.*)$ /index.php/$1 [L]

I have a controller 'Admin' with a method 'login'
Code:
function login($error_msg=''){
        $this->load->helper('form');
        $data = array();
        
        if($error_msg != ''){
            $data['error_msg'] = $error_msg;
        }
        $this->load->view('admin/login',$data);
    }
and the form in the login view submits to 'admin/check'
Code:
form_open('admin/check');

The problem is when i submit the form, it submits to the following URI :
http://localhost:59925/index.php/admin/i...dmin/check

Why does it double the last segments?
Also, the stylesheet doesn't get loaded. I've specified the following link in the href:
/system/application/resources/styles/global.css

any ideas? ..
thanks


  How to Maintain session using Database
Posted by: El Forum - 10-23-2007, 06:39 AM - Replies (1)

[eluser]MASS MASS[/eluser]
Can anybody help me to store a session in database rather than maintaining in cookie file


Please specify with code


  Does is CodeIgniter support AJAX ?
Posted by: El Forum - 10-23-2007, 05:41 AM - Replies (8)

[eluser]ningnoht[/eluser]
Does is CodeIgniter support AJAX ?


  Picture uploader
Posted by: El Forum - 10-23-2007, 05:26 AM - Replies (1)

[eluser]Robb__[/eluser]
Does anyone have or know of a freeware to upload pictures to a folder on my webserver and, with some small changes, also upload info about them to a mysql database?


  validation reference in codeigniter
Posted by: El Forum - 10-23-2007, 04:47 AM - Replies (2)

[eluser]mistress_shiira[/eluser]
good day!ive been trying to make a validation form...i have read the tutorial on the validation class.but there is something that i want to learn more.this is regarding setting the rules for validation.
example i have this:
$rules['email'] = 'required|trim|valid_email';

there was a note that if i wanted to know more about validation rules i will just look up validation reference..but for the life of me i dont know where it is.Smile
can anyone send me a link to it?i want to know the available rules that i can use.
thanks


  Custom Library Problem [solved]
Posted by: El Forum - 10-23-2007, 04:41 AM - Replies (2)

[eluser]n8m[/eluser]
Hi,

I've got a problem writing my own Libraries. Here's my Class:

Code:
class Aclass{
    
    function Aclass()
    {
    $CI=& get_instance();
    $CI->load->library('session');
        

    }
    
    function checksessionid()
    {

        $session_id = $CI->session->userdata('session_id');
        echo $session_id;
    }

}

The funny thing is, that it works when I put the Constructor lines into the method. Where's the error?

Thanks for your help
n8m


  multiple db problem
Posted by: El Forum - 10-23-2007, 04:05 AM - No Replies

[eluser]Steerlin[/eluser]
Hi,

I'm using CI to develop a DB migration tool for a client. I've managed to connect to an Access and Postgres DB simultaneously but run into trouble when the querying starts. It appears as if the two connections share an odbc object:

Code:
class Test extends Controller {

    function Test()
    {
        parent::Controller();    
    }
    
    function index()
    {
        echo "connect to Access DB\n";        
        $msaccess    = $this->load->database('msaccess', TRUE);
        echo "connect to Postgres DB\n";
        $postgres    = $this->load->database('postgres', TRUE);
        
        $msaccess->limit(1);
        $editorial    = $msaccess->get('tablename');
        foreach($editorial->result() as $row)
        {
            echo $row->Id." ";
        }    
    }
}


This works fine if I put the $postgres statement after the foreach loop or when I comment it out. But loading and using the two db's simultaneously (code exactly as above) crashes:

Severity: WarningMessage: odbc_errormsg(): 27 is not a valid ODBC-Link resource
Filename: odbc/odbc_driver.phpLine Number: 320
A PHP Error was encountered

Severity: WarningMessage: odbc_error(): 27 is not a valid ODBC-Link resourceFil
ename: odbc/odbc_driver.phpLine Number: 333
A PHP Error was encountered

Severity: WarningMessage: odbc_errormsg(): 27 is not a valid ODBC-Link resource
Filename: odbc/odbc_driver.phpLine Number: 320
Database Error

Could this be a bug ?

to clarify:

this works:

Code:
$msaccess    = $this->load->database('msaccess', TRUE);
$res    = $msaccess->get('picture')->result();
print_r($res);
            
$postgres    = $this->load->database('postgres', TRUE);            
$res    = $postgres->get('poi')->result();
print_r($res);

this doesn't work:

Code:
$msaccess    = $this->load->database('msaccess', TRUE);
$postgres    = $this->load->database('postgres', TRUE);

$res    = $msaccess->get('picture')->result();
print_r($res);        
                
$res    = $postgres->get('poi')->result();
print_r($res);


Welcome, Guest
You have to register before you can post on our site.

Username
  

Password
  





Latest Threads
Changing Session cookie -...
by codeus
56 minutes ago
hot-reload side effects s...
by PaulC
11 hours ago
using app/Config/App.php ...
by sam547
Yesterday, 03:04 PM
Setting baseURL in Regist...
by grimpirate
05-15-2025, 02:20 PM
CRUD Code Generator
by DeanE10
05-15-2025, 05:31 AM
CodeIgniter.com - Report ...
by Harry Lyre
05-14-2025, 04:26 AM
Missing closing bracket w...
by abf
05-13-2025, 07:27 PM
Update from 4.6.0 to 4.6....
by FlavioSuar
05-13-2025, 04:17 AM
Sessions old files are de...
by InsiteFX
05-12-2025, 10:30 PM
Ajax post failing with Ty...
by PaulC
05-12-2025, 12:23 AM

Forum Statistics
» Members: 146,562
» Latest member: oefwoef
» Forum threads: 78,392
» Forum posts: 379,465

Full Statistics

Search Forums

(Advanced Search)


Theme © iAndrew 2016 - Forum software by © MyBB