Any pointers for registration code in php

Hi I want to achieve to make a record with php for my channel so to have control on access roku I have this in a mysql table


CREATE TABLE `device` (
  `id` int(11) NOT NULL auto_increment,
  `firstname` varchar(50) NOT NULL default '',
  `lastname` varchar(50) NOT NULL default '',
  `email` varchar(100) NOT NULL default '',
  `password` varchar(25) NOT NULL default '',
  `deviceID` tinyint(4) NOT NULL,
  `regCode` tinyint(4) NOT NULL,
  `end_date` date NOT NULL,
  `creation` date NOT NULL,
  `status` int(11) NOT NULL default '0',
  PRIMARY KEY  (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;

I want to create a code where you can record data roku to mysql so then check for mysql to allow access if there blockea access so require activation again want to activate with the code that generates send the registration roku which like these

deviceID
regCode

and to check for expired or if serious about it

deviceID
end_date

I have this code to generate the

regcode.php


<?php
    $random = rand(1679616, 60466175);
    print base_convert($random,10,36);
 ?>

I would fail the regScreen.brs php file and for consultation and data logging

I hope averme esplicado good time since I’ve been trying to get success in my order thanks first and foremost :roll: :roll:

I hope I explained well as it took time trying to get success in my order thanks to nothing

It doesn’t need to be that complex. Every time you give out a code log it to your code table with the user id token.
When they enter the code on your site, remove all the tokens you have given out with that id token from the code table and add the info you want to your ‘users table’.

Once you have that working you can then deal with whatever else data you want to deal with like first names, last names, t-shirt size, coupons, subscriptions, dates, rentals, logging, emails, etc etc etc.

“destruk” wrote:
It doesn’t need to be that complex. Every time you give out a code log it to your code table with the user id token.
When they enter the code on your site, remove all the tokens you have given out with that id token from the code table and add the info you want to your ‘users table’.

Once you have that working you can then deal with whatever else data you want to deal with like first names, last names, t-shirt size, coupons, subscriptions, dates, rentals, logging, emails, etc etc etc.

if it will help me with that I’d appreciate it very much

http://sdkdocs.roku.com/display/sdkdoc/ … nd+Linking

http://en.sourceforge.jp/projects/sfnet … ister.zip/

already been using it and testing it but does not work for me to do what I want