Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I just converted some of my HTML pages to PHP pages, and I'm not that familiar with PHP. In my HTML pages, assuming it's just a static web app, I can link to another page quite simply by playing the following anchor on the page:

<a href="go-to-this-page.html">This is a link</a>

So, after converting the pages to PHP in order to make sure that I can template and include templates a bit easier and faster, I don't know how to include these links.

For example, say I have two pages, index.php, and page2.php. How would I create an anchor link to this page?

<a href="??????">This is a link</a>

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
440 views
Welcome To Ask or Share your Answers For Others

1 Answer

Use like this

<a href="index.php">Index Page</a>
<a href="page2.php">Page 2</a>

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...