Hi there. I am new to using nuBuilder, and I have to say it is an excellent tool! I am a novice, and I have been able to get extremely far with it. However, I do have a couple questions that I have tried to research, but have come up short on. Now, I am not very experienced with PHP and Javascript, but for the most part I am able to figure out what is going on (eventually). Here are my two questions, if you would be so kind to answer:
1) I am trying to create a hidden field on a form submission page that logs the username of the individual who is logged in as a record when they save it. So, "Joe123" is logged in and submits a new entry. "sales_agent" is the field that is being used to log the user id. How would I get it so that Joe123 is automatically logged in the sales_agent field?
2) It took me a while to get a hang of the Home page and its functions. However, I am still a little unclear on how to create a button that does anything else than open up a form browse. More specifically: I am trying to make a button on the home page that reads "Add Order" and goes directly to the "Add Record" page for that table. This is opposed to "View Orders," which is the default browse table (which then allows you to click add record on the top right). Could you explain how I can make the button go directly to the add order (add record) page?
Thanks so much and keep up the outstanding work!
Welcome to the nuBuilder Forums!
Register and log in to access exclusive forums and content available only to registered users.
Register and log in to access exclusive forums and content available only to registered users.
2 Questions - login_username and Home Button Event
-
- Posts: 8
- Joined: Mon Sep 14, 2015 3:40 pm
Re: 2 Questions - login_username and Home Button Event
CreationX,
Hopefully these links will help answer your questions..
1.http://wiki.nubuilder.net/index.php/Forms#Save_Button
(Adding these fields will allow user info to be automatically collected)
2.Creating a button with a RecordID of -1 will give you a new record..
http://wiki.nubuilder.net/index.php/Add ... Button_Tab
Steven
Hopefully these links will help answer your questions..
1.http://wiki.nubuilder.net/index.php/Forms#Save_Button
(Adding these fields will allow user info to be automatically collected)
Code: Select all
ALTER TABLE ??
ADD ??_log_added_at DATETIME NOT NULL,
ADD ??_log_added_by VARCHAR(25) NOT NULL,
ADD ??_log_changed_at DATETIME NOT NULL,
ADD ??_log_changed_by VARCHAR(25) NOT NULL,
ADD ??_log_viewed_at DATETIME NOT NULL,
ADD ??_log_viewed_by VARCHAR(25) NOT NULL
http://wiki.nubuilder.net/index.php/Add ... Button_Tab
Steven
-
- Posts: 8
- Joined: Mon Sep 14, 2015 3:40 pm
Re: 2 Questions - login_username and Home Button Event
Thank you! These both worked very well, except it displays the code for the user, instead of the user id. How can I get it to display the user id in the browse form?