PDA

View Full Version : a little programing problem regarding memberlink


schneberger
02-24-2008, 11:11 AM
Hello there..

i am working on a littlebit of a garagemod for our site , wich uses profilepics and interactive profiles. i have tried to search my templates for this code that i am looking for but i canĀ“t seem to find it.

ok here it goes.

When you are in the memberlist , a thread or just anything u can click on a users name and you are sent to this persons profile, what i have done is that i have taken the member.php renamed it a i make it call on a template called memberinfo2 isntead of memberinfo. i think i did right thing as far as that goes. what i want is a link in the regular profile that calls on the member2.php. BUT this is my big but. i cant find the code anywhere of how i should code it so it does opens the member2.php in the current users name. in other words the same code that is everywhere else on the site where you can click on a username an be redirected to this persons profile. i need this code because i think i can use the same code with the same variables but just change the pagename its calling to member.php.

i hope you understand what i mean. and can help me with that code.

thanks in advance..
markus

Lynne
02-24-2008, 03:37 PM
So you want it so everywhere it used to call member.php, you want it to call member2.php? It might be easier to just rename your member2.php to member.php and then everything will work without you changing any templates.

If you do decide you want to change the templates instead, go to your admin cp > templates & styles and click on search in templates and enter "member" or "member.php" and all the templates that use it will get listed. You can then click on the template and change member.php to member2.php

schneberger
02-24-2008, 06:07 PM
i think i described my problem a little bad.

on all the places where it calls on the member.php it should call the member.php.. but i want to have a link in the users profile that callson member2.php and calls the member2.php for the specifik users profile that iam in . a little like having two profiles with separate templates.

as for now i have a link that calls upp member2.php in the profile
its like this <a href="member2.php?u=1></A> but that makes it a fixed call.. i want the same link to link to that user in whos profile i am in..

i think that i might be descibing my issue bad but i try as good as i can..i hope you understand what i am trying to achive

Lynne
02-24-2008, 06:51 PM
You didn't say where in the member page you want to put the link, but I believe the code would be along the lines of:

<a href="member2.php?u=$userinfo[userid]" rel="nofollow">Member2 Page</a>

I'm not sure if you need a "do=something" in there at all since you didn't talk about any parameters in your new page.

schneberger
02-24-2008, 06:59 PM
thanks for the reply.. you desciped it like i fell over it in the profile gallery thread..

my issue is solved so now i will just make the garage and i think i will uppload it as a mod here..i think it can be very cool

thanks for takin the time to help me out