⚠ In case you've missed it, we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This is an archived forum. ⚠

  •     

profile picture

broken link in the gcgrid page view



fduque

fduque
  • profile picture
  • Member

Posted 12 December 2017 - 07:58 AM

Hi fellas

 

i have lost of url path

a gc flexgrid is shown in a simple view that has a link to the home page

i have tryed with routes or real path but does not work everytime after  use a action button 

the ulr is changed to something like that [::1]/gcerp ( localhost/gcerp  is the home page )

 

note. im using set_crud_url_path() in order to make gc grid work in a mvc pattern

 

 

i'd apreciate any help


Amit Shah

Amit Shah
  • profile picture
  • Member

Posted 12 December 2017 - 09:12 AM

In the action button - use absolute URL rather then relative URL

 

Also, will recommend you setting the base_url in config.php ...

Codeigniter is based on MVC itself - you dont need to use  set_crud_url_path .. it automatically picks up the path and stuff.. 

that feature is required to be brought in use only when you have made some extra changes in the routes table 

 

say for example ... you have controller file (Manage.php)

and in there you have function users...

 

now by default you will refer to the same as http://localhost/appname/manage/users

 

If you want to use it in other way - like http://localhost/appname/users ...

u need to set this in routing and the same then u need to use the function set_crud_url_path ... 

 

It will be effective and in use only at that point of time.

 

Happy GCing :)


fduque

fduque
  • profile picture
  • Member

Posted 13 December 2017 - 08:13 AM

i'v decidecd to adopt GC's pattern instead traditional MVC one , is less traumatic

now i can concentrate my efforts to the logical of the application

 

thanks a lot Amit

 

you are a great guy 

supporting us with all kind of difficulties 

you make this project a real one by your self donation

i expect to count on you further