Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7308757
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T23:36:48+00:00 2026-05-28T23:36:48+00:00

I have used this custom Helper in My Razor View. @Html.Link(OpenewWindow, Constants.Value, new {

  • 0

I have used this custom Helper in My Razor View.

  @Html.Link("OpenewWindow", Constants.Value, new { k = Constants.k, Staff_ID = LoginHelper.GetLoggedInUser() }, new { id = "mytag", target="_blank" })

When I Click on this link it opens me a new window with the Querystrings ConstantValue/Constants?=someValue&Staff_ID=UserLoggedName.

I want to pick the radio button selected value on the form and pass the checked value in QueryString.

So where can I use Jquery function in my custom Helper method to pick the value from the form.

The Custom Helper method takes this kind of aurguments.

 public static IHtmlString Link(this HtmlHelper htmlHelper, string linkText, string baseUrl, object query, object htmlAttributes).
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T23:36:48+00:00Added an answer on May 28, 2026 at 11:36 pm

    You could use javascript to do that. For example you could subscribe to the click event of the link and then open a popup window by appending the new query string parameter:

    $(function() {
        $('#id_of_link').click(function() {
            var url = this.href;
            if (url.indexOf('?') > -1) {
                url += '&';
            } else {
                url += '?';
            }
    
            // get the value of the radio button
            var value = $(':radio[name="name_of_your_radio_groups"]:checked').val();
            url += url + 'radiovalue=' + encodeURIComponent(value);
            window.open(url, 'newwindow');
    
            // cancel the default action
            return false;
        });
    });
    

    If you don’t need to use javascript then a cleaner approach is to use a form instead of a link. This way the value of the selected radio button will automatically be sent.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have build a custom Html Helper extension as follows: public static string DatePicker(this
I have used this in my HTML: <q> Hai How r u </q> Which
I have used Javascript onlaod like this: function check() { var pic = new
I have used this page from MSDN to apply a custom style to my
i have used custom validator protected void cvIsActive_ServerValidate(object source,ServerValidateEventArgs args) { if(args.Value.Length==1) args.IsValid =
I have an html helper in MVC3 that renders a custom section of html
Hai Freinds So far i have used this coding to create a custom Control
I have used this code for extracting urls from web page.But in the line
I have used this effect before, everything is in order (As far as I
I am creating a rails app and have used this code in one of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.