Solved

Need help with PHP with href not working.

Posted on 2009-07-09
8
177 Views
Last Modified: 2012-05-07
The Read More link is not working with the commneted code to Read More.  However, I took the print out of $newLink and subsitute that for $newLink in the commented code of ReadMore and that Link works just fine.  Why is that so?  Thanks.
echo "Event link is " .$newLink;

					  //echo "<li><span class='date'>" . $newDate ."</span><br/><i>" .$event->title. "</i><br/><a href='http://www.google.com/calendar/hosted/labctsi.org/event?eid=bmFzZnF0dTFvbjA3MzZycnRuaTNnYmo1YjAgY2Jpc0BsYWJjdHNpLm9yZw'>Read More</a></li>";

					  

					  echo "<li><span class='date'>" . $newDate ."</span><br/><i>" .$event->title. "</i><br/><a href='".$newlink."'>Read More</a></li>";

Open in new window

0
Comment
Question by:lapucca
  • 3
  • 3
  • 2
8 Comments
 
LVL 12

Expert Comment

by:Chad Haney
ID: 24818038
0
 

Author Comment

by:lapucca
ID: 24818107
Weird!  It shows '', two single quote.  And I notice there is an extra </li>.  What's going on here?
0
 

Author Comment

by:lapucca
ID: 24818112
Event link is http://www.google.com/calendar/hosted/labctsi.org/event?eid=Y2NqMXZwZjY2aDBqYjlrMXFudmZvY3Bic2sgY2Jpc0BsYWJjdHNpLm9yZw<li><span class='date'>July 31, 2009</span><br/><i>OFF</i><br/><a href=''>Read More</a></li>      </li>

</ul>
                        
0
 
LVL 12

Accepted Solution

by:
Chad Haney earned 500 total points
ID: 24818119
Change $newlink
to $newLink
0
Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

 
LVL 12

Expert Comment

by:Chad Haney
ID: 24818125
Not sure about your second </li>, cant see anything that would be causing that.
0
 

Author Closing Comment

by:lapucca
ID: 31601814
Thank you.  That fixed the problem.  I'
0
 
LVL 14

Expert Comment

by:profya
ID: 24818339
They are different variables, the l is big then samll:
$newLink does not equal $newlink
0
 
LVL 14

Expert Comment

by:profya
ID: 24818351
This should work:
echo "<li><span class='date'>" . $newDate ."</span><br/><i>" .$event->title. "</i><br/><a href='".$newLink."'>Read More</a></li>";

Open in new window

0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

This is a PowerShell web interface I use to manage some task as a network administrator. Clicking an action button on the left frame will display a form in the middle frame to input some data in textboxes, process this data in PowerShell and display…
Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
In this tutorial viewers will learn how to style transparent/translucent elements using alpha transparency in CSS Start with a normal styled element, such as a div.: Define its "background-color" property as "rgba (255, 255, 255, .5): The numbers in…
The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

757 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now