Advertisement

05.04.2008 at 05:45AM PDT, ID: 23374806
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

Stay logged in after registration?

I created a registration page in dreamweaver using developer's toolbox. Registration form works great, but after registration, I'm tying to immediatley send uses to inside the restricted site. Right after registration, it's asking for a username and password (login reqest). Is there a way to make the registation form also count as the "first time" login? I'm trying to avoid the user having  to login right after registration.

PS: I'm not using an Activate Account feature (sends link in email)
Start your free trial to view this solution
Question Stats
Zone: Web Development
Question Asked By: dsellers99
Solution Provided By: jason1178
Participating Experts: 4
Solution Grade: A
Views: 0
Translate:
Loading Advertisement...
05.04.2008 at 05:50AM PDT, ID: 21495553

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 05:59AM PDT, ID: 21495564

Rank: Wizard

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 06:39AM PDT, ID: 21495633

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 06:41AM PDT, ID: 21495635

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 06:47AM PDT, ID: 21495650

Rank: Master

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 11:15AM PDT, ID: 21496428

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 11:24AM PDT, ID: 21496461

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 11:29AM PDT, ID: 21496490

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 11:34AM PDT, ID: 21496512

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 11:47AM PDT, ID: 21496569

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 11:48AM PDT, ID: 21496575

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 12:09PM PDT, ID: 21496636

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 12:48PM PDT, ID: 21496732

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 01:02PM PDT, ID: 21496771

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.04.2008 at 02:56PM PDT, ID: 21497092

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.05.2008 at 03:52AM PDT, ID: 21499038

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.06.2008 at 12:20AM PDT, ID: 21505338

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.06.2008 at 05:12PM PDT, ID: 21512095

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.06.2008 at 05:17PM PDT, ID: 21512175

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.07.2008 at 03:03AM PDT, ID: 21514736

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.07.2008 at 09:39AM PDT, ID: 21518118

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 02:59PM PDT, ID: 21528834

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 09:48PM PDT, ID: 21530446

Rank: Genius

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 10:02PM PDT, ID: 21530475

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
05.08.2008 at 10:08PM PDT, ID: 21530489

Rank: Genius

All comments and solutions are available to Premium Service Members only.

Start your 7 day free trial and see for yourself why Experts Exchange is the easiest and most proven technology resource in the world. Get Started

Already a member? Login to view this solution.

 
 
Loading Advertisement...
Microsoft
  • Internet Protocols
  • Applications
  • Development
  • OS
  • Hardware
  • Windows Security
Apple
  • Operating Systems
  • Hardware
  • Programming
  • Networking
  • Software
Internet
  • Search Engines
  • File Sharing
  • WebTrends / Stats
  • Spy / Ad Blockers
  • Web Browsers
  • New Net Users
  • Web Development
  • Chat / IM
  • Anti Spam
  • Web Servers
  • Anti-Virus
  • Email Clients
Gamers
  • Tips
  • Online / MMORPG
  • Puzzle
  • Emulators
  • Action / Adventure
  • Role Playing
  • Consoles
  • Game Programming
  • Strategy
  • Sports
  • Misc
  • Computer Games
Digital Living
  • Hardware
  • New Net Users
  • New Users
  • Software
  • Digital Music
  • Gaming World
  • Home Security
  • Apple
  • Networking Hardware
Virus & Spyware
  • Vulnerabilities
  • IDS
  • Encryption
  • Anti-Virus
  • Operating Systems Security
  • Software Firewalls
  • WebApplications
  • Cell Phones
  • Operating Systems
  • Internet
  • Hardware Firewalls
Hardware
  • Handhelds / PDAs
  • Displays / Monitors
  • Components
  • Networking Hardware
  • Peripherals
  • Laptops/Notebooks
  • Storage
  • Servers
  • Desktops
  • New Users
  • Misc
  • Apple
Software
  • System Utilities
  • Industry Specific
  • Network Management
  • Photos / Graphics
  • Page Layout
  • VMWare
  • Misc
  • Web Development
  • OS
  • CYGWIN
  • Voice Recognition
  • Message Queue
  • Quality Assurance
  • Security
  • Firewalls
  • MultiMedia Applications
  • Development
  • Database
  • Office / Productivity
  • Business Management
  • OS/2 Apps
  • Server Software
  • Internet / Email
ITPro
  • OS
  • Storage
  • Encryption
  • Operating Systems Security
  • Apple Hardware
  • Laptops & Notebooks
  • Servers
  • Networking Hardware
  • Peripherals
  • Devices
  • Displays / Monitors
  • WebTrends / Stats
  • Search Engines
  • Firewalls
  • WebApplications
  • IDS
  • Vulnerabilities
  • Email Clients
  • File Sharing
  • Spy / Ad Blockers
  • Web Browsers
  • Web Servers
  • Networking
  • Anti-Virus
  • Chat / IM
  • Anti Spam
Developer
  • Web Servers
  • Web Browsers
  • Game Programming
  • Dev Tools
  • Industry Specific
  • Office / Productivity
  • Database
  • CYGWIN
  • Web Development
  • Search Engines
  • File Sharing
  • WebTrends / Stats
  • Programming
  • Content Management
  • Application Servers
  • Protocols
Storage
  • Removable Backup Media
  • Storage Technology
  • Servers
  • Grid
  • Remote Access
  • Backup / Restore
  • Misc
  • Hard Drives
OS
  • Miscellaneous
  • Security
  • Development
  • Linux
  • VMWare
  • MainFrame OS
  • Unix
  • Apple
  • OS / 2
  • AS / 400
  • BeOS
  • Microsoft
  • VMS / OpenVMS
Database
  • Oracle
  • Miscellaneous
  • MySQL
  • Software
  • Sybase
  • Contact Management
  • PostgreSQL
  • Data Manipulation
  • Clarion
  • InterSystems Cache
  • Siebel
  • MUMPS
  • OLAP
  • SQLBase
  • SAS
  • GIS & GPS
  • 4GL
  • Berkeley DB
  • DB2
  • Informix
  • Interbase / Firebird
  • FoxPro
  • Reporting
  • LDAP
  • Filemaker Pro
  • MS SQL Server
  • dBase
  • MS Access
Security
  • Misc
  • Web Browsers
  • Software Firewalls
  • Operating Systems Security
  • File Sharing
  • Spy / Ad Blockers
  • Vulnerabilities
  • WebApplications
  • IDS
  • Anti-Virus
  • Encryption
  • Anti Spam
  • Email Clients
  • VPN
  • Chat / IM
Programming
  • Editors IDEs
  • Installation
  • Handhelds / PDAs
  • Multimedia Programming
  • System / Kernel
  • Algorithms
  • Game
  • Signal Processing
  • Project Management
  • Open Source
  • Database
  • Misc
  • Languages
  • Processor Platforms
  • Theory
Web Development
  • Scripting
  • Blogs
  • Web Servers
  • Software
  • Search Engines
  • Web Graphics
  • Images
  • Internet Marketing
  • Images and Photos
  • Components
  • Document Imaging
  • Web Languages/Standards
  • Illustration
  • WebApplications
  • Fonts
  • WebTrends / Stats
  • Authoring
  • Digital Camera Software
  • Miscellaneous
Networking
  • Protocols
  • Apple Networking
  • Network Management
  • Message Queue
  • Application Servers
  • Content Management
  • File Servers
  • Email Servers
  • Misc
  • Java Editors & IDEs
  • Wireless
  • Networking Hardware
  • Backup / Restore
  • System Utilities
  • ISPs & Hosting
  • Web Servers
  • Storage Technology
  • Removable Backup Media
  • Servers
  • Broadband
  • Grid
  • OS / 2
  • Novell Netware
  • Unix Networking
  • Windows Networking
  • Security
  • Telecommunications
  • Operating Systems
  • Linux Networking
Other
  • Community Advisor
  • Lounge
  • Community Support
  • New Net Users
  • Philosophy / Religion
  • Math / Science
  • Miscellaneous
  • URLs
  • Expert Lounge
  • Politics
  • Puzzles / Riddles
Community Support
  • Suggestions
  • New to EE
  • New Topics
  • Community Advisor
  • CleanUp
  • Announcements
  • General
  • Feedback
  • Input
  • EE Bugs
 
05.04.2008 at 05:50AM PDT, ID: 21495553
you can automatically log user in if you place the code below ,after your form submit(in the line where you insert info to db succesfully)
$user_name = $_POST['username'] ; //assume that you get the via post method,
session_register('user_name') ;
 
05.04.2008 at 05:59AM PDT, ID: 21495564

Rank: Wizard

Yes, set the cookie or the session variable right after the registration script.
 
05.04.2008 at 06:39AM PDT, ID: 21495633

Rank: Master

Pass the username and password directly to the loginpage.asp

response.redirect("loginpage.asp?user="&var_user&"&pwd="&var_password)
 
05.04.2008 at 06:41AM PDT, ID: 21495635
cyberwebservice: passing password via URL ?
 
05.04.2008 at 06:47AM PDT, ID: 21495650

Rank: Master

oops...thanks for noticing that.
Also, i have given the code in ASP instead of PHP. Must take rest now ;)
 
05.04.2008 at 11:15AM PDT, ID: 21496428
Here is my first form post tag:

<form method="post" id="form2" action="<?php echo KT_escapeAttribute(KT_getFullUri()); ?>">

Then this tag follows shortly:

<input type="text" name="user_name" id="user_name" value="<?php echo ucwords($row_rsregistration['user_name']); ?>" size="32" />

Any ideas on where I should post:

$user_name = $_POST['username'] ;

Thanks for any help.

 
05.04.2008 at 11:24AM PDT, ID: 21496461
can you please post us the sql query that you use to save form posts to DB
 
05.04.2008 at 11:29AM PDT, ID: 21496490
Here's the code for the form:

<?php require_once('../Connections/project1.php'); ?>
<?php require_once('../Connections/project1.php'); ?>
<?php
// Load the common classes
require_once('../includes/common/KT_common.php');

// Load the tNG classes
require_once('../includes/tng/tNG.inc.php');

// Make a transaction dispatcher instance
$tNGs = new tNG_dispatcher("../");

// Make unified connection variable
$conn_project1 = new KT_connection($project1, $database_project1);

// Start trigger
$formValidation = new tNG_FormValidation();
$formValidation->addField("user_name", true, "text", "", "2", "20", "Please create a username between 2-20 characters");
$formValidation->addField("firstname", true, "text", "", "1", "25", "Please enter your first name (1- 25 characters)");
$formValidation->addField("e_mail", true, "text", "email", "", "", "Please enter a valid e-mail address.");
$tNGs->prepareValidation($formValidation);
// End trigger

// Make an insert transaction instance
$userRegistration = new tNG_insert($conn_project1);
$tNGs->addTransaction($userRegistration);
// Register triggers
$userRegistration->registerTrigger("STARTER", "Trigger_Default_Starter", 1, "POST", "KT_Insert1");
$userRegistration->registerTrigger("BEFORE", "Trigger_Default_FormValidation", 10, $formValidation);
$userRegistration->registerTrigger("END", "Trigger_Default_Redirect", 99, "../instruct1/instruct3.php");
// Add columns
$userRegistration->setTable("registration");
$userRegistration->addColumn("user_name", "STRING_TYPE", "POST", "user_name");
$userRegistration->addColumn("firstname", "STRING_TYPE", "POST", "fields_fname");
$userRegistration->addColumn("e_mail", "STRING_TYPE", "POST", "fields_email");
$userRegistration->setPrimaryKey("userid", "NUMERIC_TYPE");

