Welcome to Geeklog, Anonymous Sunday, December 22 2024 @ 08:09 am EST
Geeklog Forums
Catalog Plugin for GeekLog 1.4.1
Page navigation
sk716
I used the FAQ Plugin as the base (since there doesn't seem to be a universal plugin for GeekLog 1.4.x)
I'm not a php expert so I'm sure the code is really rough. But it does work. With a few language changes it could be used to catalog Books, Movies, or Music as well.
My demo server is running on PHP5 and it's working with no problems.
You can see it at work here:
http://oddduck.net/plugtest/catalog/index.php
To download the package go here:
http://test.oddduck.net/easyfile/file.php?msg=file_uploaded&show=20070702213904355
LWC
Some questions:
1) Can you define your own type of fields? For example, currently each of your items has 11 text fields, 2 textareas and 1 image.
2) Can you decide which fields appear in the general lists? For example, currently your lists have 3 text fields, last update's date and hits.
*3) Do you have an interface to upload the image and can you later replace it?
*4) Must the attached media be in image form?
* Consider having Media Gallery taking care of those things. Then it would take care of handling the media and supporting anything MG does (remote videos, etc.). Unless Mark wants to combine MG with your plugin and make it the most powerful plugin ever, I think your biggest challenge should be to find ways to use MG to do those things. The uploading part would be probably be hard, but as for presenting, you can just accept MG's autotags.
P.S.
When going to your advanced search and clicking "Type", there's a blank where your plugin's title should go. However, if you choose the blank, the search generally does work. So you just need a title in the language files. Then again, it doesn't find some of the words from the category "Arc".
sk716
Very nice! Geeklog really needed this.
Some questions:
1) Can you define your own type of fields? For example, currently each of your items has 11 text fields, 2 textareas and 1 image.
They're all hand coded in, but with a little basic SQL and PHP Knowledge it's pretty easy to edit in some changes. But I'm not hard core enough to have programmed in the options.
Yep, I hardcoded all of the options into the /catalog/index.php file and then just added the ones I wanted displayed to the function.
*4) Must the attached media be in image form?
Yes and any file type should be fine, I didn't add any blocks.
I wouldn't even know where to begin, I love MediaGallery, but everytime I have to crack open a page of the code I feel like a noob.
When going to your advanced search and clicking "Type", there's a blank where your plugin's title should go. However, if you choose the blank, the search generally does work. So you just need a title in the language files. Then again, it doesn't find some of the words from the category "Arc".[/p]
Whoops. I know it still needs a lot of work, but like I said, I'm a novice at this plugin business..
I also discovered late last night that my download file got all scrambled up and I have to get it fixed so someone can use the plugin.
LWC
Ok, so you can upload and replace files, but how do you know how to handle them? For example, images need the "img src" HTML tag and other media types need other tags.
sk716
Ok, so you can upload and replace files, but how do you know how to handle them? For example, images need the "img src" HTML tag and other media types need other tags.
I wrote the images tag into the display template.
sk716
Then while you let one upload any type of media file, you always use "img src" for it (or always use something else, if the template is manually changed).
Right.
If I new a better way to write it, I would have. I'm good with HTML and pretty weak on PHP.
sk716
I still have quite a lot of work to do on it, but it's serviceable for usage.
http://test.oddduck.net/easyfile/index.php?folder=2
Current demo here: http://simoneindex.com/catalog/index.php
LWC
Are there any changes backstage (especially in the hardcoding department)?
Also, in the main page it lists the item count and then their hits (in brackets), but it's very confusing. I only realized it's an item count + hits once I entered the categories and saw the same numbers but with the title "hits".
sk716
You've fixed the title in the advanced search, but I still can't search for words from the category "Arc".
Hmmm... thought I got that Advanced Search fixed. I'll have to look at it again, I may have lost the change when I was working on the image upload.
A few minor changes to make everything work smoother.
I keep intending to remove those entirely, I just don't like the way the numbers look beside the category titles.
I'm going to add automatic image resizing, but that's going to have to go on hold for a little while.
trampoline
I think this is just what I was trying to start writing today.
I want a kind of database where a site User (based on Group permissions)
can create a number of entries for sponsorship of Projects and people.
so
User x for instance might want to create 2 sponsorships
1/ University education for person in India
2/ Building a school in Tibet...
the records being searchable by any user on the system but only editable by root user and the creator ??
Obviously I would have to create some fields etc for our own use...
???
I really hope this will work !!!!
trampoline
got this error.... still not installed, tried twice....
Fri 20 Jul 15:15:43 2007 - Log File Cleared
Fri 20 Jul 15:16:34 2007 - Attempting to install the Catalog plugin
Fri 20 Jul 15:16:35 2007 - Attempting to create Catalog Admin group
Fri 20 Jul 15:16:35 2007 - 1062: Duplicate entry 'Catalog Admin' for key 2. SQL in question:
Fri 20 Jul 15:16:35 2007 - Dropping catalog table
Fri 20 Jul 15:16:35 2007 - ...success
Fri 20 Jul 15:16:35 2007 - Dropping catalog category table
Fri 20 Jul 15:16:35 2007 - ...success
Fri 20 Jul 15:16:35 2007 - Attempting to remove the Catalog Admin Group
Fri 20 Jul 15:16:35 2007 - ...success
Fri 20 Jul 15:16:35 2007 - Attempting to remove rights to catalog.edit from all groups
Fri 20 Jul 15:16:35 2007 - 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1. SQL in question: DELETE FROM gl_access WHERE acc_ft_id =
sk716
Could you use this to achieve the following...
I think this is just what I was trying to start writing today.
I want a kind of database where a site User (based on Group permissions)
can create a number of entries for sponsorship of Projects and people.
so
User x for instance might want to create 2 sponsorships
1/ University education for person in India
2/ Building a school in Tibet...
the records being searchable by any user on the system but only editable by root user and the creator ??
Obviously I would have to create some fields etc for our own use...
???
I really hope this will work !!!!
It should. You would need to make a few language changes, but otherwise I don't see why it wouldn't. I've still got a bug in the Advanced Search function that has been mentioned previously in this thread.
trampoline
You'll have to manually remove the duplicate entries in the SQL database. Was the first installation attempt interrupted?
No it was not interupted.
I'll try and remove these entries.
trampoline
Any code snipets or other pointer most appreciated.
trampoline
Mon 30 Jul 15:35:12 2007 - Attempting to install the Catalog plugin
Mon 30 Jul 15:35:12 2007 - Attempting to create Catalog Admin group
Mon 30 Jul 15:35:12 2007 - 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 's time to bring in new blood! Who will be asked to join Oracle in her all-new Bi' at line 1. SQL in question: INSERT INTO `gl_catalog` VALUES ('bop_100', 'demo', 'DC Comics', 'Birds of Prey', '100', 'Blood & Circuits Part 1: A Chance To Do Good', '11-15-2006', 'January 2007', 'Gail Simone and Tony Bedard', 'Nicola Scott and Paulo Sequiera', 'Doug Hazlewood and Robin Riggs', 'Hi-Fi', 'Jerry Ordway', 'Mike Carlin and Tom Palmer Jr.', 'bop_100.jpg', 'It/'s time to bring in new blood! Who will be asked to join Oracle in her all-new Birds Of Prey? Who will refuse, and who will fly the coop for good? Plus, a backup story following Black Canary and her new role in the DCU!', 'Acrata,
Big Barda,
Bulleteer,
Bumblebee,
Doctor Light 04 (Kimiyo Hoshi),
Firehawk,
Grace,
Hawkgirl 02 (Kendra Saunders),
Huntress (Helena Bertinelli),
Janissary,
Judomaster 03,
Lady Blackhawk 01 (Zinda Blake),
Madame Xanadu,
Manhunter 06 (Kate Spencer),
Oracle,
Phantom Lady 03 (Stormy Knight),
Power Girl,
Skyrocket,
Spy Smasher 02 (Katarina Armstrong),
Thorn 02 (Rose Forrest),
Wonder Woman', 13, '2007-07-02 19:00:03', 2, 23, 3, 2, 2, 2);
trampoline
I have a UNI Code SQL database and suspect the syntax of the dummy entries were not correct.
However I now have this error...
Mon 30 Jul 18:44:53 2007 - Log File Cleared
Mon 30 Jul 18:45:06 2007 - Attempting to install the Catalog plugin
Mon 30 Jul 18:45:06 2007 - Attempting to create Catalog Admin group
Mon 30 Jul 18:45:06 2007 - 1062: Duplicate entry 'Catalog Admin' for key 2. SQL in question:
Mon 30 Jul 18:45:06 2007 - Dropping catalog table
Mon 30 Jul 18:45:06 2007 - ...success
Mon 30 Jul 18:45:06 2007 - Dropping catalog category table
Mon 30 Jul 18:45:06 2007 - ...success
Mon 30 Jul 18:45:06 2007 - Attempting to remove the Catalog Admin Group
Mon 30 Jul 18:45:06 2007 - ...success
Mon 30 Jul 18:45:06 2007 - Attempting to remove rights to catalog.edit from all groups
Mon 30 Jul 18:45:06 2007 - 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1. SQL in question: DELETE FROM gl_access WHERE acc_ft_id =
What do I do about this ?
sk716
Okay, again, manually remove the duplicate entries in the SQL database. Then go into /plugins/sql/install.php file in the dummy entry and remove the offending apostrophe. " 'It/'s time to bring in new blood!
"
With the apostrophe and slash removed, it will install with no more problems.
trampoline
just removing the one character did it !
Thanks..
Page navigation
- Normal Topic
- Sticky Topic
- Locked Topic
- New Post
- Sticky Topic W/ New Post
- Locked Topic W/ New Post
- View Anonymous Posts
- Able to post
- Filtered HTML Allowed
- Censored Content