We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

basic question

Development and Programming

Greg Aker's avatar
Greg Aker
6,022 posts
17 years ago
Greg Aker's avatar Greg Aker

EDIT:

I have it now….I Should have read the top of this page a little closer: http://expressionengine.com/docs/development/plugins.html 😊

-greg


Hello,

I’m working on my first “real” plug-in. Not sure how functional it will be, but I’m just trying to learn & practice. (so please be kind! 😉

I have run into one thing so far that for the life of me I can’t figure out…

How do I pass variables from one function to another?

If I have something like:

<?php
 class My_class{
   function My_function(){
      $foo =$TMPL->fetch_param('foo');
   }
}
?>

How can I get the value of $foo into ‘function My_secondFunction()’

These are things that the user puts in as variables in the plugin tag call.

For my first “real” try at this, I’m pretty proud that I was able to write about 300 lines of code before I got stumped. =)

Many thanks in advance,

-greg

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.