![]() |
PHP file to alphabetize your smilies
1 Attachment(s)
If your board has a bunch of smilies that you added over time, keeping them in order can be a real pain in the ass. Makes sense to alphabetize them. But it's a real pain in the ass to do it manually with the display order field. This php file does the work for you, after you run it your smilies displayorder will be in alpha order from the smilie titles.
Upload file to the includes/cron directory, and set up a scheduled task. Keep the task marked inactive. filename that the task calls will be: ./includes/cron/alphasmilies.php Then just go to scheduled task, click run, and your smilies are now in alpha order, and the displayorder increments by 10 so there's plenty of space to add more smilies later in the right spot, if you want to sort a few manually. Also, this keeps categories intact, so if you have multiple smilie categories, this will sort them within each category, but will not group all smilies into a single category. |
I get an error for this. Any one have something to similar to this?
|
I'm still using this from time to time if I add smilies; still seems to work fine with 3.8.7. What error are you seeing when you run it?
|
ozzy my Man ..would this work on vB4?
|
Yes, I just tried it and it seemed to work correctly. But I would try it on a test site first to ensure you get the desired results.
http://www.myfriendsspace.com/images.../Babycha-a.gif For anyone wanting to use this, see the file in this post, https://vborg.vbsupport.ru/showpost....6&postcount=21 |
Ok good stuff my man ...thanks ...
|
Not a problem, glad to help. :)
|
I got the following error when running the task:
--------------- Added [DATE]1420152915[/DATE] at [TIME]1420152915[/TIME] --------------- The table should be "cagisf_smilie" ...... |
Try this file. Remember test site first. :)
|
I got this now:
|
Ok once again. Remember test site first. :)
|
Nope still same error :)
|
Well it is a bit different, the space is now gone. Try this one. Remember test site first. :)
|
Nope..back to the 1st error: :p
|
Strange wonder why I am not getting no errors. How about this one. Remember test site first. :)
|
Lol !!! Now I got this one ...
|
Well that is probably due to the previous attempts. but at least we are getting closer. So try this one.
|
No problem my Man ....here it goes:
|
I swear I think I know what I am doing. :p Try again.
|
WOOOOHOOOOO !!!! YOOOO-IZA-DA' MAN !!!!
That did it lol ...... Only one thing lol ... when it re-arranged the smilies it started the first one with (4400) instead of (1) and ended the last one with (8780) ..... Any reason why it doesn't start it with (1) Senor ozzy? |
1 Attachment(s)
Well we are not through yet. Now you have to load this file up, just incase you ever run it again.
Yeah it keeps the original smiles numbers, but this just alphabetizes them. It does not change the number assigned to them. If it were to do that, I think if you had a smile in a post, and it's ID was 456, by changing the ID number, might just change the smile in the post. |
Ah ok ..so I can run the task now with this last one and be good to go? or more steps? :p
|
Yeah you can run it again with the last file just to see if you get any errors, but it won't actually change anything really, as it is already done.
|
This is what I am talking about ozzy ...the display order number starts with 4400 instead of 1
https://vborg.vbsupport.ru/external/2015/01/33.jpg --------------- Added [DATE]1420157011[/DATE] at [TIME]1420157011[/TIME] --------------- Quote:
|
Yeah I know, as I said, this just alphabetizes them, it does not change the ID number of the smile in the DB. That is unique to each smile as you import them into the DB.
I see no reason to even attempt to change that either, as that is only viewable in the ACP. :) |
Ok good stuff .... muahaha!!!!
Is there anything available already that can search for smilies by name or a "my favorite" smilies for v4? I am looking and I see nothing for v4 ... |
Perhaps this mod, [DBTech] vBEditorTabs v1 (vB4)
vBEditorTabs is an editor add-on, allowing administrators and users the ability to create custom tabs below the editor for categorizing smilies, with the potential to add further content in future releases. The tabs integrate smoothly with vBulletin's editor, are powered via jQuery, and there is no limit to the number of tabs you can have, as they wrap under each other and still function normally. vBEditorTabs is currently only compatible with vB4.1.4 and higher (CKEditor). |
If it didn't require the copyright notification I would use a lot more of the DB mods ... but I rather not get into that because DB's mods are good stuff ... thank you though ozzy once again !!!
|
I understand that. I sent you a pm. :)
|
All times are GMT. The time now is 04:57 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|