Buy Sell Discuss UK Domain Names at AcornDomains.co.uk

Today's Drop Dates are: 19-02-2012 or 26-02-2012   All times are GMT. The time now is 12:38:49 PM.
Domain Name Sales Domain Software Calculate UK Domain Drop Dates Domain Registration NameDrive Domain Parking Subscribe to our Domains For Sale newsletter
Go Back   Domain Forum Acorn Domains Buy Sell Auction UK Domains > Website Design and Promotion > Website Design > Scripts and Coding
Connect with Facebook

Scripts and Coding PHP, MySQL, scripts

Closed Thread
 
LinkBack Thread Tools Display Modes
Old 30-10-2008, 04:15:40 AM     #1 (permalink)

 
GreyWing's Avatar
 
Join Date: Aug 2006
Location: Barnsley
Posts: 3,176
GreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond repute

Quick PHP Question

Does anyone know what I can add to get the results to sort by the order_id field, and is descending order?

any help appreciated, cheers GW

$SQL = "SELECT * FROM jos_vm_order_user_info";
$result = mysql_query($SQL);

while ($db_field = mysql_fetch_assoc($result)) {
print $db_field['order_id'] . "<BR>";
print $db_field['title'] . "<BR>";
print $db_field['first_name'] . " ";
print $db_field['last_name'] . "<BR>";
print $db_field['address_1'] . "<BR>";
print $db_field['address_2'] . "<BR>";
print $db_field['city'] . "<BR>";
print $db_field['zip'] . "<BR> <BR> <BR>";


}

mysql_close($db_handle);

}
else {
print "Database NOT Found ";
mysql_close($db_handle);
}

?>
__________________
Make cash from your website, any website, any sector... That.co.uk Find out more
GreyWing is offline  
Old 30-10-2008, 04:35:35 AM     #2 (permalink)

 
woopwoop's Avatar
 
Join Date: Jan 2007
Posts: 1,586
woopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond repute

$SQL = "SELECT * FROM jos_vm_order_user_info order by order_id DESC";

I think if you replace your $SQL line with the line above it'll do what you want.
(btw/ change DESC to ASC for ascending)
woopwoop is offline  
Old 30-10-2008, 10:53:26 AM     #3 (permalink)

 
GreyWing's Avatar
 
Join Date: Aug 2006
Location: Barnsley
Posts: 3,176
GreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond repute

Cheers mate I'll give it a try,

Thanks
GW
__________________
Make cash from your website, any website, any sector... That.co.uk Find out more
GreyWing is offline  
Old 30-10-2008, 02:58:57 PM     #4 (permalink)

 
GreyWing's Avatar
 
Join Date: Aug 2006
Location: Barnsley
Posts: 3,176
GreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond reputeGreyWing has a reputation beyond repute

Cheers mae it worked 100%, saed me some time there, owe you one.

Thanks
GW
__________________
Make cash from your website, any website, any sector... That.co.uk Find out more
GreyWing is offline  
Old 30-10-2008, 03:09:53 PM     #5 (permalink)

 
woopwoop's Avatar
 
Join Date: Jan 2007
Posts: 1,586
woopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond reputewoopwoop has a reputation beyond repute

No probs GW you made me feel like an expert for today!
(usually I'm the person asking php questions on google groups)
woopwoop is offline  
Closed Thread



Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Domain Name Community Replies Last Post
quick question please....?? Paulo1Chop General Board 10 10-10-2007 04:31:38 PM
quick question on bad faith Mendis Domain Name Disputes 4 22-03-2006 09:59:30 PM

Web Hosting from UK2 from just 99p


All times are GMT. The time now is 12:38:49 PM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.6.0 RC 2
All content on Acorn Domains is member generated and is not moderated before posting. All content is viewed and used by you at your own risk and AD does not warrant the accuracy or reliability of any of the information. The views expressed are those of the individual contributors and not necessarily those of AD. Please contact us to report any issues or send a PM to "Admin".