MyBB Community Forums

Full Version: [Tutorial] Drop-Down List Report vs Textbox Report
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
If you're running myBB with it's default templates for reporting then a report box should look something like this.

[Image: 0ArwM.png]

When it could look more like this -

[Image: hXXPP.png]

personally I believe this to be superior to a textbox method for more then one reason. For once it could eliminate the possibility of a user spamming reports which would be a waste of his time, and very uncommon, but it's gone Cool. I also believe it makes the site more professional, and the reports are easier to manage, this is simply a personal belief. But why not take a look for yourself, just read this tutorial and you will have this on your site in no time Wink.



We're going to start out by navigating to your admin panel, logging in and doing the following.

Admin CP > Templates & Style > Templates > Expanding Your Current Template > Report Templates > Expand > Report > Full Edit

Do a search for
<input type="text" class="textbox" name="reason" size="40" maxlength="250" />
and replace it with the following
<SELECT NAME="reason">
<OPTION VALUE="Leeching" >Leeching
<OPTION VALUE="Low Quality" >Low Quality
<OPTION VALUE="Spamming" >Spamming
<OPTION VALUE="Hacking" >Hacking
</SELECT>
Also using this method you can display a different reason as the text displayed to the users, sounds confusing? Let me explain more. Using the
<OPTION VALUE="Low Quality" >Low Quality
method, we can edit what's in quotes to be posted to the report, and leave the [php>Low Quality[/php] as is and it would be displayed as such to the user. So we could do
<OPTION VALUE="Leech (If valid then delete, do not trash)"  >Leeching
so users see -
[Image: VtUVf.png]
but our staff sees -
[Image: iQqNb.png]
hmm a pretty simple way to give pretty simple instructions.

Now if you want some more tips, look up what all you can do with drop-down boxes! w3schools is a good resource I'm assuming or just stick to google! For example one thing I learned is you can set the box to automatically select whichever report you want, without switching the order. This could be used for example, to auto-select the most popular report reason, without having to change any orders. Take your code, for example -
<OPTION VALUE="Spamming" >Spamming
and between the text in quotes, and the ">", add the word, without quotes, "SELECTED". So your code would become
<OPTION VALUE="Spamming" SELECTED >Spamming
[Image: pFwp8.png]
Purrfect.

Let me know if you have any questions guys. Also I would like to say as a little in before, I'm well aware none of the code is php, but I think the colors for it are awesome Toungue, also I'm sure this has been posted but I'm trying to go in depth and show all aspects of this option. Enjoy enjoy and let me know if you want me to add some more tips like making a certain choice auto-selected!
Anybody appreciate / use this tutorial?
Good and detailed tutorial. Thank You. Smile
(2012-03-26, 04:59 AM)Yaldaram Wrote: [ -> ]Good and detailed tutorial. Thank You. Smile

Ditto..
Thank you for this tutorial. I've updated my forums with this. I think my mods will be happy to have this.
IMHO its more useful. I personally use this. Keeping textbox makes report reasons long and spammy and in an uncommon and unprofessional manner. This keeps it short and good.
(2012-03-26, 04:59 AM)Yaldaram Wrote: [ -> ]Good and detailed tutorial. Thank You. Smile
Thank you senior.
(2012-03-27, 05:43 AM)seeker Wrote: [ -> ]
(2012-03-26, 04:59 AM)Yaldaram Wrote: [ -> ]Good and detailed tutorial. Thank You. Smile

Ditto..
Ditto.
(2012-03-27, 10:37 AM)MichaudĀ© Wrote: [ -> ]Thank you for this tutorial. I've updated my forums with this. I think my mods will be happy to have this.
I sure hope so, and I'm glad somebody got use out of this tutorial Big Grin
(2012-03-27, 06:51 PM)crazy4cs Wrote: [ -> ]IMHO its more useful. I personally use this. Keeping textbox makes report reasons long and spammy and in an uncommon and unprofessional manner. This keeps it short and good.
Indeed good sire.
Thanks good tutorial. I have a question, I want to put an option of "other" that comes down when selected to enter the reason, how could I do?
i have made a small plugin for this, with admin panel to add options for report. other is not provided.

i will upload it soon.
(2012-04-04, 07:12 AM)xxx Wrote: [ -> ]i have made a small plugin for this, with admin panel to add options for report. other is not provided.

i will upload it soon.

The forum will go up also? I'm interested, especially for my question above Smile
Pages: 1 2 3