php - Initializing variables in plugin for use on Wordpress pages -
i created session plugin in wordpress send success/error messages after form submissions. looks this:
class mysession{ //do stuff... } $mysession = new mysession(); $ssuccess = $mysession->success(); $serror = $mysession->error(); i can use $mysession on actual wordpress pages other 2 variables don't initialized. have manually insert last 2 lines of code in page. idea why or i'm doing wrong?
change mysession = new mysession();
to
$mysession = new mysession(); then ->
$ssuccess = $mysession->success(); $serror = $mysession->error();
Comments
Post a Comment