Dearest Thorsten,
our passion for phpMyFAQ is huge and so we realized a feature that we needed a lot: the sorting of FAQ categories through drag & drop.
In order to realize this feature we modified some files and added a file save the sorting on a new database table.
If you want to use this new feature, you must copy the following files into:
index.php under /admin
category.order.php under /admin
category.main.php under /admin
category.php under /src/phpMyFAQ
Look at the zipped attached file (phpmyfaq-dragndrop.zip)
You also need to run the following query to create the new table that will store the category sorting.
CREATE TABLE faqcategoriesorders (
category_id int(11) NOT NULL,
position int(11) NOT NULL,
PRIMARY KEY (category_id)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
Bug fix: We also fixed a bug that after adding a new category, by refreshing it, added it again.
With a new validation method we check if the category exists and is not duplicated.
Paolo Caparrelli
GOLINE SA
We have created the drag and drop functionality for category sorting
Moderator: Thorsten
-
- Posts: 11
- Joined: Wed Sep 17, 2014 5:35 pm
- Location: Stabio, Switzerland, Europe
- Contact:
We have created the drag and drop functionality for category sorting
You do not have the required permissions to view the files attached to this post.
Re: We have created the drag and drop functionality for category sorting
Hi,
wow, this is awesome!
As it changes the database structure I'll add this for 3.1!
Thank you very much!
bye
Thorsten
wow, this is awesome!
As it changes the database structure I'll add this for 3.1!
Thank you very much!
bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
amazon.de Wishlist
Re: We have created the drag and drop functionality for category sorting
Hi,
finally your code went into v3.1 with some changes.
Thank you very much!
Cheers
Thorsten
finally your code went into v3.1 with some changes.
Thank you very much!
Cheers
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
amazon.de Wishlist