Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在做一个项目,我应该根据推荐人或谷歌广告词显示不同的联系电话号码。
是否有可能知道访问者搜索了哪个广告词来访问网站和引荐来源?
所有数字都基于数据库。有没有简单的 JScript 可以做到这一点?
这么晚才回复很抱歉...
一个简单的解决方案是在他们访问的链接中通过谷歌传递电话号码。
然后在网站上使用PHP
<?php $_SESSION['_phone'] = 'default number'; if (!empty($_GET['phone'])) { $_SESSION['_phone'] = $_GET['phone']; } ?> <p><?php echo $_SESSION['_phone'];?></p>