简体   繁体   中英

How to fetch the value of a dropdown in XSL (SobiPro plugin in Joomla)?

I am trying to make some modifications to SobiPro plugin in a Joomla site. Ref: Site Url We have implemented SobiPro search feature. There are 2 dropdowns.

  1. Specialty/Category of doctor
  2. Hospital Name

In the Specialty dropdown, different specialities are listed down in the following format;

  • Select Category
    • Dentist
    • Psychologist
    • Anaesthetist

When a specific category is selected the rsearch results are getting displayed correctly. What I am trying to do is to make a different display when a user 'doesn't select a default category'.

ie - A user selects 'Select category' in first dropdown and 'Hospital name' in second dropdown.

A layout with the 'Specialty' as heading in top row. Then all the doctors in that specialty will be displayed under that heading.

For this to work, I need to fetch the value of 'Specialty/Category' dropdown. How can I do it in XSL?

<select name="field_speciality" id="field_speciality" class="" style="width: 200px;">
    <option selected="selected" value="0">Select Category</option>
        <option disabled="disabled" value="55">- Doctors</option>
        <option value="74">Dentist</option>
        <option value="262">Psychologist</option>
        <option value="118">Pulmonologist</option>
</select>

How can I implement the same?

I have done the modifications using 'Muenchian method'. I am attaching a reference link here incase anyone have a similar requirement. Ref: http://www.jenitennison.com/xslt/grouping/muenchian.xml

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM