Jump to content

How Pass Custom Variables In Php


arivanbastos

Recommended Posts

Hello,

 

I'm using the follow code to display a banner in PHP:

 

if (@include_once('/www/delivery/alocal.php')) {
    if (!isset($phpAds_context)) {
         $phpAds_context = array();
    }
}

$phpAds_raw = view_local('', 1, 0, 0, '', '', '0', $phpAds_context, '');
echo $phpAds_raw['html'];

How can I pass custom variables (site variables) to be used as filters for banner display?

This seems to be a very basic question, but I could not find the answer even searched enough.

 

Thank u so much.

 

Regards,

Link to comment
Share on other sites

  • 5 months later...
  • 1 year later...

something like this:

 

...you need to set some cookie first

$_COOKIE['OAID'] = md5(rand(1,100000000)); 

...and then you set up your params

$_REQUEST['foo'] = 'bar';

require_once('/data/www/yourserver.com/www/delivery/alocal.php');            
$adArray = view_local('', $zoneid, 0, 0, '', '', '0', $OA_context, '');       
 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...