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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T16:14:01+00:00 2026-06-01T16:14:01+00:00

This might be really simple but I’m not used to this way of coding

  • 0

This might be really simple but I’m not used to this way of coding – How can I change this select menu:

$control .= '<select name="'. $this->_hash_value($hash, $xml_obj->value) .'" id="'. $this->_hash_value($hash, $xml_obj->value) .'" data-native-menu="false">';
foreach ($nameArr as $folder => $imageArr) {
            foreach ($imageArr as $image) {
                if (substr($folder, 1, strlen($folder)).$image == $xml_obj->value) {
                    $control .= '<option value="'. substr($folder, 1, strlen($folder)).$image .'" selected="selected">'. $image .'</option>';
                } else {
                    $control .= '<option value="'. substr($folder, 1, strlen($folder)).$image .'">'. $image .'</option>';
                }
            }
        }
        $control .= '</select>';

into a single list item (with the value of the currently chosen item) that leads to a basic list with all the items the user can choose from?

  • 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-01T16:14:02+00:00Added an answer on June 1, 2026 at 4:14 pm

    List 1:

    $control .= '<ul data-role="listview" data-inset="true">';
            $control .= '<li>';
            $control .= '<a href="'. site_url() .'/mobilegallery/gallery/'.$x[0]->attributes()->indexI.'">Bilder</a>';
            $control .= '</li>';
            $control .= '</ul>';
    

    List 2, on new page:

    $html .= '<ul data-role="listview" class="ui-listview" data-inset="true">';
        for($i = 0, $c = $xml->COM->MOVIE->count(); $i < $c; $i++ ){
    
            $html .= '<li>';
            $html .= '<a>
            <img src="https://[url]/'.rawurlencode($this->_decode_path($xml->COM->MOVIE[$i]->attributes()->dbIcoFilename)).'" id="imgThumb" alt="'.$xml->COM->MOVIE[$i]->attributes()->nameS.'" />
            <h1>'.$xml->COM->MOVIE[$i]->attributes()->nameS.'</h1>
            </a>';
            $html .= ' </li>';
    
        }
        $html .= '</ul>';
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I feel like this might be really simple but I'm just not getting it
This might have been asked before but I'm really looking for a simple way
There might be a really simple solution to this question, but i just don't
hey guys, this might be really stupid, but hopefully someone can help. I'm trying
I know this might be really a simple question but I don't know the
This might be a pretty simple question, but if there really is a difference,
this might be really simple and I've tried searching but I haven't been able
This might be really simple, but i cannot figure out the problem with this
There might be a really simple answer for this but I've been pondering it
This might be a really simple thing but i was unable to find an

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.