Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 04-17-2005, 11:18 PM
T3MEDIA T3MEDIA is offline
 
Join Date: Dec 2004
Posts: 944
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default URL's for Members names (see inside)

Can some one make a simple php file that can turn long urls into simple ones for members?
for example
https://vborg.vbsupport.rus/member.p...ername=t3media will get you to my profile page.
Could some one make a php so it will look like http://www.vbulletin.org/page.php?=t3media

I think this would be an awsome addition (not really a hack) for members who have community sites based around thier profiles.
I think it could simply just pass info to the long string since its already there.

Fingers crossed on hoping someone can pull this off.
Reply With Quote
  #2  
Old 04-18-2005, 03:08 AM
tnguy3n's Avatar
tnguy3n tnguy3n is offline
 
Join Date: May 2003
Location: U of I, Iowa
Posts: 846
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

it's very possible, but then it may be a little problem with users who user special characters or space or quotation marks etc in their username.
Reply With Quote
  #3  
Old 04-18-2005, 11:16 AM
T3MEDIA T3MEDIA is offline
 
Join Date: Dec 2004
Posts: 944
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by tnguy3n
it's very possible, but then it may be a little problem with users who user special characters or space or quotation marks etc in their username.
Yes indeed. I have a hack installed that only allows standard characters. No spaces etc. I get your point though. (BTW that hack is awsome)
How would you go about doing such a feat?
Reply With Quote
  #4  
Old 04-18-2005, 11:28 AM
Vaelen's Avatar
Vaelen Vaelen is offline
 
Join Date: Oct 2003
Posts: 22
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Don't those characters come back through URLs like spaces as %F20 or something like that... maybe you could use those somehow.
Reply With Quote
  #5  
Old 04-18-2005, 12:24 PM
sabret00the's Avatar
sabret00the sabret00the is offline
 
Join Date: Jan 2003
Location: London
Posts: 5,268
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

simple page using a
PHP Code:
$username addslashes($_REQUEST['u']);

// might wanna add a line in here to reconvert stuff like %20 to plain text

if (!$username)
{
print_standard_error("USER NOT FOUND");
exit();
}

$getID $DB_site->query_first("SELECT userid, username
FROM " 
TABLE_PREFIX "user
WHERE username = 
$username
"
);

$url $vboptions['bburl'] . "/member.php?u=" $getID['userid'];
print_standard_redirect("Whisking you to profile"); 
would work if you didn't wanna use a mod-rewrite for it

untested, as it was just me playing with code
Reply With Quote
  #6  
Old 04-18-2005, 12:45 PM
Colin F's Avatar
Colin F Colin F is offline
 
Join Date: Jul 2004
Location: Switzerland
Posts: 1,551
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I use the code here: https://vborg.vbsupport.ru/showthrea...ight=subdomain

to redirect http://username.myforum.com to their profile, that might be something you could work with...
Reply With Quote
  #7  
Old 04-18-2005, 12:53 PM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

PHP Code:
WHERE username $username 
That will never work, unless you quote it:
PHP Code:
WHERE username '$username' 
Reply With Quote
  #8  
Old 04-18-2005, 01:02 PM
sabret00the's Avatar
sabret00the sabret00the is offline
 
Join Date: Jan 2003
Location: London
Posts: 5,268
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by MarcoH64
PHP Code:
WHERE username $username 
That will never work, unless you quote it:
PHP Code:
WHERE username '$username' 
Oops, rookie mistake, too use to working with numbers
Reply With Quote
  #9  
Old 04-20-2005, 09:55 PM
T3MEDIA T3MEDIA is offline
 
Join Date: Dec 2004
Posts: 944
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Colin F
I use the code here: https://vborg.vbsupport.ru/showthrea...ight=subdomain

to redirect http://username.myforum.com to their profile, that might be something you could work with...
Thanks for the heads up. Your vb 3.0.7 or at least 3.0.0?

The post seems outdated so I just wanted to be sure.
Reply With Quote
  #10  
Old 06-04-2005, 12:48 AM
T3MEDIA T3MEDIA is offline
 
Join Date: Dec 2004
Posts: 944
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

bump
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 10:20 PM.


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.04530 seconds
  • Memory Usage 2,260KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (5)bbcode_php
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (10)postbit_onlinestatus
  • (10)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • 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
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete