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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 2, 20262026-06-02T18:20:33+00:00 2026-06-02T18:20:33+00:00

I have a form page where users enter some data and upon hitting ‘submit’

  • 0

I have a form page where users enter some data and upon hitting ‘submit’ a query is executed in our database that pulls up relevant information.

So, users put in two things into the form: class name and time.

after that, our php file pulls up a table with section information.

for example: ENG 212 has two sections: ENG212-001 and ENG212-101. So, in the table, it has information about the section like max enrollment and location, etc. it also shows how many people are currently enrolled in that section.

Now I want users to select a section. if the max enrollment is 10 and currently enrolled are 10 students, then the user can’t select that. if currently enrolled is < max enrollment, then the user can select that section.

so, HTML page with form –> php file that pulls up the table —> now i need a way for user to select one of the sections, but if they are full I want them not to be able to even select it.

I’m thinking of doing radio buttons but I have no idea how I’d implement them for this particular scenario

how do i implement this? i’ve tried looking online and I have no idea how to implement this.

any help would be appreciated.

  • 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-02T18:20:35+00:00Added an answer on June 2, 2026 at 6:20 pm

    After you submit the HTML Form and you get the max enrollment value check it in PHP and print the radio buttons from within PHP based on the value you got.

    if ($max_of_section_1>10) 
        echo "<input type='radio' disabled='disabled' value='Section01'/>Section 01";
    else
        echo "<input type='radio'  value='Section01'/>Section 01";
    if ($max_of_section_2>10) 
        echo "<input type='radio' disabled='disabled' value='Section02'/>Section 02";
    else
        echo "<input type='radio'  value='Section02'/>Section 02";
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to build a form where users can enter some data in a
I have a basic html form that adds some data to the page using
in my PHP web application,I have a dataentry form where users will enter data
I have a form where users can enter data that ultimately would be used
I have an HTML page with a simple form. When the user clicks submit,
I have a form on my site which sends data to some remote site
I have a form that is supposed to store some of its data into
I have a form that requires the user to enter some information. If they
I have a form where the user enters data. Then, when they click submit,
I have a form with a textarea. Users enter a block of text which

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.