I know you folks are busy but just wanted to ask 2 questions.
The setup:
I have figured out how to access the table User_Email thru some pretty rough code (not using OST native code). I have been able to reconstruct a unique email. I am using this recontructed email to insert in the "New User" form. This created 2 issues that needs to be resolved:
Issue 1 - The form that gets dynamically created I believe is called from the filename "user-lookup.tmpl.php" and creates this line -
input type="email" id="_UNIQUE-ID" size="40" placeholder="" name="dd11b2b4e6299f" value=""
This line is the "EMAIL" field in the lookup form when creating a new user. I have a script that targets the UNIQUE-ID and inserts my generated email into that field. It worked great, until I found out that the ID is dynamic. So I need to be able to get the value of the UNIQUE-ID to make my script consistent.
My question for this is: Where is the file or code that actually generates this form?
Issue 2 - In reference to the "rough code" from above, the way I have been accessing the DB is thru a hard coded line which includes the DB-NAME, PASSWORD and USER_NAME unto which I know that this is a very large NO NO and I did it this way just for testing purposes. Now that I have proven that I can actually get the information I need, I would like to re-write the code correctly so that it does not expose that information.
I have done many searches that yielded the answer to use "db_query('your query')". I was under the impression that the line would go something like this:
db_query('SELECT * FROM table")
However, I am confident that this is not correct. I am unsure of the syntax to be used here and was wondering if you could provide an example for me to follow? Every time I have changed my code, the form just does not show up telling me that there is an error and I get no additional information after that.
Thank you very much for any help,
Craig. (Wizdos)