View Single Post
  #386  
Old 03-17-2006, 03:30 AM
SludgeMeister SludgeMeister is offline
 
Join Date: Mar 2006
Posts: 16
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by ZacUSNYR
I've had quite a few requests for my code.

I'll probably make some changes but that is what I have so far.

Added back a join date / Skype / user notes / and a signature section.

It's not a myspace rip since it's on a riding site and it's more riding focused so it'll require some changes

Example :

http://members.twowheelfemales.com/Corny

Code:
$stylevar[htmldoctype]
<html dir="$stylevar[textdirection]" lang="$stylevar[languagecode]">
<head>
$headinclude

<title>$vboptions[bbtitle] - $vbphrase[view_profile]: $userinfo[username]</title>
<!-- Declare style from profile field -->
<if condition="$userinfo[field35]">
<style type="text/css">$userinfo[field35]</style>
</if>
</head>
<body>

<!-- Call header and navbar -->
$header
$navbar

<!-- Check to see if user viewing profile is themselves - show link to usercp -->
<if condition="$userinfo[userid] == $vbulletin->userinfo[userid]">
  <table class="tborder" cellpadding="0" cellspacing="1" border="0" width="30%" align="center">
    <tr>
      <td class="alt1" align="center">
        <div class="smallfont">
        <phrase 1="$userinfo[username]">$vbphrase[x_you_are_viewing_your_profile]</phrase>
        <strong><a href="http://www.twowheelfemales.com/forum/profile.php?do=editprofile">Edit Profile</a></strong></div>
      </td>
    </tr>
  </table>
<br />
</if>
 
<!-- Declare main table -->
<table width="100%" border="0" align="center" cellpadding="0" cellspacing="0"> 
  <tr> 
    <td valign="top" width="0%">

<!-- Left column - first table - includes name, avatar, sex, location, last online time -->
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"> 
  <tr class="tcat"> 
    <td colspan="2">
      <div align="left" class="bigusername">
      <strong>$userinfo[username]</strong>
      </div>
    </td>
  </tr>
  <tr>
    <td class="thead" align="center" colspan="2"><a href="http://members.twowheelfemales.com/$userinfo[username]" class="smallfont" /><strong>members.twowheelfemales.com/$userinfo[username]</strong></a>
  </tr>

<!-- Declare the avatar - use IF statement to show default if one is not present -->
  <tr> 
    <td class="alt2" align="center">
    <if condition="$show['avatar']">
      <div align="center"><a href="/forum/vbpicgallery.php?do=hall&amp;u=$userinfo[userid]" /><img src="$post[avatarurl]" border="0" alt="" style="border-color:white;" alt="<phrase 1="$post[username]">$vbphrase[xs_avatar]</phrase>" border="0" /></a></div>
    <else /> 
      <div align="center"><img src="http://www.twowheelfemales.com/forum/images/arcade/noavatar.gif" /></div>
    </if>
<!-- View More Pics - link to PhotoPlog -->
    <br />
    <strong><a href="http://www.twowheelfemales.com/gallery/index.php?$session[sessionurl]u=$userinfo[userid]" title="View More Pics in the Photo Gallery" />View More Pics.</a></strong>
<!-- View my garage link - link to vBPicGallery (vbgarage) -->
    <br />
    <div align="center"><strong><a href="/forum/vbpicgallery.php?do=hall&amp;u=$userinfo[userid]" title="View my Garage" />View my Garage.</a></strong></div>
  </td>


