Avatar

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

admin

About

Username
admin
Joined
Visits
8,799
Last Active
Roles
Administrator

Comments

  • You are right in that it is not dependent on the precedence but on the ID value. The items are saved in the order in which they appear and so their IDs naturally determine their order. Using the ID instead of the precedence allows it to work on mode…
  • For a simple module, each language version has it's own record. The pages module does something similar but with the fuel_pagevariables table (each language has it's own set of page variables associated with it). When you go to create a page with…
  • For simple modules, it just becomes a where condition on your model call since it's just a table. The Pages module has a different table structure and so it operates a bit differently.
  • Did you try adding your own $this->order_by() in the list_items model? If you put in $this->debug_query() right before it returns the data items in the method, it will output the SQL being generated if you need to examine it.
  • For modules, you can add a varchar field called "language" to your module and query your front end results based on the language being viewed. There will then also be a dropdown select in the admin for you to filter the languages.
  • Use $CI instead of $this
  • Thanks for the report. This has been updated in the 7.2 compatibility branch
    in PHP 7.2 Comment by admin May 2018
  • Thanks for the report. I've pushed an update for that.
    in PHP 7.2 Comment by admin May 2018
  • If you are using the Pages module to save these values you can hook into the saving process using a Layout object (instead of an array). There is a post_process_saved_values($values) that you can implement which passes in an array of data to be save…
    in xss Comment by admin May 2018
  • If you change the title field to be the 2nd column in your table instead of the foreign key field does it work? Also, if you print out the value of $val, is it equal to 'title' before calling the parent::options_list(...)?
    in Foreign Key Comment by admin May 2018
  • Try this or just changing $val to be title; public function options_list($key = 'id', $val = 'title', $where = array(), $order = TRUE, $group = TRUE) { if ($val == 'category_id') { $val = 'title'; } $data = parent::options_l…
    in Foreign Key Comment by admin May 2018
  • Do you know what line number the error was on and what was your work-around?
    in PHP 7.2 Mcrypt Comment by admin May 2018
  • In your model, you can overwrite the default behavior: public function options_list($key = 'id', $val = 'title', $where = array(), $order = TRUE, $group = TRUE) { $data = parent::options_list($key, $val, $where, $order); return $data; }
    in Foreign Key Comment by admin May 2018
  • FUEL should be using the newer encryption library already. Where are you seeing issues with it using encrypt? Also, note that there is a branch on GitHub for 7.2 that we are working on addressing specific issues with 7.2.
    in PHP 7.2 Mcrypt Comment by admin May 2018
  • Yes... FUEL is just a layer on top of CI.
  • You can put in a redirect in the fuel/application/config/redirects.php to force the redirect to the specific language version.
  • You can do something like the following in your module's config in MY_fuel_modules.php: ... 'table_actions' => array('VIEW', 'EDIT', 'PDF' => array('func' => function($fields){ $CI =& get_instance(); if ($CI->fuel-…
  • The change I recommended hasn't been pushed to the branch yet and was something I thought you could test out locally since I'm not able to replicate just yet. The code change was specified here to the Dwoo/Compiler.php file: https://forum.getfuelcm…
    in PHP 7.2 Comment by admin May 2018
  • It's not at the same line number though since it was replaced with a foreach correct?
    in PHP 7.2 Comment by admin May 2018
  • Is the error message the same you listed above at the same line number (regarding each() function)?
    in PHP 7.2 Comment by admin May 2018
  • The documentation may be a little old there. CI 3 complicated how FUEL got around that with hooks that so now when a controller is setup, it will take over regardless. So any view files would need to be rendered from the controller as well.
  • Try looking at the main index.php file around line 142 where you should see the following: error_reporting(-1); ini_set('display_errors', 1);
    in PHP 7.2 Comment by admin April 2018
  • If you are wanting to automatically create associated records, then you'll need to do it on an on_after_save hook on your model.
  • You'll definitely want it set to "auto" instead of "views" if you are wanting to pull data from the CMS. If you create another page in the CMS does it pull in more data than home?
  • I'm having a tough time replicating that issue. If you change that line in the error in the Dwoo/Compiler 3044 to the following does it work: foreach ($map as $k => $v) {
    in PHP 7.2 Comment by admin April 2018
  • Is there an ending script tag? For the Dwoo/Compiler.php error, I'll need to probably look into updating that codebase... ugh!
    in PHP 7.2 Comment by admin April 2018
  • I've fixed the $l_delim error in that branch. Regarding the spacing, what is the real HTML for that suppose to be?
    in PHP 7.2 Comment by admin April 2018
  • The post_process hook just needs to be callable. This means it could be a string value for a function, an array with the the object and method (e.g. array($my_object, 'my_post_process')) or a Closure function.
  • Are you wanting to save those dates onto another model entirely? Perhaps something like a foreach loop on the on_after_save hook that loops through the dates to save those to another model?