Jump to content

Recommended Posts

to be honest i should really know how to do this but nevermind..

 

all i want to do is add a url to all these echo's...

 

 


<?php 
    if ($player->ncolor == 1)
    {
    echo "<font color=\"blue\">".$player->username."</font>";
    }
    else if($player->ncolor == 2)
    {
    echo "<font color=\"green\">".$player->username."</font>";
    }
    else if($player->ncolor == 3)
    {
    echo "<font color=\"yellow\">".$player->username."</font>";
    }
    else if($player->ncolor == 4)
    {
    echo "<font color=\"pink\">".$player->username."</font>";
    }
    else if($player->ncolor == 5)
    {
    echo "<font color=\"silver\">".$player->username."</font>";
    }
    else if($player->staff >= 1)
    { 
    echo "<font color=\"gold\">".$player->username."</font>";
    }
    else if($player->rm >= 1)
    {
    echo "<font color=\"red\">".$player->username."</font>";
    }
else
{
echo "<font color=\"\">".$player->username."</font>";	
}
    ?>

 

this is the url i wanted added.


<a href=\"profile.php?id=" . $member['username'] . "\">"

 

 

Link to comment
https://forums.phpfreaks.com/topic/153540-solved-very-simple/
Share on other sites

why are you still posting on a resolved post...

 

in answer to your question. i did google it but i didnt know wxactly what to search.

 

i didnt know how to do it, so i looked for help.... thats what this forum is for and it worked brilliantly.

 

when seeking help.. a good reply isnt "have a guess, go crazy" how is that helping anything?

 

i did try to do it myself and failed... which is why i posted here.

 

finally, i dont mean to be rude either... because i respect everyone who spends their time trying to help others..

 

but you have now made two posts on here... and neither was educational nor on subject.

 

Link to comment
https://forums.phpfreaks.com/topic/153540-solved-very-simple/#findComment-807235
Share on other sites

Ok, well the purpose of my first post was an attempt to invoke some effort on your part. If you honestly googled it, you would have found many articles and tutorials about how to do this, such as this amongst others.

 

Even if you couldn't find anything on google, guessing would have sufficed. I mean...is it not obvious how to echo a hyperlink? You've succeeded in echoing font colors...that's basically the same thing.

 

Forgive me if I am incorrect, but I don't believe that you attempted this at all before posting here.

 

And you have my sincere apologies; I didn't know that it is forbidden to post in solved topics.

Link to comment
https://forums.phpfreaks.com/topic/153540-solved-very-simple/#findComment-807266
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.