Getting All List Items Of An Unordered List In Php
- Music
- Lion
Solution 2:
You can't get these in PHP unless you send the data back to the server somehow. PHP executes on the server, if this is coming in via a jquery, then PHP knows nothing about it.
You will need to either use javascript to get all the information and send it back to the server, or you need to send the entire page HTML (somehow) back to the server to be looked at by PHP. I suggest the first option.
Edit: I am not flash-hot with javascript, just use some basic functions, but you could write an event into a <div>
or where the data is coming into along. The function would find how many <li>
there are in the <ul id="tag-cloud-list">
pop them into an array and send them to the PHP server, by a form or ajax query.
Sorry that I can't help much with the js code.
Solution 3:
You need to get all items in the ul using .find() function from JQuery and make a POST with ajax and process the information
Post a Comment for "Getting All List Items Of An Unordered List In Php"