This blog has moved to a new location! http://iqandreas.github.com/

Sunday, June 6, 2010

[K2Fave] Joomla! K2 Favorite item manager

NOTE! This modification has been updated to release version 1.0, if you still have the old version (without proper translations), please update. More information is available in this post

Greetings Joomlaers!

As there was a need for a "favorites" option in the Joomla! plugin k2, I have released these modifications. Note that this is not an installable extension. Instead, these are files added to the server, and slight modifications to already existing k2 pages.

I am releasing these modifications for for free, and although it's not required, if you do make money from the project, I would appreciate a donation so I can keep my programming work alive and keep these modifications and extensions coming for free.
These files are released as-is with no guarantee to be free from flaws or completely secure. If you are worried about the code containing security holes, look over the code yourself and make the necessary changes. If you find any vulnerabilities let me know and I will be sure to fix them in the next release.


This is the first release of the project, so any suggestions or tips are VERY welcome.

If you would rather not do all the work of adding the plugin yourself, for $30 USD I will upload and make all changes directly to the server, so you don't have to worry about anything, including any wanted customization such as speical text, CSS formatting, etc. If you have any other "wants" for the project, I can implement those as well.

For further details, leave a comment in the section below, or on my in progress website, or send me an email via the address provided in the README.txt file.


Instuctions for use/installation

Download the ZIP file and extract it temporary location
http://iqandreas.isbetterthanyou.org/files/joomla/k2fave/k2fave.zip

Save the "items.php" file as:
components/com_k2/templates/default/item.php
Note that if you are using an updated version of K2 with a different "item.php" page, copy lines 27-33 into the new "item.php" page, and place them right before the line containing "<!-- K2 Plugins: K2BeforeDisplay -->"

Save the entire folder "k2fave" inside of the folder
components/com_k2/

Finally, create a new table named "jos_k2_favorites", using whatever prefix your Joomla installation currently uses. Your table should be formatted like this:
user_id int(11) PRIMARY_KEY
item_id int(11) PRIMARY_KEY

The easiest way it to open up PHPMyAdmin and add this table manually, however, it is possible to do so via SQL statements instead.


If you have any questions or would like me to do any other Joomla modifications, send me a message.


Cheers,
Andreas
http://iqandreas.blogspot.com/
http://iqandreas.isbetterthanyou.org/

7 comments:

  1. This is a much awaited feature. Thank you for writing these lines of code!

    ReplyDelete
  2. Hi i have made the changes for k2 favorites and i can now ad a item as favorite thanks.

    but i have a problem i cant remove it i doesnt remove it from the database.

    ReplyDelete
  3. Hello, could you please explain how to display these favorites once you have implemented the above?

    ReplyDelete
  4. Hi!
    This will be must-have addon for K2, so thank you very much for starting the development!

    Unfortunately it doesn't work properly, I have the same 2 questions that are posted below by 2 other user. How can the marks be removed from the items, and how can the marked item be listed?

    ReplyDelete
  5. Good afternoon, how do I display a favorite page?

    ReplyDelete
  6. i have a an error code.

    Warning: mysqli_num_rows() expects parameter 1 to be mysqli_result, boolean given in /home/insidene/public_html/agencia/libraries/joomla/database/database/mysqli.php on line 263

    ReplyDelete
  7. Hi, the link is broken, can anyone upload again pls

    ReplyDelete