CodeIgniter Forums
BackendPro 0.6.1 - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forumdisplay.php?fid=22)
+--- Thread: BackendPro 0.6.1 (/showthread.php?tid=7381)



BackendPro 0.6.1 - El Forum - 06-21-2010

[eluser]shinokada[/eluser]
I am not sure if I wrote this before.
My wish list to a BEP version 1.0:

Currently when I install BEP, it adds be_ in the database.
I wish I could modify it when I install it.
Because I want to install more than one application to one database.

Thanks.


BackendPro 0.6.1 - El Forum - 06-24-2010

[eluser]CARP[/eluser]
Hi Adam...
I've upgraded to latest xampp, with php 5.3.1, etc. and now all my apps are screwed...
More info:
http://ellislab.com/forums/viewthread/158776/

Do you have any idea what I could do to fix?
Thanks,


BackendPro 0.6.1 - El Forum - 06-25-2010

[eluser]adamp1[/eluser]
BackendPro 0.6.1 dosn't yet work with PHP 5, you can patch it by following the following instructions.

http://www.kaydoo.co.uk/2010/04/patch-backendpro-0-6-1-for-use-with-php-5


BackendPro 0.6.1 - El Forum - 06-25-2010

[eluser]CARP[/eluser]
Thanks Adam, just fixing the #414 line in Loader.php worked...


BackendPro 0.6.1 - El Forum - 06-28-2010

[eluser]alainm[/eluser]
Adam, i was wondering if you have any updates to the SVN? i have not seen anything new checked in since May 22.. Sad

Looking forward to all the nice fixes..

cheers,
Alain


BackendPro 0.6.1 - El Forum - 06-30-2010

[eluser]adamp1[/eluser]
No, sadly I am having to work flat out at work to get some stuff done, so by the time it gets to weekend/evening the last thing I want to do is go on the computer again.


BackendPro 0.6.1 - El Forum - 07-05-2010

[eluser]CARP[/eluser]
Hi Adam
I'm being asked about some stuff, and I wonder if I'll be able to do it with BP:

The Admin user will be the only one with access to BP (Control Panel). All the other users will access only to the frontend site. But there's an user called "Distributor" which should be able to add users to the application. These users will be final users with "more restricted profile" than Distributor

What would be your advice?

1- To do it with BP by tweaking some stuff (how?)
2- To do some gui in the app and use BP functions?

PS: each user should be able to change his password in the "profile" section of the app. Which BP functions should I use for this? from which file?

Thanks again


BackendPro 0.6.1 - El Forum - 07-12-2010

[eluser]shinokada[/eluser]
Hi Adam,

I am having a problem to access session user_data.

Code:
In controller:
$data['user_data'] = $this->session->userdata('user_data');

In view:
var_dump ($user_data);
or
var_dump ($user_data['username']);

I can retrieve ip_address, session_id, and others except user_data.

When I var_dump() it, it display bool(false) even though I can see data in database.


Can you tell me how to access/retrieve user_data in BEP?


BackendPro 0.6.1 - El Forum - 07-12-2010

[eluser]shinokada[/eluser]
Ok, never mind. I found it.

Code:
$data['user_data'] = $this->session->userdata('username');

Thanks anyway.


BackendPro 0.6.1 - El Forum - 08-01-2010

[eluser]shinokada[/eluser]
Question regarding custom user profile, http://www.kaydoo.co.uk/backendpro/user_guide/features/userauth.html

Hi Adam.
After reading the manual, I have a couple of questions.

Q1. Could you suggest the best way to auto fill custom user profile when editing?
.../index.php/auth/admin/members/form/1

Currently all the custom fields I created are blank and when I update, I have to fill all.

I guess I can pull the data from the table be_user_profiles and use something like this.

Code:
echo "\n<p><label for='comname'>Company Name</label><br/>\n";
$data = array('name'=>'company_name','id'=>'comname','size'=>40, 'value' => $profiles['company_name']);
echo form_input($data) ."</p>\n";


Q2. I updated Userlib config file

Code:
...
$config['userlib_profile_rules'] = array('gender' => 'required|alpha');


Do I still have to set validation rules and validate in function form()?

Code:
this is your code.
function form($id = NULL)
    {
        // VALIDATION FIELDS
        $fields['id'] = "ID";
        $fields['username'] = $this->lang->line('userlib_username');
        $fields['email'] = $this->lang->line('userlib_email');
        ...
        $fields = array_merge($fields, $this->config->item('userlib_profile_fields'));
        $this->validation->set_fields($fields);

        // Setup validation rules
        if( is_null($id))
        {
            // Use create user rules (make sure no-one has the same email)
            $rules['username'] = "trim|required|spare_username";
            $rules['email'] = "trim|required|valid_email|spare_email";
            $rules['password'] = "trim|required|min_length[".$this->preference->item('min_password_length')."]|matches[confirm_password]";


Q3. I am wondering what $this->validation->username in your example code.
It seems setting the value, but how come it is using $this->validation->username.


Code:
&lt;?php print form_label($this->lang->line('userlib_username'),'username')?&gt;
                &lt;?php print form_input('username',$this->validation->username,'id="username" class="text"')?&gt;


I appreciate any inputs.

Thanks in advance.