// Execute all the registered transactions
$tNGs->executeTransactions();

// Get the transaction recordset
$rsregistration = $tNGs->getRecordset("registration");
$row_rsregistration = mysql_fetch_assoc($rsregistration);
$totalRows_rsregistration = mysql_num_rows($rsregistration);

?><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Subscribe The The Life Enrichment Guide Today!</title>
<meta name="rating" content="general" />
<meta name="copyright" content="Copyright © 2008" />
<meta name="expires" content="never">
<meta name="distribution" content="global" />
<meta name="robots" content="index,follow" />
<link href="../css/text1.css" rel="stylesheet" type="text/css">
<link href="../includes/skins/mxkollection3.css" rel="stylesheet" type="text/css" media="all" />
<script src="../includes/common/js/base.js" type="text/javascript"></script>
<script src="../includes/common/js/utility.js" type="text/javascript"></script>
<script src="../includes/skins/style.js" type="text/javascript"></script>
<?php echo $tNGs->displayValidationRules();?>
<link href="../includes/skins/mxkollection3.css" rel="stylesheet" type="text/css" media="all" />
<script src="../includes/common/js/base.js" type="text/javascript"></script>
<script src="../includes/common/js/utility.js" type="text/javascript"></script>
<script src="../includes/skins/style.js" type="text/javascript"></script>
<?php echo $tNGs->displayValidationRules();?>
</head>  
<body topmargin="0" leftmargin="0" rightmargin="0" bottommargin="0">
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" id="AutoNumber5" class="tborder1" align="center" width="775">
    <tr>
      <td align="center" valign="top" class="marginside1"><form method="post" id="form2" action="<?php echo KT_escapeAttribute(KT_getFullUri()); ?>">
        <table width="100%" cellpadding="0" cellspacing="0">
            <tr>
              <td align="left" valign="top"><label for="user_name"></label></td>
              <td><input type="text" name="user_name" id="user_name" value="<?php echo KT_escapeAttribute($row_rsregistration['user_name']); ?>" size="32" />                <?php echo $tNGs->displayFieldError("registration", "user_name"); ?></td>
            </tr>
            <tr>
              <td align="left" valign="top"><label for="firstname"></label></td>
              <td><input type="text" name="fields_fname" id="fields_fname" value="<?php echo KT_escapeAttribute($row_rsregistration['firstname']); ?>" size="32" />                <?php echo $tNGs->displayFieldError("registration", "firstname"); ?></td>
            </tr>
            <tr>
              <td align="left" valign="top"><label for="e_mail"></label></td>
              <td><input type="text" name="fields_email" id="fields_email" value="<?php echo KT_escapeAttribute($row_rsregistration['e_mail']); ?>" size="32" />                <?php echo $tNGs->displayFieldError("registration", "e_mail"); ?></td>
            </tr>
            <tr align="left" valign="top" class="marginbullethoz1">
              <td colspan="2"><input type="submit" name="KT_Insert1" id="KT_Insert1" value="Click To Submit Your Info" />              </td>
          </tr>
        </table>
      </form></td>
    </tr>
</table>
</body>
</html>
 
05.04.2008 at 11:34AM PDT, ID: 21496512
If your code checks for user_name (usually its so) this should work ;
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
87:
88:
89:
90:
91:
92:
93:
94:
95:
<?php require_once('../Connections/project1.php'); ?>
<?php require_once('../Connections/project1.php'); ?>
<?php
// Load the common classes
require_once('../includes/common/KT_common.php');
 
// Load the tNG classes
require_once('../includes/tng/tNG.inc.php');
 
// Make a transaction dispatcher instance
$tNGs = new tNG_dispatcher("../");
 
// Make unified connection variable
$conn_project1 = new KT_connection($project1, $database_project1);
 
// Start trigger
$formValidation = new tNG_FormValidation();
$formValidation->addField("user_name", true, "text", "", "2", "20", "Please create a username between 2-20 characters");
$formValidation->addField("firstname", true, "text", "", "1", "25", "Please enter your first name (1- 25 characters)");
$formValidation->addField("e_mail", true, "text", "email", "", "", "Please enter a valid e-mail address.");
$tNGs->prepareValidation($formValidation);
// End trigger
 
// Make an insert transaction instance
$userRegistration = new tNG_insert($conn_project1);
$tNGs->addTransaction($userRegistration);
// Register triggers
$userRegistration->registerTrigger("STARTER", "Trigger_Default_Starter", 1, "POST", "KT_Insert1");
$userRegistration->registerTrigger("BEFORE", "Trigger_Default_FormValidation", 10, $formValidation);
$userRegistration->registerTrigger("END", "Trigger_Default_Redirect", 99, "../instruct1/instruct3.php");
// Add columns
$userRegistration->setTable("registration");
if($userRegistration->addColumn("user_name", "STRING_TYPE", "POST", "user_name")) {
	session_register($_POST['user_name']) ;
	}
$userRegistration->addColumn("firstname", "STRING_TYPE", "POST", "fields_fname");
$userRegistration->addColumn("e_mail", "STRING_TYPE", "POST", "fields_email");
$userRegistration->setPrimaryKey("userid", "NUMERIC_TYPE");
 
// Execute all the registered transactions
$tNGs->executeTransactions();
 
// Get the transaction recordset
$rsregistration = $tNGs->getRecordset("registration");
$row_rsregistration = mysql_fetch_assoc($rsregistration);
$totalRows_rsregistration = mysql_num_rows($rsregistration);
 
?><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Subscribe The The Life Enrichment Guide Today!</title>
<meta name="rating" content="general" />
<meta name="copyright" content="Copyright © 2008" />
<meta name="expires" content="never">
<meta name="distribution" content="global" />
<meta name="robots" content="index,follow" />
<link href="../css/text1.css" rel="stylesheet" type="text/css">
<link href="../includes/skins/mxkollection3.css" rel="stylesheet" type="text/css" media="all" />
<script src="../includes/common/js/base.js" type="text/javascript"></script>
<script src="../includes/common/js/utility.js" type="text/javascript"></script>
<script src="../includes/skins/style.js" type="text/javascript"></script>
<?php echo $tNGs->displayValidationRules();?>
<link href="../includes/skins/mxkollection3.css" rel="stylesheet" type="text/css" media="all" />
<script src="../includes/common/js/base.js" type="text/javascript"></script>
<script src="../includes/common/js/utility.js" type="text/javascript"></script>
<script src="../includes/skins/style.js" type="text/javascript"></script>
<?php echo $tNGs->displayValidationRules();?>
</head>   
<body topmargin="0" leftmargin="0" rightmargin="0" bottommargin="0">
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" id="AutoNumber5" class="tborder1" align="center" width="775">
    <tr>
      <td align="center" valign="top" class="marginside1"><form method="post" id="form2" action="<?php echo KT_escapeAttribute(KT_getFullUri()); ?>">
        <table width="100%" cellpadding="0" cellspacing="0">
            <tr>
              <td align="left" valign="top"><label for="user_name"></label></td>
              <td><input type="text" name="user_name" id="user_name" value="<?php echo KT_escapeAttribute($row_rsregistration['user_name']); ?>" size="32" />                <?php echo $tNGs->displayFieldError("registration", "user_name"); ?></td>
            </tr>
            <tr>
              <td align="left" valign="top"><label for="firstname"></label></td>
              <td><input type="text" name="fields_fname" id="fields_fname" value="<?php echo KT_escapeAttribute($row_rsregistration['firstname']); ?>" size="32" />                <?php echo $tNGs->displayFieldError("registration", "firstname"); ?></td>
            </tr>
            <tr>
              <td align="left" valign="top"><label for="e_mail"></label></td>
              <td><input type="text" name="fields_email" id="fields_email" value="<?php echo KT_escapeAttribute($row_rsregistration['e_mail']); ?>" size="32" />                <?php echo $tNGs->displayFieldError("registration", "e_mail"); ?></td>
            </tr>
            <tr align="left" valign="top" class="marginbullethoz1">
              <td colspan="2"><input type="submit" name="KT_Insert1" id="KT_Insert1" value="Click To Submit Your Info" />              </td>
          </tr>
        </table>
      </form></td>
    </tr>
