Jump to content
php.lv forumi

Multiple & PHP


ray

Recommended Posts

Lieta tāda, ka man ir forma, kurā ir <select multiple...> un man vajag dabūt MySQL datubāzē tā ierakstus, tipa katrs Multiple savā tabulas rindā.

Piem.

<input type='text' name='kkads' value='vertiba'>
<select multiple name='bla'>
<option value='1'>1</option>
<option value='2'>2</option>
<option value='3'>3</option>
</select>

un no tā man vajag dabūt tabulu:

vertiba | 1
vertiba | 2
vertiba | 3

Edited by ray
Link to comment
Share on other sites

nebija, bet strādā un man dikti patīk šitāds,

tabulām ar daudz laukiem vieglāk sparast ko kur liec, un nav jāskaita, pirmais, otrais.. divdesmitotrais.

 

tikko iedomājos var it kā salikt hašmapā fieldname1=>"value1" un ar array_keys(), array_values() panākt kaut ko līdzīgu ar standarta sql, lai nebūtu jāskaita lauki ar pirkstu.

Edited by v3rb0
Link to comment
Share on other sites

Jā, sintakse jau ērta vispār :).

 

Liels oft, bet, ray, tu gan esi melis :).

 

No tavas lapas:

Like one of the biggest skiing and snowboarding web sites we are offering to you advertising possibilities in our site. Skiroad.com will be the best chance for you to reach your best client count. More than 1 000 000 times a month people are using our site skiroad.com to find information about skiing for themselves.
Bet tajā pašā laikā lapas apakšā:
Visitors:

# Total: 667430

# Today: 36

Edited by andrisp
Link to comment
Share on other sites

×
×
  • Create New...