Jump to content

Just *cannot* get re-order right.


Anidazen

Recommended Posts

Hey guys.

 

I'm being massively held up by being unable to get a function right to sort my rows.

 

I have an array called prices. Format is as such:

 

prices[sellerID][priceID]

 

 

 

I want to be able to sort it by the price element. Been trying to get a function that will take a new priceID , and will give me an ordered list of sellerID s for that price. Lowest to highest, preferably with undefined coming last.

 

Eg. to return an array like "5,1,4,0,3,2", with every element referring to sellerID, as ordered by priceID.

 

 

 

 

This is really causing me some grief... I just can't wrap my head round it at all

 

If anyone can help me I'd really appreciate it.

Link to comment
https://forums.phpfreaks.com/topic/77538-just-cannot-get-re-order-right/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.