Latest Forum Posts
Home arrow Forum
Design Forum
Welcome, Guest
Please Login or Register.    Lost Password?
Go to bottom Post Reply Favoured: 0
TOPIC: Re:Sequence in Childlist

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656
#177
neo_polo (User)
Fresh Boarder
Posts: 2
graphgraph
User Offline Click here to see the profile of this user
Sequence in Childlist 4 Years, 11 Months ago  
hi,

first, thank you very much for this Mod, it's realy good.

My english is realy bad, i hope you understand my text

My question:

How can i change the sequence in the childlist in order details.

At the moment its unsortet by me

Size 40
Size 80
Size 50
Size 60

I hope you can help me, i now its a little thing, but for me its important.

Greets
neo_polo
 
  The administrator has disabled public write access.

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656
#179
macallf (Admin)
Administrator
Admin
Posts: 655
graph
User Online Now Click here to see the profile of this user
Re:Sequence in Childlist 4 Years, 11 Months ago  
You have to edit ps_product_attribute.php

VM by default does not sort the child items, my mod does not either!

Lines 229,241,436 and 447 have to be edited.

At the end of each line add an order by clause

this is one of the lines (They are different so dont just cut & paste!)

Code: :

 $q "SELECT product_id,product_name,product_parent_id FROM #__{vm}_product WHERE product_parent_id='$product_id' AND product_publish='Y'";



Edit it to add the order by clause

Code: :

 $q "SELECT product_id,product_name,product_parent_id FROM #__{vm}_product WHERE product_parent_id='$product_id' AND product_publish='Y' ORDER BY product_name";



instead of product name you could use

product_sku, product_id etc

If your SKU's are in order then I would use product_sku
 
 
Mark
  The administrator has disabled public write access.

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656
#180
neo_polo (User)
Fresh Boarder
Posts: 2
graphgraph
User Offline Click here to see the profile of this user
Re:Sequence in Childlist 4 Years, 11 Months ago  
thank you very much for the fast answer.

Now its a lot beter
 
  The administrator has disabled public write access.

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656
#782
shultman (User)
Fresh Boarder
Posts: 2
graphgraph
User Offline Click here to see the profile of this user
Re:Sequence in Childlist 4 Years, 7 Months ago  
macallf wrote:
You have to edit ps_product_attribute.php

VM by default does not sort the child items, my mod does not either!

Lines 229,241,436 and 447 have to be edited.

At the end of each line add an order by clause

this is one of the lines (They are different so dont just cut & paste!)

Code: :

 $q "SELECT product_id,product_name,product_parent_id FROM #__{vm}_product WHERE product_parent_id='$product_id' AND product_publish='Y'";



Edit it to add the order by clause

Code: :

 $q "SELECT product_id,product_name,product_parent_id FROM #__{vm}_product WHERE product_parent_id='$product_id' AND product_publish='Y' ORDER BY product_name";



instead of product name you could use

product_sku, product_id etc

If your SKU's are in order then I would use product_sku


I am really happy I found your site!
Iīve been struggling with this sorting problem some time and found this thread.
Please, could you explain, i am trying to edit ps_product_attribute.php (version 1.0.12) but the line numbers confuses me a bit. Line 241 I found, not the others. Maybe the original file is changed since you wrote this post?
As I donīt know what to look for, some help would be very appreciated.

Thanks!
//Sune
 
  The administrator has disabled public write access.

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656
#783
macallf (Admin)
Administrator
Admin
Posts: 655
graph
User Online Now Click here to see the profile of this user
Re:Sequence in Childlist 4 Years, 7 Months ago  
This information is for my childlist mod, not for the standard VM childlist. Hence it is posted in this forum. This forum is for help with my mods not for help with VM in general, those questions should be posted in the VirtueMart forum.

The same principles will apply though, but my mod has three options for the display of children. The standard dropdown, a list with one add to cart button and a list with one add to cart button per child.
 
 
Mark
  The administrator has disabled public write access.

Warning: array_merge() [function.array-merge]: Argument #1 is not an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 653

Warning: array_walk() [function.array-walk]: The argument should be an array in /home/markfco/public_html/design/components/com_fireboard/class.fireboard.php on line 656
#785
shultman (User)
Fresh Boarder
Posts: 2
graphgraph
User Offline Click here to see the profile of this user
Re:Sequence in Childlist 4 Years, 7 Months ago  
Sorry, didnīt notice that your mod replaces the original file.

Anyway, you have lead me in the right direction, so I could solve the problem. I have answered my own question in the VM forum, so hopefully others can be helped by it.

This has saved me hours. Thank you!
 
  The administrator has disabled public write access.
Go to top Post Reply
Powered by FireBoardget the latest posts directly to your desktop