Welcome Guest, Not a member yet? Register   Sign In
The URI you submitted has disallowed characters.
#1

[eluser]itzmevishu[/eluser]
Hello Sir,

Im facing the problem "The URI you submitted has disallowed characters." . Im mylocal system it is working fine but in server it is throwing the error

Please have a look in config.php file
Code:
<?php if (!defined('BASEPATH')) exit('No direct script access allowed');



$config['base_url'] = "http://207.211.64.234/pd1";


$config['index_page'] = "index.php?";

$config['uri_protocol']    = "REQUEST_URI";



$config['url_suffix'] = "";


$config['language']    = "english";


$config['charset'] = "UTF-8";


$config['enable_hooks'] = FALSE;



$config['subclass_prefix'] = 'MY_';


$config['permitted_uri_chars'] = 'a-z 0-9~%.:_?\-';



$config['enable_query_strings'] = FALSE;
$config['directory_trigger'] = 'd';
$config['controller_trigger'] = 'c';
$config['function_trigger'] = 'm';

$config['log_threshold'] = 0;


$config['log_path'] = '';


$config['log_date_format'] = 'Y-m-d H:i:s';


$config['cache_path'] = '';


$config['encryption_key'] = "C1l5e7v89e2r77I3g5n9i5t7e1r2R3o1c4k5s6";


$config['sess_cookie_name']        = 'lr_session';
$config['sess_expiration']        = 7200;
$config['sess_encrypt_cookie']    = TRUE;
$config['sess_use_database']    = TRUE;
$config['sess_table_name']        = 'lr_sessions';
$config['sess_match_ip']        = FALSE;
$config['sess_match_useragent']    = TRUE;
$config['sess_time_to_update']     = 300;




$config['cookie_prefix']    = "";
$config['cookie_domain']    = "";
$config['cookie_path']        = "/";


$config['global_xss_filtering'] = TRUE;


$config['compress_output'] = TRUE;


$config['time_reference'] = 'local';



$config['rewrite_short_tags'] = TRUE;
Here is my .htacess file
Code:
RewriteEngine on
RewriteCond $1 !^(index\.php|public|favicon\.ico)
RewriteRule ^(.*)$ index.php/$1 [L]

Please suggest me with any solution . Thanks in advance
#2

[eluser]TheFuzzy0ne[/eluser]
Welcome to the CodeIgniter forums!

It's hard to tell what the problem is without knowing the URL you're trying to use. Please post the request URI part of the string.
#3

[eluser]itzmevishu[/eluser]
Hello Sir,

Thanks for instant reply.

Im using Jquery to poplate data in textbox .

Code:
$.get('<?=base_url()?>mediainfo/mediainfo/getinfo',{ url: val },function(data){
    
      if(data.length){
        //Do something with the data  
        var result = data.split('~');
        
        document.getElementById('medianame').focus();
        document.getElementById('medianame').value  =  result[0] ;
        document.getElementById('alexarank').value  = result[1] ;
        document.getElementById('googlerank').value  = result[2] ;
      
      }
    });
  }

It is working in my local system but not in server .

Response im getting is disallowed characters.

Once again loads of thanks to you sir
#4

[eluser]itzmevishu[/eluser]
Sir to make you clear ,

Please login into the site

http://ipoditunesongo.com/pd/

userId:/password : admin/linkster

After login if you click on logout button you can see the type of error. Like wise whereever i use the javascript methods its throwing the error

Thanks
#5

[eluser]TheFuzzy0ne[/eluser]
The problem is the & and =. I would suggest configuring CodeIgniter to use query strings,
Code:
$config['enable_query_strings'] = TRUE;

or structuring your URLs differently to bypass this problem. One of my favourites is this:

http://mysite.tld/arg1:some_value/arg2:a...lue/arg3:1

This is valid and can easily be broken up into an array for accessing the data.
#6

[eluser]itzmevishu[/eluser]
Sir i have already tried with that option .. but no change in my problem.
Still im wondering how in my local system it is working and not in server ...

Have you tried to login into the site which i posted ?
#7

[eluser]TheFuzzy0ne[/eluser]
Yes, I logged in, hence my suggestion. Enabling query strings will fix the problem you're currently experiencing. Please try it again.

Your production server and development server clearly have different configurations. The only way to get a URL like the one your using through to CodeIgniter without being told you have invalid characters is to either add those characters to the allowed characters string, or to enable query strings. Without one or the the other, I don't see how this could work on your development server.
#8

[eluser]itzmevishu[/eluser]
Sir ..Im very thankfull to you for giving replies ..
i allowed those those two characters and enabled querystring . Now its giving 404 error page not found. Hoping to get solved

Thanks alot sir
#9

[eluser]TheFuzzy0ne[/eluser]
I won't pretend I have a clue what's going on with your URL, however, try adding a slash after the "logout" part of the URI.
#10

[eluser]itzmevishu[/eluser]
:-S

<ul class="side_nav">
&lt;?php if ($this->user->confirm_logout): ?&gt;
<li>&lt;?=anchor('login/logout/', 'Logout', array('class' => 'confirm'))?&gt;</li>
&lt;?php else: ?&gt;
<li>&lt;?=anchor('login/logout/', 'Logout')?&gt;</li>
&lt;? endif; ?&gt;
</ul>

but its removing trailing slash .. while showing up .. and same 404 error


I think im a poor programmer




Theme © iAndrew 2016 - Forum software by © MyBB