Go Back   vb.org Archive > Community Central > Community Lounge
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #11  
Old 02-02-2015, 04:13 PM
Dave Dave is offline
 
Join Date: May 2010
Posts: 2,583
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Simon Lloyd View Post
You could always add a plugin with a simple replace for all those that get up your nose
You can already do that with the Replacement Variable Manager in vBulletin.
Reply With Quote
  #12  
Old 02-02-2015, 04:22 PM
CAG CheechDogg's Avatar
CAG CheechDogg CAG CheechDogg is offline
 
Join Date: Feb 2012
Location: Riverside, California USA
Posts: 1,080
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Dave View Post
You can already do that with the Replacement Variable Manager in vBulletin.

So how do you that if say I wanted for the acronym (CAG) always be capitalized if someone posted (cag) but it not affect a word like "cage" or "bird cage" or any other word that might have "cag" in it? ...

I ask because I used the replacement variable manager for this and it changed any word that had "cag" to "CAG" ...so the word cage became "CAGe" ...

--------------- Added [DATE]1422901449[/DATE] at [TIME]1422901449[/TIME] ---------------

Oh one other thing .... it also affects file extensions as well ...most of my images have cag in them so it breaks images as well lol ...
Reply With Quote
  #13  
Old 02-02-2015, 04:40 PM
Simon Lloyd's Avatar
Simon Lloyd Simon Lloyd is offline
 
Join Date: Aug 2008
Location: Manchester
Posts: 3,481
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by CAG CheechDogg View Post
So how do you that if say I wanted for the acronym (CAG) always be capitalized if someone posted (cag) but it not affect a word like "cage" or "bird cage" or any other word that might have "cag" in it? ...

I ask because I used the replacement variable manager for this and it changed any word that had "cag" to "CAG" ...so the word cage became "CAGe" ...

--------------- Added [DATE]1422901449[/DATE] at [TIME]1422901449[/TIME] ---------------

Oh one other thing .... it also affects file extensions as well ...most of my images have cag in them so it breaks images as well lol ...
You'd have to use REGEX and get complicated with looking forward and back to check that "cag" is indeed a word on its own then replace it
Reply With Quote
  #14  
Old 02-02-2015, 04:47 PM
CAG CheechDogg's Avatar
CAG CheechDogg CAG CheechDogg is offline
 
Join Date: Feb 2012
Location: Riverside, California USA
Posts: 1,080
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yeah I know lol ...I used the following two in plugins but it still didn't work as it should:

Code:
$find = array( 
'cag', 
'Cag',  
); 

$replace = array( 
'CAG', 
'CAG', 
); 

$this->post['message'] = str_ireplace($find, $replace, $this->post['message']);

and


Code:
$word = array(  
'/\cag\b/',  
'/\Cag\b/'  
);  

$changedword = 'CAG';  

$post['message'] = preg_replace($word, $changedword, $post['message']);
I used postbit_display_complete on both and it still changed it in words that had "cag" and also in images lol ... So I gave up
Reply With Quote
  #15  
Old 02-02-2015, 05:57 PM
Replicant's Avatar
Replicant Replicant is offline
 
Join Date: Sep 2014
Location: Phoenix, Az. USA
Posts: 485
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by CAG CheechDogg View Post
[CODE]
'/\cag\b/',
'/\Cag\b/'

try '/cag(?= )/'
Reply With Quote
Благодарность от:
CAG CheechDogg
  #16  
Old 02-02-2015, 06:42 PM
kh99 kh99 is offline
 
Join Date: Aug 2009
Location: Maine
Posts: 13,185
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Dave View Post
You can already do that with the Replacement Variable Manager in vBulletin.
You can, but I'd be careful about using that. As CAG mentioned, it does a replacement on the entire html document, so if you replace something that happens to appear in an html tag for example, you can break things.
Reply With Quote
2 благодарности(ей) от:
CAG CheechDogg, Max Taxable
  #17  
