Subject: "quote of the day" coming soon to a blog near you

Posted on: 19/08/04 04:03pm
By: machinari

I'm developing my first plugin--should be awesome.</sarcasm> It is a "quote of the day" plugin for GL 1.3.9 that will support the following features:

*user -- add quote
*admin -- add ; edit ; delete ; batch add ; batch delete after search/list
*list/search quotes -- all ; by category ; by quoted ; by contributor
*stats -- no. of quotes; most quoted
*GL stuff like moderation, permissions, search

*will sport centerblock functionality for a random quote, and a random quote block will be included.

if you have any suggestions, let me know. It'll take me a week or two due to my busy schedule.

"quote of the day" coming soon to a blog near you

Posted on: 19/08/04 04:21pm
By: Anonymous

There is one quote of the day block for GL:
http://blog.smartgeek.co.uk/filemgmt/viewcat.php?cid=1

"quote of the day" coming soon to a blog near you

Posted on: 19/08/04 05:04pm
By: machinari

[QUOTE BY= tester] There is one quote of the day block for GL:
http://blog.smartgeek.co.uk/filemgmt/viewcat.php?cid=1[/QUOTE]
There is actually more than one, but I guess you don't need to download another one then.

"quote of the day" coming soon to a blog near you

Posted on: 19/08/04 08:09pm
By: mrjeff

Sounds great Machinari, can't wait to try it!

"quote of the day" coming soon to a blog near you

Posted on: 21/08/04 04:10pm
By: machinari

Response to inquiries:

Just wanted to make one thing clear: this plugin will not search other sites for a quote of the day, but rather relies on your own database, thus the add and delete functions, etc.

I currently have a db of over 600 philosophy and religion quotes and I'd like to use them on some of my sites. Thus the plugin.

As far as the quote being random, whether it is in the centerblock or the phpblock, the quote will change with every refresh or change of the page.

"quote of the day" coming soon to a blog near you

Posted on: 21/08/04 04:43pm
By: Dirk

[QUOTE BY= machinari] this plugin will not search other sites for a quote of the day, but rather relies on your own database, thus the add and delete functions, etc.[/QUOTE]
Cool, exactly what I'd like to have

[QUOTE BY= machinari] As far as the quote being random, whether it is in the centerblock or the phpblock, the quote will change with every refresh or change of the page.[/QUOTE]
That's certainly the easiest to implement. Also it would be nice if it were configurable to only change every n hours ...

bye, Dirk

"quote of the day" coming soon to a blog near you

Posted on: 21/08/04 11:58pm
By: Limynali

I just wanted to throw out there that I modified Tony's fortune plugin months ago and it will do some of what you wanted. You maintain your own quote database and can have a quote of the day and have the quote cached for x hours/days etc. It's nothing too fancy but it works for my simple needs.

"quote of the day" coming soon to a blog near you

Posted on: 23/08/04 10:05pm
By: newblogger

i'm interested in a quote of the day block or something of the sort, i would like to maintain my own quote database, i can't program my dvd so i guess i'll have to wait on one of you smart guys. thanks for all the help thus far

"quote of the day" coming soon to a blog near you

Posted on: 31/08/04 06:40pm
By: machinari

well it has been at least a week and a bit more. Thought I'd share my progress.

first- not as simple a project as I thought with all the stuff I want the plugin to be able to do.
*had to redesign the tables 12 times already.
*it installs
*centerblock works
*phpblock in lib-custom works
*add, batch add both work with all the relevant data being stored properly--finally. i'm not a big mysql guy.
*the plugin's index page displays a listing of all quotes and can be sorted from there.
*permissions work and are configurable. the default upon installation does not allow anon users to add quotes, but logged-in users can (1 at a time unless they are root).
*working on the search functions right now.
*the admin functions, delete, alter, etc., will be next.

it will take me longer than i thought because my classes begin next week, but will still be "plugin" away.

"quote of the day" coming soon to a blog near you

Posted on: 31/08/04 06:48pm
By: Blaine

good to hear about your progress. Just wanted to note that our phpblock function can be in your plugins functions.inc file which will make it an easier install.

"quote of the day" coming soon to a blog near you

Posted on: 02/09/04 01:23am
By: machinari


You can see the phpblock in action at alfiegeorge.com though it is only a block with a quote and byline in it. There are about 660 philosophy, religion, and misc quotes there and of course some from starwars. In a few days I should have the main display page with various sorting features working properly as well as the search form.

Just didn't want anyone getting worried that it wasn't workin' out.

"quote of the day" coming soon to a blog near you

Posted on: 02/09/04 01:33am
By: newblogger

... more like suicide.... looks good i refreshed it about 15 times, i like that it changes with each refresh, actually it looks great as does the rest of your site. is this using a admin defined quote database or is it pulling quotes from somewhere. if you're looking for someone else to test it.. i'm ready and willing. great work

"quote of the day" coming soon to a blog near you

Posted on: 02/09/04 02:18am
By: machinari

[QUOTE BY= newblogger]is this using a admin defined quote database or is it pulling quotes from somewhere[/QUOTE]Those quotes are all coming from my own database. add forms are available for those who have permission.[QUOTE BY= newblogger]if you're looking for someone else to test it.. i'm ready and willing[/QUOTE]as far as testing goes, gimme a week or so and i'll give you all another update and we'll go from there.[QUOTE BY= newblogger]actually it looks great as does the rest of your site[/QUOTE]if you like the theme, it is called alfiegeorge, after my son, and you can dl it from the downloads section on this site.

"quote of the day" coming soon to a blog near you

Posted on: 04/09/04 04:41am
By: machinari

You can see the main page in action here.
The search form is there but I haven't finished the backend.
To see the admin functions, you'll just have to wait to download it. a few more days anyway.
If you guys saw my code, you would laugh. it's bloated, dirty, and inconsistant. but it works.

don't mind the difficult read due to the background picture. you'll get over it.
oh, and you can't sort by "most quoted" cuz i forgot to uncomment some sql.

"quote of the day" coming soon to a blog near you

Posted on: 07/09/04 12:55am
By: machinari

search form works now, and i've made it a bit more display friendly using the block header and footer COM's.

for the most part, as far as the anon user is concerned, it works. sort by most quoted, gl search, what's new, i think are all i have left for the basic stuff.

the stats work well IMO tho the search page doesn't yet handle the url's. Admin stuff is almost done. loggedin users can add and admin can batch add. admin can edit contributors, quotes, persons quoted, categories. I haven't looked at the moderation functions yet.

take a look at it and tell me what you think so far. it's pretty basic. it's not meant to be much more than it is, but if you have suggestions, please let me know. visit the dailyquote plugin.

"quote of the day" coming soon to a blog near you

Posted on: 07/09/04 01:49pm
By: ppmnt


loggedin users can add and admin can batch add.


One cool thing would be to have permissions in the admin section that allow us to customize that. For example, maybe allow all visitors to add.

Even cooler would be to have this go through the submission process like stories and links can.

"quote of the day" coming soon to a blog near you

Posted on: 07/09/04 04:37pm
By: machinari

[QUOTE BY= ppmnt]
One cool thing would be to have permissions in the admin section that allow us to customize that. For example, maybe allow all visitors to add. [/QUOTE]already done. i just listed how it is upon default install.[QUOTE BY= ppmnt]Even cooler would be to have this go through the submission process like stories and links can.[/QUOTE]yup, the moderation functions are being worked on.

"quote of the day" coming soon to a blog near you

Posted on: 08/09/04 04:37pm
By: ppmnt

Very cool, good stuff!

"quote of the day" coming soon to a blog near you

Posted on: 10/09/04 01:16am
By: newblogger

Looks awesome. You know I'm a relative newbie and your stuff looks great. I've been awaiting the arrival of the plug-in for a while now. Keep up the great work. You are a real inspiration i went out and bought php and mysql for dummies as a reference point, hopefully i will gain some knowledge and as my expierence grows i can create some cool stuff.

keep rockin'

"quote of the day" coming soon to a blog near you

Posted on: 13/09/04 02:37am
By: machinari

just finishing of the config backend tonight. I'll clean it up and release a prerelease thurs or fri.. I have a busy week so it'll have to wait till then...

In the meantime, you may dl some few pics of the plugin that I snapped just to keep your whistle wet. half Meg and you can get them here

"quote of the day" coming soon to a blog near you

Posted on: 20/09/04 01:55am
By: machinari


The dailyquote plugin for geeklog is ready for testing. It is fully functional though not all the features that I intend to add have been added yet. Included are 50 quotes to use for testing. The documentation isn't done. like I say, it is for testing.

Let me know what you think and any bugs that you find etc. Let me know if you think it is useful or not. It serves my purpose anyway.

find it here. This file will be replaced by version 1.0 after I've received a bit of feedback. thanks.

error message???

Posted on: 22/09/04 09:44pm
By: newblogger

run trying to run the install.php i get this error

Fatal error: Cannot redeclare random_quote() (previously declared in C:Inetpubwwwrootwmwdiarynewblogsystemlib-custom.php:363) in C:Inetpubwwwrootwmwdiarynewblogpluginsdailyquotefunctions.inc on line 619

"quote of the day" coming soon to a blog near you

Posted on: 22/09/04 11:56pm
By: hidden

[QUOTE BY= newblogger] run trying to run the install.php i get this error

Fatal error: Cannot redeclare random_quote() (previously declared in C:Inetpubwwwrootwmwdiarynewblogsystemlib-custom.php:363) in C:Inetpubwwwrootwmwdiarynewblogpluginsdailyquotefunctions.inc on line 619[/QUOTE]

seems you have two functions named random_quote.

"quote of the day" coming soon to a blog near you

Posted on: 23/09/04 12:09am
By: machinari

[QUOTE}
seems you have two functions named random_quote.[/QUOTE]
yes, yes... you'll have to check your lib-custom.php for a function named random_quote().

however, newblogger, you make a point. my functions should all be prefixed somehow with "dq" or something of that nature to prevent this type of problem from occuring. thank you and I will fix that.

"quote of the day" coming soon to a blog near you

Posted on: 23/09/04 11:25am
By: newblogger

OK I have installed the plugin and have added a few quotes manually one at a time, they seem to be working fine. My next question is, what do i have to do to be able to get the quote to show-up in a php-block on the side of my page rather than the centerblock?

"quote of the day" coming soon to a blog near you

Posted on: 23/09/04 01:04pm
By: machinari

