Jump to content

Search the Community

Showing results for tags 'code'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Using and Managing Revive Adserver
    • Documentation
    • Using Revive Adserver
    • Managing Revive Adserver
    • Bugs
  • Advanced Topics
    • Performance, Scalability, and Reliability
    • For Developers
  • Revive Adserver Community
    • Revive Adserver Project News and Announcements
    • Feature Requests
    • Plugins
    • Requests for Consulting
    • Off Topic

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL

Found 6 results

  1. Hi, everyone ! I have installed Revive Adserver-3.2.3 in my IDE used Eclipse and the server is wampserver in windows. As I did not learned the php before, so recently I have learned the grammar about the php and the template about smarty. What's more, I found this project has also used PEAR to expand the php function. I can understand most of the meaning about the code,but I still have some confused about this entire program, especially the entire structure. I saw there was lib folder and it contains java-xmlrpc ,junit,Zend,xmlrpc and some other folders,but I could not understand these folders's function. I want to modify this project in my demand, but I don't know how to modify especially the UI style. I konw the basic using about smarty,such as templates files are stored in lib/templates/admin, the cache files are generated in var/cache and the grammar about assign() , display(),but I don't understand how to work about the hook, listener,register function? For example: the template advertiser-index.htm the content is below: {view_before_content} {include file=advertiser-index-list.html from=$aAdvertisers aCount=$aCount} {view_after_content} I found ViewHook.php has defined the 'view_before_content' and 'view_after_content' like below: protected function register(OA_Admin_Template $oTpl) { $oTpl->register_function('view_before_content', array($this, 'beforeContent')); $oTpl->register_function('view_after_content', array($this, 'afterContent')); } public function beforeContent($aParams, &$oTpl) { return OX_Admin_UI_Hooks::beforePageContent($this->pageId, $this->pageData, $oTpl); } public function afterContent($aParams, &$oTpl) { return OX_Admin_UI_Hooks::afterPageContent($this->pageId, $this->pageData, $oTpl); } but the function OX_Admin_UI_Hooks::beforePageContent in Hooks.php is public static function beforePageContent($pageId, $pageData, &$oTpl) { self::init(); $result = ''; $oContext = new OX_Admin_UI_Event_EventContext(array( 'pageId' => $pageId, 'pageData' => $pageData, 'oTpl' => $oTpl )); $aStrings = self::getDispatcher()->triggerEvent('beforePageContent', $oContext); if (!empty($aStrings)) { $result = join('\n', $aStrings); } return $result; } The self::getDispatcher()->triggerEvent() function is in EventDispatcher.php and the function is below: public function triggerEvent($eventName, OX_Admin_UI_Event_EventContext $context) { $aCallbacks = $this->getRegisteredListeners($eventName); //enhance context with event name $context->eventName = $eventName; $result = array(); //invoke event on listener and collect results foreach ($aCallbacks as $callback) { $result[] = call_user_func($callback, $context); } return $result; } According to my understanding, the call_user_func() finally execute the function is 'beforePageContent' but the function 'beforePageContent' seems has nothing connected with the html and css files, so I do not know where to call these UI file(htm,css,js) ? Thanks to anyone can help me about this question!
  2. It's possible with Js invocation code by adding what parameter: document.write ("?campaignid=20&amp;what=135"); Is it also possible with Async code? I tried something like this: <ins data-revive-zoneid="20" data-revive-what="135" data-revive-id="7b688cbc1393bd0a30159029589233f9"></ins> but data-revice-what seems to be unused.
  3. This is NOT a rant against Revive. Revive has what appears to be a solid, well tested, codebase which people can extend using a clean plugin interface. I am talking here about available plugins for common, and lacking, functionality in the core. Simply, I'm trying to extend a Revive installation to handle advertiser billing, and advertiser/publisher registration, and publisher revenue share, and so forth. You'd think this would be easy with an ADs server. I've now tried 3 different plugin providers (the only ones I can find which offer any kind of plugins to do the job). I'm NOT going to name names, here, as I think that's counter-productive, but I am going to post a couple of examples to demonstrate the kinds of problems we (as end users) are up against, and which the Revive community could perhaps consider addressing. 1. using short php tags: [php5:error] [pid 8509] [client 127.0.0.1:60745] PHP Parse error: syntax error, unexpected end of file in /home/adsman/revive/www/admin/account-settings-banner-approve.php on line 125, referer: http://srv.localhost/www/admin/account-settings-plugins.php https://kovshenin.com/2012/reminder-dont-use-the-short-php-open-tag/ 2. Installation instructions in one module say to apply "SQL.sql" against the database and in the next module it's "sql.sql" 3. Installation instructions in one module say to copy all the files manually from the "lib-OA/" directory into "lib/OA/", and in the next module it's "lib_OA/" into "lib/OA/". 4. The descriptions, and instructions, are written in such poor English, it's very difficult to tell one product from another, or even precisely what their functionality actually is. It doesn't matter where you come from, *everybody* knows you need a "native speaker" to proof-read the final for-public-consumption documentation. This is also discussed here in the following link. http://forum.revive-adserver.com/topic/542-billing-and-payment/#entry4158 Eg: You may registerd with us after this period. Eg: in right top corner you can able to see “Working as” ? click it Eg: Upload below files with respectively attached file in”lib/OA/Admin/Menu” folder. There's just no need/excuse for this. 5. The modules are not coded as plugins, (to be installed using the existing Revive plugins import functionality), but instead one has to copy the file across manually, leading to unreliability and potential copying errors. 6. When the files from one module are copied over existing files which another module happens to use, the functionality from the existing module is (obviously) lost...! There appears to be no understanding of the distinctness of the term "modular". 7. There seems to be no concept of testing code, or QA against user experience. The items above may even be quite acceptable to script kiddies or apprentice programmers, (clearly they are acceptable to the devs and their managers), but, imho, this standard of quality is indicative of sloppy work crassly implemented by people who couldn't care less. and so it goes on. So, this rant is concerning plugin providers who "provide" badly described, under-documented, code which, when installed manually (because automatic is unsupported), destroys existing functionality and leaves a broken system. The end user is expected to "merge" these files correctly, such that the intended operation is restored, even though the code is of such a high quality that it is "protected" by obfuscation, making any sensible debugging approach quite impossible. I've purchased 3 or 4 modules and have lost count of the number of (quite unnecessary) bugs I've reported. Now, you might say to me, "code it yourself then". Well, yes, and I intend to improve my PHP such that I am able to sort some of these problems out myself, in the future. In the short term, I have to rely on plugin "providers" who do NOT do what they say on the box. In the long term, what do we expect to happen when the payment intermediary (paypal etc.) changes their protocol and module support is requested from the existing providers based on prior experience? I'll say it again: I LIKE Revive!, it's largely a very tidy codebase, (with perhaps a little bit of cruft here and there, but who's looking). Revive is great, open-source is great. The *available* plugins facilitators appear to be a very different breed. If I had any hair left, I'd pull it out. Rant over.
  4. Hi Can anyone give me the invocation code for inline video ads? The one in - documentation/zones - doesn't seem to work. [securityErrorEvent type=securityError" bubbles=false cancelable=false eventPhase=2 text="Error #2048] Maybe nobody knows how to do it.... Any help would be greatly appreciated if there is anyone that can make it happen.
  5. Hello, I'm using Revive for a website that was setup using Joomla. I can't seem to find where I should be placing the invocation code within the files as Joomla uses modules/module types. Any help is greatly appreciated. Cheers in advance!
  6. I'd thought my upgrade from OpenX to Revive had gone through successfully, but I see how that it hadn't. While ads are being served, no impressions are being logged (though the cron-job for maintenance is running hourly). The error log in the "var" folder contains loads of errors, all of the type "Failed to find package definition file" all in reference to the old OpenX "plugins" directory. When I set logging to include line numbers, the following sorts of lines were referenced for each "plugins" problem file: on line 72 of "/home/account_name/public_html/adserver_folder/lib/OX/Maintenance.php" on line 62 of "/home/account_name/public_html/adserver_folder/lib/OA/Maintenance/Auto.php" on line 3222 of "/home/account_name/public_html/adserver_folder/www/delivery/lg.php" on line 82 of "/home/account_name/public_html/adserver_folder/lib/OX/Maintenance.php" on line 62 of "/home/account_name/public_html/adserver_folder/lib/OA/Maintenance/Auto.php" on line 3222 of "/home/account_name/public_html/adserver_folder/www/delivery/lg.php" on line 96 of "/home/account_name/public_html/adserver_folder/lib/OX/Plugin/ComponentGroupManager.php" on line 109 of "/home/account_name/public_html/adserver_folder/lib/OX/Plugin/ComponentGroupManager.php" on line 900 of "/home/account_name/public_html/adserver_folder/lib/OX/Plugin/PluginManager.php" on line 998 of "/home/account_name/public_html/adserver_folder/lib/OX/Plugin/PluginManager.php" on line 983 of "/home/account_name/public_html/adserver_folder/lib/OX/Plugin/PluginManager.php" on line 54 of "/home/account_name/public_html/adserver_folder/lib/OX/Maintenance/Statistics/Task/SummariseIntermediate.php" on line 174 of "/home/account_name/public_html/adserver_folder/lib/OX/Maintenance/Statistics.php" on line 140 of "/home/account_name/public_html/adserver_folder/lib/OX/Maintenance.php" on line 105 of "/home/account_name/public_html/adserver_folder/lib/OX/Maintenance.php" ...where "account_name" is the hosting-provider's name for the directory holding my domain, and "adserver_folder" is the directory containing the Revive installation. Yes, the same line may be referenced more than once for a given error. I have tried switching back to my old installation folder (containing the OpenX installation) by renaming the folders. The ads still serve, but logging isn't working on the old installation now, either. Update: After running the cron-job a few more times (??), the logging has resumed on the old OpenX installation. But I'd still like to upgrade, so this is only a stop-gap. Also, when I tried to check the invocation code under the new Revive installation, the software returned error coding: MESSAGE: ksort() expects parameter 1 to be array, null given TYPE: Warning FILE: /home/account_name/public_html/adserver_folder/lib/max/Admin/Invocation.php LINE: 290 DEBUG INFO: 285 'name' => $invocationTag->getName() 286 ); 287 } 288 } 289 290 ksort($aOrderedComponents); 291 foreach ($aOrderedComponents as $order => $aComponent) { 292 $allowed[$aComponent['pluginKey']] = $aComponent['isAllowed']; 293 } 294 295 if (!isset($this->codetype) || $allowed[$this->codetype] == false) { MESSAGE: Invalid argument supplied for foreach() TYPE: Warning FILE: /home/account_name/public_html/adserver_folder/lib/max/Admin/Invocation.php LINE: 291 DEBUG INFO: 286 ); 287 } 288 } 289 290 ksort($aOrderedComponents); 291 foreach ($aOrderedComponents as $order => $aComponent) { 292 $allowed[$aComponent['pluginKey']] = $aComponent['isAllowed']; 293 } 294 295 if (!isset($this->codetype) || $allowed[$this->codetype] == false) { 296 foreach ($allowed as $codetype => $isAllowed) { MESSAGE: Invalid argument supplied for foreach() TYPE: Warning FILE: /home/account_name/public_html/adserver_folder/lib/max/Admin/Invocation.php LINE: 315 DEBUG INFO: 310 311 $buffer .= ""; 312 $buffer .= "codetype == $pluginKey ? ' selected' : '').">".$invocationTagName." (The coding above has been anonymised in the manner explained earlier.) The old (OpenX) installation still displays the invocation coding correctly. Advice? Thank you. Eliz.
×
×
  • Create New...