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 8546327
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T12:59:32+00:00 2026-06-11T12:59:32+00:00

I got the following issue. A clients wants that the text after checkboxes are

  • 0

I got the following issue. A clients wants that the text after checkboxes are links to other pages and thus between …

I have the following code:

$form['boxes_brands'] = array(
        '#type'=>'checkboxes',
        '#title'=>'<div id="title-container">Merken</div>',
        '#options'=>$brandArr,
        '#default_value'=>$_SESSION['filter_brands_cat'],           
    );

=> $brandArr is an array of brands.

I looked in the Form Api of Drupal but I did not find an option to do this. I could alter the values in $brandArr but of course that changes the value of the value attribuut of the input object too.

Using the prefix and suffix options won’t do it either because I don’t want the checkboxes in the tags too.

Is there a clean way to do this?

Thanks!

  • 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-06-11T12:59:33+00:00Added an answer on June 11, 2026 at 12:59 pm

    If you created the form with the UI, then you should be able to specify something like this in as the options and links would be rendered as links:

    google|<a href="http://www.google.com">This is a link to google</a>
    yahoo|<a href="http://www.yahoo.com">Yahoo</a>
    bing|<a href="http://www.bing.com">Bing!</a>
    

    See example:
    Options label as links

    Otherwise, you should be able to modify the $brandArr accordingly to create links in the label. Doing this should NOT change the value of the attribute as it should be a $value->$label associative array. You just need to change the $label not the $value.

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

Sidebar

Related Questions

I have got the following issue, my function appends code to a string $string
I got the following issue while trying to insert multiple entries into a MySQL
Recently I've spotted a very disturbing issue. I've got the following python code: for
I got following repeating syntax and I want to keep all <h1> that is
I've got a similar issue to that reported by another user here XAMPP v1.7.4
I have two coupled classes DhcpServer and SessionManager . I got the following requirements
I'm new in Oracle and I got the following issue. Why I must double
I've a strange question.I have got a document that a client send it to
Basically I've got 2 sshexec tasks in an ant target, one after the other.
I got following code in an XHTML-document and every browser saysit is malformed :(

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.