- Readme First! - Read and follow the rules, otherwise your posts will be closed
There are currently, 56 guest(s) and 0 member(s) that are online. You are Anonymous user. You can register for free by clicking here
Nuke Cops :: View topic - Is it possible? [ ]
Author
Message
Nova45
Guest
Posted:
Wed Aug 24, 2005 6:34 pm
I was wondering if it was possible to disable registration on a php site so that noone outside the administrator can make account. I still need people to be able to login for the accounts i create but i dont want anyone to be able to register unless i make the account for them. is it possible? if so.. how..
Thanks in advance
Rockdrala
Sergeant
Joined: Aug 09, 2005
Posts: 97
Posted:
Wed Aug 24, 2005 6:45 pm
Hey I am having touble getting the upload profile photo mod working
I can pull up the table install module..
here is the code
<?php
/*
table inst for profile photo mod
*/
define('IN_PHPBB', true);
$phpbb_root_path='./';
include($phpbb_root_path.'extension.inc');
include($phpbb_root_path.'common.'.$phpEx);
//
// Start session management
//
$userdata = session_pagestart($user_ip, PAGE_INDEX, $nukeuser);
init_userprefs($userdata);
//
// End session management
//
function query($sql, $errormsg)
{
global $db;
if ( !($result = $db->sql_query($sql)) )
{
print "<br><font color=\"red\">\n";
print "$errormsg<br>";
$sql_error = $db->sql_error();
print $sql_error['code'] .": ". $sql_error['message']. "<br>\n";
print "<pre>$sql</pre>";
print "</font>\n";
return FALSE;
}
else
{
return $result;
}
}
function insert_into_config($name, $value)
{
global $db;
$sql = 'SELECT config_name FROM ' . CONFIG_TABLE . ' WHERE config_name=\'' . $name . '\'';
$result = $db->sql_query($sql);
if ($db->sql_numrows($result) != 0)
{
return;
}
echo 'Insert ' . $name . ' into ' . CONFIG_TABLE . '...<br />';
$sql = 'INSERT INTO ' . CONFIG_TABLE . ' (config_name, config_value) VALUES (\'' . $name . '\', \'' . $value . '\')';
query($sql, 'Could not insert ' . $name . ' into ' . CONFIG_TABLE . '.');
}
//
// Add New Config Variables
//
echo "<html>";
echo "<body>";
insert_into_config('allow_photo_remote', '1');
insert_into_config('allow_photo_upload', '1');
insert_into_config('photo_filesize', '6144');
insert_into_config('photo_max_height', '80');
insert_into_config('photo_max_width', '80');
insert_into_config('photo_path', 'images/photos');
echo "done<br />";
echo "create user variable 'user_photo'...";
$sql = "ALTER TABLE " . USERS_TABLE . " ADD user_photo VARCHAR(100)";
query($sql, "Couldn't alter users table");
echo "done<br />";
echo "create user variable 'user_photo_type'...";
$sql = "ALTER TABLE " . USERS_TABLE . " ADD user_photo_type TINYINT(4) DEFAULT '0' NOT NULL";
query($sql, "Couldn't alter users table");
echo "done<br />";
echo "<br />sucessfully added new config variables.<br />";
echo "</body>";
echo "</html>";
webshark
Sergeant
Joined: Apr 21, 2005
Posts: 106
Posted:
Wed Aug 24, 2005 10:30 pm
nova
check out approve membership and cnb ya modules
rock
wash your face
_________________
USM
Guest
Posted:
Thu Aug 25, 2005 12:02 am
Nova look at the resend email module as this gives you the ability to check users applications to join before sending the email
You can post new topics in this forum You can reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum