Quantcast
Channel: WordPress.org Forums » [W3 Total Cache] Support
Viewing all articles
Browse latest Browse all 19294

christopheran on "[Plugin: W3 Total Cache] How to use variables in fragments?"

$
0
0

I need to have a few variables figured in one place, then echo'd in another.

So basically, I have this:

<!-- mfunc nfs098  -->
$test = " test4";
<!-- /mfunc nfs098 -->

then later in the page, this:

<!-- mfunc nfs098 -->
echo $test;
<!-- /mfunc nfs098 -->

but when I run this nothing is echo'd.

I can combine those into an mfunc and it works. But my actual script is split. I declared $test as a global in the second one, that didn't help.

What do I need to do differently?

Chris

http://wordpress.org/extend/plugins/w3-total-cache/


Viewing all articles
Browse latest Browse all 19294

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>