</table>
</body>
</html>
Open in New Window
 
05.04.2008 at 11:47AM PDT, ID: 21496569
ali_kayahan:

Thanks a lot for the help. I'm a bit confused though - can you tell me what line your code modification is in  the post above? I can't seem to find  it.
 
05.04.2008 at 11:48AM PDT, ID: 21496575
if($userRegistration->addColumn("user_name", "STRING_TYPE", "POST", "user_name")) {
      session_register($_POST['user_name']) ;
      }
 
05.04.2008 at 12:09PM PDT, ID: 21496636
ali_kayahan:

Still can't seem to bypass the login request after the registrtion form submits. The code modification section looks like this now:

// Add columns
$userRegistration->setTable("registration");
if($userRegistration->addColumn("user_name", "STRING_TYPE", "POST", "user_name")) {
      session_register($_POST['user_name']) ;
      }
$userRegistration->addColumn("firstname", "STRING_TYPE", "POST", "fields_fname");
$userRegistration->addColumn("e_mail", "STRING_TYPE", "POST", "fields_email");
$userRegistration->addColumn("targetstat", "STRING_TYPE", "POST", "targetstat");
$userRegistration->addColumn("targetexer", "STRING_TYPE", "POST", "targetexer");
$userRegistration->setPrimaryKey("userid", "NUMERIC_TYPE");

Any ideas on what I need to do? Thanks for the help.
 
05.04.2008 at 12:48PM PDT, ID: 21496732
can you please post your login form code,we have to check what kind of a session variable it checks to log the user in
 
05.04.2008 at 01:02PM PDT, ID: 21496771
Here you go:

<?php require_once('../Connections/project1.php'); ?>
<?php
// Load the common classes
require_once('../includes/common/KT_common.php');

// Load the tNG classes
require_once('../includes/tng/tNG.inc.php');

// Make a transaction dispatcher instance
$tNGs = new tNG_dispatcher("../");

// Make unified connection variable
$conn_project1 = new KT_connection($project1, $database_project1);

// Start trigger
$formValidation = new tNG_FormValidation();
$formValidation->addField("kt_login_user", true, "text", "", "", "", "");
$formValidation->addField("kt_login_password", true, "text", "", "", "", "");
$tNGs->prepareValidation($formValidation);
// End trigger

// Make a login transaction instance
$loginTransaction = new tNG_login($conn_project1);
$tNGs->addTransaction($loginTransaction);
// Register triggers
$loginTransaction->registerTrigger("STARTER", "Trigger_Default_Starter", 1, "POST", "kt_login1");
$loginTransaction->registerTrigger("BEFORE", "Trigger_Default_FormValidation", 10, $formValidation);
$loginTransaction->registerTrigger("END", "Trigger_Default_Redirect", 99, "{kt_login_redirect}");
// Add columns
$loginTransaction->addColumn("kt_login_user", "STRING_TYPE", "POST", "kt_login_user");
$loginTransaction->addColumn("kt_login_password", "STRING_TYPE", "POST", "kt_login_password");
$loginTransaction->addColumn("kt_login_rememberme", "CHECKBOX_1_0_TYPE", "POST", "kt_login_rememberme", "0");
// End of login transaction instance

// Execute all the registered transactions
$tNGs->executeTransactions();

