Tips and Tricks HQ Support Portal › Forums › WP eMember › WP eMember Tweaks › Adding extra info from SQL to display member details
Tagged: database, eMember, mysql, phpMyAdmin
- This topic has 5 replies, 2 voices, and was last updated 14 years, 4 months ago by
e49.
-
AuthorPosts
-
April 25, 2010 at 10:55 pm #1129
e49
MemberHi all, MAJOR WP & PHP NEWBIE HERE so please be gentle… LOL…
I like this plugin and am trying to display a lil bit more info for my customers to see on my web site.
The plan is with the already exsisting set up of the customers login page, after they login as follows…
(ie
You are logged in as: username
Your membership level is: level
Your Account Status: active
Your Account Expires: April 25, 2011
>Logout
>My Secure RSS
>Edit Profile
)
Then under this I would like to add more fields to display, I already have the SQL fields set up in the database and I enter them manually there (or if so can I set that in wordpress also)… I just need to set up the string on the particular users page so it would show…
You are logged in as: username
Your membership level is: level
Your Account Status: active
Your Account Expires: April 25, 2011
Your extra info: HERE
Your extra info: HERE
Your extra info: HERE
Your extra info: HERE etc…
>Logout
>My Secure RSS
>Edit Profile
)
The customers does not need to edit this info, it would be left strictly for me to change either in SQL or if it can be edited on the wordpress add/edit members tab.
Hope I hear back from anyone who can help… Thanks
April 26, 2010 at 7:53 am #20088amin007
ParticipantOpen the “wp_eMember1.php” file and search for the following function:
function eMember_login_widget()
The code in that function is what displays those stuff in the login widget. So, retrieve your data from the SQL database for that member and display it there.
April 26, 2010 at 8:05 am #20089e49
MemberDoes the widget function display the same as what would if I place it on main content of the page… If not where would I need to find it… Cheers…
April 26, 2010 at 8:26 am #20090amin007
ParticipantIt’s the same function that displays it on both places.
April 26, 2010 at 8:45 am #20091e49
MemberGreat I have found it and started testing… Now I will need to replace some other areas to complete the modified function.
It is now currently showing…
$output .= ‘
‘ . EMEMBER_LOGGED_IN_LEVEL;$output .= ‘<label class=”eMember_highlight”>’.$username.'</label>’;
How do I edit the EMEMBER_LOGGED_IN_LEVEL to display something else for e.g. Membership Number.
Also how do I call the SQL over from the table to replace the .$username. cos on my SQL it shows that it is user_name
Is there another file I need to find to edit this function…? Cheers…
April 26, 2010 at 10:17 am #20092e49
MemberHey all is good, I’ve figured it out, kudos to me and yourself for all your help… Cheers…
-
AuthorPosts
- You must be logged in to reply to this topic.