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