ASP相当于使用isset($ _ POST) [英] ASP equivalent to isset($_POST)

查看:118
本文介绍了ASP相当于使用isset($ _ POST)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个文件加载完毕后,页面上打开一个彩盒。问题是,我只是想,如果有人已经从一个链接,通过点击它来加载。我会做这在PHP中使用表单POST或GET变量,但该网站建于ASP,这是我无法从电子商务网站改变了一个框架。

I have a Colorbox that opens on a page after the document finishes loading. The problem is I only want it to load if someone has clicked through from a link. I would do this in PHP with form POST or GET variables but the site is built in ASP and it's a framework that I can't alter from an e-commerce site.

我想看看是否有在ASP中一个相当于如果使用isset($ _ POST),但似乎没有是一个。有没有办法在ASP中做到这一点?

I tried to see if there was an equivalent to if isset($_POST) in ASP but there doesn't seem to be one. Is there a way to do this in ASP?

<% IF (Request.Form("clicked")="clicked") %>

<script>
jQuery(document).ready(function(){
  jQuery.colorbox({
    iframe      : true,
    innerWidth  : 430,
    innerHeight : 208,
    href        : "/v/browse_market.asp"
  });
});
</script>
<%ELSE%>
<%END IF%>

这是近?我有一个提交后隐藏的变量,=点击和值=点击此页面的名称另一个页面上的表单。它似乎仍然处处流露出(我是否通过点击与否)。

Is this close? I have a form on another page that submits a hidden post variable with the name="clicked" and the value="clicked" to this page. It still seems to be showing always (whether I click through or not).

推荐答案

IF(的Request.Form(元素)&LT;&gt;中),然后是在ASP有道(经典)
如果(的Request.Form [元素]&LT;&gt;中)在ASP.NET有道

IF (request.form("element") <> "") THEN is the proper way in asp (classic) if(Request.Form["element"] <> "") is the proper way in ASP.NET

这篇关于ASP相当于使用isset($ _ POST)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