


javascript - 像那些广告联盟,是怎么实现的呢,比如我淘宝上搜一个商品,然后优酷看视频,其它一些乱七八糟的广告百度联盟的啊,都是相关的推荐广告?
像那些广告联盟,是怎么实现的呢,比如我淘宝上搜一个商品,然后优酷看视频,其它一些乱七八糟的广告百度联盟的啊,都是相关的推荐广告?
这个是怎么实现的呢,不同网站不是不能实现cookie共享的吗?
难道其实他们都是合作的,或是怎么搞的,感觉有点神了?
有高手详细的解释下原理吗?
谢谢了!
回复内容:
像那些广告联盟,是怎么实现的呢,比如我淘宝上搜一个商品,然后优酷看视频,其它一些乱七八糟的广告百度联盟的啊,都是相关的推荐广告?
这个是怎么实现的呢,不同网站不是不能实现cookie共享的吗?
难道其实他们都是合作的,或是怎么搞的,感觉有点神了?
有高手详细的解释下原理吗?
谢谢了!
谈一下百度联盟吧
首先,我们在使用百度的时候,百度会记录我们的操作行为。
比如:
这是我某一天的搜索记录。
百度会长期跟踪个人行为,然后对用户进行分析。包括性别,爱好等等
当然,也包括你使用的相关百度产品也会进行分析。
下面,站长在使用百度联盟的时候,就会根据你的相关信息,给你推荐相关内容。
这是我的网站ENUE,也加入百度联盟。
iframe
====补充====
这是腾讯网首页天猫广告的源码,腾讯网通过加载
http://p.tanx.com/ex?i=mm_26051537_2367569_21224084
这一段天猫的js,用于初始话广告,这端js会陆续的加载其他的天猫js,但最终要的是加载了
http://ope.tanx.com/ex?i=mm_26051537_2367569_21224084&cb=jsonp_callback_3386&callback=&userid=&o=&f=&n=&re=1920x1080&r=1&cah=1040&caw=1920&ccd=24&ctz=8&chl=2&cja=1&cpl=6&cmm=8&cf=19.0&cg=a9af6a03f12808613c16ff3d163de1dd&pvid=acee1495435d1164d78b4af9766fed19&pvid_1=e7f394a9f05512679be354485eb0a5c5&ai=0&ac=1537&prm=45906808&cas=prm&cbh=0&cbw=700&dx=1&u=http%3A%2F%2Fwww.qq.com%2F&k=&tt=alimama%20ad
这段js,是一段jsonp的数据,data字段包含了一个iframe字符串
"<iframe scrolling=\"no\" height=90 frameborder=\"0\" width=700 style=\"border: 0pt none;\" marginheight=\"0\" allowtransparency=\"true\" marginwidth=\"0\" border=\"0\" src=\"http:\/\/strip.taobaocdn.com\/tfscom\/TB1y4V6HpXXXXXIXFXXO04pFXXX.html?name=itemdsp&url=http%3A%2F%2Fwww.qq.com%2F&iswt=1&pid=tt_26051537_2367569_21224084&refpid=tt_26051537_2367569_21224084&refpos=,n,i&adx_type=0&pvid=0ab7409100005656702e17b903bd0151_0&ps_id=acee1495435d1164d78b4af9766fed19&fl=3&tanxdspv=http%3a%2f%2frdstat.tanx.com%2ftrd%3ff%3d%26k%3da09e279ad7f7a12a%26p%3dmm_26051537_2367569_21224084%26pvid%3d0ab7409100005656702e17b903bd0151%26s%3d700x90%26d%3d17534123%26t%3d1448505390\"><\/iframe><img src=\"http:\/\/dsp.simba.taobao.com\/feedback?bid=0ab7409100005656702e17b903bd0151&v=1&e=2&p=AQq3QJEAAFZWcC4XuQO9AVFYLrjIi7dXDg%3D%3D\" style="max-width:90%"0\" height=\"0\" \/ alt="javascript - 像那些广告联盟,是怎么实现的呢,比如我淘宝上搜一个商品,然后优酷看视频,其它一些乱七八糟的广告百度联盟的啊,都是相关的推荐广告?" >"
这个iframe的最终地址是
http://strip.taobaocdn.com/tfscom/TB1y4V6HpXXXXXIXFXXO04pFXXX.html?name=itemdsp&url=http%3A%2F%2Fwww.qq.com%2F&iswt=1&pid=tt_26051537_2367569_21224084&refpid=tt_26051537_2367569_21224084&refpos=,n,i&adx_type=0&pvid=0ab7409100005656702e17b903bd0151_0&ps_id=acee1495435d1164d78b4af9766fed19&fl=3&tanxdspv=http%3a%2f%2frdstat.tanx.com%2ftrd%3ff%3d%26k%3da09e279ad7f7a12a%26p%3dmm_26051537_2367569_21224084%26pvid%3d0ab7409100005656702e17b903bd0151%26s%3d700x90%26d%3d17534123%26t%3d1448505390
题主自己用浏览器打开一下这个地址,就是那个广告。
另外题主可以上网随便百度一下js跨越访问的相关知识(随手帮你找了http://www.cnblogs.com/2050/p/3191744.html),window.name,windon.domain,iframe,jsonp,postMessage等技术都可以完成跨越访问。

What’s still popular is the ease of use, flexibility and a strong ecosystem. 1) Ease of use and simple syntax make it the first choice for beginners. 2) Closely integrated with web development, excellent interaction with HTTP requests and database. 3) The huge ecosystem provides a wealth of tools and libraries. 4) Active community and open source nature adapts them to new needs and technology trends.

