Current time: 11-23-2024, 04:30 AM Hello There, Guest! (LoginRegister)


Announcement
We have the biggest collection of MyBB Plugins here on the Net. We have currently 175+ MyBB Exclusive Plugins, 80+ MyBB Compatible MyCodes and 16+ MyBB 1.4.x Themes (Some are still under construction...) Thus, we provide you the largest MyBB Stuff on the net including tutorials. Stay with us, you will find out some more to come.
Now you can easily create your own buttons set for MyBB! Click here to have a look...
*** You cannot do your registration behind any Proxies anymore! ***
Welcome Guest[18.191.215.30], connected from Columbus, Ohio United States
Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Help] Create a plugin
01-21-2010, 04:44 AM
Post: #1
[Help] Create a plugin
Hi I want to create a plugin

I want to add a code to postbit template by activing that plugin!
How can I add a code to a template by PHP in a plugin? Coffee

Kevin's signature THE BIGGEST COLLECTION OF PLUGINS THEMES AND MYCODES FOR MYBB
Visit this user's website Find all posts by this user
Quote this message in a reply
01-21-2010, 11:19 AM
Post: #2
RE: [Help] Create a plugin
The standard way to accomplish this, for the "postbit" template, is to use this code :

PHP Code:[Highlight]
require MYBB_ROOT.'/inc/adminfunctions_templates.php';
    
find_replace_templatesets(
"postbit",
'#'.preg_quote('{$WhateverVariableYouWantToChange}').'#',
'{$WhateverVariableYouWantToChange} Whatever You Want To Add After The Variable Here'
    
); 

I hope this will help you, but normaly we are taking request for our own plugins! Wink

exdiogene's signature MyBBCodes.com administrator
Cool " It is not what you know that matters, it is what you do or do not do!"
Visit this user's website Find all posts by this user
Quote this message in a reply
01-21-2010, 03:36 PM (This post was last modified: 01-21-2010 03:40 PM by Kevin.)
Post: #3
RE: [Help] Create a plugin
Really thanks and if I want to add a code to Header I have to change
find_replace_templatesets(
"postbit",

to
find_replace_templatesets(
"header",
?
And another question I want to add {$asdpm} Variable after {$ignore_bit} in postbit would you please show me the way of it whith the code yo have gotten to me?

Kevin's signature THE BIGGEST COLLECTION OF PLUGINS THEMES AND MYCODES FOR MYBB
Visit this user's website Find all posts by this user
Quote this message in a reply
01-21-2010, 04:10 PM
Post: #4
RE: [Help] Create a plugin
(01-21-2010 11:19 AM)exdiogene Wrote:  I hope this will help you, but normaly we are taking request for our own plugins! Wink

You should read the message above, because you are still asking help for your own plugins isn't it?

Nadjia's signature
Visit this user's website Find all posts by this user
Quote this message in a reply
01-22-2010, 04:54 AM
Post: #5
RE: [Help] Create a plugin
I have understood but when I add HtML codes instead of "Whatever You Want To Add After The Variable Here" It gets's This error
Parse error: parse error in d:\program files\easyphp1-8\www\inc\plugins\topicstats.php on line 31

Kevin's signature THE BIGGEST COLLECTION OF PLUGINS THEMES AND MYCODES FOR MYBB
Visit this user's website Find all posts by this user
Quote this message in a reply
01-23-2010, 03:21 PM
Post: #6
RE: [Help] Create a plugin
Then this mean you made a syntax error in your code so it won't parse...

exdiogene's signature MyBBCodes.com administrator
Cool " It is not what you know that matters, it is what you do or do not do!"
Visit this user's website Find all posts by this user
Quote this message in a reply
02-05-2010, 12:35 AM
Post: #7
RE: [Help] Create a plugin
is there tut on how to make plugings

LuminousX's signature
Visit this user's website Find all posts by this user
Quote this message in a reply
0 member(s) viewed this thread in the last 365 days :
Post Reply 


Was This Thread Useful ?
Please Link To Us
URL
BBCode
HTML

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Recherche le plugin de ce forum : HitCounter Plugin Pichorka 2 352 06-12-2014 06:11 AM
Last Post: Pichorka
Tongue self open and close plugin Philly 0 1,121 07-28-2011 01:17 AM
Last Post: Philly
  Connected From Plugin H0AX 1 1,357 07-02-2011 02:14 PM
Last Post: exdiogene
Question User Browser Detection Plugin or Script ? H0AX 6 2,003 06-30-2011 12:08 PM
Last Post: H0AX
  I Would Like to request a tag cloud plugin howman 24 7,348 11-20-2010 02:57 PM
Last Post: howman

Forum Jump:

 
New To Site ?
Some Useful Links
  • Help

  • You Might Need To Register

  • Forum Statistics

  • Mark All Forums Read

  • Forum Staff

  • Log Out
  • Contact Us

  • Mybbcodes

  • Return to Top

  • Return to Content

  • Lite (Archive) Mode

  • RSS Syndication
  • Powered By MyBB, © 2002-2024 MyBB Group.
    Golden Crown - Designed and Published by ghazal & exdiogene of MyBBCodes.
    Hosting provided by WWWHostingServer.com