Posts made by Judy Hsu

I found this thread which answered my question:

http://moodle.org/mod/forum/discuss.php?d=135707

edit the file moodle\admin\uploadusers.php (using a simple text editor)

search for $usersnew++ and then add the two lines shown here (the comment line and the set_user_preference link) so that the code now looks like the following: (with or without the line spacing I have shown)

    $usersnew++;

    // Hack to force password change for all new users in the upload csv file
    set_user_preference('auth_forcepasswordchange', 1, $user->id);

    if ($createpasswords and empty($user->password)) {

Now save the file and the test it

Hi, I"m glad that I found this old thread. I have a similar but different question here.

Let's say that instead of using DBase, I was using bulk user upload (CSV file) to upload user accounts and enroll users into a course. All users would get a generic password to begin with (e.g. changeme).

On their first login, we want them to be redirected to a user agreement page (done), then after they click on "Yes" button, instead of showing them the course listing page, we want them to be automatically redirected to their user profile page (editing tab) so that they can start filling out all the information. How should I change the  codes so that it will behave like this? Thanks a bunch!

Judy

I have a similar but different question.

Let's say if I use bulk upload users (CSV file), and after the accounts get created by Moodle and we informed students with their initial username/password, they will then try to login using their initial password. For their first login, how do I redirect the users to their "editing profile" page (instead of showing them their Moodle courses)? Which php file should I touch and which redirect function should I use? Thanks a bunch!

~Judy

Hi all, sorry for a rookie's quick question. How do you change the codes so that it will make the "Unmask" checkbox checked (for the New password field) in the user profile editing page?? I have looked at the page source code and tried to change /lib/adminlib.php and /lib/form/passwordunmask.php, and /lib/javascript-static.js (1.9.13, search keyword "unmaskPassword" among all source codes), but can't get it to work. I feel that I'm close. Please help, thanks!

Average of ratings: -

Hi fellow developers, thanks for reading this thread.

In Moodle 1.9.x (I'm using 1.9.12), there is a "user (customized) profile fields" feature under Site Administration => Users => Accounts => User profiel fields. It seems that the newly added User Profile Fields will always be added to the bottom of the user profile page (and the editing profile page). Is there a way to move these customized user fields around, say, move it between the First Name field and Last Name field? Any help would be highly apprecated. Thanks!

Judy

Average of ratings: -