Banners aren't happening for us, including the positioning which alters when you're using a small low resolution monitor or a huge high resolution display. So let's forget the Dolphin internal banners system for now. I'm still searching for the code to inject a graphic (hard-coded) next to the logo position - a banner style image, alongside the logo. The position would remain constant regardless of the window/monitor size and would be 100% reliable. Any ideas? Thanks!
Something like this:
 |
Just a thought here... but I'm wondering if one might be able to manipulate the quotes module/block to place a banner in the header?
I used it to insert a background image to the right of my logo, you might be able to use it to inject some HTML code for a banner?
Skype: shawn.nelson |
We tried that before, to no avail - good suggestion though :) |
We tried that before, to no avail - good suggestion though :)
LIke this? http://webcamyourface.com/
ManOfTeal.COM a Proud UNA site, six years running strong! |
No. Your site's advert (I assume it's yours) is locked to the right-hand site of the browser. On a high res monitor the site is in the middle and your banner is over there on the right. On a low-res monitor the banner is forced to overlap your logo. This is the issue I'm trying to address. At the moment our banners are doing what yours are doing and it doesn't look pro. See attachments. |
your right but for most site users are at the res I use. 1280x1024, I hope we can find a solution.
site users from statcounter
| |
2844 |
40.12% |
Unknown |
|
2020 |
28.50% |
1280x1024 |
|
1623 |
22.90% |
1024x768 |
|
307 |
4.33% |
1600x1200 |
|
144 |
2.03% |
1152x864 |
|
141 |
1.99% |
800x600 |
|
9 |
0.13% |
640x480 |
ManOfTeal.COM a Proud UNA site, six years running strong! |
Assuming the injection_logo_after injection point has not been removed from whatever template your currently running, then this is easy.
Run the following query in phpMyAdmin
INSERT INTO `sys_injections` (`name`, `page_index`, `key`, `type`, `data`, `replace`, `active`) VALUES ('my_injection_01', 0, 'injection_logo_after', 'text', '<div style="margin-top:12px;margin-right:12px;float:right;"><img src="http://www.deanbassett.com/images/468x60.gif"></div>', 0, 1)
Replace the above banner URL with your actual banner URL.
This injection is for a 468x60 banner image.
The margins may need to be adjusted depending on size of logo and size of banner being used.
I tested this on my site. So i know it works.
EDIT: I forgot to mention. The cache needs to be cleared after this is inserted.
https://www.deanbassett.com |
Yes, hopefully there will be a more definite solution than merely hoping users will use a certain resolution. The banners positioning has always been shaky. A definite banner position would be better - it must be possible, if someone has the right code.
Just for your info, and to reassure us both, here is our site's data from a larger sample (the previous one million visitors):
1. 1280x800 - 22.92%
2. 1024x768 - 20.91% 3. 1366x768 - 12.32%
|
Excellent, deano92964 - you've saved the day! And the end of my pissing around with positioning. Brilliant, many thanks for such a great little bit of code! I can also confirm this functions correctly with OpenX banner code. I do hope this thread will help others. |
Welcome.
I am actually working on a new module to replace the quotes module that will allow the insertion of various different types of code there.
Banners, logon boxes, paypal donation buttons, ect. Not all able to be displayed at the same time of course, but the ability to easily be able to change code from in admin and have different code used for members and guests.
https://www.deanbassett.com |
That would be a welcome addition, certainly. However, for now, your above code works a treat. |
Of course, with a manual injection inserted as you just did, you will need to remember you did it. If you ever want to go back to using the quotes module, or another module to take the place of the quotes position then that injection will need to be removed.
Thats the problem with doing things manually. Remembering what has been done.
https://www.deanbassett.com |
Exactly. I've renamed the injection to a more obvious title and subscribed to this thread along with logging it down - as with another post I made earlier, if anyone's reading this... backup, backup, backup... and write down modifications. Dolphinmania can strike at any time! |
Ha! Leave it to deano to come up with a fix that I never even thought about. Using the database never once occurred to me as I just wasted an hour away working on what I thought would be a fairly easy task. Can't wait for the quotes mod. Maybe you could add a feature that allows to adust height, width and text alignment of the quotes. Just a thought. |
Assuming the injection_logo_after injection point has not been removed from whatever template your currently running, then this is easy.
Run the following query in phpMyAdmin
INSERT INTO `sys_injections` (`name`, `page_index`, `key`, `type`, `data`, `replace`, `active`) VALUES ('my_injection_01', 0, 'injection_logo_after', 'text', '<div style="margin-top:12px;margin-right:12px;float:right;"><img src="http://www.deanbassett.com/images/468x60.gif"></div>', 0, 1)
Replace the above banner URL with your actual banner URL.
This injection is for a 468x60 banner image.
The margins may need to be adjusted depending on size of logo and size of banner being used.
I tested this on my site. So i know it works.
EDIT: I forgot to mention. The cache needs to be cleared after this is inserted.
How will this work for a google banner?
Can I put the adsense code there in place of:
<div style="margin-top:12px;margin-right:12px;float:right;"><script type="text/javascript"><!-- google_ad_client = "pub-xxxxxxxxxxxx"; /* 468x60, created 2/11/11 */ google_ad_slot = "xxxxxxxx"; google_ad_width = 468; google_ad_height = 60; //--> </script> <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script></div>
ManOfTeal.COM a Proud UNA site, six years running strong! |
Yes, we did the same but with OpenX code - try it and see, you can always just change it in the data field in the sys_injections table to make it right for your code. |
Thanks JoeWa, I will try on a test site first.
[edit] :\ Thanks Deano!!!
ManOfTeal.COM a Proud UNA site, six years running strong! |