Hello and welcome to our community! Is this your first visit?
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Oct 2012
    Thanked 0 Times in 0 Posts

    php script has wrong link

    Hi, I am hoping someone can help me with a line of code I think is wrong.
    Basically I have a script and when users signup they have one last step. That is to activate there account by clicking on a link that is sent to them in an email.
    Now everything else works.
    But the link appears to be joined up here is my example. Lets say a user has signed up and there name is mark and they have said there website address is "www.makeup.com"
    I need them to click on the link which will take them to the active.php page

    Email looks like below.
    Hello mark,<BR>Get ready to start getting the hits you deserve. Now here is your login info

    <BR><BR>username: computing<BR>password: computing<BR><BR><B>The next step is to click on this link to activate your account:
    <a href=http://www.makeup.comactivate.php?username=mark>CLICK HERE</a></b>

    Just look at the link above you can see it is wrong because there is nothing to separate the URL from the activate.php

    The code line I think is wrong is this below.
    "<B>The next step is to click on this link to activate your account: <a href=".$siteUrl."activate.php?username=".$signup[username].">CLICK HERE</a></b>";

  2. #2
    God Emperor Fou-Lu's Avatar
    Join Date
    Sep 2002
    Saskatoon, Saskatchewan
    Thanked 2,668 Times in 2,637 Posts
    It needs some work. The line that you have there for the code isn't setting up a valid attribute, but the bigger problem is its simply missing the /.
    PHP Code:
     '<B>The next step is to click on this link to activate your account: <a href="'.$siteUrl.'/activate.php?username=' .$signup['username'].'">CLICK HERE</a></b>'
    Would give you what you want. The markup itself isn't very good, but browsers should understand it.


Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts