Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #21  
Old 10-30-2001, 12:44 AM
DarkManX_19
Guest
 
Posts: n/a
Default

well, not all of us are as web savy as others.....some things aren't as easy to peice together....and since you obviously already know the answer...why cna't ya just help a guy out??
Reply With Quote
  #22  
Old 11-27-2001, 12:07 PM
veedee veedee is offline
 
Join Date: Oct 2001
Posts: 117
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Arrggh

So sorry for forgetting about this. I have changed jobs and lost the code. I will re-do it and *promise* to post everything I have done.

Cheers,

veedee
Reply With Quote
  #23  
Old 02-05-2002, 01:45 PM
Wolf42's Avatar
Wolf42 Wolf42 is offline
 
Join Date: Nov 2001
Location: Vienna, Austria, Europe
Posts: 150
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I tryed it for myself, but I have a little problem. I added the following code into register.php:
PHP Code:
// ############################### start fast signup ###############################
if ($action=="fast") {

  if (!
$allowregistration) {
    eval(
"standarderror(\"".gettemplate("error_noregister")."\");");
    exit;
  }

  if (
$bbuserinfo[userid]!=and !$allowmultiregs) {
    
$getuser=$DB_site->query_first("SELECT username FROM user WHERE userid='$bbuserinfo[userid]'");
    
$username=$getuser[username];

    eval(
"standarderror(\"".gettemplate("error_alreadyregistered")."\");");

    exit;
  }

  
$coppadate=vbdate($dateformat,mktime(0,0,0,date("m"),date("d"),date("Y")-13));

  if (!
$usecoppa) {
    
$who="adult";
  }

  if (
$who=="coppa") {
    eval(
"dooutput(\"".gettemplate("signupcoppa")."\");");
  } else {
    if (
$who=="adult") {
      eval(
"dooutput(\"".gettemplate("signupadult_fast")."\");");
    } else {
      eval(
"dooutput(\"".gettemplate("signupverify")."\");");
   }
 }
}
// ############################### start register fast ###############################
if ($action=="registerfast") {
  if (!
$allowregistration) {
    eval(
"standarderror(\"".gettemplate("error_noregister")."\");");
    exit;
  }

  if (
$bbuserinfo[userid]!=and !$allowmultiregs) {
    
$getuser=$DB_site->query_first("SELECT username FROM user WHERE userid='$bbuserinfo[userid]'");
    
$username=$getuser[username];

    eval(
"standarderror(\"".gettemplate("error_alreadyregistered")."\");");

    exit;
  }

  if (
$allowhtml) {
    
$htmlonoff=$ontext;
  } else {
    
$htmlonoff=$offtext;
  }
  if (
$allowbbcode) {
    
$bbcodeonoff=$ontext;
  } else {
    
$bbcodeonoff=$offtext;
  }
  if (
$allowbbimagecode) {
    
$imgcodeonoff=$ontext;
  } else {
    
$imgcodeonoff=$offtext;
  }
  if (
$allowsmilies) {
    
$smiliesonoff=$ontext;
  } else {
    
$smiliesonoff=$offtext;
  }
  
//MaxPosts by User
  
$optionArray explode(","$usermaxposts);
  while (list(
$key$val) = each($optionArray))
  {
     eval (
"\$maxpostsoptions .= \"".gettemplate("modifyoptions_maxposts")."\";");
  }
  
$postsdefaultselected "selected";
  
// Referrer
  
if ($usereferrer and $bbuserinfo['userid']==0) {
    if (
$bgcolor=="{firstaltcolor}") {
      
$bgcolor="{secondaltcolor}";
      
$bgclass="alt2";
    } else {
      
$bgcolor="{firstaltcolor}";
      
$bgclass="alt1";
    }
    if (
$bbreferrerid) {
      if (
$referrername=$DB_site->query_first("SELECT username FROM user WHERE userid = '".addslashes($bbreferrerid)."'")) {
        
$referrername $referrername['username'];
      }
    }
    eval(
"\$referrer = \"".gettemplate("register_referrer")."\";");
  }
  
//Birthday
  
if ($calbirthday == 1) {
     if (
$bgcolor=="{firstaltcolor}") {
        
$bgcolor="{secondaltcolor}";
        
$bgclass="alt2";
     } else {
        
$bgcolor="{firstaltcolor}";
        
$bgclass="alt1";
     }
     eval(
"\$birthday = \"".gettemplate("register_birthday")."\";");
  }
  
// get extra profile fields
  
$profilefields=$DB_site->query("SELECT *
                                  FROM profilefield
                                  WHERE editable = 1
                                  ORDER BY displayorder"
);
  while (
$profilefield=$DB_site->fetch_array($profilefields)) {
    
$profilefieldname="field$profilefield[profilefieldid]";
    if (
$profilefield[required] == 1) {
      if (
$bgcolor1=="{firstaltcolor}") {
        
$bgcolor1="{secondaltcolor}";
        
$bgclass1="alt2";
      } else {
        
$bgcolor1="{firstaltcolor}";
        
$bgclass1="alt2";
      }
      
$temp $bgcolor;
      
$tempclass $bgclass;
      
$bgcolor $bgcolor1;
      
$bgclass $bgclass1;
      eval(
"\$customfields_required .= \"".gettemplate("register_customfields")."\";");
      
// vBPortal Begin
      
$showleftcolumnchecked="checked";
      
$showleftcolumnnotchecked="";
      eval (
"\$leftcolumncell = \"".gettemplate("P_leftcolumncell")."\";");
      
// vBPortal End
      
$bgcolor $temp;
      
$bgclass $tempclass;
    } else { 
// Not Required
      
if ($bgcolor=="{firstaltcolor}") {
        
$bgcolor="{secondaltcolor}";
        
$bgclass="alt2";
      } else {
        
$bgcolor="{firstaltcolor}";
        
$bgclass="alt1";
      }
      eval(
"\$customfields .= \"".gettemplate("register_customfields")."\";");
    }
  }

  
$bgcolor "{secondaltcolor}";
  
// User selectable style sets
  
$stylesetlist "";
  if (
$allowchangestyles==1) {
    
$stylesets=$DB_site->query("SELECT * FROM style WHERE userselect=1");
    while(
$thisset=$DB_site->fetch_array($stylesets)) {
      if (
$bbuserinfo[styleid]==$thisset[styleid]) {
        
$selected "selected";
      } else {
        
$selected "";
      }
      
$thisid $thisset[styleid];
      
$thisstylename $thisset[title];

      eval (
"\$stylesetlist .= \"".gettemplate("modifyoptions_styleset")."\";");
      eval (
"\$stylecell = \"".gettemplate("register_stylecell")."\";");
      
$bgcolor "{firstaltcolor}";
    }
  } else {
    
$stylecell "";
  }

  if (
$avatarenabled) {
    
$avatars $DB_site->query("SELECT avatarid, title, avatarpath
                                    FROM avatar
                                    WHERE minimumposts = 0
                                    ORDER BY title"
);
    if (
$DB_site->num_rows($avatars) > 0) {
      while (
$avatar $DB_site->fetch_array($avatars)) {
        if (!
$avatar['title']) {
          
$avatar['title'] = $avatar['avatarpath'];
          if (
strstr($avatar['title'], '/')) {
            
$avatar['title'] = substrstrrchr($avatar['title'], '/') , 1);
          }
          
$avatar['title'] = str_replace('_'' '$avatar[title]);
          
$dotpos strrpos($avatar[title], '.');
          
$avatar[title] =  substr($avatar[title], 0$dotpos);
        }
        eval(
"\$avatarbits .= \"".gettemplate("register_avatarbit")."\";");
      }
      eval(
"\$avatarbit = \"".gettemplate("register_avatar")."\";");
    }
  }

  if (
$who=="adult") {
    eval(
"dooutput(\"".gettemplate("register_fast")."\");");
  } else {
    eval(
"dooutput(\"".gettemplate("registercoppa")."\");");
  }
}
  
