WordPress.org

Support

Support » Plugins and Hacks » [Resolved] Default AdCode

[Resolved] Default AdCode

Viewing 6 replies - 1 through 6 (of 6 total)
  • For fix the problem i have added a javascript code in my template:

    function adrotate_default() {
    	if($_GET['page']=='adrotate-ads') {
    		echo '<script type="text/javascript">
    		jQuery(document).ready(function() {
    			if (jQuery("#adrotate_bannercode").text() == "") {
    			jQuery("#adrotate_bannercode").text("<a href=\'%link%\'><img src=\'%image%\' /></a>");
    			}
    		});
    		</script>';
    	}
    }
    
    add_filter('admin_head', 'adrotate_default');

    iGenius
    Member

    @igenius

    This will be a nice feature!!

    Great!!

    Plugin Author Arnan de Gans
    Participant

    @adegans

    my solution is better because my staff does not know html, so they have less of the steps to add a new banner

    my solution is better because my staff does not know html, so they have less of the steps to add a new banner…

    Plugin Author Arnan de Gans
    Participant

    @adegans

    Until an ad is different from your ‘template’ or when your theme has an update and overwrites your functions.php (and thus your edit) 😉

    But sure, your method has less clicking to achieve a similar result.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘[Resolved] Default AdCode’ is closed to new replies.