<!-- Right Column General info box: Sex, Location, Online Status -->
<td align="left" valign="top" class="alt2"> 
  <table width="100%" cellspacing="0" cellpadding="1" align="center">
    <!-- Declare the usertitle in an IF statement -->
    <if condition="$userinfo['usertitle']"> 
    <tr> 
      <td colspan="2" align="left"><span class="smallfont">$userinfo[usertitle]</span></td> 
    </tr>
    </if> 
    <tr>
      <td colspan="2" height="1"></td>
    </tr>
    <tr>
      <td colspan="2" height="5">$userinfo[onlinestatus]</td>
    </tr>
    <tr>
      <td colspan="2" height="1"></td>
    </tr>
    <tr>
      <td width="20%">
      <strong>Sex:&nbsp;&nbsp;&nbsp;</strong>
      </td>
      <td align="left">
      <!-- Call Sex Field -->
      $userinfo[field5] 
      </td>
    <tr>
      <td colspan="2" height="2"></td>
    </tr>
  <if condition="$show['age']">
    <tr>
      <td>
      <strong>$vbphrase[age]:&nbsp;&nbsp;&nbsp;</strong> 
      </td>
      <td align="left">
      $userinfo[age]
      </td>
    </tr>
    <tr>
      <td colspan="2" height="2"></td>
    </tr>
  </if> 
    <tr>
      <td colspan="2"><strong>$vbphrase[join_date]: </strong></td>
    </tr>
    <tr>
      <td colspan="2">$userinfo[datejoined]</td>
    </tr>
    <tr>
      <td colspan="2">
      <strong>Location:</strong> 
      </td>
    </tr>
    <tr>
      <td colspan="2" align="left">
      <!-- Declare location Field -->
      $userinfo[field2]
      </td> 
    <tr>
      <td colspan="2" height="2"></td>
    </tr>
    <tr>
      <td colspan="2">
      <strong>Last Online:</strong> 
      </td>
    </tr>
    <tr>
      <td colspan="2" align="left">$userinfo[lastactivitydate] at $userinfo[lastactivitytime]</td>
    </tr>
  </table>
    </td> 
  </tr> 
</table> 

<!-- Declare the Contact Username Table -->
<br />
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"> 
  <tr class="tcat"> 
    <td colspan="2"><strong>Contacting $userinfo[username]</strong></td>  
  </tr> 
  <tr> 
    <td class="alt2" nowrap="nowrap" width="50%" valign="middle" align="center"> 
    <a href="private.php?$session[sessionurl]do=newpm&amp;u=$userinfo[userid]&quot;&gt;&lt;"><img border="0" src="http://www.twowheelfemales.com/forum/images/profile/sendpm.gif" width="79" height="22"></a>
    </td> 
    <td class="alt2" nowrap="nowrap" width="50%" valign="middle" align="center"> 
    <a href="sendmessage.php?$session[sessionurl]do=mailmember&amp;u=$userinfo[userid]&quot; rel=&quot;nofollow"><img border="0" src="http://www.twowheelfemales.com/forum/images/profile/sendmailicon2.gif" width="79" height="22"></a> 
    </td> 
  </tr>
  <tr> 
    <td class="alt2" nowrap="nowrap" valign="middle" align="center"> 
    <if condition="$show['addbuddylist']"> 
      <a href="profile.php?$session[sessionurl]do=addlist&amp;userlist=buddy&amp;u=$userinfo[userid]"><img border="0" src="http://www.twowheelfemales.com/forum/images/profile/addbuddy.gif" width="79" height="22"></a> 
    <else />
      <a href="profile.php?$session[sessionurl]do=removelist&amp;userlist=buddy&amp;u=$userinfo[userid]"><img border="0" src="http://www.twowheelfemales.com/forum/images/profile/remove.jpg" width="79" height="22"></a>
    </if>
    </td> 
    <td class="alt2" nowrap="nowrap" valign="middle" align="center"> 
    <if condition="$show['addignorelist']">
      <a href="profile.php?$session[sessionurl]do=addlist&amp;userlist=ignore&amp;u=$userinfo[userid]"><img border="0" src="http://www.twowheelfemales.com/forum/images/profile/block.jpg" width="79" height="22"></a>
    <else />
      <a href="profile.php?$session[sessionurl]do=removelist&amp;userlist=ignore&amp;u=$userinfo[userid]"><img border="0" src="http://www.twowheelfemales.com/forum/images/profile/addbudy.jpg" width="79" height="22"></a>
    </if> 
    </td> 
  </tr>
</table>

<!-- Declare all Instant Message contacts in IF conditions -->
<br />
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"> 
  <tr class="tcat"> 
    <td colspan="2"><strong>Instant Message $userinfo[username]</strong></td>  
  </tr> 
<if condition="$userinfo['showicq']">  
  <tr>
    <td class="alt2" valign="middle" align="center" width="10%">$userinfo[icqicon]</td>
    <td class="alt2" valign="middle" align="left">
    <a href="#" dir="ltr" onclick="imwindow('icq', '$userinfo[userid]', 500, 450); return false;">$userinfo[icq]</a> 
    </td>
  </tr>
</if> 
<if condition="$userinfo['showaim']"> 
  <tr>
    <td class="alt2" valign="middle" align="center" width="10%">$userinfo[aimicon]</td>
    <td class="alt2" valign="middle" align="left">
    <a href="#" dir="ltr" onclick="imwindow('aim', '$userinfo[userid]', 400, 200); return false;">$userinfo[aim]</a> 
    </td>
  </tr>
</if>
<if condition="$userinfo['showmsn']">  
  <tr>
    <td class="alt2" valign="middle" align="center" width="10%">$userinfo[msnicon]</td>
    <td class="alt2" valign="middle" align="left">
    <a href="#" dir="ltr" onclick="imwindow('msn', '$userinfo[userid]', 400, 200); return false;">$userinfo[msn]</a> 
    </td>
  </tr>
</if>
<if condition="$userinfo['showyahoo']">  
  <tr>
    <td class="alt2" valign="middle" align="center" width="10%">$userinfo[yahooicon]</td>
    <td class="alt2" valign="middle" align="left">
    <a href="#" dir="ltr" onclick="imwindow('yahoo', '$userinfo[userid]', 400, 200); return false;">$userinfo[yahoo]</a> 
    </td>
  </tr>
</if>
<if condition="$userinfo['showskype']">
  <tr>
    <td class="alt2" valign="middle" align="center" width="10%">$userinfo[skypeicon]</td>
    <td class="alt2" valign="middle" align="left">
<a href="#" dir="ltr" onclick="imwindow('skype', '$userinfo[userid]', 400, 220); return false;">$userinfo[skype]</a></td>
</tr>
</if>
</table> 
 
<!-- Declare the User Information Table -->
<br />
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"> 
  <tr class="tcat"> 
    <td><strong>User Information</td></strong>
  </tr> 	
  <tr> 
    <td class="alt2"><a href="$userinfo[homepage]" target="_blank" dir="ltr" class="smallfont">My Home Page</a></td>
  </tr> 
<if condition="$show['profileviews']">
  <tr> 
    <td class="alt2">
    <if condition="$show['profileviewsother']"><a href="#" onClick="openWindow('misc.php?$session[sessionurl]do=profileviews&u=$userinfo[userid]', 300, 400); return false;" class="smallfont">$vbphrase[profile_views]</a>
    <else />
    <span class="smallfont">$vbphrase[profile_views]</if>: $userinfo[profileviews]</span>
    </td>
  </tr> 
</if>
  <tr> 
    <td class="alt2"><a href="search.php?$session[sessionurl]do=finduser&amp;u=$userinfo[userid]" rel="nofollow" class="smallfont"><phrase 1="$userinfo[username]">$vbphrase[find_all_posts_by_x]</phrase></a></td> 
  </tr> 
  <tr> 
    <td class="alt2"><a href="search.php?$session[sessionurl]do=process&amp;showposts=0&amp;starteronly=1&amp;exactname=1&amp;searchuser=$userinfo[urlusername]" rel="nofollow" class="smallfont"><phrase 1="$userinfo[username]">$vbphrase[find_all_threads_started_by_x]</phrase></a></td> 
  </tr> 
  <tr> 
    <td class="alt2"><div class="smallfont">$vbphrase[total_posts]: <strong>$userinfo[posts]</strong> (<phrase 1="$postsperday">$vbphrase[x_posts_per_day]</phrase>)</td></div>
  </tr> 
<if condition="$vboptions['usereferrer']">
  <tr> 
    <td class="alt2"><div class="smallfont"><strong>$vbphrase[referrals]:</strong> $referrals</div></td>
  </tr> 
</if> 
<if condition="$show['usernotes']">
  <tr> 
    <td class="alt2"><div class="smallfont"><strong>$vbphrase[user_notes]:</strong>
    <if condition="$show['usernoteview']">
    <strong>$usernote[total]</strong> [<a href="usernote.php?$session[sessionurl]u=$userinfo[userid]">$vbphrase[view]</a>]
    </if>
    <if condition="$show['usernotepost']">
    [<a href="usernote.php?$session[sessionurl]do=newnote&amp;u=$userinfo[userid]">$vbphrase[post_user_note]</a>]
    </if>
    <if condition="$show['usernoteview']">
    <br />($vbphrase[last_note]: $usernote[lastpostdate] <span class="time">$usernote[lastposttime]</span>)
    </div>
    </if>
    </td>
  </tr> 
</if>
</table> 

<!-- Declare User Interests Table -->
<br />
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"> 
  <tr class="tcat"> 
    <td colspan="3" valign="middle"><strong>$userinfo[username]'s Interests</strong></td>
  </tr>
<if condition="$userinfo[field6]"> 
  <tr valign="top"> 
    <td class="alt1" align="left" valign="top"><span class="normal"><strong>General:</strong></span></td> 
    <td class="alt2" align="left" valign="top">$userinfo[field6]</td> 
  </tr> 
</if>
<if condition="$userinfo[field3]">
  <tr> 
    <td class="alt1" align="left" valign="top"><span class="normal"><strong>Music:</strong></span></td> 
    <td class="alt2" align="left" valign="top">$userinfo[field3]</td> 
  </tr> 
</if>
<if condition="$userinfo[field4]">
  <tr> 
    <td class="alt1" align="left" valign="top"><span class="normal"><strong>Movies:</strong></span></td> 
    <td class="alt2" align="left" valign="top">$userinfo[field4]</td> 
  </tr> 
</if>
<if condition="$userinfo[field32]">
  <tr> 
    <td class="alt1" align="left" valign="top"><span class="normal"><strong>Television:</strong></span></td> 
    <td class="alt2" align="left" valign="top">$userinfo[field32]</td> 
  </tr>
</if>
<if condition="$userinfo[field11]">
  <tr> 
    <td class="alt1" align="left" valign="top"><span class="normal"><strong>Racing:</strong></span></td> 
    <td class="alt2" align="left" valign="top">$userinfo[field11]</td> 
  </tr> 
</if>
<if condition="$userinfo[field27]">
  <tr> 
    <td class="alt1" align="left" valign="top"><span class="normal"><strong>Books:</strong></span></td> 
    <td class="alt2" align="left" valign="top">$userinfo[field27]</td> 
  </tr>
</if>
  <tr> 
    <td class="alt1" align="left" valign="top"><span class="normal"><strong>Groups:</strong></span></td> 
    <if condition="$show['membergroups']"> 
    <td class="alt2" valign="top"><span class="normal">$membergroupbits</span></td>
    <else /> 
    <td class="alt2" valign="top"><span class="normal"><strong><phrase 1="$userinfo[username]">$vbphrase[x_is_not_a_member_of_any_public_groups]</phrase></strong></span></td> 
  </tr>
</if> 
</table> 

<!-- Declare User Details Table	-->
<br />
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"> 
  <tr class="tcat"> 
    <td class="text" align="left" height="10" valign="center" colspan="2"><strong>$userinfo[username]'s Details</strong></td>		
  </tr> 
  <tr> 
    <td class="alt1" align="left" width="33%"><span class="normal"><strong>Riding Status:</strong></span></td> 
    <td class="alt2">$userinfo[field15]</td> 
  </tr> 
  <tr> 
    <td class="alt1" align="left"><span class="normal"><strong>I Ride:</strong></span></td> 
    <td class="alt2" align="left"><if condition="$comma =''"></if>
    <if condition="$post['field393']&1">
    $comma Streets
    <if condition="$comma =','"></if>
    </if> 
    <if condition="$post['field393']&2">
    $comma Track
    <if condition="$comma =','"></if>
    </if>
    <if condition="$post['field393']&4">
    $comma Off-Road
    <if condition="$comma =','"></if>
    </if>
    <if condition="$post['field393']&8">
    $comma Water
    <if condition="$comma =','"></if>
    </if>
  </tr>
  <tr> 
    <td class="alt1" align="left"><span class="normal"><strong>Riding Style:</strong></span></td> 
    <td class="alt2" align="left">$userinfo[field14]</td> 
  </tr> 
  <tr> 
    <td class="alt1" align="left"><span class="normal"><strong>Hometown:</strong></span></td> 
    <td class="alt2" align="left">$userinfo[field390]</td> 
  </tr> 
  <tr> 
    <td class="alt1" align="left"> <div align="left"><span class="normal"><strong>Ethnicity:</strong></span></td> 
    <td class="alt2" align="left" id="ProfileReligion:">$userinfo[field16]</td> 
  </tr> 
  <tr> 
    <td class="alt1" align="left"><span class="normal"><strong>Zodiac Sign:</strong></span></td> 
    <td class="alt2" align="left">
    <if condition="$show['zodiacsign']"> 
    $zodiacsign
    </if>
    </td> 
  </tr> 
  <tr> 
    <td class="alt1" align="left"><span class="normal"><strong>Smoke / Drink:</strong></span></td> 
    <td class="alt2" align="left">$userinfo[field17] / $userinfo[field18]</td> 
  </tr> 
  <tr> 
    <td class="alt1" align="left"><span class="normal"><strong>Favorite Gear:</strong></span></td> 
    <td class="alt2" align="left">$userinfo[field394]</td> 
  </tr> 
  <tr> 
    <td class="alt1" align="left"><span class="normal"><strong>Brand Loyality:</strong></span></td> 
    <td class="alt2" align="left">$userinfo[field23]</td> 
  </tr> 
</table>
</td> 

<!-- Declare Center Separating Column -->
<td width="10">&nbsp;</td>

<!-- Declare Right Side Column -->	
<td valign="top" width="60%"> 

<!-- Declare the Journal Table in an IF statement -->
<if condition="$show[journalinfo]">
  <table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"> 
    <tr class="tcat">
      <td><strong>$userinfo[username]'s Latest Journal Entry</td></strong> 
    </tr> 
    <tr> 
      <td class="alt2">
      <if condition="$show[journalinfo]"> 
      <if condition="$show[journal_lastentry]">
      <a href="journal.php?$session[sessionurl]do=showentry&e=$journal[lastentry_id]">$journal[lastentry]</a> ($journal[lastentry_date])<br /> 
      <else />
      $vbphrase[private]
      </if>
      </if>
      </td> 
    </tr> 
    <tr> 
      <td class="alt1">
      <if condition="$show[journalinfo]"> 
      [<a href="journal.php?$session[sessionurl]do=showjournal&j=$journal[journal_id]"><phrase 1="$userinfo[username]">$vbphrase[visit_xs_journal]</phrase></a>] 
      </if>
      </td> 
    </tr> 
  </table> 
</if> 

<!-- Declare the About Table -->
<br />
<table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"> 
  <tr class="tcat"> 
    <td><strong>A Little About $userinfo[username]</strong></td>
  </tr> 
<!-- About me -->
  <tr> 
    <td class="alt2" valign="top"><strong>About Me and My Bike:</strong><br />$userinfo[field8]</td> 
  </tr> 
<!-- How I got into Riding -->
  <tr> 
    <td class="alt2"><strong>How I Got Into Riding:</strong><br />$userinfo[field25]</td> 
  </tr> 
<!-- Show Signature -->
<if condition="$show['signature']">
  <tr>
    <td class="alt1"><strong>My Signature:</strong><br />$userinfo[signature]</td>
  </tr>
</if>
</table>

<!-- Declare Friends List -->
    <br />
    $FNB_HTML

<!-- Declare Comments -->
    <br />
    $comment_panel

    </td>
  </tr>
</table>

</td> 
</table>

<!-- Declare User Options Table in IF statement for Admins -->
<if condition="can_moderate()">
<br />
  <table class="tborder" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" border="0" width="100%" align="center"> 
    <tr>
      <td align="center" class="vbmenu_control"><a href="moderator.php?$session[sessionurl]do=useroptions&amp;u=$userinfo[userid]">$vbphrase[user_options]</a></td>
    </tr>
  </table>
</if>

$footer 
</body>
</html>
For some reason when I paste your layout code (copied exactly as you wrote there) into my MEMBERINFO I get the following:

Forbidden
You don't have permission to access /admincp/template.php on this server.

Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.


However, when I originally pasted Stangsta's example into MEMBERINFO it accepted fine and saved fine? I am using his example right now.

I can modify Stangsta's example fine (saves fine), just when I copy and paste your code in its entirety, and save, I get that error?

Any ideas what that problem is?

Tom
Reply With Quote
 
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01166 seconds
  • Memory Usage 1,884KB
  • Queries Executed 11 (?)
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
  • (1)bbcode_code
  • (1)bbcode_quote
  • (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_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_display_complete
  • post_thanks_function_can_thank_this_post_start
  • showpost_complete