you will need to create a new block -- a php block rather than a normal or portal block. The function that you will use is contained in the functions.inc file, and as Blaine suggested earlier, there is no need to move it to your lib-custom.php file. It is called "phpblock_random_quote()." enter that name, without the parentheses, into the PHP Block Options box. It is able to function at the same time as your centerblock and will display the same quote if one is cached, otherwise it will be random, obviously.
this will be covered in the documentation once i write it. thanks.

"quote of the day" coming soon to a blog near you

Posted on: 23/09/04 11:48pm
By: machinari

First: I've decided not to make use of the moderation functions developed for the plugin API. Rather, moderation will be accessible from the dailyquote "manage quotes" screen. Any Comments?

Second: Any comments yet? What do you think of the plugin's orginization, screens, options, usefulness, etc.?

"quote of the day" coming soon to a blog near you

Posted on: 24/09/04 11:10am
By: newblogger

thank you, works like a charm. the plug-in works great for me, this is exactly what i've been looking for. it is actually more than i need. great work. you can see it working
here

"quote of the day" coming soon to a blog near you

Posted on: 28/09/04 03:15pm
By: ppmnt

Hi there,

Just getting started with it, installed it and tried a couple of things.

I'm logged in as admin and can add single quotes fine, but when I click on Batch Add I get:

Access Denied
Only Authorized Users have Access to this Page. Your user name and IP have been recorded.

When I set "allow members to batch add" it works fine. I should add that my user is not the user "admin", but actually a new user that is a member of the Root group (and all other groups). Could it be that you're checking to see if i'm the actual admin user, instead of a admin user?

"quote of the day" coming soon to a blog near you

Posted on: 28/09/04 06:47pm
By: machinari

the way the prerelease is set up, only the root user, UID 2, can access that page if the batch add is turned off for members. If batch add is turned on for members, then all but anonymous users should be able to access that page.

This has been changed, however, in CVS... I've always wanted to say that. Access is now not limited to the one original root user, but to any belonging to the group dailyquote.edit, which root users are members of by default. This allows all root users, as far as I know so far, access, as well as those who have been added to a group granted the dailyquote.edit priveledge.

I've also done the moderation page and a few other things, bug fixes included.

"quote of the day" coming soon to a blog near you

Posted on: 28/09/04 07:55pm
By: machinari

scratch everything i just said. i was confused and was talking about a different page.

what you described is exactly how it is supposed to work. only the root user can batch add unless batch add is turned on for members. I can change this to group. no problem.

"quote of the day" coming soon to a blog near you

Posted on: 28/09/04 10:00pm
By: ppmnt

Cool... Yeah, I think it would be good to use the group for all security checks to avoid confusion. The root group has all dailyquote rights, so a member of the root group should be able to do everything, including batch add.

I'm sure I'm not the only one who doesn't sue the 'admin' user for everything, but instead gave their own user admin rights. That way posts and news are form me, not from 'admin'.

"quote of the day" coming soon to a blog near you

Posted on: 28/09/04 10:19pm
By: ppmnt

Alright, I've got it all set up now, and it looks great! Check it out here: - discobug.com - (the block is on the lower right)

You can see that I changed some minor things: I'm using text links because your images didn't really match my site's colors. One suggestion might be to have that be an option in the administration screen. That way you wouldn't need to provide more images, and others could choose to make their own or just use text links.

Also, I added the "add" link to the block. One of the things I wanted to do is allow all visitors to submit quotes, which brings me to this:

[QUOTE BY= machinari]
I've decided not to make use of the moderation functions developed for the plugin API. Rather, moderation will be accessible from the dailyquote "manage quotes" screen. Any Comments?
[/QUOTE]

I assume by that you mean submitted quotes wouldn't go through the "Submissions" lifecycle, allowing an admin or privilged user to approve them before they show up on the site? While this may be OK if you don't allow anonymous users to add quotes, but doing so would be too risky due to automated sex posts and the like. How hard would it be to have it go through submissions like news stories and links? If that as possible, I'd probably use the centerblock on the home page.

You asked for comments on layout and functionality -- I think it turned out great! It's organized well and formatted nicely. Functionality is great, the only things I'd like to see are above.

Great work!

"quote of the day" coming soon to a blog near you

Posted on: 28/09/04 11:45pm
By: machinari

[QUOTE BY= ppmnt]I'm using text links because your images didn't really match my site's colors.[/QUOTE]Yes, I've decided that would be a better idea as well, in order to make the plugin more readily portable. If the user wishes to use images, as you suggest, they can make them to suit their site.[QUOTE BY= ppmnt]Also, I added the "add" link to the block.[/QUOTE]Looks very nice.[QUOTE BY= ppmnt]I assume by that you mean submitted quotes wouldn't go through the "Submissions" lifecycle, allowing an admin or privilged user to approve them before they show up on the site?[/QUOTE]Actually, all that I meant was that I wouldn't use the GL api's to accomplish moderation. Moderation would still occur, however. I have it all set up and it works well with the option to turn on or off the queue. the moderation link will appear in the link row at the top for those having edit rights, and on the manage page.

This weekend I'll upload a newer version with many fixes and the new stuff. I've found some database bugs that I'm surprised you all haven't found yet. Hmmm... I guess I should write an update script because I've added to the database a bit.

and hey, ppmnt, thanks for the feedback.

I don't think a preview screen is necessary, do you?

"quote of the day" coming soon to a blog near you

Posted on: 29/09/04 01:15am
By: ppmnt

[QUOTE BY= machinari] Actually, all that I meant was that I wouldn't use the GL api's to accomplish moderation. Moderation would still occur, however. I have it all set up and it works well with the option to turn on or off the queue. the moderation link will appear in the link row at the top for those having edit rights, and on the manage page.[/QUOTE]

Oh, I see, I'm sorry I posted before testing submitting a quote as an anonymous user. I just tried it and saw the message that it was in the queue.

However, how do I approve the quote now? I went to the manage screen and don't see it there. I tried searching for it, but can't find it. I also tried logging in as 'admin' instead of my admin user, no luck. And since it's not under Submissions, I'm not sure where else to look. What am I missing?

[QUOTE BY= machinari] I don't think a preview screen is necessary, do you?[/QUOTE]

Nah, I don't think so. Users are submitting mostly one-liners that they probably pasted form somewhere else, so I would hope they wouldn't need to preview it. ;-)

"quote of the day" coming soon to a blog near you

Posted on: 29/09/04 03:21am
By: machinari

[QUOTE BY= ppmnt]how do I approve the quote now?[/QUOTE]
ah yes... i threw a bit about that in the incredibly limited documentation (i think). the submission process was set up to be moderated before the moderation page was complete. your queued quotes are in the db, they're just waiting on the moderation page to view them... sorry.

i'm teaching thru thursday afternoon..after that i'll get the updated package online by thurs night/fri morning.

"quote of the day" coming soon to a blog near you

Posted on: 29/09/04 12:59pm
By: ppmnt

Aaah, I see it now. I take it status=1 is approved, status=0 is the queue. I just updated it in mysql to status 1 and it's showing up great!

However, I found a little bug that way: When an anonymous user submits a quote (UID=1 in gl_dailyquote_quotes) the "Submitted by:" field is empty.

It's just a test quote, but I left it up to show you: _my quote index_, just search for the word "test".

[QUOTE BY= machinari] ah yes... i threw a bit about that in the incredibly limited documentation (i think)[/QUOTE]
Documentation? My docs directory was empty... (Although I didn't expect documentation yet)

"quote of the day" coming soon to a blog near you

Posted on: 29/09/04 02:36pm
By: machinari

[QUOTE BY= ppmnt]When an anonymous user submits a quote... the "Submitted by:" field is empty.[/QUOTE]Yes, I noticed that as well. I overlooked it in the language file--oops. The updated version properly supplies "Anonymous" as the contributor.

"quote of the day" coming soon to a blog near you

Posted on: 29/09/04 04:36pm
By: ppmnt

I've got one more for you. This is what I get in error.log when trying to delete a quote:


Wed Sep 29 13:34:40 2004 - 1064: You have an error in your SQL syntax near 'gl_dailyquote_quotes, gl_dailyquote_lookup FROM gl_dailyquote_quotes, gl_dailyqu' at line 1. SQL in question: DELETE gl_dailyquote_quotes, gl_dailyquote_lookup FROM gl_dailyquote_quotes, gl_dailyquote_lookup WHERE gl_dailyquote_quotes.ID=11 AND 11=gl_dailyquote_lookup.QID


Looks like you're listing the table names twice...

"quote of the day" coming soon to a blog near you

Posted on: 29/09/04 06:04pm
By: ppmnt

Just thought I'd let you know that I'm using it as my centerblock now, the first thing you see on my homepage! I know you're still working on it, but for now I have it tweaked the way I want it, and I'll just have to manually updates quotes added instead of using the manage screen.

Looks really nice, _check _it_out_

"quote of the day" coming soon to a blog near you

Posted on: 29/09/04 07:00pm
By: machinari

[QUOTE BY= ppmnt]Looks like you're listing the table names twice...[/QUOTE]Yes, I am, but that's not the problem.
Notice where the error statement begins: between the DELETE and the first table. You may, somehow, have an extra space between "DELETE" and "gl_daily...." (probably not the problem however)

It may be a mySQL version error (more likely). this is a multitable delete statement and requires at least mySQL 4.0.0. You'll have to check your mySQL version for compatability.

your next option requires a bit of memory. did you update the status on this quote without also updating the status on any category that was created along with it? I doubt this is the problem, but we'll see. Is this the first delete you've attempted? any successes prior to this?

"quote of the day" coming soon to a blog near you

Posted on: 29/09/04 07:16pm
By: ppmnt

[QUOTE BY= machinari]
It may be a mySQL version error (more likely). this is a multitable delete statement and requires at least mySQL 4.0.0. You'll have to check your mySQL version for compatability.
[/QUOTE]

I see... I wasn't aware of the multitable syntax, I was thinking of standard SQL (i.e. "delete from table_name where etc"). You're right, my mySQL version is 3.23.56, so this will not work for me. I can update my own box where I test my site, but this is a hosted server, and I'm afraid other folks might run into this as well...

I ended up manually deleting the quote form both tables.

Just FYI: no new category was created with the anonymous quote.

"quote of the day" coming soon to a blog near you

Posted on: 29/09/04 07:37pm
By: machinari

[QUOTE BY= ppmnt] this is a hosted server, and I'm afraid other folks might run into this as well...[/QUOTE]
You might try requesting that your host updates their very antiquated version of mySQL.

There are other statements here and there that also require more up to date versions of the mySQL server as well as PHP.

I don't know that I want to go and make it all backward compatable--I'm not that good and the plugin is already more bulky than it should be.
Any suggestions?

"quote of the day" coming soon to a blog near you

Posted on: 30/09/04 12:57pm
By: ppmnt

Couple of ways:

You could change sql statements to be standard SQL syntax. That would make sure it'll work for everybody. MySQL 4 is significantly different from MySQL 3 (kind of like Apache 1.3 -> 2.0), so many hosts have not udpated yet (same with Apache). In the Geeklog documentation they recommend MySQL 3.23 or 4, so it would be nice for your plugin, as for all plugins, to work with all those versions as well. It would definitely give your plugin more visibility and it could easily be one of those common, almost standard plugins.

So that would be my recommendation. I wouldn't bother trying to check for the version and using different SQL each time, just use the standard syntax that'll work with both.

The other option would be to put in your readme or documentation that MySQL 4.0 is a requirement. That would probably restrict the audience though. Many people don't have control over what's installed on web servers, and plenty folks won't even know how to check it... They'd probably just like to know that if Geeklog works for them then plugins will work too...

I know that's probably not what you wanted to hear as it would require some re-writing and testing... As for me, I can handle it. If you decide against changing it I'll probably just write some shell scripts to deal with deletes, or I'll just have to tweak your code (which I'm trying to avoid though).


