Chief Alchemist - Business Consulting For The 21st Century Via A Holistic & Intelligent Approach
Share ChiefAlchemist.com. RSS 2.0 feed for ChiefAlchemist.com. Sign up for the mailing list. Follow Chief Alchemist on Twitter. 'Like' the Chief Alchemist's page on Facebook. See what Chief Alchemist has been Q&A'ing on Quora. Chief Alchemist bookmarks & highlights on Diigo.com. Follow the Chief Alchemist on Digg.com. Chief Alchemist channel on Last.fm. Chief Alchemist on Flickr. Mark 'Chief Alchemist' Simchock on LinkedIn. Free Initial Consultation. Email Chief Alchemist. Phone Chief Alchemist.
  • Mark ‘Chief Alchemist’ Simchock
  • 'Email me.Email => ca .at. ChiefAlchemist .dot. com
  • 'Phone me.Alchemy United => 732 997-0028
  •  
  • Free initial consultation.Free => Initial Consultation
  • Please be sure to subscribe to your communication channels of choice.
  • Click To Close => The small green (consultation), red (email) or blue (phone) icons in the top upper right.
CURRENT “TOP 10” TOPICS TOOLS CLIENTS & PROJECTS SOURCES SEARCH HIDE
Business Consulting For The 21st Century Via A Holistic & Intelligent Approach

Passing PHP Varibles Between EE Templates

The short of it is I want minimize hits to the database in ExpressionEngine. In the header I loop through one of the channels. Further down the page, via another embed of another channel loop, I need a couple variables/parameters from the first channel.

While I didn’t necessarily expect otherwise (since EE and PHP are so comfortable together), the PHP $_SESSION variable did the trick. There’s one subtle catch. That is, EE parsing order might force you to put the session_start() in a spot that seems slightly illogical.

http://php.net/manual/en/book.session.php

http://www.plus2net.com/php_tutorial/session-variables.php

http://www.smartwebby.com/PHP/aboutsession.asp

BTW, don’t forget to destroy the session when you’re done.

Required.
Will not be published. Required.
Please include http://