$adminemail=1;
  
$showemail=0;
  
$invisible=1;
  
$cookieuser=0;
  
$nosessionhash=0;
  
$emailnotification=1;
  
$options=1;
  
$options+=2;
  
$options+=4;
  
$options+=8;
  
$receivepm=0;
  
$emailonpm=1;
  
$pmpopup=0
Also I added two new templates register_fast and signupadult_fast.

Now my problem: If I set $adminemail=1 it becomes NO. If I set $adminemail=0 it becomes NO. WHY??

Please help.
Reply With Quote
  #24  
Old 02-05-2002, 01:54 PM
veedee veedee is offline
 
Join Date: Oct 2001
Posts: 117
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I have made enough excuses. Here is another one. I was made redundant and forgot about all this stuff. I need this for my site and will spend the rest of the day gathering info on this. I will post up any updates.

Cheers,

Ben
Reply With Quote
  #25  
Old 02-05-2002, 03:15 PM
veedee veedee is offline
 
Join Date: Oct 2001
Posts: 117
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

ok here goes...


In global.php add

PHP Code:
if ($bbuserinfo['userid']==0) {
  eval(
"\$headexpressreg = \"".gettemplate('head_expressreg')."\";");

right after

PHP Code:
$newpmmsg=1;
  eval(
"\$headnewpm = \"".gettemplate('head_newpm')."\";");

now create a new template, head_expressreg and put this in it:

Code:
<script language="javascript"><!-- 
window.open('http://www.yoursite.com/forum/file.php');
// --></script>
Now go to your style set area. Find the text area where you enter content to go in the <head> of the page. Enter in $headexpressreg under $headnewpm

This will pop file.php up. Now to make file.php

Try this:

Code:
<html>
<title>Welcome to visordown.com - register today</title>
<head>
<STYLE type=text/css>
.nf { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt }
.sf { font-family: verdana,arial,helvetica,sans-serif; font-size: 8pt; color: #ffffff; }
</style>
</head>
<body bgcolor="#000000">

<!-- content table -->
<font class="sf">Registration is required if you want to post messages on visordown.com</font>
<table bgcolor="#000000" width="100%" cellpadding="10" cellspacing="0" border="0"><tr><td>
<form action="http://www.visordown.com/forums/register.php" method="post">
<input type="hidden" name="s" value="">

<table border="0" cellspacing="1" cellpadding="4" width="100%" bgcolor="#555576">
<!-- *** -->
<tr>
	<td bgcolor="#0000ee" colspan="2"><font face="verdana" size="2" color="#ffffff" class="thtcolor"><b>Registration</b></font>
	<font face="verdana" size="1" color="#ffffff" class="thtcolor">(*) fields are required.  Please note that passwords are case sensitive.</font></td>
</tr>
<!-- *** -->
<tr>
	<td bgcolor="#AAAAE6"><font class="nf"><b>*User Name:</b></font></td>
	<td bgcolor="#AAAAE6"><font class="nf"><input type="text" name="username" size="25" maxlength="15"></font></td>
</tr>
<tr>
	<td bgcolor="#C3C3EB"><font class="nf"><b>*Password:</b></font></td>
	<td bgcolor="#C3C3EB"><font class="nf"><input type="password" name="password" size="25" maxlength="15"></font></td>
</tr>
<tr>
	<td bgcolor="#C3C3EB"><font class="nf"><b>*Enter Password Again:</b></font></td>
	<td bgcolor="#C3C3EB"><input type="password" name="passwordconfirm" size="25" maxlength="15"></td>
</tr>
<tr>
	<td bgcolor="#AAAAE6"><font class="nf"><b>*Email:</b></font><br>
	<font color="#000000" face="verdana" size="1">Please enter a <b>valid</b> email address.</font></td>
	<td bgcolor="#AAAAE6"><font class="nf"><input type="text" name="email" size="25" maxlength="50"></font></td>
</tr>
<tr>
	<td bgcolor="#AAAAE6"><font class="nf"><b>*Enter Email Again:</b></font></td>
	<td bgcolor="#AAAAE6"><font class="nf"><input type="text" name="emailconfirm" size="25" maxlength="50"></font></td>
</tr>


<tr><td bgcolor="#113274">
&nbsp;
</td><td bgcolor="#113274"><input type="hidden" name="allowmail" value="yes">
<input type="hidden" name="invisible" value="no">
<input type="hidden" name="showemail" value="yes">
<input type="hidden" name="cookieuser" value="yes">
<input type="hidden" name="nosessionhash" value="yes">
<input type="hidden" name="emailonpm" value="yes">
<input type="hidden" name="prunedays" value="-1">
<input type="hidden" name="umaxposts" value="-1">
<input type="hidden" name="startofweek" value="1">
<input type="hidden" name="timezoneoffset" value="-5">
<input type="hidden" name="emailnotification" value="yes">
<input type="hidden" name="showsignatures" value="yes">
<input type="hidden" name="showavatars" value="yes">
<input type="hidden" name="showimages" value="yes">
<input type="hidden" name="vbcode" value="yes">
<input type="hidden" name="pmpopup" value="yes">
<input type="hidden" name="receivepm" value="yes">
<input type="hidden" name="url" value="http://www.visordown.com/forums/thanks.html">
<input type="hidden" name="action" value="addmember">
<input type="submit" name="Submit" value="Submit">
<input type="reset" name="Reset" value="Reset"></td>
</tr></font>
</td></tr></table>
</form>
<font class="sf">By pressing the registration button above you declare that you have read and agree with the <a href="/" target="blank">Community Guidelines</a></font>
<!-- End content area table -->
</td></tr></table>
</body>
</html>
Obviously modify the colours and the paths to your site. It should work a treat. Just visit my site now www.visordown.com/forums as a guest and it should pop up. It isn't perfect, however it works !

Does this help?

Ben
Reply With Quote
  #26  
Old 02-06-2002, 08:10 AM
Wolf42's Avatar
Wolf42 Wolf42 is offline
 
Join Date: Nov 2001
Location: Vienna, Austria, Europe
Posts: 150
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thank you very much!! :up:
Reply With Quote
  #27  
Old 02-06-2002, 09:55 AM
veedee veedee is offline
 
Join Date: Oct 2001
Posts: 117
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Great - Now all I need to work out is how to make the pop up only pop up once per user visit. I would also like to make it pop up in a nicer looking window.

Hmmm can we get together on this one ?
Reply With Quote
  #28  
Old 02-06-2002, 10:34 AM
Wolf42's Avatar
Wolf42 Wolf42 is offline
 
Join Date: Nov 2001
Location: Vienna, Austria, Europe
Posts: 150
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

For the windowsize: How about a little change in your head_expressreg template:
Code:
<script language="javascript">
window.open("file.php?, "Register now!!", "toolbar=no,scrollbars=yes,resizable=yes,width="300",height="600");
</script>
For once per visit: How about setting a cookie with lifetime i.e. 1 day.
Reply With Quote
  #29  
Old 02-06-2002, 10:51 AM
veedee veedee is offline
 
Join Date: Oct 2001
Posts: 117
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Superb!

How do I set a cookie. I have had a go but it doesn't work.

Any code going?

Cheers!

Ben
Reply With Quote
  #30  
Old 02-06-2002, 01:25 PM
Wolf42's Avatar
Wolf42 Wolf42 is offline
 
Join Date: Nov 2001
Location: Vienna, Austria, Europe
Posts: 150
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

How to set a cookie:
Code:
<script language="javascript">
document.cookie = "your-cookie-settings";
</script>
I have tryed to figure out how vB is setting the cokkies, but I didn't. Sorry.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 06:13 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05104 seconds
  • Memory Usage 2,361KB
  • Queries Executed 12 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (4)bbcode_code
  • (3)bbcode_php
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (9)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • postbit_imicons
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete