Today, I’m going to follow up with a few in depth answers to a recent email I received. The sender used my contact form here and asked for help using the AdRotate plugin in response to my previous post about it. I attempted to email them back, but unfortunately the email address they gave me didn’t work. In light of that however, all of you benefit!
First, if you’re having trouble with something outside of the scope of what my three adrotate tutorials cover, please feel free to start by checking out the AdRotate manuals that cover all the popular features when using AdRotate. If you don’t find your answer there, you’re welcome to ask in the comments here and, if I can answer it simply I will. Or if you’d prefer to have a one-on-one lesson in using this (and possibly other plugins), feel free to contact me and I’ll set you up with a quote for a training session.
Ad Spacing Issues
The reader’s first problem was getting the ads to center or show up where they wanted them to. Since my ads are pretty much always going to already be the size that fits perfectly (or close) within my space, I only encountered this problem when using “Blocks” of ads.
When you do not add parameters for spacing within the blocks they will squish together and just look nasty. In the screenshot below you will see how I added a little html for a span style within the block management option under “wrapper code” (see yellow highlights). These settings create the spacing you see in the image to the left of this paragraph (I added a border around the image to try and help the spacing stand out).
As far as any other spacing changes within any of the management areas of the AdRotate plugin, I personally have not needed to change anything.
That said, for individual ads you can (in theory) add html similar to that seen in the image above, to the html code for the ad in the “ad code” section for each ad (see image right).
Note: For groups there are not any setting changes that you can make to adjust margins or spacing.
Using AdRotate Outside of Widgets
One of the things that is most appealing about the AdRotate plugin is how very easy it is to use throughout the widgeted areas of your site… virtually “plug and go” if you will. But, that doesn’t mean that it will come without the need to know how to place code within your theme if you want the ads to show up in places that are not “widgeted”.
Warning: if your eyes are beginning to glaze over and your brain feels a little fuzzy and you are beginning to think I’m no longer speaking English, stick with widgets… it will be your best friend!
AdRotate has it’s own code that will allow you to place it not only within widgets, but also at the end of your posts (you have to manually insert at the end to do this – hint: I use another plugin for static banner ads to display at the end of each post!). Again, it’s worth mentioning to make sure you check out the manuals for AdRotate for more on all of this but here’s the basic gist of it.
Posts and Pages – Shortcode
AdRotate generates shortcodes that you can use in Posts or Pages (that is the ONLY place these shortcodes will work). To the right is a shortcode example from the AdRotate manual. Shortcodes within wordpress are always within brackets [ ].
Site-Wide Code – PHP
Yep, you can definitely do that! In an effort not to re-invent the wheel, I am going to send you to this page on the AdRotate site for all the specifics (start about halfway down the page… after the shortcode explanation).
But again, the gist of it is to make a note of the number (group, ad, or block – as referenced in my tutorials) and then you will be adding the matching PHP code on the appropriate index.php, page.php or single.php of your theme, within your theme editor.
Simple right? Ok, so I’ll admit that although the options to use this virtually anywhere on your site is super cool, it really isn’t going to be everyone’s cup of tea to even consider diving into some of the more complicated parts of the site. But, if you stick to the widgets and use this plugin to it’s true potential the time you put into getting the ads setup will really pay off in a beautiful setup for your ads!
Again, if you have any other questions or need help, please feel free to ask them here or contact me via the contact form (please be sure the email entered is answerable and a link to your site is always helpful if you are exampling a problem you are having!).