Jump to content

HTML Bookmark written in PHP?


Skipjackrick

Recommended Posts

I've got an issue.

 

I need a typical html bookmark. 

 

Example,

<a href="index.php#article5">See Article 5</a>

<!-- Then somewhere way down the page I have this --->
<a name="article5"></a>

 

When I write this in PHP I get an error as expected.

<?php
   echo " <li class='next'><a href='{$_SERVER['PHP_SELF']}#article5?currentpage=1'>First <<</a></li> ";
?>

 

Parse error:  syntax error, unexpected T_STRING, expecting ',' or ';' in /development/index.php on line 2

 

Does anyone know how to direct the user to that article?  Or how to properly use a bookmark using PHP?

Link to comment
https://forums.phpfreaks.com/topic/189885-html-bookmark-written-in-php/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.