Welcome Guest, Not a member yet? Register   Sign In
Image display and routes.php or controller??
#3

(This post was last modified: 11-14-2014, 08:13 AM by Chroma.)

(11-12-2014, 02:09 AM)sv3tli0 Wrote: Can you copy the images paths in both cases (which are generated in your browser)?

Its good to use base_url() . '/img/path' for such static files ..

I have always found it better from a maintainability perspective to put the path inside the base_url() function:

base_url('/img/path')

(11-12-2014, 01:39 AM)discofunk Wrote: Thus
Code:
http://localhost/website/en/1/Home-Page
gives the english page of page_id 1.

Routes file therefore has:

PHP Code:
$route['default_controller'] = "content";
$route['en/(:num)/(:any)'] = "content/en/$1";
$route['de/(:num)/(:any)'] = "content/de/$1";
$route['es/(:num)/(:any)'] = "content/es/$1"
etc

I don't know how your program is supposed to work, but I do notice, that you are disposing of anything in the route apart from the number.

You are not using $2 which is the (:any) part of the route.

Is this a deliberate part of your system or do you need the remainder?
Reply


Messages In This Thread
RE: Image display and routes.php or controller?? - by Chroma - 11-14-2014, 08:09 AM



Theme © iAndrew 2016 - Forum software by © MyBB