vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.7 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=228)
-   -   Profile Enhancements - Extra Profile Fields Page (https://vborg.vbsupport.ru/showthread.php?t=179989)

RedGTiVR6 05-30-2008 02:05 AM

https://vborg.vbsupport.ru/showpost....&postcount=292

This is the post I take it?

The provided code is a bit off, but I figured it out.

I've entered the code as follows, but now my memberlist.php page doesn't even show up...

In memberlist.php:


FIND:
PHP Code:

    $profilefields $db->query_read_slave("
        SELECT *
        FROM " 
TABLE_PREFIX "profilefield
        WHERE searchable = 1
            WHERE form = 0 " 

REPLACE WITH:
PHP Code:

    $profilefields $db->query_read_slave("
        SELECT *
        FROM " 
TABLE_PREFIX "profilefield
        WHERE searchable = 1
            WHERE form = 0 OR form = 6 " 


FIND:
PHP Code:

    // get extra profile fields
    
$profilefields $db->query_read_slave("
        SELECT *
        FROM " 
TABLE_PREFIX "profilefield
        WHERE searchable = 1
            AND form = 0 

REPLACE WITH:
PHP Code:

    // get extra profile fields
    
$profilefields $db->query_read_slave("
        SELECT *
        FROM " 
TABLE_PREFIX "profilefield
        WHERE searchable = 1
            AND form = 0 OR form = 6 

The correct code should be as follows for the first replacement, the second one is right.

PHP Code:

    $profilefields $db->query_read_slave("
        SELECT profilefieldid, type, data, optional, memberlist, searchable
        FROM " 
TABLE_PREFIX "profilefield
            WHERE form = 0 OR form = 6" 


Mike-D 05-30-2008 12:55 PM

To Wired: Would you please so kindly to tell me: How it's possible to prevent the page switching to the UserCP, after the Settings have been saved. Know what I mean? Let's start an example...

1. Currently I'm on the vbulletin/profile.php?do=extra page
2. After pressing the Save Button the Redirect appears to save the settings
3. After saving the page returned to vbulletin/usercp.php

And exactly the last point I'd like to know how it works. So I'm not sure but I believe it has something to do with that Code below. Especially the last "else" statement...

PHP Code:

if (empty($vbulletin->GPC['gotopassword']))
 {
  
$vbulletin->url 'usercp.php' $vbulletin->session->vars['sessionurl_q'];
 }
  else
 {
 
$vbulletin->url 'profile.php?' $vbulletin->session->vars['sessionurl'] . 'do=editpassword';
 } 


Would you please help me? I'm sure it's just a small thing. Thanks in advance :) -Mike

Mike-D 05-31-2008 10:22 AM

Quote:

Originally Posted by odeezie (Post 1527374)
I figured out why it would not show up.

The Extra Options link in the userCP will not show up if you have the UserCP icons hack installed: https://vborg.vbsupport.ru/showthread.php?t=170558

Once I disabled those icons, it worked just fine. Is there anyway I can make this work with the icons enabled?

Regarding the "Icons for UserCP Navigation 1.2" here an example to add the Extra Profile Link below the "Profile Picture" Link inside the UserCP...

Template USERCP_SHELL_ICONS => Add this Code
Code:

<if condition="$show['profilepiclink']">
          <tr>
            <td class="$navclass[profilepic]" nowrap="nowrap">
                  <table border="0" cellspacing="0" cellpadding="0">
                    <tr>
                      <td width="20"><img border="0" src="$stylevar[imgdir_misc]/usercp_icons/picture_edit.gif" width="16" height="16"></td>
                            <td><a class="smallfont" href="profile.php?$session[sessionurl]do=editprofilepic">$vbphrase[edit_profile_picture]</a></td>
                    </tr>
                  </table>
            </td>
          </tr>
    </if>

<!-- Extra Profile Field -->
<tr>
  <td class="$navclass[extraoptions]" nowrap="nowrap">
    <table border="0" cellspacing="0" cellpadding="0">
          <tr>
            <td width="20">
                <img border="0" src="$stylevar[imgdir_misc]/usercp_icons/page_user.gif" width="16" height="16"></td>
                <td><a class="smallfont" href="profile.php?$session[sessionurl]do=extraoptions">$vbphrase[extra_options]</a></td>
          </tr>
    </table>
  </td>
</tr>
<!-- / Extra Profile Field -->

<!-- / My Profile -->


Mike-D 05-31-2008 06:27 PM

Attn To Wired: Could you please help regarding my last Post #62 ??? Please! Thank you :)

UK-Biker 06-01-2008 08:06 AM

This is great, but it would be 500% greater if I could include an image field.

I was going to use the VB_garage mod for our motorbike club site, but ti's not compatible with 3.7

https://vborg.vbsupport.ru/showthrea...63681&page=119

I've installed this mod, and made some extra fields for bike make, model, mods etc but would be awsome if I could include some images. Maybe 2 or 3 images.

I suppose I need to be able to create a New User Profile Field but have the option to have an image field instead of radio buttons or single line text box's etc.


Great hack anyway. Hope somebody can look into images side of it.

SVTOA 06-01-2008 01:28 PM

Quote:

Originally Posted by UK-Biker (Post 1537624)
This is great, but it would be 500% greater if I could include an image field.

I was going to use the VB_garage mod for our motorbike club site, but ti's not compatible with 3.7

https://vborg.vbsupport.ru/showthrea...63681&page=119

I've installed this mod, and made some extra fields for bike make, model, mods etc but would be awsome if I could include some images. Maybe 2 or 3 images.

I suppose I need to be able to create a New User Profile Field but have the option to have an image field instead of radio buttons or single line text box's etc.


Great hack anyway. Hope somebody can look into images side of it.

Not sure what you mean, but I have this working for images as well with Vb Garage and Vb3.7.x. There's a field on my board "VB Garage Picture" using the IMG tag where if the member pastes an image URL into the profile field, it correctly parses the IMG code into the Vb Garage and displays the picture in the Garage section. This is nice because they can put any image they want on the web without having to upload it to my server or use up one of the uploads they get with the garage. I am using this hack for "Edit Vehicle Profile" but I can add any fields I want to that versus only the Timeslip Database fields. it works perfectly...

Audentio 06-01-2008 05:05 PM

I don't see the point in this mod if you can't view what people fill in lol.

UK-Biker 06-01-2008 07:55 PM

Quote:

Originally Posted by SVTOA (Post 1537814)
Not sure what you mean, but I have this working for images as well with Vb Garage and Vb3.7.x. There's a field on my board "VB Garage Picture" using the IMG tag where if the member pastes an image URL into the profile field, it correctly parses the IMG code into the Vb Garage and displays the picture in the Garage section. This is nice because they can put any image they want on the web without having to upload it to my server or use up one of the uploads they get with the garage. I am using this hack for "Edit Vehicle Profile" but I can add any fields I want to that versus only the Timeslip Database fields. it works perfectly...




VB Garage will not install on my 3.7 site

Get the error

Code:

Fatal error: Call to a member function on a non-object in /dir/00/0000000/htdocs/website/admincp/install_vbgarage.php on line 321

Wired1 06-03-2008 02:08 AM

Quote:

Originally Posted by Mike-D (Post 1537214)
Attn To Wired: Could you please help regarding my last Post #62 ??? Please! Thank you :)

When I fix it in a future version :)


Quote:

Originally Posted by UK-Biker (Post 1537624)
Great hack anyway. Hope somebody can look into images side of it.

Well that'd be me since it's my mod :) However, this mod is purely for the input page, so you'd use a different mod to display the image. In this mod, all you'd do is create a profile field that would take in the URL.

Guys, if you're having a problem with someone else's thread, please take it to their thread, not mine!


Quote:

Originally Posted by Audentio (Post 1537988)
I don't see the point in this mod if you can't view what people fill in lol.

Read the thread. People use it with other various mods, some are mine, some aren't. You've already downloaded it I see, so you've either installed it, or not...

Mike-D 06-03-2008 02:05 PM

Quote:

Originally Posted by Wired1 (Post 1539320)
When I fix it in a future version :)

There's no fix needed, because I have deleted that Code. The lines starting with 'gotopassword' makes no sense and is really not needed. Unless there exist an hidden Form Field 'gotopassword' and its value is '1'. After the User is being redirected to the Page to change his password. Without these lines it works perfectly ;)


All times are GMT. The time now is 07:58 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01501 seconds
  • Memory Usage 1,778KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (2)bbcode_code_printable
  • (6)bbcode_php_printable
  • (7)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete