php - Want to create a ul li from some comma seperated values -


Currently I have different values ​​than commas such as

and

  • Apple
  • Pies

      $ data = "orange, apple, pie"; Li $ symbol = $ data = explosion (',', $ data); echo & lt; ul & gt; 'foreign currency ($ item $ item) {echo'  complex  stuff with accurate, hard-to-read codes ( Yes, I know, technically a string Technically there is an array, although it is different from what is usually with the array ):  
      $ input = 'oranges, apples, pie'; $ output = ' '; $ Output =' 
    • gt; '$ InputLength = strlen ($ input); $ Skip Space = true; ($ N = 0; $ n & lt; $ inputLength; ++ $ n) {If ($ skipSpaces) {if ($ input [$ n] === '') {continue; } $ Skip Spaces = false; } If ($ input [$ n] === ',') {$ skip Spaces = true; $ Output = '& Lt; / Li & gt; & Lt; Li & gt; '; to continue; } $ Output. = $ Input [$ n]; } $ Output. = '& Lt; / Li & gt; & Lt; / Ul & gt; '; Var_dump ($ product);

  • Comments