Correction for password validation, using this:
$this->validator->add_rule('password', 'is_safe_character', 'The password can contain only numbers, letters, underscores or dashes', $this->input->post('password'));
Instead of the regex.
Ok, this post helped: http://www.getfuelcms.com/forums/discussion/212
$this->validator->add_rule('captcha', array($this, '_valid_captcha'), 'captcha');
Sorry, in the rush, forgot to search the forum first.
I am having the same problem, but your solution does not work.
First you wrote the same code for both:
"If you are using just a straight up validator object you can do the following:
$validator = register_to_global_errors = FALSE;
If you are using …
Ok, found the solution:
$this->validator->add_rule('email', 'valid_email', 'Please enter in a valid email', $this->input->post('email')); $minLength = $this->config->item('password_min_length', 'tank_auth'); $minLengthMsg = "The …
Ok, have another question here.
The tank_auth is working, but when a controller of mine redirects to the login form it does not get the main layout.
I have added this fuel_set_var('layout', 'main') to the login_form file but still, no layout.
How…
Lance, my menu is create with a file, not through the cms.
So I can't call my menu like you do I need to give it all the parameters that I am giving it.
admin, there is no Menu.php file under: fuel/modules/fuel/libraries
There is one under fule/a…
At last I managed to solve this problem.
I found this post which helped:
http://www.getfuelcms.com/forums/discussion/584/save-related-data-to-another-table/p1
function form_fields($values = array()) { $fields = parent::form_fields(); $CI =&am…
( ! ) Fatal error: Maximum execution time of 300 seconds exceeded in C:\wamp\www\clarenssaNewFuel\fuel\codeigniter\libraries\Email.php on line 1839
Call Stack
# Time Memory Function Location
1 0.0009 398128 {main}( ) ..\index.php:0
2 0.0024 462216 r…
Ok, found the problem !!!
The nav array was:
$nav['home'] and not $nav['Home']
Changed that, now at last everything works.
Thank you very much for all the help.
Ok, this code works in hardcoding but when I call fuel_nav the active class again, is not added to the li.
Css:
ul#topmenu li { display: inline; margin: 0; padding: 0; } ul#topmenu li a { float: left; background: url("../images/template/nav/navle…
Ok, that helped 'active_class'=>'active' but the problem is the active class is being added to the list item, I need it to be added to the link item.
Is there a way to add the class to the link and not the list item in the call to the fuel_nav?
I checked the css with hardcoding the menu and adding the active class and it works.
The active class is not being added to the menu when I browse to: http://localhost/clarenssaNewFuel/home
Yes there is a sidenav too, why?
I have added in the header_block view:
echo fuel_nav(array('container_tag_id' => 'topmenu', 'item_id_prefix' => 'topmenu_', 'pre_render_func' => 'my_menu_func', 'active_class'=>'on', 'active' => uri_…
Ok, trying to add just the category now.
I have this code:
class Members_model extends Base_module_model { public $required = array(); public $foreign_keys = array('category_id' => 'categories_model'); ...} function on_after_save($values) { …
Another debug:
I added these lines in the save_related function in My_model:
echo "Model: $model "; echo "key_field: "; print_r($key_field); echo " data: "; print_r($data);die;
This is what I get and nothing is being created in t…
Hi Lance,
I have tried 2 different scenarious with no success.
First I tried to have category with multiple select and sub category with a dropdown where only one value can be selected. That's where I tried to use $this->save instead of $this-&…
Another try I made is that both are multiple choices.
Tried that:
function on_after_save($values) { $catId = (!empty($this->normalized_save_data['categories'])) ? $this->normalized_save_data['categories'] : array(); $subCatId = (!empty($…
Hi Lance,
Thanks for the help but I still don't understand what do I need to change.
I looked at the userguide Creating Simple Modules tutorial and copied the code from there, although I have to admit, I don't fully understand what it is doing.
T…