PHP and Python are both high-level programming languages that are widely used in web development, data processing and automation tasks. 1.PHP is often used to build dynamic websites and content management systems, while Python is often used to build web frameworks and data science. 2.PHP uses echo to output content, Python uses print. 3. Both support object-oriented programming, but the syntax and keywords are different. 4. PHP supports weak type conversion, while Python is more stringent. 5. PHP performance optimization includes using OPcache and asynchronous programming, while Python uses cProfile and asynchronous programming.

PHP is mainly procedural programming, but also supports object-oriented programming (OOP); Python supports a variety of paradigms, including OOP, functional and procedural programming. PHP is suitable for web development, and Python is suitable for a variety of applications such as data analysis and machine learning.

PHP originated in 1994 and was developed by RasmusLerdorf. It was originally used to track website visitors and gradually evolved into a server-side scripting language and was widely used in web development. Python was developed by Guidovan Rossum in the late 1980s and was first released in 1991. It emphasizes code readability and simplicity, and is suitable for scientific computing, data analysis and other fields.

PHP is suitable for web development and rapid prototyping, and Python is suitable for data science and machine learning. 1.PHP is used for dynamic web development, with simple syntax and suitable for rapid development. 2. Python has concise syntax, is suitable for multiple fields, and has a strong library ecosystem.

PHP remains important in the modernization process because it supports a large number of websites and applications and adapts to development needs through frameworks. 1.PHP7 improves performance and introduces new features. 2. Modern frameworks such as Laravel, Symfony and CodeIgniter simplify development and improve code quality. 3. Performance optimization and best practices further improve application efficiency.

PHPhassignificantlyimpactedwebdevelopmentandextendsbeyondit.1)ItpowersmajorplatformslikeWordPressandexcelsindatabaseinteractions.2)PHP'sadaptabilityallowsittoscaleforlargeapplicationsusingframeworkslikeLaravel.3)Beyondweb,PHPisusedincommand-linescrip

PHP type prompts to improve code quality and readability. 1) Scalar type tips: Since PHP7.0, basic data types are allowed to be specified in function parameters, such as int, float, etc. 2) Return type prompt: Ensure the consistency of the function return value type. 3) Union type prompt: Since PHP8.0, multiple types are allowed to be specified in function parameters or return values. 4) Nullable type prompt: Allows to include null values and handle functions that may return null values.


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

MinGW - Minimalist GNU for Windows
This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

SublimeText3 English version
Recommended: Win version, supports code prompts!

SublimeText3 Chinese version
Chinese version, very easy to use

VSCode Windows 64-bit Download
A free and powerful IDE editor launched by Microsoft

DVWA
Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is very vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, to help web developers better understand the process of securing web applications, and to help teachers/students teach/learn in a classroom environment Web application security. The goal of DVWA is to practice some of the most common web vulnerabilities through a simple and straightforward interface, with varying degrees of difficulty. Please note that this software