Data at Your Fingertips: Explore Our New Reporting and Statistical Capabilities By Ryan Ashbrook Tuesday at 01:29 PM
ipbfuck Posted February 10, 2016 Share Posted February 10, 2016 Hi! yesterday in 10 minute i've write a small plugin for wordpress to make click-able background with cursor and title (demo in my website - i've put manually inside ipb). now i want try to make a plugin/app/hook for ipb... i've installed ipb in my wamp server; dev tools, all is ok but... really, i don't have any idea on how to continue! 1) hook; app; plugin... what is the real difference? when is best to make one instead of another? 2) i need just a little page with a url input a txt input (two setting field) and include a javascript code block in footer with this custom variables. - how i can do this? someone can help me to make my first plugin? ? thanks in advance, S.N. Link to comment Share on other sites More sharing options...
Daniel F Posted February 10, 2016 Share Posted February 10, 2016 Applications are what make up the IPS Community Suite. Applications provided by IPS include Forums, Gallery, Commerce, etc. As a third party developer, you can create your own applications to add new areas of the suite. Plugins provide a way for developers to modify or extend the behaviour of applications within the IPS Community Suite. Further information can be found on: https://community.invisionpower.com/4docs/advanced-usage/development/plugins-r71/ Link to comment Share on other sites More sharing options...
ipbfuck Posted February 10, 2016 Author Share Posted February 10, 2016 then, for this little work the best choice is a hook, im right? Link to comment Share on other sites More sharing options...
Daniel F Posted February 10, 2016 Share Posted February 10, 2016 Just now, laltroweb.it said: then, for this little work the best choice is a hook, im right? exactly Link to comment Share on other sites More sharing options...
ipbfuck Posted February 10, 2016 Author Share Posted February 10, 2016 ok, thank'u! please, can u help me to find any guide to make a little hook to put a jquery + 2 setting field in hook page and add this in footer? i need just to start and understood how this work. if i can work with wp i think i can work also with ipb Link to comment Share on other sites More sharing options...
ipbfuck Posted February 10, 2016 Author Share Posted February 10, 2016 Ok, work! but i don't know how to use "setting" key and put it as input field in plugin detail page :/ ok, work with: {setting="mykey"} but, styll, i cannot see setting page in plugin detail :| Link to comment Share on other sites More sharing options...
newbie LAC Posted February 10, 2016 Share Posted February 10, 2016 Hello, Just now, laltroweb.it said: then, for this little work the best choice is a hook, im right? Hook is part of plugin or app. Just now, laltroweb.it said: but i don't know how to use "setting" key and put it as input field in plugin detail page :/ Go to plugins folder - your plugin - rename settings.rename.php to settings.php and open it. Add form fields. See 2. go to ACP - System - Plugins - your plugin - tab Settings. Add settings Link to comment Share on other sites More sharing options...
ipbfuck Posted February 10, 2016 Author Share Posted February 10, 2016 thank'u, my plugin work now Link to comment Share on other sites More sharing options...
ipbfuck Posted February 10, 2016 Author Share Posted February 10, 2016 Hi, i've another question sorry! I've put code in fotter and vaf in form, but i don't have understood how i can put, in same plugin, also a different piece of code in header (for css). when i go to template class list i cannot found nothing for css inclusion :| Link to comment Share on other sites More sharing options...
ipbfuck Posted February 11, 2016 Author Share Posted February 11, 2016 hi, sorry, i need to ask for clean output. this is in form setting (no clean, i've try with htmlentities ecc, but nothing seems to work here. $form->add( new \IPS\Helpers\Form\Text( 'Url', \IPS\Settings::i()->url ) ); $form->add( new \IPS\Helpers\Form\Text( 'Title', \IPS\Settings::i()->title ) ); so, i want try to fix output: public static function hookData() { $url = '{setting="url"}'; $title = '{setting="title"}'; but also here, var contain quotes, so, eg, i cannot use dd slashes. im sure exist a simplest way, but i don't know. someone can report me a way for this? thank in advance Link to comment Share on other sites More sharing options...
BomAle Posted February 11, 2016 Share Posted February 11, 2016 check this \IPS\Settings::i()->url for example Link to comment Share on other sites More sharing options...
ipbfuck Posted February 11, 2016 Author Share Posted February 11, 2016 thank'u very much is more simple with this instead of {setting="key"} now i've used this, and work as expected: // remove single e double quotes in url $url = htmlentities(str_replace(array('"', '\''), '', \IPS\Settings::i()->url)); // maintain quotes here, but fix with add addslashes $title = addslashes(htmlentities(\IPS\Settings::i()->title, ENT_NOQUOTES)); regards Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.