Old 02-02-2015, 09:43 PM
CAG CheechDogg's Avatar
CAG CheechDogg CAG CheechDogg is offline
 
Join Date: Feb 2012
Location: Riverside, California USA
Posts: 1,080
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Replicant View Post
try '/cag(?= )/'
Ok I will check this out and see what it does ...ty ...

--------------- Added [DATE]1422921304[/DATE] at [TIME]1422921304[/TIME] ---------------

Quote:
Originally Posted by Replicant View Post
try '/cag(?= )/'
Good stuff my my Man this is working perfectly so far ... THANK YOU !!
Reply With Quote
  #18  
Old 02-03-2015, 05:19 PM
Replicant's Avatar
Replicant Replicant is offline
 
Join Date: Sep 2014
Location: Phoenix, Az. USA
Posts: 485
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by CAG CheechDogg View Post
Ok I will check this out and see what it does ...ty ...

--------------- Added [DATE]1422921304[/DATE] at [TIME]1422921304[/TIME] ---------------



Good stuff my my Man this is working perfectly so far ... THANK YOU !!
Glad I could help.:up:
Reply With Quote
Благодарность от:
CAG CheechDogg
  #19  
Old 02-03-2015, 05:43 PM
TheAdminMarket's Avatar
TheAdminMarket TheAdminMarket is offline
 
Join Date: Jun 2013
Location: Thessaloniki, Greece
Posts: 511
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by CarpCharacin View Post
For some reason, it makes me mad. I had to edit a few posts today on my site to fix abbreviations. I think it is kind of annoying when forum members use abbreviations.
At least you can understand what that abbreviations means. The real problem is on international sites (just like this), when the native English members (much more if they belong to Staff) are posting with abbreviations or local sayings.

It tooks me months (actually I had to ask someone) to understand the meaning of "My two cents" or similar sayings. I was reading "OP" and thought that it means Operator while latest someone told me that means "Original Poster".

Especially when you reply to someone that you know that English is not his tongue, everyone must tries to use simple words and phrases. Forums (at all, not just here), it's not a place to promote your English level.

Addition: My father who died almost 30 years ago was Professor at Univercity. Still remember some words of him. "Educated is not that one who knows a lot, but that one who can talk to a farmer like a farmer, to a child like a child etc ".
Reply With Quote
2 благодарности(ей) от:
CAG CheechDogg, socialteenz
  #20  
Old 02-05-2015, 09:49 AM
cellarius's Avatar
cellarius cellarius is offline
 
Join Date: Aug 2005
Posts: 1,987
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Not disputing your point at all. Anyway:

Quote:
Originally Posted by NickTheGreek View Post
It tooks me months (actually I had to ask someone) to understand the meaning of "My two cents"
Doing a simple google search brings up Wikipedia and the Urban Dictionary as results #1 and #2. Both explain it pretty well. And there's a ton of lists that explain usenet/internet acronyms like OP.

Quote:
Especially when you reply to someone that you know that English is not his tongue, everyone must tries to use simple words and phrases. Forums (at all, not just here), it's not a place to promote your English level.
On the other hand, I always saw sites such as this as a pretty entertaining way to improve my everyday english, pick up idioms and so on.
Reply With Quote
4 благодарности(ей) от:
CAG CheechDogg, ozzy47, Simon Lloyd, socialteenz
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 07:02 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.05312 seconds
  • Memory Usage 2,292KB
  • Queries Executed 13 (?)
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
  • (2)bbcode_code
  • (11)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
  • (3)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_box_bit
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (5)post_thanks_postbit
  • (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_postinfo_query
  • fetch_postinfo
  • 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
  • fetch_musername
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • post_thanks_function_fetch_thanks_bit_start
  • post_thanks_function_show_thanks_date_start
  • post_thanks_function_show_thanks_date_end
  • post_thanks_function_fetch_thanks_bit_end
  • post_thanks_function_fetch_post_thanks_template_start
  • post_thanks_function_fetch_post_thanks_template_end
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete