MyBB Hacks

Full Version: Additional Settings For Custom Profile Fields [1.2]
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
(05-06-2012 10:56 AM)ZiNgA BuRgA Wrote: [ -> ]Yeah, the screenshot looks pretty awesome
Thanks, Yumi Biggrin

(05-06-2012 02:03 PM)Sama34 Wrote: [ -> ]Too bad MyBB doesn't allow more that one editor in the same page, we need to choose what field will use the editor :/
I can't find a way to do that.
Unfortunately, there are some MyBB's MyCode not compatible with other BBCode Editor. For example, CKEditor. Font Size BBCode in CKEditor (by default) has a different format with Font Size in MyBB's MyCode (by default).

With some styling, maybe we can use the BBCode posted by Lee (I've been trying it for replacing CKEditor):
(04-05-2012 10:52 AM)leefish Wrote: [ -> ]http://code.google.com/p/sbbeditor/
Not WYSWYG, but at least I have a BBCode editor that supports more than one textarea for my needs.
[attachment=807]
My Textarea and My Textarea 2 use the BBCode editor.
(05-03-2012 05:09 AM)RateU Wrote: [ -> ]You need to "load" the non custom profile fields manually. Just add the code in the plugin attached to this post.

Can you clarify what you mean here? Sorry!

Maybe you could share the template for the profile you created there? I could learn from that.
(05-07-2012 07:05 AM)RateU Wrote: [ -> ]With some styling, maybe we can use the BBCode posted by Lee (I've been trying it for replacing CKEditor):
(04-05-2012 10:52 AM)leefish Wrote: [ -> ]http://code.google.com/p/sbbeditor/
Not WYSWYG, but at least I have a BBCode editor that supports more than one textarea for my needs.

My Textarea and My Textarea 2 use the BBCode editor.

That actually looks really good RateU - I had to double check which one was the mybb one. Biggrin
Just like Leefish, I think it does looks better that mybb default one, after all users just need it for simple things (b, i, s, u, etc..).

Will download and try it.
(05-07-2012 07:18 AM)brad-t Wrote: [ -> ]
(05-03-2012 05:09 AM)RateU Wrote: [ -> ]You need to "load" the non custom profile fields manually. Just add the code in the plugin attached to this post.

Can you clarify what you mean here? Sorry!
I mean you need to add your own code into the plugin file for displaying and processing the non custom profile fields input (Date of Birth, Website, Notification and etc - depends on whatever input fields you want to be displayed there).

(05-07-2012 07:18 AM)brad-t Wrote: [ -> ]Maybe you could share the template for the profile you created there? I could learn from that.
Do you mean the usercp template? It is a standard usercp template. I just add some variable for displaying the custom profile fields there:

HTML Code
<html>
<head>
<title>{$lang->user_cp}</title>
{$headerinclude}
<script src="{$mybb->settings['bburl']}/jscripts/sbbeditor.js" type="text/javascript"></script>
</head>
<body>
{$header}
<table width="100%" border="0" align="center">
<tr>
{$usercpnav}
<td valign="top">
<form action="usercp.php" method="post" name="input">
<input type="hidden" name="my_post_key" value="{$mybb->post_code}" />
{$errors}
<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder">
<tr>
<td class="thead" colspan="3"><strong>{$lang->account_summary}</strong></td>
</tr>
<tr>
<td class="tcat smalltext" style="text-align:center"><strong>Avatar</strong></td>
<td class="tcat smalltext" style="text-align:center"><strong>Account Info</strong></td>
<td class="tcat smalltext" style="text-align:center"><strong>Additional Info</strong></td>
</tr>
<tr>
<td class="trow2" style="width:1px">{$avatar}</td>
<td class="trow2">
<span class="largetext">{$username}</span><br />
<strong>{$lang->postnum}</strong> <a href="search.php?action=finduser&amp;uid={$mybb->user['uid']}">{$mybb->user['posts']}</a> {$lang->posts_day}<br />
{$reputation}
<strong>{$lang->email}</strong> {$mybb->user['email']}<br />
<strong>{$lang->registration_date}</strong> {$regdate}<br />
<strong>{$lang->primary_usergroup}</strong> {$usergroup}<br />
{$referral_info}
{$xtpf_minp['fid1']}
</td>
<td class="trow2">
	<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" style="width:100%">
		{$xtpf_minp['fid3']}
		{$xtpf_minp['fid5']}
		{$xtpf_minp['fid6']}
		{$xtpf_minp['fid7']}
	</table>
</td>
</tr>
<tr>
	<td class="tcat smalltext" colspan="3"><strong>Options</strong></td>
</tr>
<tr>
	<td class="trow1" colspan="3" style="text-align:center">
		<strong>Threads Per Page: </strong>{$threadperpage} &nbsp;
		<strong>Posts Per Page: </strong>{$postperpage}
	</td>
</tr>
</table>
<br />
{$xtpf_minp['fid2']}{$xtpf_minp['fid9']}{$xtpf_minp['fid10']}{$xtpf_minp['fid4']}
<br />
<div style="text-align:center">
	<input type="hidden" name="action" value="do_update_xt_proffields" />
	<input type="submit" class="button" value="Update Profile" />
</div>
</form>
{$latest_subscribedx}
{$latest_threadsx}
{$latest_warningsx}
{$user_notepadx}
</td>
</tr>
</table>
{$footer}
</body>
</html>


@Lee: Thanks for the links, Lee Smile

@Sama34: At least we can add our own MyCode buttons there Biggrin

Ahh I'm so confused ... I'll need to take some time this week to really look into this.
(04-03-2012 07:41 AM)RateU Wrote: [ -> ]

PHP Code:
$xt_proffields_custom = 0;

to

PHP Code:
$xt_proffields_custom = 1;


I've been searching for this, but can't find it. Which file, exactly, is this in?
(05-25-2012 07:15 PM)Gstone Wrote: [ -> ]I've been searching for this, but can't find it. Which file, exactly, is this in?
Tried the attached file?
(05-25-2012 10:19 PM)ZiNgA BuRgA Wrote: [ -> ]
(05-25-2012 07:15 PM)Gstone Wrote: [ -> ]I've been searching for this, but can't find it. Which file, exactly, is this in?
Tried the attached file?

Yeah, I've searched for that code in the plugin file, but my editor doesn't return anything. I've also looked on line 297, but the string isn't there.
I'm sorry, I've moved the settings into a setting group:
(04-07-2012 09:17 AM)RateU Wrote: [ -> ]There are some settings added to this version:
  • Move the settings to the Settings Groups:
    AdminCP -> Configuration -> Settings -> Additional Settings For Custom Profile Fields
I did it because I need to access the setting for my other plugin.

Note that if you set the settings to Yes, you need at least put {VALUE} in the Display Format setting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20
Reference URL's