开发者

Need to change value of checkbox if depending on link in Drupal 7

I have a webpage with two links, for example example.com/link1 and example.com/link2. Both links must to link to the same webpage, only for first link (example.com/link1) the form on the linked page should have checked checkboxes, but for other unchecked. Maybe somebody can jus开发者_开发知识库t advise on how to do that, just the idea hoe to do that using Drupal.


I'm looking for something slightly similar and remembered the "Flag" module. I'm not sure if you can get to it via a URL, but it seems like it might be possible. http://drupal.org/project/flag


Add a query to your link (ex: example.com/linked?checked=1 - see the $options argument for l()) and test for this using $_REQUEST['checked'] in your form.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