Thread: Profile Enhancements - Extra Profile Fields Page
View Single Post
  #39  
Old 08-17-2009, 06:59 AM
blind-eddie's Avatar
blind-eddie blind-eddie is offline
 
Join Date: Apr 2006
Location: Michigan
Posts: 2,310
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I have created 3 pages so for with this mod. There are many mods here that require you to make new User Profile fields & then add it to Edit Details or Edit Options or New ones we have made. I think adding them to default vb Profile Fields looks ugly if they really do not belong in that section. So, creating new pages is the way to go, to seperate Fields that need their own section.

I will do my best to walk you through creating new pages using this mod.
================================================== ==========
First, Change the product name to the name you wish to use.

You will need to open your newly named duplicate product with your favorite editor.

Next, Find:
Code:
                                <product productid="wired1_epfp" active="1">
Change wired1 to wired2
If this is not done, you will over-write your System Specs Product & will result in a white page when viewing your System Specs Page.
================================================== ==========
Find:
Code:
<title><![CDATA[Wired1's Extra Profile Field Page]]></title>
Change the highlighted text to Test. ( You can change this later, after you have tested it)
This will be the name of the Product on the Products list.
================================================== ==========
Next, you will need to find every instance of the word extra and replace it with the name of your page, in this instance, name it test.
Easy way to do them all at once is to click edit, if you are using wordpad as your editor, then click Replace. You will see a pop-up.

Find what: type in extras.
Replace with: test.
click replace all.

================================================== ==========
Next, Find:

Code:
<template name="page" templatetype="template" date="1136338972" username="Wired1" version="3.1.0"><![CDATA[<form action="profile.php" method="post">
Change page to test

Next, Find:

Code:
	$globaltemplates = array_merge($globaltemplates, array('page', 'userfield_checkbox_option', 'userfield_radio', 'userfield_radio_option', 'userfield_select', 'userfield_select_multiple', 'userfield_select_option', 'userfield_textarea', 'userfield_textbox', 'userfield_wrapper'));
}]]></phpcode>
Change page to test
================================================== ===========
Next, Find:
Code:
$templatename = 'page';
Change page to test


================================================== ==========

Next, Find:

Code:
<phpcode><![CDATA[if ($profilefield['form'] == 6)
Change the 6 to 7. (This number will increase by one for each page you create)

Save it, Upload your newly named product.
================================================== ==========

Next, you will again need to edit your admincp/profilefield.php

Search for:

Code:
"$vbphrase[options]: $vbphrase[extra_options]"
Replace with:

Code:
		"$vbphrase[options]: $vbphrase[extra_options]",
		"$vbphrase[options]: $vbphrase[test_options]"
Find:

Code:
	6 => "$vbphrase[options]: $vbphrase[extra_options]",
Add below:

Code:
     7 => "$vbphrase[options]: $vbphrase[test_options]",
Save it, Upload it to your admincp file, allow over-write.

================================================== ==========

Now you will need to edit your USERCP_SHELL template
Skip this if you want to add your new page to its own section.

Find:
Code:
	<tr><td class="$navclass[profile]" nowrap="nowrap"><a class="smallfont" href="profile.php?$session[sessionurl]do=editprofile">$vbphrase[edit_your_details]</a></td></tr>
Add after:

Code:
	<tr><td class="$navclass[test]" nowrap="nowrap"><a class="smallfont" href="profile.php?$session[sessionurl]do=test">$vbphrase[edit_test_options]</a></td></tr>
Note: test will need to be changed to new page name for each page made.

================================================== ===========


If you want to add your new page in its own section, simply add the following.

In your USERCP_SHELL, Find:


Code:
<tr><td class="tcat" nowrap="nowrap"><a href="usercp.php$session[sessionurl_q]">$vbphrase[your_control_panel]</a></td></tr>
Add after:

Code:
          <tr><td class="thead">Test Options</td></tr>
	<tr><td class="$navclass[test]" nowrap="nowrap"><a class="smallfont" href="profile.php?$session[sessionurl]do=test">$vbphrase[edit_test_options]</a></td></tr>
Note: test will need to be changed to new page name for each page made.


To get Profile Fields to show up on your new page, Go into your Profile Field Manager.

Select your User Profile field you want to add to this page, at the very bottom, Select, Options Test Options.

Hopefully I covered all the bases & this will help many of you to create new profile pages from this mod.
You will need to re-do these steps for every Profile page you wish to create.

Thanks Wired....Later, Tim
Attached Files
File Type: xml product-test.xml (4.8 KB, 17 views)
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01448 seconds
  • Memory Usage 1,823KB
  • Queries Executed 12 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD_SHOWPOST
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (14)bbcode_code
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_box
  • (1)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (1)post_thanks_postbit_info
  • (1)postbit
  • (1)postbit_attachment
  • (1)postbit_onlinestatus
  • (1)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • reputationlevel
  • showthread
Included Files:
  • ./showpost.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showpost_start
  • bbcode_fetch_tags
  • bbcode_create
  • postbit_factory
  • showpost_post
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete