Automatically add admin as friend when signed up? |
| |||
Hey, I wanted to know if this can be done, the reason is I will be using the newsfeed about site updates/changes etc. and displaying them in the feed of members would be great, they would always have the option to remove as friend if they dont want to see updates. Thanks
|
| |||
file: member.module.php function signup below [code] [code] assuming that the account id of admin is 1
|
| |||
Thank you very much falcon :) Easier than I thought :)
|
| |||
this is something i'm looking to do please give a little more detail
|
| |||
just put this.. [code]sql_query("insert into below this [code]$uid = insert_id();[/code] in this file member.module.php which is in includes/libs you can change the 1 to whatever ID # admin is which would normally be 1 in default install but could be something else just check in phpMyadmin (accounts table) if you think it could be something else and change it
|
| |||
but which code set should i insert it in between. like in html you have body tags and headers etc. There is so much code here i'm not sure where to put it. Do i just put it anywhere?
|
| |||
well as i wrote before file: includes\libs\member.module.php there is a function called signup in that function there is a line $uid = insert_id(); just below that insert these two lines sql_query("insert into
|
| |||
Thanks. I've managed to go to the files and everything but i still can't seem to find the signup function. i'm using version 4.2.1. please make sure your wording everything carefully. I understand it, but i just cant seem to find the signup fucntion.
|
| |||
mate what do you mean 'please make sure your wording everything carefully. I understand it, but i just cant seem to find the signup fucntion' its pretty straight forward just put these 2 lines of code.. below this line of code. [Code]$uid = insert_id();[/code] in this file member.module.php which is in includes/libs the wording couldn't be more accurate .. open file (member.module.php) in your editor go to search find this line [code]$uid = insert_id();[/code] and insert the other 2x lines below it.. simple
|
| |||
lol cool. finally found it. thanks so much lol. my eyes were everywhere. thanks again. Also please sign up for my site also which is
|
| |||
:) glad to hear it Mike ...
|
| |||
thanks mate, for the translation ;)
|