"quote of the day" coming soon to a blog near you

Posted on: 01/10/04 03:01pm
By: machinari

After much thought, I've decided not to support mySQL 3.23. My reasons:
the short version: mySQL 3.23 is five years old.
the long version: in order to support the table design necessary for the dailyquote features, first and foremost, multiple categories, functions such as delete and update need to, at the very least, be able to reference multiple tables. This leaves behind mySQL versions prior to 4.0.4, which is already 2 years old. I've had to make concessions, not big ones, in order to support 4.0.

My apologies to those of you who are stuck with lazy hosts. Feel free to flame me. Better yet, inform me of ways that these issues may be resolved peacefully.

"quote of the day" coming soon to a blog near you

Posted on: 01/10/04 05:35pm
By: ppmnt

[QUOTE BY= machinari]
My apologies to those of you who are stuck with lazy hosts. Feel free to flame me. Better yet, inform me of ways that these issues may be resolved peacefully.
[/QUOTE]

Like I said, I myself will just write something myself if you don't support MySQL pre-4. Regarding suggestions for "peaceful resolution" (I was never planning to flame you) though, one-to-many relationships have been around for a long time, so one quote having several categories is possible to do with standard SQL (enterprise DB systems like Oracle still don't have multi-table deletes. Well, I can't speak for Oracle 9i).

It would just have to be one SQL statement per table, that's all...

[ ... update ... ]

In fact, I just modified my manage.php so it'll work for me. I just changed the del_quote function from:
function del_quote($qid){
    global $_DQ_TABLES, $LANG_DAILYQUOTE;

    $sql = "DELETE {$_DQ_TABLES['dailyquote_quotes']}, {$_DQ_TABLES['dailyquote_lookup']}";
    $sql .= " FROM {$_DQ_TABLES['dailyquote_quotes']}, {$_DQ_TABLES['dailyquote_lookup']}";
    $sql .= " WHERE {$_DQ_TABLES['dailyquote_quotes']}.ID=$qid";
    $sql .= " AND $qid={$_DQ_TABLES['dailyquote_lookup']}.QID";

    if (!DB_query($sql)){
        $retval = "<p align="center" style="font-weight: bold; color: red;">" . $LANG_DAILYQUOTE['delerror'] . "</p>";
        COM_errorLog("An error occured while deleting a quotation",1);
    } else {
        $retval = "<p align="center" style="font-weight: bold; color: red;">" . $LANG_DAILYQUOTE['delsuccess'] . "</p>";
        COM_errorLog("Deleted Quotation and related data.  Q.ID = $qid",1);
    }

    return $retval;
}



to:
function del_quote($qid){
    global $_DQ_TABLES, $LANG_DAILYQUOTE;

    // 20041001 make delete MySQL 3 compatible
    $del_error=0;

    $sql = "DELETE FROM {$_DQ_TABLES['dailyquote_quotes']} WHERE ID=$qid";

    if (!DB_query($sql)){
        $del_error=1;
    } else {
        // continue only if first SQL was successful
        $sql2 = "DELETE FROM {$_DQ_TABLES['dailyquote_lookup']} WHERE QID=$qid";
        if (!DB_query($sql2)){
            $del_error=1;
        }
    }

    if ($db_error == 0){
        $retval = "<p align="center" style="font-weight: bold; color: red;">" . $LANG_DAILYQUOTE['delsuccess'] . "</p>";
        COM_errorLog("Deleted Quotation and related data.  Q.ID = $qid",1);
    } else {
        $retval = "<p align="center" style="font-weight: bold; color: red;">" . $LANG_DAILYQUOTE['delerror'] . "</p>";
        COM_errorLog("An error occured while deleting a quotation",1);
    }

    return $retval;
}



It's only a few more lines and works fine, tested with MySQL 3.23.56

"quote of the day" coming soon to a blog near you

Posted on: 01/10/04 06:22pm
By: machinari

that's all good.. and I am actually talking about a many to many relationship. however, I did the same thing, but the update function is a bit more involved. Have you used the update yet? does it work as is? That's the one where I stopped looking for a solution. I need to reference more than one table even if I only update one table at a time. Take a look at that one and let me know what you think.

anyway, presently, you'll have to deal with another multitable delete in the update function if you remove a category from a quote.

"quote of the day" coming soon to a blog near you

Posted on: 01/10/04 06:42pm
By: machinari

notice that if a quotation does belong to more than one category, only one is displayed on the index and search page. -this has been fixed. multiple cats now display.
-a few spelling errors fixed.
-language file is cleaned up a bit.
-moderation page has been added with options on the config page.
-images for links have been commented out leaving the alt text. style as you please.
-I bought a lawn mower!

question: should i throw a link per quote on the index page for those with edit rights that shoots the person and the particular quote right to the manage page? or would that clutter up the listing?

"quote of the day" coming soon to a blog near you

Posted on: 01/10/04 06:47pm
By: ppmnt

I see. I hadn't messed with update yet and didn't know where else you might have multi-table statements.

Just taking a quick look I just noticed the gl_dailyquote_submitter table. I'm not sure if that's even needed, couldn't you just use the GL user table? You use the same uid, can look up the name, and anonymous submitters don't get to enter a name anyway.

The only other thing in that table is the IP address, but that would not necessarily be unique. The same user may want to submit/update quotes from different computers. This doesn't matter if you only use it for the error.log, but since you have it in the DB I'm assuming that maybe you're planning to use it at a later time, e.g. have it be visible to the admin user when viewing quotes. In that case the IP should probably be stored with the quote, not the user.

As for the rest of the update function, I'll have to look at it later, running out of time right now. But I'll think about it.

"quote of the day" coming soon to a blog near you

Posted on: 01/10/04 06:52pm
By: ppmnt

By the way, I just noticed that if you have a quote that's a member of several categories, then it shows up that many times on the index page. So for example my test quotes is showing up 4 times in a row right now...

"quote of the day" coming soon to a blog near you

Posted on: 01/10/04 07:13pm
By: machinari

yes, that was fixed with the display of multiple categories. just a matter of separating the category select from the the distinct quote select.

the idea behind the submitter table was to list only those that actually contributed quotes, not all members of the site. much like the forum's member list or the author exclusion list in the gl account prefs. there is a drop down here and there with the user list, eg, to sort by contributor i believe, and if you want to change contributor on the manage or moderation page.

re the IP: it was for the admin like you say, but since there is a submission queue it is not necessary and will be taken out. thanks for reminding me.

and by the way, I appreciate you taking the time to troubleshoot this with me. It helps alot.

"quote of the day" coming soon to a blog near you

Posted on: 01/10/04 07:58pm
By: Blaine

Just as a note: You won't find any MySQL 4.0+ syntax in Geeklog. MySQL 3.23 is still a very popular database and there were multiple updates in 2003 with the most recent release 3.23.58 just over a year ago.

You often find ISP's running very old releases of PHP and MySQL and then again, you will find ISP's that feel they must run the latest. Both cases make it hard to support these apps and contributed projects. And let's not get started on browsers

Needless to say - I don't want to suggest it should or not support MySQL 3.23. It takes a lot of time to support these plugins in the long-run so do what you feel is best.

"quote of the day" coming soon to a blog near you

Posted on: 02/10/04 03:59am
By: Dirk

[QUOTE BY= Blaine] You often find ISP's running very old releases of PHP and MySQL and then again, you will find ISP's that feel they must run the latest.[/QUOTE]
Just to chime in on that: My hosting service is a bit on the conservative side and they feel that MySQL 4 isn't ready for production environments yet. So for my own sites, I'm stuck with MySQL 3.23.xx for the foreseeable future.

I'm by no means a database expert, but since my hosting service has a reputation of being reliable (and I pay them for that ...), I'm going to trust them on that.

geeklog.net is currently running on MySQL 4.0.17, but then again we do have occasional hickups here and I have to wonder where they come from ...

bye, Dirk

"quote of the day" coming soon to a blog near you

Posted on: 02/10/04 02:09pm
By: ppmnt

[QUOTE BY= machinari]the idea behind the submitter table was to list only those that actually contributed quotes, not all members of the site. much like the forum's member list or the author exclusion list in the gl account prefs. there is a drop down here and there with the user list, eg, to sort by contributor i believe, and if you want to change contributor on the manage or moderation page.[/QUOTE]

Machinari,

You can still achieve that without the extra table, by just storing the UID with the quote. Then, when you need to populate a list of just users who submitted quotes, you can do something like this:

select username from gl_users where uid in (select distinct uid from gl_dailyquote_quotes);

That may be a little more flexible in the future.

[QUOTE BY= machinari]and by the way, I appreciate you taking the time to troubleshoot this with me. It helps alot.[/QUOTE]

No problem, I'm glad I can help some.


"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 05:17am
By: machinari

released dailyquote version 0.9.1 for testing. download it here

updated config; added moderation page and submission queue; fixed a number of reported bugs; now displays multiple categories properly; database changes. I have not provided an update script so if you have added many quotes that are not in the sample files provided, back them up because you'll have to run the install script again. In otherwords, if you don't know what you're doing, wait for version 1.0.

next version: will be mySQL 3.23 compatable; will drop the contributors table making more use of GL's user tables; documentation.
I have a line on how to work the syntax in my update, and approve functions in order to make them 3.23 compatable, but I thought that I would release this version before I make all those changes so that I could get advice from any that care to give it.

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 12:55pm
By: shetzel

First, let me say thanks. I used to have a random quote generator running on my old site, but I gave up on it when I migrated to Geeklog. It's the most requested feature among my users, so thanks very much for taking the initiative. You're saving me a ton of work, so the least I can do is help you debug.

1) About 0.9.1 .... what happened to functions.inc? It's not included in the packaging. We kinda need it.

2) What's the purpose of the categories? Will there be a user inclusion/exclusion feature in the future? Where a user could "turn off" certain categories from appearing on his/her page? Just wondering.

3) What's up with your package timestamps? The filedates are Dec 31, 1969 across the board. Not a big deal, but he Linux version of tar that I use complains about each and every file.

Thanks again, I got 0.9 last night and I'll be working with you until you get 1.0 out the door. For the moment, I'll start digging deeper.

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 01:01pm
By: ppmnt

Machinari,

That's great news about your planned features for 1.0!

So I tried installing 0.9.1. It seems that functions.inc is missing from the tar ball.

I copied the old functions.inc from 0.9 into the 0.9.1 directory. Then, during the install, the following happens:

It creates all tables successfully, then:
[ ... ]
Sun Oct 3 09:51:09 2004 - Success - Created table
Sun Oct 3 09:51:09 2004 - Inserting default data into dailyquote_settings table
Sun Oct 3 09:51:09 2004 - 1136: Column count doesn't match value count at row 1. SQL in question:
Sun Oct 3 09:51:09 2004 - Error inserting default data into dailyquote_settings table
Sun Oct 3 09:51:09 2004 - Attempting to unregister the Daily Quote plugin from Geeklog
[ ... ]
Following this are successful uninstall messages (removing tables, etc)

Thoughts?

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 01:11pm
By: machinari

oh crap! sorry folks. my bad for the missing file. and yes I know exactly where that error is.. i'll fix it right now. look for 0.9.1.1 in an hour or so...

done. get it here

oh and about those timestamps.. who knows.. wintarball screwed them up. thanks for noticing. i'll put up a .rar instead

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 01:59pm
By: ppmnt

[QUOTE BY= machinari] oh and about those timestamps.. who knows.. wintarball screwed them up. thanks for noticing. i'll put up a .rar instead[/QUOTE]

Er, don't mean to be a pain, but rar complicates things for some of us. For me for example it would add the step of downloading it to my Windows box, unrarring, then tarring it back up with cygwin and gzipping it, then uploading to my host... Whereas when you were using .tgz or tar.gz or even zip I can just wget it straight to my host. I think generally .tgz or .zip are more compatible with all hosts...

Personally, I don't care about time stamps, but one tip, if you want unix/linux type capabilities on your windows box, I highly recommend _cygwin_

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 02:09pm
By: machinari

[QUOTE BY= shetzel] What's the purpose of the categories? Will there be a user inclusion/exclusion feature in the future? Where a user could "turn off" certain categories from appearing on his/her page?[/QUOTE]
I have never actually thought of any other purpose for categories beyond simply displaying related quotations together. If you have ideas for further uses of the categories, I'm glad to hear them. Your idea sounds good and I think it would be easy to implement. I'll put it on my notepad.

this brings me to a known bug in 0.9.1.1: in order to display multiple categoris properly when they belong to a singular quote, I've had to separate one select into two selects. This means that you will not be able to sort by category for the time being. You'll get errors if you try. That's first on my list for later today.

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 02:18pm
By: machinari

[QUOTE BY= ppmnt]don't mean to be a pain[/QUOTE]you're not a pain.. these are things that I need to know.
oh, and I threw up the zip file per your advice.

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 02:25pm
By: ppmnt

So I got 0.9.1.1 installed, and of course the first thing I tried was deleting a quote, since I noticed in manage.php that you already changed it.

Sun Oct 3 11:20:23 2004 - 1064: You have an error in your SQL syntax near 'gl_dailyquote_quotes WHERE gl_dailyquote_quotes.ID=35 LIMIT 1' at line 1. SQL in question: DELETE gl_dailyquote_quotes WHERE gl_dailyquote_quotes.ID=35 LIMIT 1

Seems you're missing the FROM (i.e. DELETE FROM table_name WHERE etc). I added it in manage.php in line 350 and 357 and it works fine.

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 02:27pm
By: ppmnt

[QUOTE BY= machinari] oh, and I threw up the zip file per your advice.[/QUOTE]
Very cool. Thanks.

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 02:46pm
By: machinari

[QUOTE BY= ppmnt]Seems you're missing the FROM [/QUOTE]
how very thorough of me, eh? sorry.

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 02:49pm
By: ppmnt

Alright... Just tried approving a quote in the queue, which of course failed. I figure I won't tell you anymore when something doesn't work for me because of the MySQL version, you know better than me where you are doing multi-table updates or deletes. However, let me know if you need help looking at some of the SQL.

I do have one suggestion though: How about including the "Add Quote" link in the block and/or centerblock, if the user has enough rights to add quotes? Something like I did with my center block, which is now back up: _my_site_. If you don't think everyone would like that it could also be an optional setting.

Obviously it was easy for me to include it... Since I am allowing anonymous users to submit quotes I just added it to centerblock.thtml without any logic of checking for necessary rights (I know, I know, not good practice). It would be a little more work for you, I just thought I'd suggest it.

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 02:51pm
By: ppmnt

[QUOTE BY= machinari] [QUOTE BY= ppmnt]Seems you're missing the FROM [/QUOTE]
how very thorough of me, eh? sorry.[/QUOTE]

Every developer needs a good QA team! You can't find everything.

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 03:31pm
By: shetzel

Zips are fine. I can do zips, as I think most Windows and Linux users can. What are most packages in, anyway? I don't even know for cross-platform stuff like this.

And thanks for getting the functions.inc file included for us. I'll be at it in a bit, after a break. Exciting stuff.

As for features to think about (worth about ):
1) The category stuff. I imagine something that would work like the topic system for the news posts. By default, all users can see any quote. However, some categories could be "turned off", either by the admin or by individual users in their Preferences screen. I am not implying that people would also be able to switch off quotes based on the author or the submitter (too much detail).

1b) As an example, when I migrate my existing quote list, I'll have mostly movie quotes, TV quotes, and a vast list of "personal" quotes, since my site is used primarily by people I know in person. When someone says something particularly funny or stupid, someone else usually submits that as a quote. Perhaps those quotes are all some users will want to see. Other users, who DON'T know us personally, might wish to skip those.

1c) It could be useful for the admin to do global category enable/disable, too. For example, I have a category of quotes that arose from specific events, say yearly St. Patrick's parties, where those quotes may seem ... out of place in September. I'd enable them only in March, for instance. I realize this is getting a bit theatrical, but I try to dress up the site before holidays like Google does. I change the title, put up bunting, etc, etc. I used to swap the quote datafile. Limiting the site to Chirstmas or patriotic (July 4th) categories for a couple weeks would not be beyond my uses. Feel free to ignore it, though.

2) I'd like the ability to turn on/off a "Submit" link like ppmnt suggested. Many people will certainly find it useful; however, I usually just build links like that into my title menu bar. It's where I've trained my users to look for that sort of thing.

3) I'd like the ability to display the submitter (as an option), so long as it's not the admin or anonymous. I find people are more willing to submit things to the database when they think that they will get public credit for them. I'll probably hack it into mine, sooner or later, if you don't.

3b) I still need to examine your display code. Once I do, I'll know more about what I'm asking you for. It may be simple or messy.

4) Option to turn off the title bar ("Quote of the Day") in the case of a center block placement, above the featured story. That's where I'm putting it on my site, where it really doesn't need any explaination. I can probably do it myself with a couple of deleted/modified lines, but it might be something others want.

That's all I got for now, believe me, I'll have more. Obviously, you'll be more concerned with base functionality right now. Just tell me to stop if you wish to fry those other fish before talking about these guppies. However, don't underestimate the demand your plugin will have in the community. I think you'll be pleasantly surprised to find out how many people will enjoy it. And from myself, thanks again.

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 04:50pm
By: machinari

[QUOTE BY= ppmnt]How about including the "Add Quote" link in the block and/or centerblock, if the user has enough rights to add quotes?[/QUOTE]there is already a link in the user functions for logged in members to add a quote if they have rights. the only place where there is not a link on the main page is, as you say, if you are an anonymous user. sooooo.... ok, I just added it to my list. It will be an option, but only when anon add is turned on and will appear in centerblock and php_block.
[QUOTE BY= shetzel]I'd like the ability to display the submitter (as an option)[/QUOTE]the submitter is already displayed per quote in dailyquote/index.php. I realize you are suggesting to display it in the centerblock, however, I tend to go with the uncluttered look, which is why I didn't include links there either (at first anyway). How bout this: I'll add the code, but I'll leave the variable commented out in the template file. If you want the contributor's name all you have to do is uncomment said variable. I'm going to hold off on making it an option just for now.[QUOTE BY= shetzel]By default, all users can see any quote. However, some categories could be "turned off", either by the admin or by individual users in their Preferences screen.[/QUOTE]This is an excellent idea for some of the reasons you stated. however, I'm going to put it on the back burner for now until the rest is operating smoothly. As you may have noticed, I only work on this on the weekends so it may be a couple.
[QUOTE BY=shetzel] Option to turn off the title bar ("Quote of the Day") in the case of a center block placement, above the featured story[/QUOTE]This is a function of GeekLog's plugin API in its handling of the centerblock. I cant help you there.

"quote of the day" coming soon to a blog near you

Posted on: 03/10/04 05:38pm
By: shetzel

by: machinari] I'm going to put it on the back burner for now until the rest is operating smoothly. As you may have noticed, I only work on this on the weekends so it may be a couple.

I agree. The categories thing is something I want/need, but certainly not as important as getting the fundamentals done and smooth. So long as users are careful about adding quotes correctly, that funcionality can be "switched on" anytime. The data will be ready.

by: machinari] I realize you are suggesting to display it in the centerblock, however, I tend to go with the uncluttered look, which is why I didn't include links there either (at first anyway).

I tend to favor an uncluttered interface as well, so I appreciate your position on the contributor's name. But thanks for your compromise.

by: machinari] This is a function of GeekLog's plugin API in its handling of the centerblock. I cant help you there.

Yeah, I just found out that Geeklog requires the block header. I'll see if I can do anything for myself. It'll be a hack to get what I want, so nothing you'll be able to use.

'Preciate your time.

"quote of the day" coming soon to a blog near you

Posted on: 05/10/04 10:16pm
By: machinari

find version 0.9.2 here.

This is the latest beta release. This should now be mySQL 3.23 compatable--this was the main issue for this release and needs testing especially on the moderation page (approve, delete, and update functions). This was actually easier than I thought it would be--I was making things more complicated than they needed to be.

A number of other things were tweaked as well. For example, there is now an option to display an add link in the centerblock for anon users when they have permission to add. Limiting/sorting by category also works properly now. The database tables have undergone a few more changes. Again, I have not provided an update script so if you have added many quotes that are not in the sample files provided, back them up because you'll have to run the install script again. In otherwords, if you don't know what you're doing, wait for version 1.0. Remember, this is still beta--released for testing purposes.

next version: category titles when limiting/searching by category; ability to turn on/off categories(admin only--for now); cleaner code; a few other tweaks; documentation.

Check it out and report any errors/bugs please. Also if you think of features you would like to see in this plugin, let me know, but remember, it is only a quote of the day type plugin so don't go crazy.

I should mention one bug/oddity that I haven't been able to track down or reproduce--that may be a good thing, maybe a bad thing. I searched for a single letter without limitation in my 700 quotes. returned a result set of just about all of them, but my CPU raced out of control. I thought it was mySQL in a loop, but shut it down and shut the web server down and still the cpu was going full throtle. finally had to shut the system down. Dunno what it was so just wanted you to be aware and maybe you could shed some light. maybe it's just my system needed a break.

"quote of the day" coming soon to a blog near you

Posted on: 06/10/04 02:56am
By: shetzel

Cool. I also thank you for dropping the (nearly) useless submitter table in this release. That tidies things up a bit, too.

A couple of small issues to report:

1) I uninstalled and tried to reinstall the plugin and got an SQL error. I had accidentally left the block installed and enabled during the procedure. It seems that phpblock_random_quote doesn't check to make sure that the plugin is installed completely before attempting an SQL query. Once disabled, I was able to install the block smoothly. Oddly enough, when the plugin wasn't installed at all, the block reported the missing function correctly and allowed the rest of the page to display. Not that important, but makes things look "professional" when upgrades are smooth. It was my fault, but others will make the same mistake.

2) I have some quotes that have apostrophes in the quoted field, i.e. "Luke's Father". In the site stats page, these quotes come up as "most quoted" and list counts correctly. When clicking on them, however, the search refuses to find any. The apostrophes (and a few other special chars) may need to be replaced in the hyperlinks like spaces are with "%20". Perhaps? Management search engine works fine, though.

3) Are you dropping planned support for the "What's New" block permanently? Just curious. I saw the indications in the config.php file and thoguht it might be in. But now I see that they're gone. Hardly important, but just wondering what your thinking is on this. Back-burner?

4) I've been poking around in your code and I like what I see. It's not as bad as you made it out to be. My modifications mostly involve displaying the "Submitted by" line to encourage submissions. The code was already in place for the centerblock, just like you said. I added similarly trivial code for the side block.

5) Just to let you know, my users were overjoyed to have their random quotes back after a 7-month hiatus. It is really appreciated.

"quote of the day" coming soon to a blog near you

Posted on: 06/10/04 03:35am
By: machinari

[QUOTE BY= shetzel]phpblock_random_quote doesn't check to make sure that the plugin is installed completely before attempting an SQL query[/QUOTE]good call, I can accomodate that very easily.[QUOTE BY= shetzel]In the site stats page, these quotes come up as "most quoted" and list counts correctly. When clicking on them, however, the search refuses to find any. The apostrophes (and a few other special chars) may need to be replaced in the hyperlinks like spaces are with "%20". Perhaps?[/QUOTE]hmmm... my bad--i think. I thought I had gone through all that, but it's quite possible that I missed those few functions in the functions.inc file. I'll check into what I did with the slashes/spaces, etc. there. good testin![QUOTE BY= shetzel]Are you dropping planned support for the "What's New" block[/QUOTE]Well, I was planning on setting that up, and i'm still not unwilling to implement it, however... I get tired of looking at a rarely updated site that uses that block--all you see is "no new stories," "no new comments," "no new links," etc. so was just unsure of going ahead with that. again, just personal preference. I guess I could look into whether it would work as a configurable option or not.

"quote of the day" coming soon to a blog near you

Posted on: 06/10/04 09:08am
By: Blaine

[QUOTE BY= machinari] [QUOTE BY= shetzel]phpblock_random_quote doesn't check to make sure that the plugin is installed completely before attempting an SQL query[/QUOTE]good call, I can accomodate that very easily[/quote]

[disclaimer: have not looked at the code]
If the plugin includes the phpblock function in the plugins functions.inc then you wont' have to check. The code for the function will not be included if the plugin is disabled or not installed. Also during the plugin installation, you can include the sql to insert the block definition. Include the delete of this record as well in the plugin un-install function.

"quote of the day" coming soon to a blog near you

Posted on: 06/10/04 09:58am
By: shetzel

by Blaine] If the plugin includes the phpblock function in the plugins functions.inc then you wont' have to check. The code for the function will not be included if the plugin is disabled or not installed.
It did it, I swear! After I thought to disable the side block, it all went through like Ex-Lax.
by machinari] I'll check into what I did with the slashes/spaces, etc. there. good testin!
Thanks, but it just happened to be the first one I clicked on when I discovered the page. Random chance, really. At first, I thought they were all busted/unfinished. By another random chance, I happend to click on a different one a couple days later.
by machinari] Again, just personal preference. I guess I could look into whether it would work as a configurable option or not.
Fair 'nuff. I'd probably use it, because it ties back to that whole "encourage the users" thing. They like the recognition, and having to go into a pool of 480 (currently) and waiting before 1 person notices your efforts may ... deter some people. Maybe deter is too strong a word, but I like giving them incentives.

Your call, totally. Or perhaps I'll look into it sometime if you don't get around to it first. My coding skilz aren't that bad...

"quote of the day" coming soon to a blog near you

Posted on: 06/10/04 06:14pm
By: machinari

[QUOTE BY= shetzel]The apostrophes (and a few other special chars) may need to be replaced in the hyperlinks[/QUOTE]
try this until the next release: at approx. line 188 in search.php, change
            list($quoted) = DB_fetchArray($result);
            $sql .= " AND Quoted='$quoted'";

to this
            list($quoted) = DB_fetchArray($result);
            $quoted = slashctrl($quoted);
            $sql .= " AND Quoted='$quoted'";


and at approx. line 197, change
    elseif (isset($stat)){// this comes from the GL stats page
        $sql .= " AND Quoted='$stat'";

to this
    elseif (isset($stat)){// this comes from the GL stats page
        $stat = slashctrl($stat);
        $sql .= " AND Quoted='$stat'";

that works for me-- let me know if it works for you.

"quote of the day" coming soon to a blog near you

Posted on: 06/10/04 06:18pm
By: machinari

[QUOTE BY= Blaine]If the plugin includes the phpblock function in the plugins functions.inc then you wont' have to check[/QUOTE] that function is in the functions.inc file per your advice earlier on. so nothing to change there.
[QUOTE BY= Blaine]during the plugin installation, you can include the sql to insert the block definition. Include the delete of this record as well in the plugin un-install function.[/QUOTE]more excellent ideas! adding this to my list as we speak, er, type...

"quote of the day" coming soon to a blog near you

Posted on: 07/10/04 03:56pm
By: ppmnt

machinari -- nice work! I just installed it and did just a couple of initial tests. I was able to update, delete, change categories... Yay. I still need to try other functionality that was MySQL version dependent (like moderation), but it looks cool so far!

I also like the option of including the "add quote" link in the centerblock. Thanks for adding that! One suggestion though: I think that if somebody wants to enable the add quote link, they'd probably want it to show for anybody who has the right to add quotes. I.e. if members and anonymous members can add quotes, then both of them should see the link. Otherwise you're only suggesting to anonymous users that they should share their quotes. What do you think?

Good stuff, good stuff.

"quote of the day" coming soon to a blog near you

Posted on: 07/10/04 06:14pm
By: machinari

[QUOTE BY= ppmnt]One suggestion though: I think that if somebody wants to enable the add quote link, they'd probably want it to show for anybody who has the right to add quotes. I.e. if members and anonymous members can add quotes, then both of them should see the link. Otherwise you're only suggesting to anonymous users that they should share their quotes. What do you think?[/QUOTE]actually, my thinking was that there only be one "add" link on the page at any one time. let's say that anon and logged in users have permission to add. anon would see the link in the centerblock and logged in users would see it in their user's functions block. otherwise the link would appear in both places for the logged in member, which is more clutter than I prefer.

still up for discussion tho.

question: how do you find the cached quote time options (1 hour; 6 hours; etc.)? to limiting? need more options? other options? suggestions? or is it just fine?

"quote of the day" coming soon to a blog near you

Posted on: 08/10/04 02:44pm
By: ppmnt

[QUOTE BY= machinari]actually, my thinking was that there only be one "add" link on the page at any one time. let's say that anon and logged in users have permission to add. anon would see the link in the centerblock and logged in users would see it in their user's functions block. otherwise the link would appear in both places for the logged in member, which is more clutter than I prefer.

still up for discussion tho.[/quote]

Oh, I see where you're coming from. Personally, I'd like it to be consistent. People who come to the page but their cookie is expired might see the link and then wonder why it disappeared when they logged in. I don't think having the link twice is that bad, it's similar to "get published" or other functionality like that, which usually shows up in the horizontal menu bar and again in a menu block on the left. Just my 2 cents (American, Canadian, or now European cents?).

[QUOTE BY= machinari]question: how do you find the cached quote time options (1 hour; 6 hours; etc.)? to limiting? need more options? other options? suggestions? or is it just fine?[/QUOTE]

I think it's fine the way it is. You could allow the admin to enter the number of hours, rounding to the closest half hour (e.g. .5 could be allowed). That is, if you're up for doing the appriate checking (i.e. has to be a number). I guess it would then become a radio button: either
o page refresh or
o [ ] hours

For me personally it's fine the way it is, because I treat it as a random quote, not a quote of the day. But it probably wouldn't be too hard to offer that additional admin function...

"quote of the day" coming soon to a blog near you

Posted on: 12/10/04 01:46pm
By: machinari

like this thread isn't long enough. update to 0.9.2. Find dialyquote 0.9.2.1 here.

+++ added support for the what's new block. this can be enabled or disabled in the dailyquote admin page (configured in the config.php). To accomodate this you can run the update script rather than the install script. just overwrite your files to make all other changes.
+++ revised the perms for the add link in the centerblock.
+++ slash control from the GL stats and search page should work now.
+++ the phpblock_random_quote() definition has been added to the plugin's install and uninstall routines.
+++ this thread is included in the docs dir for reference.

anymore necessary fixes notwithstanding, and once the documentation has been completed, and some sort of category management page is worked out (working on it), the official 1.0 version of the dailyquote plugin will be available for download on this site.

"quote of the day" coming soon to a blog near you

Posted on: 14/10/04 01:43pm
By: shetzel

Sorry for my absence, my wife and I were on vacation for a week. But now I'm back, recharged, and ready to complain!!! (Not really, hopefully it's more useful than that.)

1) In templates/centerblock.thtml would you consider adding class="content" to the tag? It makes the quote appear in basically the same font as article summaries. Not a big deal, but I noticed that the default font used doesn't seem to be anywhere else on my entire webpage. I'm OK with the speaker and contrib lines being in different fonts, since I'm not sure what else they'd look better as.

2) Thanks for fixing your tarball. It works like a charm now. I forgot to mention that last time.

3) Your upgrade sql patch does not include the 'whatsnew' column, it includes a 'test' column, which I assume is unused.

4) Why doesn't a submitted quote appear in the "Submissions" page of the admin block? I know where to find them (under "Manage Quotes" for privledged users), but is it possible using the plugin API to have it added to the submissions page, too? It's nice for admins who enable their submission queues to have only one place to check for articles, events, links, quotes, etc...

5) Thanks for the "What's New" functionality. Now my users don't have to wait potentially weeks to see the fruits of their labor. I know some admins would like to keep new quotes a surprise, and that's great, too. I like options.

There are a couple of other things I'm tracking right now, but I'd like a little more time to pin them down to exact causes. If I can't solve them the least I can do is tell you exactly what's happening.

I think you're very close to a 1.0 release. I'm not the kind of guy who likes to sit on beta versions forever, though, so I'm biased. I think at this point, you've got a very solid code base which works as advertised. I've never come across any "showstopper" bugs (except during install), and you've been extremely responsive to bugs and suggestions.

By the way, I don't cache my quotes, so I really have no feedback for you on your previous query. I'm totally random.

-Shane

"quote of the day" coming soon to a blog near you

Posted on: 14/10/04 02:09pm
By: machinari

[QUOTE BY= shetzel]1) In templates/centerblock.thtml would you consider adding class="content" to the tag? It makes the quote appear in basically the same font as article summaries. Not a big deal, but I noticed that the default font used doesn't seem to be anywhere else on my entire webpage. I'm OK with the speaker and contrib lines being in different fonts, since I'm not sure what else they'd look better as.[/QUOTE]seems to me that I didn't specify a particular font for either the quote or byline. they both will take on the site's default font or else the browser's default font. beyond that, it is pretty easy to customize so I think I'll leave that one. the only diff between the quote and the byline is the "em" tag.
[QUOTE BY= shetzel]3) Your upgrade sql patch does not include the 'whatsnew' column, it includes a 'test' column, which I assume is unused.[/QUOTE]oops. just replace 'test' with 'whatsnew'. cant believe i left that in there.
[QUOTE BY= shetzel]4) Why doesn't a submitted quote appear in the "Submissions" page of the admin block?[/QUOTE]without getting it in front of me just now, I'd have to say it is simply because I didn't use the GL functions for this feature, but rather used my own. I'll look into that.

thanks for the feedback!

"quote of the day" coming soon to a blog near you

Posted on: 14/10/04 09:38pm
By: machinari

here is a bug that i'm surprised hasn't bothered anyone yet:[QUOTE BY= frawo] Thank you for a nice plugin (it looks good on others sites), but I get this error:
parse error, unexpected T_IF in /faunogfiskarlaget.net/dailyquote/add.php on line 205
Why?
[/QUOTE]
go to line 204 of add.php and simply put a semi-colon at the end of the line.
change this:
$retval = "<p align="center" style="font-weight: bold; color: red;">"
to this:
$retval = "<p align="center" style="font-weight: bold; color: red;">";


thanks to frawo who posted at summitpages.ca with this bug report.

"quote of the day" coming soon to a blog near you

Posted on: 15/10/04 02:46am
By: shetzel

How long has it been like that? Admittedly, I haven't added a new quote with the new version yet.

OK, here's subtler issue #1.

1) Double quotation marks in the quotes. I know, weird, but it happens. Some very interesting things occur. First, obviously, the quote looks odd, since it has the encapsulating quotation marks around the whole thing. Second, it seems to work just fine everywhere except the management page. When you try to edit the quote, it cuts it off at the first mark in the text box.

So how do we handle it? Do we manually prevent double quotation marks from being present when we moderate the submissions? Or would we want to convert all double quotes to single quotes? Admittedly, I don't have a real strong opinion, but I thought you mightlike to know.

-Shane

"quote of the day" coming soon to a blog near you

Posted on: 15/10/04 06:36am
By: ppmnt

Sorry I haven't replied yet, I have not had a chance to try it. I should get to it this weekend.

"quote of the day" coming soon to a blog near you

Posted on: 15/10/04 01:50pm
By: machinari

[QUOTE BY= shetzel] How long has it been like that?[/QUOTE]crept in at 0.9.2.1 so recently.
[QUOTE BY= shetzel]Double quotation marks in the quotes. I know, weird, but it happens.[/QUOTE]Well, on the batch add page the instructions say not to enclose quotations in double quotes, but, obviously, I neglected those instructions on the single add page. still doesn't solve our problem tho does it?
[QUOTE BY= shetzel]So how do we handle it? Do we manually prevent double quotation marks from being present when we moderate the submissions? Or would we want to convert all double quotes to single quotes?[/QUOTE]converting the double quotes to single quotes automatically isn't going to fix the problem. Simply because we are going to deal with people who cant distinguish properly between a regular quotation and a quotation within a quotation. and then, if you have alot of traffic, moderating everybody's punctuation can also be a pain.

maybe a regex that converts all inner double quotes to single quotes and removes any encapsulating double quotes. I say "remove" because the logic adds double quotes automatically.

"quote of the day" coming soon to a blog near you

Posted on: 20/10/04 03:50pm
By: machinari

the documentation for this plugin includes the install doc as well as some basic instructions and "how to's." It will be included with the 1.0 release this weekend. It's time for midterms so I have a bit of time in the next few days to do this. no exams for the teacher

I've decided not to include a category management page until a later release. not to worry shetzel, it'll be done by Christmas so you can turn those Xmas quotes on and those halloween quotes off.

I'll also check for 1.3.10 compatablilty. I haven't checked yet if there will be any issues. there shouldn't be.

"quote of the day" coming soon to a blog near youhttp

Posted on: 25/10/04 04:56am
By: machinari


DailyQuote 1.0 is Released!
It is FuLLy FunctionaL

Get it here! It is also awaiting approval here at geeklog.net and so then you will be able to find it here as well.

documentatoin is included. changes from the last beta involve a few permission errors for add.php, centerblock, and what's new. Fixed a few typos and a message or two. Also fixed the quotation mark issue in GET--depends on your perspective i guess.

"quote of the day" coming soon to a blog near you

Posted on: 25/10/04 11:27am
By: shetzel

Super. I'll install it today and start playing with it.

Thanks for addressing the quotation mark issue. If your final solution is anything like you described above, that would be a good solution for a thorny problem. I don't know if there is an ideal solution, either.

And not to worry about the categories; it's a wishlist feature totally separate from the core functionality. I'll expect it when it's done.

Thanks for all your work. Does this mean we have to start a new thread?

"quote of the day" coming soon to a blog near you

Posted on: 26/10/04 08:47pm
By: machinari

[QUOTE BY= jasonhackwith] I've installed the plugin at http://www.intotheflame.com/, and everything appears to be working correctly except for one thing: deleting a user submitted quote from the moderation queue.

Upon clicking on "delete," I get a SQL error:

Tue Oct 26 12:23:06 2004 - 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 'WHERE itf_dailyquote_quotes.ID=394 LIMIT 1' at line 1. SQL in question: DELETE itf_dailyquote_quotes WHERE itf_dailyquote_quotes.ID=394 LIMIT 1

If I hit "approve," I can then go find it and delete it, but I can't delete it directly out of the submission queue.

Otherwise, everything is fantastic. I have 394 quotes in the system already and more going... ultimately I'll be putting in at least a few thousand more.[/QUOTE]
My apologies... in rewriting the mySQL statements to be 3.23 compatable, I neglected the addition of a single word, "FROM."

in moderation.php on line 195, change
    if (!DB_query("DELETE {$_DQ_TABLES['dailyquote_quotes']} WHERE {$_DQ_TABLES['dailyquote_quotes']}.ID=$qid LIMIT 1")){

to this:
    if (!DB_query("DELETE FROM {$_DQ_TABLES['dailyquote_quotes']} WHERE {$_DQ_TABLES['dailyquote_quotes']}.ID=$qid LIMIT 1")){

and on line 202, change
    if (!DB_query("DELETE {$_DQ_TABLES['dailyquote_lookup']} WHERE {$_DQ_TABLES['dailyquote_lookup']}.QID=$qid")){

to this:
    if (!DB_query("DELETE FROM {$_DQ_TABLES['dailyquote_lookup']} WHERE {$_DQ_TABLES['dailyquote_lookup']}.QID=$qid")){


thanks for the report.

"quote of the day" coming soon to a blog near you

Posted on: 26/10/04 09:45pm
By: machinari

I've noticed a few of you have this plugin operating in other languages. that's awesome work! If you like, I would be glad to include your language file in the tarball. just shoot it to my email.

I'm sure others would love to benefit from your work and would appreciate you for it.

"quote of the day" coming soon to a blog near you

Posted on: 27/10/04 12:27am
By: shetzel

Would you consider making the following addition to the code for those of us who display the contributor name in the block? It brings the code in line with the centerblock code, which you already have this way.

functions.inc, line 671, original:
                if (!$dbquote = DB_query("SELECT Quotes, Quoted FROM {$_DQ_TABLES['dailyquote_quotes']} WHERE Status='1' ORDER BY rand() LIMIT 1")){
                    $retval .= $LANG_DAILYQUOTE['randomerror'];
                    COM_errorLog("An error occured while retrieving your quote",1);
                } else {
                    list ($Quotes, $Quoted) = DB_fetchArray($dbquote);
                    if (!empty($Quotes)){
                        $retval = "<p align="left">"";
                        $retval .= $Quotes;
                        $retval .= ""</p>" . LB;
                        $retval .= "<p align="right"><em>";
                        $retval .= $Quoted;
                        $retval .= "</em></p>";
                    }
                }



functions.inc, line 671, new:
                if (!$dbquote = DB_query("SELECT Quotes, Quoted, q.UID, username FROM {$_DQ_TABLES['dailyquote_quotes']} q, {$_TABLES['users']} gl WHERE Status='1' AND q.UID=gl.uid ORDER BY rand() LIMIT 1")){
                    $retval .= $LANG_DAILYQUOTE['randomerror'];
                    COM_errorLog("An error occured while retrieving your quote",1);
                } else {
                    list ($Quotes, $Quoted, $uid, $username) = DB_fetchArray($dbquote);
                    if (!empty($Quotes)){
                        $retval = "<p align="left">"";
                        $retval .= $Quotes;
                        $retval .= ""</p>" . LB;
                        $retval .= "<p align="right"><em>";
                        $retval .= $Quoted;
                        $retval .= "</em></p>";
//                        $retval .= "<p style="text-align: right; font-size: 8pt;">";
//                        $retval .= $LANG_DAILYQUOTE['subm_by'] . " " . $username;
//                        $retval .= "</p>";
                    }
                }




Thanks for your consideration. Notice that the actual display code is commented out, just like in the centerblock's thtml file.

Otherwise, 1.0 looks good so far. It'll be put through a few paces over the next couple days.

"quote of the day" coming soon to a blog near you

Posted on: 27/10/04 01:02am
By: MrHyde

Thanks a lot for this plugin. Its something that I've wanted for a long long time. So far, I've been using the Random Quote Block that used the gl_quote database, but it lacked the add/delete functionality, which meant I had to use phpMyAdmin to make changes. So, from what I've read so far, this plugin satisfies most of my requirements. I'll go home and try and install it tonight to see how it works.

Thanks once again for all the work you and other testers have done on this plugin.

"quote of the day" coming soon to a blog near you

Posted on: 27/10/04 03:16am
By: machinari

[QUOTE BY= MrHyde]I'll go home and try and install it tonight to see how it works.[/QUOTE]
You may want this update before you install what you have, MrHyde--a few fixes in the update.

DailyQuote 1.0.2 is just a few minor fixes and an feature request update. find it here. It isn't on Geeklog.net yet cuz I have no idea how to upload a file to replace the one that is there (no form field for replacement file). any hints?

[QUOTE BY= shetzel]Would you consider making the following addition to the code for those of us who display the contributor name in the block? It brings the code in line with the centerblock code, which you already have this way.[/QUOTE]
I added that functionality for you shetzel though there was a bit more involved than those few lines. Perhaps sometime later I will throw those settings in the configuration page. At that time, I'll also throw an add link in the block that can be turned on or off from settings.

As with the centerblock, you have only to uncomment the code to gain a contributor's by-line in the phpblock. Details in the change.log. Along with a few other minor fixes, this one now works.

"quote of the day" coming soon to a blog near you

Posted on: 27/10/04 05:29am
By: MrHyde

I've installed DailyQuote 1.0.2 and did not have any major problems. I've had a quick play around with it and have a few comments.

1) Installation Documentation. Very good and is it was straightforward. The only place I got slightly confused is at Section 3.3.2 - " Did you get a successful completion message that your database tables have been created." I got a message saying Installation successful. It didn't say anything about database tables being created. That sort of confused me as it gave me the impression that something was wrong since I did not get a message that databases were created.

2) The other place that confused me was " There should now be a DailyQuote link in your top header." Which top header are you talking about? Is it the one with the links to Homepage • Gallery • Get Published • Links • Calendar • Personalize • Polls • Search • Site Stats. If so, I don't have a Daily Quote link there even after refreshing numerous times. I did have the DailyQuote link in the Admin block and managed to configure it from there. I found the link to the manage quotes page from the admin block and after adding a few sample quotes, the Quote of the Day header showed up at the top.

Now for the suggestions.
1) I would like the heading "Quote of the Day" to be user configurable. I want to call it Random Thoughts.

2) Also, can the category be used as a sort of heading. Best would be a different column for "Title". Have a look at my current random thought block at my website - Crazyguy to see what I mean. You might have to reload a couple of times to hit a quote with a title.

3) Is it possible to have the author google linked. Again, have a look at my site for examples.

I believe all of these, especially 2&3 are easily implemented by changing some .php file, but I do not know which one? If you dont think it is useful enough for others, please tell me which file to edit and I'll add it to my deployed version.

Thank you for all the work done in this plugin.

Cheers,
MrHyde

"quote of the day" coming soon to a blog near you

Posted on: 27/10/04 12:12pm
By: machinari

[QUOTE BY= MrHyde]
1)...I got a message saying Installation successful. It didn't say anything about database tables being created.[/QUOTE]
For those who actually attempt to verify a successful install, the message about successfully creating tables is found in the error log--excuse the ambiguity.
[QUOTE BY= MrHyde]
2) The other place that confused me was " There should now be a DailyQuote link in your top header."... ...If so, I don't have a Daily Quote link there even after refreshing numerous times.[/QUOTE]
perhaps your browser was loading a cached page? the link should have showed up at the 1st refresh. There is nothing set up that would make that link appear only after quotations have been added.
[QUOTE BY= MrHyde]
1) I would like the heading "Quote of the Day" to be user configurable. I want to call it Random Thoughts. [/QUOTE]
This can be changed in /plugins/dailyquote/language/english.php
edit: unless you are refering to the block title used in a phpblock. that can be defined in admin->blocks--the same place where you would enable or disable the block..
[QUOTE BY= MrHyde]
2) Also, can the category be used as a sort of heading....
3) Is it possible to have the author google linked. Again, have a look at my site for examples.[/QUOTE]
not sure what you are asking for exactly. if you could fix your website link I'll be glad to take a look. and I don't know what it means to be "goggle linked."

"quote of the day" coming soon to a blog near you

Posted on: 27/10/04 12:40pm
By: shetzel

by machinari:] I added that functionality for you shetzel though there was a bit more involved than those few lines.

Darn it! I forgot about the cached quotes. It's one of those shameful cases where I tested what I used. I also noticed you did a couple consistiency clean-up where it makes the code a better read. All in all, it's looking tight. Thanks.

"quote of the day" coming soon to a blog near you

Posted on: 27/10/04 05:48pm
By: MrHyde

[QUOTE BY= machinari]
[QUOTE BY= MrHyde]
2) Also, can the category be used as a sort of heading....
3) Is it possible to have the author google linked. Again, have a look at my site for examples.[/QUOTE]
not sure what you are asking for exactly. if you could fix your website link I'll be glad to take a look. and I don't know what it means to be "goggle linked."[/QUOTE]

Hmm... the A HREF didn't work. Anyway, my website address is http://www.crazyguy.org

"quote of the day" coming soon to a blog near you

Posted on: 27/10/04 06:56pm
By: machinari

MrHyde, thanks for your input. here are my conclusions after a bit of thought.

well, I still don't know what a google link is. but in thinking about this, I decided to make the contributor's name (which was just added to the centerblock and phpblock) a link to the search page which would display all submissions by that contributor--just like it is now with the contributor's name in the GL search results.

The category as heading presents a couple of probs, not the least of which to how I cache the quote; and then there is the multiple category issue.. The code is easy--it would just mean a bunch of changes to the DB and some additional SELECTs.

How bout this? ... what if I included all the info that makes it into the regular display of a quote, like the contributor and the byline and the categories, etc., and leave a section in the settings that would allow you to include whatever pieces you wanted (would only apply to the centerblock and/or the phpblock)? then you would have only to modify your own HTML output so that it would display however you like--as a category line underneath, beside, or as a heading on top.

This would definitely be a fluff feature. If I do this, It wont be for a bit.

"quote of the day" coming soon to a blog near you

Posted on: 27/10/04 10:09pm
By: MrHyde

[QUOTE BY= machinari]
well, I still don't know what a google link is. but in thinking about this, I decided to make the contributor's name (which was just added to the centerblock and phpblock) a link to the search page which would display all submissions by that contributor--just like it is now with the contributor's name in the GL search results.
[/QUOTE]

A google link on the author is simply pointing to the google search for that author. For example, if the author of one of the quotes is Sigmund Freud, the google link will be something like http://www.google.com.au/search?hl=en&q=Sigmund+Freud&btnG=Search&meta=. This then allows the users to simply click on the name of the author to find out more information on that author.

[QUOTE BY= machinari]The category as heading presents a couple of probs, not the least of which to how I cache the quote; and then there is the multiple category issue.. The code is easy--it would just mean a bunch of changes to the DB and some additional SELECTs.
[/QUOTE]
Fair enough.. I can see how that can cause problems.

[QUOTE BY= machinari]
How bout this? ... what if I included all the info that makes it into the regular display of a quote, like the contributor and the byline and the categories, etc., and leave a section in the settings that would allow you to include whatever pieces you wanted (would only apply to the centerblock and/or the phpblock)? then you would have only to modify your own HTML output so that it would display however you like--as a category line underneath, beside, or as a heading on top.

This would definitely be a fluff feature. If I do this, It wont be for a bit.[/QUOTE]
Thanks. I don't mind if it takes time to do this.

Cheers,
MrHyde

"quote of the day" coming soon to a blog near you

Posted on: 28/10/04 01:37pm
By: machinari


fyi, for those of you who are still downloading version 1.0 from this site, be aware that 1.0.2 is in the download section as well (because I can only add, not replace).

get it here. or download it from its home.

"quote of the day" coming soon to a blog near you

Posted on: 28/10/04 04:08pm
By: jhackwith

FEATURE REQUEST

I have the plugin all installed at http://www.intotheflame.com/ without any problems, but i do have one feature request.

It would be great to have a topical index for the quotes, that would display an organized list of topics on one page so that users could get to all quotes on a topic without creating a search query. What I have in mind is something like http://www.quotegarden.com/.

The plugin as it is more than meets my needs, but this would just make it really easy for my users to find a quote on a particular topic.

"quote of the day" coming soon to a blog near you

Posted on: 28/10/04 06:01pm
By: machinari

[QUOTE BY= jhackwith] FEATURE REQUEST
It would be great to have a topical index for the quotes[/QUOTE]
that is an excellent idea and, in fact, very easy to implement. keep in mind that because quotes can belong to more than one category, they may be viewed under more than once while clicking thru the category index...
/me adds the request to the list

"quote of the day" coming soon to a blog near you

Posted on: 28/10/04 06:32pm
By: shetzel

by jhackwith] It would be great to have a topical index for the quotes

I second the motion. It all ties back into my suggestion about using the categories for quotes like Geeklog uses topics for articles. But you're right, an index page based on categories is a bit easier than the complex feature I requested, but I'm patient.

See what you did machinari? If you had never put in the categories in the first place, people wouldn't be asking for all these crazy additions.

"quote of the day" coming soon to a blog near you

Posted on: 29/10/04 01:25pm
By: jhackwith

Upgraded to 1.0.2 without a hitch!

Also, I found a typo, in line 142 of the language file:

"Quotations" is spelled as "Quotatoins"

Just an FYI,
Jason

"quote of the day" coming soon to a blog near you

Posted on: 01/11/04 01:21pm
By: machinari


nothin to see here folks.. just go on home.

thought i would add a field or two to the add form: source; and source date.
anything else that should go in there while I'm at it?

as well, I thought I would throw in some B1GA$$ quote marks to draw attention to the quotation in a centerblock or on those few dq pages that contain the random quote. but should I use CSS or images? guess i'll try both and see what happens.

"quote of the day" coming soon to a blog near you

Posted on: 01/11/04 01:24pm
By: jhackwith

Awesome. I was just going to make another feature request for at least a source field.

Keep up the great work!

"quote of the day" coming soon to a blog near you

Posted on: 01/11/04 01:34pm
By: shetzel

I'd absolutely use that! Right now, I integrate the source and date into the "Quoted" field with pair of hyphens. So I had a workable solution, and no need to ask for this. But I'd certainly appreciate it. It would also mean that I wouldn't have to edit the submissions to make them all look the same.

I guess I'd prefer CSS for the quotation marks, simply to make it easier to alter to my desires. I'd be curious to see what both looks like, though.

"quote of the day" coming soon to a blog near you

Posted on: 01/11/04 04:03pm
By: MrHyde

[QUOTE BY= machinari]
thought i would add a field or two to the add form: source; and source date.
anything else that should go in there while I'm at it?
[/QUOTE]

Great idea. I would like a title form as well which is different from the topic field. I've been using the topic field as a title, but if title could be added separately, then it would be easier.

"quote of the day" coming soon to a blog near you

Posted on: 01/11/04 04:08pm
By: shetzel

[QUOTE BY= MrHyde]Great idea. I would like a title form as well which is different from the topic field. I've been using the topic field as a title, but if title could be added separately, then it would be easier.[/QUOTE]
Could you elaborate? I'm not sure what you want, and machinari might have the same problem. A title for each quote?

"quote of the day" coming soon to a blog near you

Posted on: 03/11/04 02:40am
By: MrHyde

[QUOTE BY= shetzel]
Could you elaborate? I'm not sure what you want, and machinari might have the same problem. A title for each quote?[/QUOTE]

Yes, I would like a title for each quote. It will be a optional field and if it has no value, it is ignored. If it has a value, it is displayed in Bold before the actual quote.

"quote of the day" coming soon to a blog near you

Posted on: 03/11/04 03:43am
By: machinari

[QUOTE BY= MrHyde]I would like a title for each quote.[/QUOTE]
I understand. I visited your website and saw what you did... The categories wont do what you want as we discussed earlier. But... a "title" field is easy to implement, just as the "source" and "source date" are also easy to implement. Might as well do them now while I'm on the same page(s).

In the mean time, MrHyde, try using <strong> and <br> to set your title apart from your quotation. I did leave those tags available--in case a dialog was being quoted, one could break the line between speakers. The break tag alone is available for the "quoted" field.

speakin of quotes , check out my big quotation marks and let me know what you think before I go too far with them.

and hey, where did ppmnt go to? I lost a tester

"quote of the day" coming soon to a blog near you

Posted on: 03/11/04 04:40am
By: MrHyde

[QUOTE BY= machinari]
speakin of quotes , check out my big quotation marks and let me know what you think before I go too far with them.
[/QUOTE]

I like those quotes, but not everyone will. So, it might be best to make them user options. In fact, you could make it so that users could even choose which images they want in case they want to create some fancy quotes jpgs of their own.

"quote of the day" coming soon to a blog near you

Posted on: 03/11/04 06:23am
By: Anonymous

This sounds like a great plugin. One that I will definately be using!

"quote of the day" coming soon to a blog near you

Posted on: 03/11/04 10:42am
By: shetzel

[QUOTE BY= machinari]speakin of quotes , check out my big quotation marks and let me know what you think before I go too far with them.[/QUOTE]

They look fine, just as described. But since they are so stylized some people will want to get rid of them. How did you wind up implementing them? Is it a trivial matter to disable them by commenting something out in the centerblock.thtml file?

"quote of the day" - download it!

Posted on: 03/11/04 01:13pm
By: machinari

yup, it's all in the template file so easy to get rid of or replace. I'm really not happy with them. I'm now thinking to leave them out and if the end user wants something like that then they can adjust the template file to suit. They'll be editing the template files anyway, I'm sure.

"quote of the day" coming soon to a blog near you

Posted on: 10/11/04 07:33pm
By: Anonymous

machinari, thanks for all your hard work, your plugin is very cool!

Ok, what am I missing?

I've installed the plugin... thought it looked fabulous, and will be a great start to my geeklog system.

Whenever I add a quote, I get an error that a SQL error has occurred. Checking out my errors.log file, I see:

---------begin log snippet-------------
Wed 10 Nov 2004 05:51:21 PM CST - 1062: Duplicate entry '2-1-2' for key 1. SQL in question: INSERT into gl_dailyquote_lookup SET QID='2', CID='1', UID='2'

Wed 10 Nov 2004 05:54:25 PM CST - 1062: Duplicate entry '3-1-2' for key 1. SQL in question: INSERT into gl_dailyquote_lookup SET QID='3', CID='1', UID='2'

Wed 10 Nov 2004 05:55:25 PM CST - 1062: Duplicate entry '4-1-2' for key 1. SQL in question: INSERT into gl_dailyquote_lookup SET QID='4', CID='1', UID='2'
Wed 10 Nov 2004 05:56:30 PM CST - 1062: Duplicate entry '5-1-2' for key 1. SQL in question: INSERT into gl_dailyquote_lookup SET QID='5', CID='1', UID='2'

Wed 10 Nov 2004 06:00:06 PM CST - 1062: Duplicate entry '6-1-2' for key 1. SQL in question: INSERT into gl_dailyquote_lookup SET QID='6', CID='1', UID='2'

Wed 10 Nov 2004 06:01:52 PM CST - 1062: Duplicate entry '7-1-2' for key 1. SQL in question: INSERT into gl_dailyquote_lookup SET QID='7', CID='1', UID='2'

Wed 10 Nov 2004 06:27:10 PM CST - 1062: Duplicate entry '8-3-2' for key 1. SQL in question: INSERT into gl_dailyquote_lookup SET QID='8', CID='3', UID='2'

Wed 10 Nov 2004 06:39:43 PM CST - 1062: Duplicate entry '9-2-2' for key 1. SQL in question: INSERT into gl_dailyquote_lookup SET QID='9', CID='2', UID='2'
--------------------------------------

It creates this entry for every quote added, but DOES add the quote.

I am no MySQL genius (just learning all this) but no dummy either and I don't see what's triggering the error. The keys are unique, there is no duplication in the database. The DB has only 9 or 10 records total...

Anyone have any ideas?

"quote of the day" coming soon to a blog near you

Posted on: 10/11/04 07:42pm
By: machinari

Yes that happened to me as well, but I fixed it in 0.9x -- at least I thought I had. gimme a couple of hours to compare versions and I'll let you know what I find. oh, what version are you using?

btw, everybody, 1.0.3 will be out tommorrow evening sometime and it's looking sweet.

ok, it looks the same but has more stuff.

"quote of the day" coming soon to a blog near you

Posted on: 10/11/04 07:58pm
By: Anonymous

Thanks machinari. I am using DailyQuote_1.0.2_1.3.9.

I am also having a problem with importing a batch... it says:

ERRORS
Mime type, application/octet-stream, or extension of test not in list of allowed types.

Keep up the GREAT work!

Kev

"quote of the day" coming soon to a blog near you

Posted on: 11/11/04 03:42am
By: machinari

as far as the mime types go... the anly allowed type, txt, should have the .txt extension. It looks like, in the error you posted, that your file "test" has no extension.

I cant find where I would have fixed whatever caused your duplicate entries errors and I cant remember how I fixed it either--in fact I am just assuming that I did because it never happened again after 0.9x.

however, don't let that worry you we'll get it fixed.

first: once it happens once it'll probably keep happening. It is the result of a single error that must have occurred while adding the last quote before the one that returned the first error. So, did you notice any hesitation or error reporting or strange behaviour while adding your first and perhaps your second quote?

second: It seems as though a quote was inserted into the quotes table and never made it to the lookup table--shouldn't have happened, but a place to start anyway.
Another possibility is that you have manually deleted a quote from the lookup table without deleting it from the quotes table as well (unless done manually, this would never happen). Have you deleted any quotes and if so, using what method? for example, did you do it manually, or from the manage page, or the moderation page.

solution (i hope): start again. because you have so few quotes, i suggest you uninstall and start again. taking note of any irregularities on the first couple of inserts.

my apologies for the inconvenience. I'd sure like to track this one down. I fought with it for a couple of days, but I don't remember who won--it was a good month and a half ago.

"quote of the day" coming soon to a blog near you

Posted on: 12/11/04 01:56pm
By: machinari

starting a new thread dudes! otherwise we're going to wear out the internet.

and 1.0.3 has been released. details here

"quote of the day" coming soon to a blog near you

Posted on: 04/07/05 10:39am
By: domokun

awesome...looking forward to it!

gdjb

"quote of the day" coming soon to a blog near you

Posted on: 04/07/05 12:07pm
By: shetzel

Well, wait no longer! You came across an old thread. He's actually up to 1.0.5, which can be found here.

Geeklog - Forum
https://www.geeklog.net/forum/viewtopic.php?showtopic=39205