Welcome to Geeklog, Anonymous Sunday, November 24 2024 @ 11:57 pm EST

Geeklog Forums

what am I missing?


FreakWorld

Anonymous
Geeklog for some reason has E-mail from admin unchecked by default.
So I changed it in the sql database setup for a new site to have it checked.
And after a new site is installed.
It is checked.
But you refresh or change themes. It's back, unchecked.
What is removing the check?
How can it stay checked.
Banging your head
 Quote

Status: Banned

machinari

Forum User
Full Member
Registered: 03/22/04
Posts: 1512
look for the following in the editpreferences() function of usersettings.php: ($A is from the database)
Text Formatted Code

    // privacy options block
    if ($A['emailfromadmin'] == 1) {
        $preferences->set_var ('emailfromadmin_checked', 'checked="checked"');
    } else {
        $preferences->set_var ('emailfromadmin_checked', '');
    }



 


that said, I don't know what would cause it to uncheck itself, but here is the code that controls it from the savepreferences() function: ($A is from $_POST)
Text Formatted Code

    if (isset ($A['emailfromadmin']) && ($A['emailfromadmin'] == 'on')) {
        $A['emailfromadmin'] = 1;
    } else {
        $A['emailfromadmin'] = 0;
    }


 
 Quote

FreakWorld

Anonymous
I gave up on it and set both variables to checked.
And thin removed it from the theme
 Quote

All times are EST. The time is now 11:57 pm.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content