// Get the transaction recordset
$rscustom = $tNGs->getRecordset("custom");
$row_rscustom = mysql_fetch_assoc($rscustom);
$totalRows_rscustom = mysql_num_rows($rscustom);
?><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Subscribe The The Life Enrichment Guide Today!</title>
<meta name="description" content="Quickly and easily get the help you need - Psychic, Psychic Reading, Clairvoyant, Intuitive Services">
<meta name="rating" content="general" />
<meta name="keywords" content="psychic,psychic reading,spiritual,clairvoyant,intuitive,intuitive coach,medical intuitive,police,certified,law enforcement,psychics,psychic scams,gypsy scams,personal growth,phone readings,mediums,tarot,psychic guarantee,remote viewing,psychic test,psychic abilities,remote viewing training,South Florida,Miami,real psychic,spiritual healing,psychic scams,accurate psychic,best psychic">
<meta name="copyright" content="Copyright © 2008" />
<meta name="expires" content="never">
<meta name="distribution" content="global" />
<meta name="robots" content="index,follow" />
<link href="file:///C|/xampp/css/text1.css" rel="stylesheet" type="text/css">
<link href="../css/text1.css" rel="stylesheet" type="text/css">
<link href="../includes/skins/mxkollection3.css" rel="stylesheet" type="text/css" media="all" />
<link href="../includes/skins/mxkollection3.css" rel="stylesheet" type="text/css" media="all" />
<script src="../includes/common/js/base.js" type="text/javascript"></script>
<script src="../includes/common/js/utility.js" type="text/javascript"></script>
<script src="../includes/skins/style.js" type="text/javascript"></script>
<?php echo $tNGs->displayValidationRules();?>
</head>  
<body topmargin="0" leftmargin="0" rightmargin="0" bottommargin="0">
<table width="775" border="0" cellspacing="0" cellpadding="0" align="center">
  <tr>
    <td><?php require_once('../includes/logo.html'); ?></td>
  </tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" style="border-collapse: collapse" bordercolor="#111111" id="AutoNumber5" class="tborder1" align="center" width="775">
    <tr>
      <td align="center" valign="top" class="marginside1">&nbsp;</td>
      <td width="100%" align="center" valign="top" class="marginmid1"><img src="http://lifeleap.org/adwatcher/tracker.php?tp=a&a=42" style="width:1px;height:1px;border:0px;" />&nbsp;</td>
      <td align="center" valign="top" class="marginside1">&nbsp;</td>
  </tr>
  <tr>
    <td align="center" valign="top">&nbsp;</td>
    <td align="left" valign="top" class="title1">Welcome Back</td>
    <td align="center" valign="top">&nbsp;</td>
  </tr>
  <tr>
    <td align="center" valign="top">&nbsp;</td>
    <td align="center" valign="top"><hr noshade color="#B22222"></td>
    <td align="center" valign="top">&nbsp;</td>
  </tr>
  <tr>
    <td align="center" valign="top">&nbsp;</td>
    <td align="left" valign="top">&nbsp;</td>
    <td align="center" valign="top">&nbsp;</td>
  </tr>
  <tr>
    <td align="center" valign="top">&nbsp;</td>
    <td align="left" valign="top"><p class="para1">
      <?php
      echo $tNGs->getLoginMsg();
?>
      <?php
      echo $tNGs->getErrorMsg();
?>

      <form method="post" id="form1" class="KT_tngformerror" action="<?php echo KT_escapeAttribute(KT_getFullUri()); ?>">
        <table cellpadding="2" cellspacing="0" class="KT_tngtable">
          <tr>
            <td class="KT_th"><label for="kt_login_user">Username:</label></td>
            <td><input type="text" name="kt_login_user" id="kt_login_user" value="<?php echo KT_escapeAttribute($row_rscustom['kt_login_user']); ?>" size="32" />
                <?php echo $tNGs->displayFieldHint("kt_login_user");?> <?