How can a beginner in php obtain the title value of a hyperlink?

Source: Internet
Author: User
Php beginners help: how to obtain the title value of a hyperlink? This post was last edited by ileleX from 2013-10-3110: 07: 11. Like a hyperlink: & lt; a & nbsp; href = "http://www.example.com /? How can I obtain the title value of a hyperlink?
This post was last edited by ileleX at 10:07:11.

For example, a hyperlink:

HypeLinkTitle "title =" hyperlink title 8 "> hyperlink title 9

You can use $ _ GET ['title'] to obtain "HypeLinkTitle". how can I obtain "hyperlink title 8" and "hyperlink title 9 "?

Hope you can give me a prompt on this hyperlink. thank you! Php obtains link text and shares it:
------ Solution --------------------
Transmission through js
------ Solution --------------------
Certificate ('your maid 'Your .html ();
------ Solution --------------------
Reference:
Quote: reference:

Transmission through js

Hyperlink Title 9


Var _ h = require ('hzink'{.html ();

What then? I hope you can learn more about php.





Script


$ (Function (){

$ ('# Xxxxx'). click (function (){

Var t = $ (this). attr ('title ');
Var h = require (this).html ();
Var r = $ (this). attr ('Rel ');
// String connection,
Var u = r + '& testTitle =' + t + '& testHtml =' + h;

Alert (u );
});

})

Script

TestHtml




------ Solution --------------------

Just put them behind the question mark.
Http://www.example.com /? Title = HypeLinkTitle _ hyperlink title 8__ hyperlink title 9__ hyperlink title 100
Get and then split explode

$ Title_list = explode ("_", $ _ GET ['title']);
Echo $ title_list [0];
Echo $ title_list [1];
Echo $ title_list [100];

Reference:
Quote: reference:

Back to php?

A. Yes.
To achieve this, click this link and the php background will read the relevant articles from the database based on this link. The spider must be able to crawl.

------ Solution --------------------
Do not implement this idea.

Put all of them in the dom, and use js to switch the dom display and hiding, so that the spider can also capture

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.